[3/5] drm/i915: Remove dead weight from hdcp2_msg_timeout[]
diff mbox series

Message ID 20191010145127.7487-3-ville.syrjala@linux.intel.com
State New
Headers show
Series
  • [1/5] drm/i915: Shrink eDRAM ways/sets arrays
Related show

Commit Message

Ville Syrjälä Oct. 10, 2019, 2:51 p.m. UTC
From: Ville Syrjälä <ville.syrjala@linux.intel.com>

The .read_2_2() hooks is never called for any of the message
types with a zero timeout. So it's all just dead weight which
we can chuck.

    text	   data	    bss	    dec	    hex	filename
-  34701	    360	      0	  35061	   88f5	intel_hdmi.o
+  34633	    360	      0	  34993	   88b1	intel_hdmi.o

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
 drivers/gpu/drm/i915/display/intel_hdmi.c | 7 -------
 1 file changed, 7 deletions(-)

Comments

Ramalingam C Oct. 17, 2019, 7:02 a.m. UTC | #1
On 2019-10-10 at 17:51:25 +0300, Ville Syrjala wrote:
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> 
> The .read_2_2() hooks is never called for any of the message
> types with a zero timeout. So it's all just dead weight which
> we can chuck.
> 
>     text	   data	    bss	    dec	    hex	filename
> -  34701	    360	      0	  35061	   88f5	intel_hdmi.o
> +  34633	    360	      0	  34993	   88b1	intel_hdmi.o
> 
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>

Timeout is added for supporting msgs read. These msgs with 0 timeout
are only written. Hence can be removed from the timeout table.

Reviwed-by: Ramalingam C < ramalingam.c@intel.com>

> ---
>  drivers/gpu/drm/i915/display/intel_hdmi.c | 7 -------
>  1 file changed, 7 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/display/intel_hdmi.c b/drivers/gpu/drm/i915/display/intel_hdmi.c
> index 13c588ae88a4..8a574be86bc6 100644
> --- a/drivers/gpu/drm/i915/display/intel_hdmi.c
> +++ b/drivers/gpu/drm/i915/display/intel_hdmi.c
> @@ -1534,19 +1534,12 @@ struct hdcp2_hdmi_msg_timeout {
>  };
>  
>  static const struct hdcp2_hdmi_msg_timeout hdcp2_msg_timeout[] = {
> -	{ HDCP_2_2_AKE_INIT, 0, 0 },
>  	{ HDCP_2_2_AKE_SEND_CERT, HDCP_2_2_CERT_TIMEOUT_MS, 0 },
> -	{ HDCP_2_2_AKE_NO_STORED_KM, 0, 0 },
> -	{ HDCP_2_2_AKE_STORED_KM, 0, 0 },
>  	{ HDCP_2_2_AKE_SEND_HPRIME, HDCP_2_2_HPRIME_PAIRED_TIMEOUT_MS,
>  	  HDCP_2_2_HPRIME_NO_PAIRED_TIMEOUT_MS },
>  	{ HDCP_2_2_AKE_SEND_PAIRING_INFO, HDCP_2_2_PAIRING_TIMEOUT_MS, 0 },
> -	{ HDCP_2_2_LC_INIT, 0, 0 },
>  	{ HDCP_2_2_LC_SEND_LPRIME, HDCP_2_2_HDMI_LPRIME_TIMEOUT_MS, 0 },
> -	{ HDCP_2_2_SKE_SEND_EKS, 0, 0 },
>  	{ HDCP_2_2_REP_SEND_RECVID_LIST, HDCP_2_2_RECVID_LIST_TIMEOUT_MS, 0 },
> -	{ HDCP_2_2_REP_SEND_ACK, 0, 0 },
> -	{ HDCP_2_2_REP_STREAM_MANAGE, 0, 0 },
>  	{ HDCP_2_2_REP_STREAM_READY, HDCP_2_2_STREAM_READY_TIMEOUT_MS, 0 },
>  };
>  
> -- 
> 2.21.0
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx

Patch
diff mbox series

diff --git a/drivers/gpu/drm/i915/display/intel_hdmi.c b/drivers/gpu/drm/i915/display/intel_hdmi.c
index 13c588ae88a4..8a574be86bc6 100644
--- a/drivers/gpu/drm/i915/display/intel_hdmi.c
+++ b/drivers/gpu/drm/i915/display/intel_hdmi.c
@@ -1534,19 +1534,12 @@  struct hdcp2_hdmi_msg_timeout {
 };
 
 static const struct hdcp2_hdmi_msg_timeout hdcp2_msg_timeout[] = {
-	{ HDCP_2_2_AKE_INIT, 0, 0 },
 	{ HDCP_2_2_AKE_SEND_CERT, HDCP_2_2_CERT_TIMEOUT_MS, 0 },
-	{ HDCP_2_2_AKE_NO_STORED_KM, 0, 0 },
-	{ HDCP_2_2_AKE_STORED_KM, 0, 0 },
 	{ HDCP_2_2_AKE_SEND_HPRIME, HDCP_2_2_HPRIME_PAIRED_TIMEOUT_MS,
 	  HDCP_2_2_HPRIME_NO_PAIRED_TIMEOUT_MS },
 	{ HDCP_2_2_AKE_SEND_PAIRING_INFO, HDCP_2_2_PAIRING_TIMEOUT_MS, 0 },
-	{ HDCP_2_2_LC_INIT, 0, 0 },
 	{ HDCP_2_2_LC_SEND_LPRIME, HDCP_2_2_HDMI_LPRIME_TIMEOUT_MS, 0 },
-	{ HDCP_2_2_SKE_SEND_EKS, 0, 0 },
 	{ HDCP_2_2_REP_SEND_RECVID_LIST, HDCP_2_2_RECVID_LIST_TIMEOUT_MS, 0 },
-	{ HDCP_2_2_REP_SEND_ACK, 0, 0 },
-	{ HDCP_2_2_REP_STREAM_MANAGE, 0, 0 },
 	{ HDCP_2_2_REP_STREAM_READY, HDCP_2_2_STREAM_READY_TIMEOUT_MS, 0 },
 };