Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1716724 > unrolled thread
| Started by | Arvind Yadav <arvind.yadav.cs@gmail.com> |
|---|---|
| First post | 2017-08-21 19:10 +0200 |
| Last post | 2017-08-21 19:10 +0200 |
| Articles | 2 — 1 participant |
Back to article view | Back to linux.kernel
[PATCH 0/8] constify nfc i2c_device_id Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-21 19:10 +0200
[PATCH 8/8] nfc: st21nfca: constify i2c_device_id Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-21 19:10 +0200
| From | Arvind Yadav <arvind.yadav.cs@gmail.com> |
|---|---|
| Date | 2017-08-21 19:10 +0200 |
| Subject | [PATCH 0/8] constify nfc i2c_device_id |
| Message-ID | <ugYn7-79B-3@gated-at.bofh.it> |
i2c_device_id are not supposed to change at runtime. All functions working with i2c_device_id provided by <linux/i2c.h> work with const i2c_device_id. So mark the non-const structs as const. Arvind Yadav (8): [PATCH 1/8] nfc: microread: constify i2c_device_id [PATCH 2/8] nfc: nfcmrvl: constify i2c_device_id [PATCH 3/8] nfc: nxp-nci: constify i2c_device_id [PATCH 4/8] nfc: pn533: constify i2c_device_id [PATCH 5/8] nfc: pn544: constify i2c_device_id [PATCH 6/8] nfc: s3fwrn5: constify i2c_device_id [PATCH 7/8] nfc: st-nci: constify i2c_device_id [PATCH 8/8] nfc: st21nfca: constify i2c_device_id drivers/nfc/microread/i2c.c | 2 +- drivers/nfc/nfcmrvl/i2c.c | 2 +- drivers/nfc/nxp-nci/i2c.c | 2 +- drivers/nfc/pn533/i2c.c | 2 +- drivers/nfc/pn544/i2c.c | 2 +- drivers/nfc/s3fwrn5/i2c.c | 2 +- drivers/nfc/st-nci/i2c.c | 2 +- drivers/nfc/st21nfca/i2c.c | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) -- 2.7.4
[toc] | [next] | [standalone]
| From | Arvind Yadav <arvind.yadav.cs@gmail.com> |
|---|---|
| Date | 2017-08-21 19:10 +0200 |
| Subject | [PATCH 8/8] nfc: st21nfca: constify i2c_device_id |
| Message-ID | <ugYn9-79B-31@gated-at.bofh.it> |
| In reply to | #1716724 |
i2c_device_id are not supposed to change at runtime. All functions
working with i2c_device_id provided by <linux/i2c.h> work with
const i2c_device_id. So mark the non-const structs as const.
Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
drivers/nfc/st21nfca/i2c.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/nfc/st21nfca/i2c.c b/drivers/nfc/st21nfca/i2c.c
index cd1f7bf..1b34709 100644
--- a/drivers/nfc/st21nfca/i2c.c
+++ b/drivers/nfc/st21nfca/i2c.c
@@ -589,7 +589,7 @@ static int st21nfca_hci_i2c_remove(struct i2c_client *client)
return 0;
}
-static struct i2c_device_id st21nfca_hci_i2c_id_table[] = {
+static const struct i2c_device_id st21nfca_hci_i2c_id_table[] = {
{ST21NFCA_HCI_DRIVER_NAME, 0},
{}
};
--
2.7.4
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web