aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/usbvision/usbvision-video.c
diff options
context:
space:
mode:
authorArjan van de Ven <arjan@linux.intel.com>2007-02-12 03:55:33 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-02-12 12:48:45 -0500
commitfa027c2a0a0d6d1df6b29ee99048502c93da0dd4 (patch)
tree64a6b20c6c6e19a731882f830bd70ca5c8d99943 /drivers/media/video/usbvision/usbvision-video.c
parent2b8693c0617e972fc0b2fd1ebf8de97e15b656c3 (diff)
[PATCH] mark struct file_operations const 4
Many struct file_operations in the kernel can be "const". Marking them const moves these to the .rodata section, which avoids false sharing with potential dirty data. In addition it'll catch accidental writes at compile time to these shared resources. [akpm@sdl.org: dvb fix] Signed-off-by: Arjan van de Ven <arjan@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/media/video/usbvision/usbvision-video.c')
-rw-r--r--drivers/media/video/usbvision/usbvision-video.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/media/video/usbvision/usbvision-video.c b/drivers/media/video/usbvision/usbvision-video.c
index bdd6301d2a47..4eb7330b96f8 100644
--- a/drivers/media/video/usbvision/usbvision-video.c
+++ b/drivers/media/video/usbvision/usbvision-video.c
@@ -1475,7 +1475,7 @@ static int usbvision_vbi_ioctl(struct inode *inode, struct file *file,
1475// 1475//
1476 1476
1477// Video template 1477// Video template
1478static struct file_operations usbvision_fops = { 1478static const struct file_operations usbvision_fops = {
1479 .owner = THIS_MODULE, 1479 .owner = THIS_MODULE,
1480 .open = usbvision_v4l2_open, 1480 .open = usbvision_v4l2_open,
1481 .release = usbvision_v4l2_close, 1481 .release = usbvision_v4l2_close,
@@ -1496,7 +1496,7 @@ static struct video_device usbvision_video_template = {
1496 1496
1497 1497
1498// Radio template 1498// Radio template
1499static struct file_operations usbvision_radio_fops = { 1499static const struct file_operations usbvision_radio_fops = {
1500 .owner = THIS_MODULE, 1500 .owner = THIS_MODULE,
1501 .open = usbvision_radio_open, 1501 .open = usbvision_radio_open,
1502 .release = usbvision_radio_close, 1502 .release = usbvision_radio_close,
@@ -1517,7 +1517,7 @@ static struct video_device usbvision_radio_template=
1517 1517
1518 1518
1519// vbi template 1519// vbi template
1520static struct file_operations usbvision_vbi_fops = { 1520static const struct file_operations usbvision_vbi_fops = {
1521 .owner = THIS_MODULE, 1521 .owner = THIS_MODULE,
1522 .open = usbvision_vbi_open, 1522 .open = usbvision_vbi_open,
1523 .release = usbvision_vbi_close, 1523 .release = usbvision_vbi_close,