diff options
author | Rui Miguel Silva <rmfrfs@gmail.com> | 2017-05-12 21:16:15 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-05-16 14:23:31 +0200 |
commit | 50b7c322cfc8b44a36b1373dab2177db23e3282c (patch) | |
tree | cca951e511cf8d6c1f229c0a938adb390a738c19 /drivers/fpga/fpga-region.c | |
parent | f0d39a179b9cd38c739acfc4f92720a0c79e1d66 (diff) |
staging: typec: fusb302: refactor resume retry mechanism
The i2c functions need to test the pm_suspend state and do, if needed, some
retry before i2c operations. This code was repeated 4x.
To isolate this, create a new function to check suspend state and call it in
every need place.
As at it, move the error message from pr_err to dev_err.
Signed-off-by: Rui Miguel Silva <rmfrfs@gmail.com>
Acked-by: Yueyao Zhu <yueyao.zhu@gmail.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/fpga/fpga-region.c')
0 files changed, 0 insertions, 0 deletions