> >> I2C_M_RD is defined as 1, probably (msg->flags & I2C_M_RD) is good > >> enough here. > > > > Today is 1, tomorrow is 0x80, so, I would stay as I put in the initial > > fix. > > I believe I2C_M_RD will never get any other value than 1, since this > value is deliberately set to 1 and it is in active use by userspace > applications for years, nobody intends to break ABI tomorrow. I agree. That is one thing that permanently slips through the cracks, but I wanted to add a comment saying the I2C_M_RD is guaranteed to be 1 and then simplify the drivers. Maybe I should start with the comment right now...
Attachment:
signature.asc
Description: Digital signature