diff options
author | Lars Poeschel <poeschel@lemonage.de> | 2019-11-13 14:50:22 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-11-13 12:15:03 -0800 |
commit | 1e37be7d27d086ca72c38af14a9783eb9d7e9fa9 (patch) | |
tree | 3939db915c22bbabb562fd07098289ec93f8c591 /drivers/nfc/pn533/pn533.h | |
parent | d73cfd4283d9090b45337a93dddc43848039f14b (diff) | |
download | lwn-1e37be7d27d086ca72c38af14a9783eb9d7e9fa9.tar.gz lwn-1e37be7d27d086ca72c38af14a9783eb9d7e9fa9.zip |
nfc: pn533: pn533_phy_ops dev_[up, down] return int
Change dev_up and dev_down functions of struct pn533_phy_ops to return
int. This way the pn533 core can report errors in the phy layer to upper
layers.
The only user of this is currently uart.c and it is changed to report
the error of a possibly failing call to serdev_device_open.
Reported-by: coverity-bot <keescook+coverity-bot@chromium.org>
Addresses-Coverity-ID: 1487395 ("Error handling issues")
Fixes: c656aa4c27b1 ("nfc: pn533: add UART phy driver")
Signed-off-by: Lars Poeschel <poeschel@lemonage.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/nfc/pn533/pn533.h')
-rw-r--r-- | drivers/nfc/pn533/pn533.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/nfc/pn533/pn533.h b/drivers/nfc/pn533/pn533.h index b66f02a53167..5f94f38a2a08 100644 --- a/drivers/nfc/pn533/pn533.h +++ b/drivers/nfc/pn533/pn533.h @@ -224,8 +224,8 @@ struct pn533_phy_ops { * bring up it's interface to the chip and have it suspended for power * saving reasons otherwise. */ - void (*dev_up)(struct pn533 *priv); - void (*dev_down)(struct pn533 *priv); + int (*dev_up)(struct pn533 *priv); + int (*dev_down)(struct pn533 *priv); }; |