diff options
| author | Thomas Gleixner <tglx@linutronix.de> | 2018-06-22 21:20:35 +0200 | 
|---|---|---|
| committer | Thomas Gleixner <tglx@linutronix.de> | 2018-06-22 21:20:35 +0200 | 
| commit | 7731b8bc94e599c9a79e428f3359ff2c34b7576a (patch) | |
| tree | 879f18ccbe274122f2d4f095b43cbc7f953e0ada /drivers/gpu/drm/drm_dp_mst_topology.c | |
| parent | 48e315618dc4dc8904182cd221e3d395d5d97005 (diff) | |
| parent | 9ffc59d57228d74809700be6f7ecb1db10292f05 (diff) | |
Merge branch 'linus' into x86/urgent
Required to queue a dependent fix.
Diffstat (limited to 'drivers/gpu/drm/drm_dp_mst_topology.c')
| -rw-r--r-- | drivers/gpu/drm/drm_dp_mst_topology.c | 9 | 
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/gpu/drm/drm_dp_mst_topology.c b/drivers/gpu/drm/drm_dp_mst_topology.c index 6fac4129e6a2..658830620ca3 100644 --- a/drivers/gpu/drm/drm_dp_mst_topology.c +++ b/drivers/gpu/drm/drm_dp_mst_topology.c @@ -2941,12 +2941,14 @@ static void drm_dp_mst_dump_mstb(struct seq_file *m,  	}  } +#define DP_PAYLOAD_TABLE_SIZE		64 +  static bool dump_dp_payload_table(struct drm_dp_mst_topology_mgr *mgr,  				  char *buf)  {  	int i; -	for (i = 0; i < 64; i += 16) { +	for (i = 0; i < DP_PAYLOAD_TABLE_SIZE; i += 16) {  		if (drm_dp_dpcd_read(mgr->aux,  				     DP_PAYLOAD_TABLE_UPDATE_STATUS + i,  				     &buf[i], 16) != 16) @@ -3015,7 +3017,7 @@ void drm_dp_mst_dump_topology(struct seq_file *m,  	mutex_lock(&mgr->lock);  	if (mgr->mst_primary) { -		u8 buf[64]; +		u8 buf[DP_PAYLOAD_TABLE_SIZE];  		int ret;  		ret = drm_dp_dpcd_read(mgr->aux, DP_DPCD_REV, buf, DP_RECEIVER_CAP_SIZE); @@ -3033,8 +3035,7 @@ void drm_dp_mst_dump_topology(struct seq_file *m,  		seq_printf(m, " revision: hw: %x.%x sw: %x.%x\n",  			   buf[0x9] >> 4, buf[0x9] & 0xf, buf[0xa], buf[0xb]);  		if (dump_dp_payload_table(mgr, buf)) -			seq_printf(m, "payload table: %*ph\n", 63, buf); - +			seq_printf(m, "payload table: %*ph\n", DP_PAYLOAD_TABLE_SIZE, buf);  	}  	mutex_unlock(&mgr->lock);  | 
