summaryrefslogtreecommitdiff
path: root/drivers/nfc/fdp/i2c.c
diff options
context:
space:
mode:
authorKrzysztof Kozlowski <krzysztof.kozlowski@canonical.com>2021-07-25 00:47:36 +0300
committerDavid S. Miller <davem@davemloft.net>2021-07-25 11:21:21 +0300
commit7a5e98daf6bdba5822aa274f8555199361060658 (patch)
tree0622155e537a6520daa59b636eae9c3efcdd9903 /drivers/nfc/fdp/i2c.c
parentcb8caa3c6c04c18027258ab34e09bcf87e726f22 (diff)
downloadlinux-7a5e98daf6bdba5822aa274f8555199361060658.tar.xz
nfc: constify nfc_phy_ops
Neither the core nor the drivers modify the passed pointer to struct nfc_phy_ops (consisting of function pointers), so make it a pointer to const for correctness and safety. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/nfc/fdp/i2c.c')
-rw-r--r--drivers/nfc/fdp/i2c.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/nfc/fdp/i2c.c b/drivers/nfc/fdp/i2c.c
index c5596e514648..98e1876c9468 100644
--- a/drivers/nfc/fdp/i2c.c
+++ b/drivers/nfc/fdp/i2c.c
@@ -120,7 +120,7 @@ static int fdp_nci_i2c_write(void *phy_id, struct sk_buff *skb)
return r;
}
-static struct nfc_phy_ops i2c_phy_ops = {
+static const struct nfc_phy_ops i2c_phy_ops = {
.write = fdp_nci_i2c_write,
.enable = fdp_nci_i2c_enable,
.disable = fdp_nci_i2c_disable,