diff mbox series

[06/10] drm/i915/hdcp: convert to struct drm_device based logging.

Message ID 47d5e88dedc08ee48938344296ada550dedd5f90.1583766715.git.jani.nikula@intel.com (mailing list archive)
State New, archived
Headers show
Series drm/i915/display: conversion to drm_device based logging macros | expand

Commit Message

Jani Nikula March 10, 2020, 8:52 a.m. UTC
From: Wambui Karuga <wambui.karugax@gmail.com>

Converts various instances of the printk based drm logging macros to the
struct drm_device based logging macros in i915/display/intel_hdcp.c.
This also involves extracting the drm_i915_private device from the
intel_connector type for use in the macros.

v2 by Jani:
- rebase

Signed-off-by: Wambui Karuga <wambui.karugax@gmail.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
---
 drivers/gpu/drm/i915/display/intel_hdcp.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Wambui Karuga March 18, 2020, 2:46 p.m. UTC | #1
On Tue, 10 Mar 2020, Jani Nikula wrote:

> From: Wambui Karuga <wambui.karugax@gmail.com>
>
> Converts various instances of the printk based drm logging macros to the
> struct drm_device based logging macros in i915/display/intel_hdcp.c.
> This also involves extracting the drm_i915_private device from the
> intel_connector type for use in the macros.
>
> v2 by Jani:
> - rebase
>
> Signed-off-by: Wambui Karuga <wambui.karugax@gmail.com>
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>

Reviewed-by: Wambui Karuga <wambui.karugax@gmail.com>
> ---
> drivers/gpu/drm/i915/display/intel_hdcp.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_hdcp.c b/drivers/gpu/drm/i915/display/intel_hdcp.c
> index ee0f27ea2810..cd3b686980b2 100644
> --- a/drivers/gpu/drm/i915/display/intel_hdcp.c
> +++ b/drivers/gpu/drm/i915/display/intel_hdcp.c
> @@ -1391,6 +1391,7 @@ static
> int hdcp2_propagate_stream_management_info(struct intel_connector *connector)
> {
> 	struct intel_digital_port *intel_dig_port = intel_attached_dig_port(connector);
> +	struct drm_i915_private *i915 = to_i915(connector->base.dev);
> 	struct intel_hdcp *hdcp = &connector->hdcp;
> 	union {
> 		struct hdcp2_rep_stream_manage stream_manage;
> @@ -1431,7 +1432,7 @@ int hdcp2_propagate_stream_management_info(struct intel_connector *connector)
> 	hdcp->seq_num_m++;
>
> 	if (hdcp->seq_num_m > HDCP_2_2_SEQ_NUM_MAX) {
> -		DRM_DEBUG_KMS("seq_num_m roll over.\n");
> +		drm_dbg_kms(&i915->drm, "seq_num_m roll over.\n");
> 		return -1;
> 	}
>
> -- 
> 2.20.1
>
>
diff mbox series

Patch

diff --git a/drivers/gpu/drm/i915/display/intel_hdcp.c b/drivers/gpu/drm/i915/display/intel_hdcp.c
index ee0f27ea2810..cd3b686980b2 100644
--- a/drivers/gpu/drm/i915/display/intel_hdcp.c
+++ b/drivers/gpu/drm/i915/display/intel_hdcp.c
@@ -1391,6 +1391,7 @@  static
 int hdcp2_propagate_stream_management_info(struct intel_connector *connector)
 {
 	struct intel_digital_port *intel_dig_port = intel_attached_dig_port(connector);
+	struct drm_i915_private *i915 = to_i915(connector->base.dev);
 	struct intel_hdcp *hdcp = &connector->hdcp;
 	union {
 		struct hdcp2_rep_stream_manage stream_manage;
@@ -1431,7 +1432,7 @@  int hdcp2_propagate_stream_management_info(struct intel_connector *connector)
 	hdcp->seq_num_m++;
 
 	if (hdcp->seq_num_m > HDCP_2_2_SEQ_NUM_MAX) {
-		DRM_DEBUG_KMS("seq_num_m roll over.\n");
+		drm_dbg_kms(&i915->drm, "seq_num_m roll over.\n");
 		return -1;
 	}