diff options
author | Julia Lawall <Julia.Lawall@lip6.fr> | 2015-12-11 11:16:48 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@osg.samsung.com> | 2016-02-01 04:34:07 -0500 |
commit | ff880348e74e0fd1196ab39ec765f5fd330ed3c6 (patch) | |
tree | 4fd3bb14c2415c207bb6ffd474d5566d489cc8ba | |
parent | 2874bf3ec453f50cfe1f7bf000efdadeb6f30db6 (diff) |
[media] go7007: constify go7007_hpi_ops structures
The go7007_hpi_ops structures are never modified, so declare them as const.
Done with the help of Coccinelle.
Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
-rw-r--r-- | drivers/media/pci/saa7134/saa7134-go7007.c | 2 | ||||
-rw-r--r-- | drivers/media/usb/go7007/go7007-priv.h | 2 | ||||
-rw-r--r-- | drivers/media/usb/go7007/go7007-usb.c | 4 |
3 files changed, 4 insertions, 4 deletions
diff --git a/drivers/media/pci/saa7134/saa7134-go7007.c b/drivers/media/pci/saa7134/saa7134-go7007.c index 8a2abb34186b..2799538e2d7e 100644 --- a/drivers/media/pci/saa7134/saa7134-go7007.c +++ b/drivers/media/pci/saa7134/saa7134-go7007.c | |||
@@ -378,7 +378,7 @@ static int saa7134_go7007_send_firmware(struct go7007 *go, u8 *data, int len) | |||
378 | return 0; | 378 | return 0; |
379 | } | 379 | } |
380 | 380 | ||
381 | static struct go7007_hpi_ops saa7134_go7007_hpi_ops = { | 381 | static const struct go7007_hpi_ops saa7134_go7007_hpi_ops = { |
382 | .interface_reset = saa7134_go7007_interface_reset, | 382 | .interface_reset = saa7134_go7007_interface_reset, |
383 | .write_interrupt = saa7134_go7007_write_interrupt, | 383 | .write_interrupt = saa7134_go7007_write_interrupt, |
384 | .read_interrupt = saa7134_go7007_read_interrupt, | 384 | .read_interrupt = saa7134_go7007_read_interrupt, |
diff --git a/drivers/media/usb/go7007/go7007-priv.h b/drivers/media/usb/go7007/go7007-priv.h index 745185eb060b..bebee8ca9981 100644 --- a/drivers/media/usb/go7007/go7007-priv.h +++ b/drivers/media/usb/go7007/go7007-priv.h | |||
@@ -250,7 +250,7 @@ struct go7007 { | |||
250 | struct i2c_adapter i2c_adapter; | 250 | struct i2c_adapter i2c_adapter; |
251 | 251 | ||
252 | /* HPI driver */ | 252 | /* HPI driver */ |
253 | struct go7007_hpi_ops *hpi_ops; | 253 | const struct go7007_hpi_ops *hpi_ops; |
254 | void *hpi_context; | 254 | void *hpi_context; |
255 | int interrupt_available; | 255 | int interrupt_available; |
256 | wait_queue_head_t interrupt_waitq; | 256 | wait_queue_head_t interrupt_waitq; |
diff --git a/drivers/media/usb/go7007/go7007-usb.c b/drivers/media/usb/go7007/go7007-usb.c index 3dbf14c85c5c..14d3f8c1ce4a 100644 --- a/drivers/media/usb/go7007/go7007-usb.c +++ b/drivers/media/usb/go7007/go7007-usb.c | |||
@@ -932,7 +932,7 @@ static void go7007_usb_release(struct go7007 *go) | |||
932 | kfree(go->hpi_context); | 932 | kfree(go->hpi_context); |
933 | } | 933 | } |
934 | 934 | ||
935 | static struct go7007_hpi_ops go7007_usb_ezusb_hpi_ops = { | 935 | static const struct go7007_hpi_ops go7007_usb_ezusb_hpi_ops = { |
936 | .interface_reset = go7007_usb_interface_reset, | 936 | .interface_reset = go7007_usb_interface_reset, |
937 | .write_interrupt = go7007_usb_ezusb_write_interrupt, | 937 | .write_interrupt = go7007_usb_ezusb_write_interrupt, |
938 | .read_interrupt = go7007_usb_read_interrupt, | 938 | .read_interrupt = go7007_usb_read_interrupt, |
@@ -942,7 +942,7 @@ static struct go7007_hpi_ops go7007_usb_ezusb_hpi_ops = { | |||
942 | .release = go7007_usb_release, | 942 | .release = go7007_usb_release, |
943 | }; | 943 | }; |
944 | 944 | ||
945 | static struct go7007_hpi_ops go7007_usb_onboard_hpi_ops = { | 945 | static const struct go7007_hpi_ops go7007_usb_onboard_hpi_ops = { |
946 | .interface_reset = go7007_usb_interface_reset, | 946 | .interface_reset = go7007_usb_interface_reset, |
947 | .write_interrupt = go7007_usb_onboard_write_interrupt, | 947 | .write_interrupt = go7007_usb_onboard_write_interrupt, |
948 | .read_interrupt = go7007_usb_read_interrupt, | 948 | .read_interrupt = go7007_usb_read_interrupt, |