Skip to content

Commit da279eb

Browse files
committed
drm/dp: Implement I2C_M_STOP for i2c-over-aux
Consult the I2C_M_STOP flag to determine whether to set the MOT bit or not. Makes it possible to send multiple messages in one go with stop+start generated between the messages (as opposed nothing or repstart depending on whether thr address/rw changed). Not sure anyone has actual use for this but figured I'd handle it since I started to look at that flag for MST remote i2c xfers. Signed-off-by: Ville Syrjälä <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Reviewed-by: Dhinakaran Pandiyan <[email protected]>
1 parent b646744 commit da279eb

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

drivers/gpu/drm/drm_dp_helper.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -887,7 +887,8 @@ static void drm_dp_i2c_msg_set_request(struct drm_dp_aux_msg *msg,
887887
{
888888
msg->request = (i2c_msg->flags & I2C_M_RD) ?
889889
DP_AUX_I2C_READ : DP_AUX_I2C_WRITE;
890-
msg->request |= DP_AUX_I2C_MOT;
890+
if (!(i2c_msg->flags & I2C_M_STOP))
891+
msg->request |= DP_AUX_I2C_MOT;
891892
}
892893

893894
/*

0 commit comments

Comments
 (0)