Re: [PATCH v2 2/3] staging: typec: fusb302: reset i2c_busy state in error

2017-05-12 Thread Yueyao Zhu
Thanks for the catch! With the fix, should the `done` label be added before atomic_set(&chip->i2c_busy, 0); ? On Fri, May 12, 2017 at 2:38 AM, Rui Miguel Silva wrote: > Fix reset of i2c_busy flag if an error occurs during the i2c block read. > > Signed-off-by: Rui Miguel Silva > --- > drivers/s

[PATCH] staging: typec: fusb302: Fix chip->vbus_present init value

2017-05-04 Thread Yueyao Zhu
FUSB_REG_STATUS0 & FUSB_REG_STATUS0_VBUSOK = 0x40 & 0x80 is always zero. Fix the code to what it is intended to be: check the VBUSOK bit of the value read from address FUSB_REG_STATUS0. Reported-by: Dan Carpenter Cc: Guenter Roeck Signed-off-by: Yueyao Zhu --- drivers/staging/typec