drm/bridge: tc358767: Drop unnecessary 8 byte buffer
tc_get_display_props() never reads more than a byte via AUX, so there's no need to reserve 8 for that purpose. No function change intended. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Reviewed-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: Andrzej Hajda <a.hajda@samsung.com> Cc: Laurent Pinchart <Laurent.pinchart@ideasonboard.com> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: Andrey Gusakov <andrey.gusakov@cogentembedded.com> Cc: Philipp Zabel <p.zabel@pengutronix.de> Cc: Cory Tusar <cory.tusar@zii.aero> Cc: Chris Healy <cphealy@gmail.com> Cc: Lucas Stach <l.stach@pengutronix.de> Cc: dri-devel@lists.freedesktop.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Link: https://patchwork.freedesktop.org/patch/msgid/20190619052716.16831-14-andrew.smirnov@gmail.com
This commit is contained in:
parent
7264892648
commit
d174db0788
@ -636,8 +636,7 @@ err:
|
||||
static int tc_get_display_props(struct tc_data *tc)
|
||||
{
|
||||
int ret;
|
||||
/* temp buffer */
|
||||
u8 tmp[8];
|
||||
u8 reg;
|
||||
|
||||
/* Read DP Rx Link Capability */
|
||||
ret = drm_dp_link_probe(&tc->aux, &tc->link.base);
|
||||
@ -653,21 +652,21 @@ static int tc_get_display_props(struct tc_data *tc)
|
||||
tc->link.base.num_lanes = 2;
|
||||
}
|
||||
|
||||
ret = drm_dp_dpcd_readb(&tc->aux, DP_MAX_DOWNSPREAD, tmp);
|
||||
ret = drm_dp_dpcd_readb(&tc->aux, DP_MAX_DOWNSPREAD, ®);
|
||||
if (ret < 0)
|
||||
goto err_dpcd_read;
|
||||
tc->link.spread = tmp[0] & DP_MAX_DOWNSPREAD_0_5;
|
||||
tc->link.spread = reg & DP_MAX_DOWNSPREAD_0_5;
|
||||
|
||||
ret = drm_dp_dpcd_readb(&tc->aux, DP_MAIN_LINK_CHANNEL_CODING, tmp);
|
||||
ret = drm_dp_dpcd_readb(&tc->aux, DP_MAIN_LINK_CHANNEL_CODING, ®);
|
||||
if (ret < 0)
|
||||
goto err_dpcd_read;
|
||||
|
||||
tc->link.scrambler_dis = false;
|
||||
/* read assr */
|
||||
ret = drm_dp_dpcd_readb(&tc->aux, DP_EDP_CONFIGURATION_SET, tmp);
|
||||
ret = drm_dp_dpcd_readb(&tc->aux, DP_EDP_CONFIGURATION_SET, ®);
|
||||
if (ret < 0)
|
||||
goto err_dpcd_read;
|
||||
tc->link.assr = tmp[0] & DP_ALTERNATE_SCRAMBLER_RESET_ENABLE;
|
||||
tc->link.assr = reg & DP_ALTERNATE_SCRAMBLER_RESET_ENABLE;
|
||||
|
||||
dev_dbg(tc->dev, "DPCD rev: %d.%d, rate: %s, lanes: %d, framing: %s\n",
|
||||
tc->link.base.revision >> 4, tc->link.base.revision & 0x0f,
|
||||
|
Loading…
Reference in New Issue
Block a user