aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2011-03-06 13:33:44 (GMT)
committerHans Verkuil <hverkuil@xs4all.nl>2011-03-06 13:33:44 (GMT)
commitc9d774312215490ea8e7910f5ffb46345aef75ea (patch)
treed84160c2c76e4d5c6d0d99d0f54fa6baef4c6736
parentfed97a85c4fe90d1c25a40e9a09415605568a0c7 (diff)
Fix 2.6.31 compile warnings (vm_ops isn't const in 2.6.31)
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
-rw-r--r--backports/v2.6.31_series2
-rw-r--r--backports/v2.6.31_vm_ops.patch189
2 files changed, 190 insertions, 1 deletions
diff --git a/backports/v2.6.31_series b/backports/v2.6.31_series
index 1711839..dcf2280 100644
--- a/backports/v2.6.31_series
+++ b/backports/v2.6.31_series
@@ -10,4 +10,4 @@ v2.6.33_input_handlers_are_int.patch
v2.6.33_pvrusb2_sysfs.patch
v2.6.32_kfifo.patch
v2.6.31_nodename.patch
-
+v2.6.31_vm_ops.patch
diff --git a/backports/v2.6.31_vm_ops.patch b/backports/v2.6.31_vm_ops.patch
new file mode 100644
index 0000000..e50d2a8
--- /dev/null
+++ b/backports/v2.6.31_vm_ops.patch
@@ -0,0 +1,189 @@
+diff --git a/drivers/media/video/cafe_ccic.c b/drivers/media/video/cafe_ccic.c
+index 55ffd60..b8d9ca6 100644
+--- a/drivers/media/video/cafe_ccic.c
++++ b/drivers/media/video/cafe_ccic.c
+@@ -1368,7 +1368,7 @@ static void cafe_v4l_vm_close(struct vm_area_struct *vma)
+ mutex_unlock(&sbuf->cam->s_mutex);
+ }
+
+-static const struct vm_operations_struct cafe_v4l_vm_ops = {
++static struct vm_operations_struct cafe_v4l_vm_ops = {
+ .open = cafe_v4l_vm_open,
+ .close = cafe_v4l_vm_close
+ };
+diff --git a/drivers/media/video/et61x251/et61x251_core.c b/drivers/media/video/et61x251/et61x251_core.c
+index a982750..3ad0d25 100644
+--- a/drivers/media/video/et61x251/et61x251_core.c
++++ b/drivers/media/video/et61x251/et61x251_core.c
+@@ -1499,7 +1499,7 @@ static void et61x251_vm_close(struct vm_area_struct* vma)
+ }
+
+
+-static const struct vm_operations_struct et61x251_vm_ops = {
++static struct vm_operations_struct et61x251_vm_ops = {
+ .open = et61x251_vm_open,
+ .close = et61x251_vm_close,
+ };
+diff --git a/drivers/media/video/gspca/gspca.c b/drivers/media/video/gspca/gspca.c
+index f21f2a2..0d5e677 100644
+--- a/drivers/media/video/gspca/gspca.c
++++ b/drivers/media/video/gspca/gspca.c
+@@ -107,7 +107,7 @@ static void gspca_vm_close(struct vm_area_struct *vma)
+ frame->v4l2_buf.flags &= ~V4L2_BUF_FLAG_MAPPED;
+ }
+
+-static const struct vm_operations_struct gspca_vm_ops = {
++static struct vm_operations_struct gspca_vm_ops = {
+ .open = gspca_vm_open,
+ .close = gspca_vm_close,
+ };
+diff --git a/drivers/media/video/meye.c b/drivers/media/video/meye.c
+index 48d2c24..4e70832 100644
+--- a/drivers/media/video/meye.c
++++ b/drivers/media/video/meye.c
+@@ -1598,7 +1598,7 @@ static void meye_vm_close(struct vm_area_struct *vma)
+ meye.vma_use_count[idx]--;
+ }
+
+-static const struct vm_operations_struct meye_vm_ops = {
++static struct vm_operations_struct meye_vm_ops = {
+ .open = meye_vm_open,
+ .close = meye_vm_close,
+ };
+diff --git a/drivers/media/video/sn9c102/sn9c102_core.c b/drivers/media/video/sn9c102/sn9c102_core.c
+index ce56a1c..cc091b2 100644
+--- a/drivers/media/video/sn9c102/sn9c102_core.c
++++ b/drivers/media/video/sn9c102/sn9c102_core.c
+@@ -2078,7 +2078,7 @@ static void sn9c102_vm_close(struct vm_area_struct* vma)
+ }
+
+
+-static const struct vm_operations_struct sn9c102_vm_ops = {
++static struct vm_operations_struct sn9c102_vm_ops = {
+ .open = sn9c102_vm_open,
+ .close = sn9c102_vm_close,
+ };
+diff --git a/drivers/media/video/stk-webcam.c b/drivers/media/video/stk-webcam.c
+index d1a2cef..b24988a 100644
+--- a/drivers/media/video/stk-webcam.c
++++ b/drivers/media/video/stk-webcam.c
+@@ -672,7 +672,7 @@ static void stk_v4l_vm_close(struct vm_area_struct *vma)
+ if (sbuf->mapcount == 0)
+ sbuf->v4lbuf.flags &= ~V4L2_BUF_FLAG_MAPPED;
+ }
+-static const struct vm_operations_struct stk_v4l_vm_ops = {
++static struct vm_operations_struct stk_v4l_vm_ops = {
+ .open = stk_v4l_vm_open,
+ .close = stk_v4l_vm_close
+ };
+diff --git a/drivers/media/video/uvc/uvc_queue.c b/drivers/media/video/uvc/uvc_queue.c
+index f14581b..f628414 100644
+--- a/drivers/media/video/uvc/uvc_queue.c
++++ b/drivers/media/video/uvc/uvc_queue.c
+@@ -394,7 +394,7 @@ static void uvc_vm_close(struct vm_area_struct *vma)
+ buffer->vma_use_count--;
+ }
+
+-static const struct vm_operations_struct uvc_vm_ops = {
++static struct vm_operations_struct uvc_vm_ops = {
+ .open = uvc_vm_open,
+ .close = uvc_vm_close,
+ };
+diff --git a/drivers/media/video/videobuf-dma-contig.c b/drivers/media/video/videobuf-dma-contig.c
+index c969111..2411516 100644
+--- a/drivers/media/video/videobuf-dma-contig.c
++++ b/drivers/media/video/videobuf-dma-contig.c
+@@ -106,7 +106,7 @@ static void videobuf_vm_close(struct vm_area_struct *vma)
+ }
+ }
+
+-static const struct vm_operations_struct videobuf_vm_ops = {
++static struct vm_operations_struct videobuf_vm_ops = {
+ .open = videobuf_vm_open,
+ .close = videobuf_vm_close,
+ };
+diff --git a/drivers/media/video/videobuf-dma-sg.c b/drivers/media/video/videobuf-dma-sg.c
+index ddb8f4b..3ef135a 100644
+--- a/drivers/media/video/videobuf-dma-sg.c
++++ b/drivers/media/video/videobuf-dma-sg.c
+@@ -402,7 +402,7 @@ static int videobuf_vm_fault(struct vm_area_struct *vma, struct vm_fault *vmf)
+ return 0;
+ }
+
+-static const struct vm_operations_struct videobuf_vm_ops = {
++static struct vm_operations_struct videobuf_vm_ops = {
+ .open = videobuf_vm_open,
+ .close = videobuf_vm_close,
+ .fault = videobuf_vm_fault,
+diff --git a/drivers/media/video/videobuf-vmalloc.c b/drivers/media/video/videobuf-vmalloc.c
+index df14258..9b9631f 100644
+--- a/drivers/media/video/videobuf-vmalloc.c
++++ b/drivers/media/video/videobuf-vmalloc.c
+@@ -120,7 +120,7 @@ static void videobuf_vm_close(struct vm_area_struct *vma)
+ return;
+ }
+
+-static const struct vm_operations_struct videobuf_vm_ops = {
++static struct vm_operations_struct videobuf_vm_ops = {
+ .open = videobuf_vm_open,
+ .close = videobuf_vm_close,
+ };
+diff --git a/drivers/media/video/videobuf2-memops.c b/drivers/media/video/videobuf2-memops.c
+index a3eb656..e479bc2 100644
+--- a/drivers/media/video/videobuf2-memops.c
++++ b/drivers/media/video/videobuf2-memops.c
+@@ -156,7 +156,7 @@ EXPORT_SYMBOL_GPL(vb2_get_contig_userptr);
+ */
+ int vb2_mmap_pfn_range(struct vm_area_struct *vma, unsigned long paddr,
+ unsigned long size,
+- const struct vm_operations_struct *vm_ops,
++ struct vm_operations_struct *vm_ops,
+ void *priv)
+ {
+ int ret;
+@@ -224,7 +224,7 @@ static void vb2_common_vm_close(struct vm_area_struct *vma)
+ * vb2_common_vm_ops - common vm_ops used for tracking refcount of mmaped
+ * video buffers
+ */
+-const struct vm_operations_struct vb2_common_vm_ops = {
++struct vm_operations_struct vb2_common_vm_ops = {
+ .open = vb2_common_vm_open,
+ .close = vb2_common_vm_close,
+ };
+diff --git a/drivers/media/video/zoran/zoran_driver.c b/drivers/media/video/zoran/zoran_driver.c
+index 7c3921d..40a4cd3 100644
+--- a/drivers/media/video/zoran/zoran_driver.c
++++ b/drivers/media/video/zoran/zoran_driver.c
+@@ -2850,7 +2850,7 @@ zoran_vm_close (struct vm_area_struct *vma)
+ mutex_unlock(&zr->resource_lock);
+ }
+
+-static const struct vm_operations_struct zoran_vm_ops = {
++static struct vm_operations_struct zoran_vm_ops = {
+ .open = zoran_vm_open,
+ .close = zoran_vm_close,
+ };
+diff --git a/drivers/staging/vme/bridges/Module.symvers b/drivers/staging/vme/bridges/Module.symvers
+deleted file mode 100644
+index e69de29..0000000
+diff --git a/include/media/videobuf2-memops.h b/include/media/videobuf2-memops.h
+index fee1703..3e83625 100644
+--- a/include/media/videobuf2-memops.h
++++ b/include/media/videobuf2-memops.h
+@@ -28,14 +28,14 @@ struct vb2_vmarea_handler {
+ void *arg;
+ };
+
+-extern const struct vm_operations_struct vb2_common_vm_ops;
++extern struct vm_operations_struct vb2_common_vm_ops;
+
+ int vb2_get_contig_userptr(unsigned long vaddr, unsigned long size,
+ struct vm_area_struct **res_vma, dma_addr_t *res_pa);
+
+ int vb2_mmap_pfn_range(struct vm_area_struct *vma, unsigned long paddr,
+ unsigned long size,
+- const struct vm_operations_struct *vm_ops,
++ struct vm_operations_struct *vm_ops,
+ void *priv);
+
+ struct vm_area_struct *vb2_get_vma(struct vm_area_struct *vma);

Privacy Policy