summaryrefslogtreecommitdiff
path: root/patches/collateral-evolutions/media
diff options
context:
space:
mode:
authorLuis R. Rodriguez <mcgrof@do-not-panic.com>2013-04-13 07:13:43 -0700
committerJohannes Berg <johannes.berg@intel.com>2013-04-13 23:01:58 +0200
commitb8f2e82105322d077c174b224985aa79620dead4 (patch)
treeaa740f329879d0fc81084371cb0baf7a733c9ba5 /patches/collateral-evolutions/media
parent20906a4d28428a35dc64b1a29dbf58f4d8686ef9 (diff)
backports: add media subsystem drivers
This adds backport support for all media subsystem drivers. This is enabled only for >= 3.2. Some media drivers rely on the new probe deferrral mechanism (-EPROBE_DEFER see commit d1c3414c), those are only enabled for kernels >= 3.4. Some media drivers only depend on the regulatory but since we only support backporting the regulatory on kernels >= 3.4 we only enable those media drivers for >= 3.4. This backports 433 media drivers. 1 2.6.24 [ OK ] 2 2.6.25 [ OK ] 3 2.6.26 [ OK ] 4 2.6.27 [ OK ] 5 2.6.28 [ OK ] 6 2.6.29 [ OK ] 7 2.6.30 [ OK ] 8 2.6.31 [ OK ] 9 2.6.32 [ OK ] 10 2.6.33 [ OK ] 11 2.6.34 [ OK ] 12 2.6.35 [ OK ] 13 2.6.36 [ OK ] 14 2.6.37 [ OK ] 15 2.6.38 [ OK ] 16 2.6.39 [ OK ] 17 3.0.65 [ OK ] 18 3.1.10 [ OK ] 19 3.2.38 [ OK ] 20 3.3.8 [ OK ] 21 3.4.32 [ OK ] 22 3.5.7 [ OK ] 23 3.6.11 [ OK ] 24 3.7.9 [ OK ] 25 3.8.0 [ OK ] 26 3.9-rc1 [ OK ] real 39m35.615s user 1068m47.428s sys 155m55.657s Cc: linux-media@vger.kernel.org Cc: linux-kernel@vger.kernel.org Cc: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'patches/collateral-evolutions/media')
-rw-r--r--patches/collateral-evolutions/media/0001-pr_fmt.patch493
-rw-r--r--patches/collateral-evolutions/media/0002-dma_mmap_coherent-revert.patch58
-rw-r--r--patches/collateral-evolutions/media/0003-technisat-usb2-led-rename.patch83
3 files changed, 634 insertions, 0 deletions
diff --git a/patches/collateral-evolutions/media/0001-pr_fmt.patch b/patches/collateral-evolutions/media/0001-pr_fmt.patch
new file mode 100644
index 00000000..17aa93aa
--- /dev/null
+++ b/patches/collateral-evolutions/media/0001-pr_fmt.patch
@@ -0,0 +1,493 @@
+We can't really get this udef'd in any easier way. If you figure it out..
+great.
+
+--- a/drivers/media/media-devnode.c
++++ b/drivers/media/media-devnode.c
+@@ -29,11 +29,12 @@
+ * character devices using a dynamic major number and proper reference
+ * counting.
+ */
+-
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
+ #include <linux/errno.h>
+ #include <linux/init.h>
++#include <linux/printk.h>
+ #include <linux/module.h>
+ #include <linux/kernel.h>
+ #include <linux/kmod.h>
+--- a/drivers/media/common/saa7146/saa7146_i2c.c
++++ b/drivers/media/common/saa7146/saa7146_i2c.c
+@@ -1,5 +1,7 @@
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <media/saa7146_vv.h>
+
+ static u32 saa7146_i2c_func(struct i2c_adapter *adapter)
+--- a/drivers/media/common/saa7146/saa7146_fops.c
++++ b/drivers/media/common/saa7146/saa7146_fops.c
+@@ -1,5 +1,7 @@
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <media/saa7146_vv.h>
+ #include <linux/module.h>
+
+--- a/drivers/media/common/saa7146/saa7146_core.c
++++ b/drivers/media/common/saa7146/saa7146_core.c
+@@ -17,9 +17,10 @@
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+-
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <media/saa7146.h>
+ #include <linux/module.h>
+
+--- a/drivers/media/common/saa7146/saa7146_video.c
++++ b/drivers/media/common/saa7146/saa7146_video.c
+@@ -1,9 +1,11 @@
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
+ #include <media/saa7146_vv.h>
+ #include <media/v4l2-chip-ident.h>
+ #include <media/v4l2-event.h>
+ #include <media/v4l2-ctrls.h>
++#include <linux/printk.h>
+ #include <linux/module.h>
+
+ static int max_memory = 32;
+--- a/drivers/media/common/saa7146/saa7146_hlp.c
++++ b/drivers/media/common/saa7146/saa7146_hlp.c
+@@ -1,5 +1,7 @@
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/kernel.h>
+ #include <linux/export.h>
+ #include <media/saa7146_vv.h>
+--- a/drivers/media/pci/bt8xx/bttv-driver.c
++++ b/drivers/media/pci/bt8xx/bttv-driver.c
+@@ -34,8 +34,10 @@
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/init.h>
+ #include <linux/module.h>
+ #include <linux/delay.h>
+--- a/drivers/media/pci/bt8xx/bttv-cards.c
++++ b/drivers/media/pci/bt8xx/bttv-cards.c
+@@ -24,9 +24,10 @@
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+
+ */
+-
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/delay.h>
+ #include <linux/module.h>
+ #include <linux/kmod.h>
+--- a/drivers/media/dvb-frontends/nxt200x.c
++++ b/drivers/media/dvb-frontends/nxt200x.c
+@@ -37,12 +37,14 @@
+ * /usr/lib/hotplug/firmware/ or /lib/firmware/
+ * (depending on configuration of firmware hotplug).
+ */
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
+ #define NXT2002_DEFAULT_FIRMWARE "dvb-fe-nxt2002.fw"
+ #define NXT2004_DEFAULT_FIRMWARE "dvb-fe-nxt2004.fw"
+ #define CRC_CCIT_MASK 0x1021
+
++#include <linux/printk.h>
+ #include <linux/kernel.h>
+ #include <linux/init.h>
+ #include <linux/module.h>
+--- a/drivers/media/dvb-frontends/or51211.c
++++ b/drivers/media/dvb-frontends/or51211.c
+@@ -21,7 +21,7 @@
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ *
+ */
+-
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": %s: " fmt, __func__
+
+ /*
+@@ -32,6 +32,7 @@
+ */
+ #define OR51211_DEFAULT_FIRMWARE "dvb-fe-or51211.fw"
+
++#include <linux/printk.h>
+ #include <linux/kernel.h>
+ #include <linux/module.h>
+ #include <linux/device.h>
+--- a/drivers/media/pci/bt8xx/bttv-risc.c
++++ b/drivers/media/pci/bt8xx/bttv-risc.c
+@@ -23,9 +23,10 @@
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+
+ */
+-
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/module.h>
+ #include <linux/init.h>
+ #include <linux/slab.h>
+--- a/drivers/media/pci/bt8xx/bttv-vbi.c
++++ b/drivers/media/pci/bt8xx/bttv-vbi.c
+@@ -22,9 +22,10 @@
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+-
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/module.h>
+ #include <linux/errno.h>
+ #include <linux/fs.h>
+--- a/drivers/media/pci/bt8xx/bttv-i2c.c
++++ b/drivers/media/pci/bt8xx/bttv-i2c.c
+@@ -26,9 +26,10 @@
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+
+ */
+-
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/module.h>
+ #include <linux/init.h>
+ #include <linux/delay.h>
+--- a/drivers/media/pci/bt8xx/bttv-gpio.c
++++ b/drivers/media/pci/bt8xx/bttv-gpio.c
+@@ -25,9 +25,10 @@
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+
+ */
+-
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/module.h>
+ #include <linux/init.h>
+ #include <linux/delay.h>
+--- a/drivers/media/pci/bt8xx/bttv-input.c
++++ b/drivers/media/pci/bt8xx/bttv-input.c
+@@ -17,9 +17,10 @@
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+-
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/module.h>
+ #include <linux/init.h>
+ #include <linux/delay.h>
+--- a/drivers/media/pci/bt8xx/dvb-bt8xx.c
++++ b/drivers/media/pci/bt8xx/dvb-bt8xx.c
+@@ -19,8 +19,10 @@
+ *
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) "dvb_bt8xx: " fmt
+
++#include <linux/printk.h>
+ #include <linux/bitops.h>
+ #include <linux/module.h>
+ #include <linux/init.h>
+--- a/drivers/media/common/siano/smsdvb-debugfs.c
++++ b/drivers/media/common/siano/smsdvb-debugfs.c
+@@ -17,8 +17,10 @@
+ *
+ ***********************************************************************/
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/module.h>
+ #include <linux/slab.h>
+ #include <linux/init.h>
+--- a/drivers/media/pci/cx25821/cx25821-alsa.c
++++ b/drivers/media/pci/cx25821/cx25821-alsa.c
+@@ -20,8 +20,10 @@
+ *
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/module.h>
+ #include <linux/init.h>
+ #include <linux/device.h>
+--- a/drivers/media/pci/cx25821/cx25821-audio-upstream.c
++++ b/drivers/media/pci/cx25821/cx25821-audio-upstream.c
+@@ -20,11 +20,13 @@
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
+ #include "cx25821-video.h"
+ #include "cx25821-audio-upstream.h"
+
++#include <linux/printk.h>
+ #include <linux/fs.h>
+ #include <linux/errno.h>
+ #include <linux/kernel.h>
+--- a/drivers/media/pci/cx25821/cx25821-cards.c
++++ b/drivers/media/pci/cx25821/cx25821-cards.c
+@@ -21,8 +21,10 @@
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/init.h>
+ #include <linux/module.h>
+ #include <linux/pci.h>
+--- a/drivers/media/pci/cx25821/cx25821-core.c
++++ b/drivers/media/pci/cx25821/cx25821-core.c
+@@ -21,8 +21,10 @@
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/i2c.h>
+ #include <linux/slab.h>
+ #include "cx25821.h"
+--- a/drivers/media/pci/cx25821/cx25821-i2c.c
++++ b/drivers/media/pci/cx25821/cx25821-i2c.c
+@@ -21,9 +21,11 @@
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
+ #include "cx25821.h"
++#include <linux/printk.h>
+ #include <linux/i2c.h>
+
+ static unsigned int i2c_debug;
+--- a/drivers/media/pci/cx25821/cx25821-medusa-video.c
++++ b/drivers/media/pci/cx25821/cx25821-medusa-video.c
+@@ -20,12 +20,15 @@
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
+ #include "cx25821.h"
+ #include "cx25821-medusa-video.h"
+ #include "cx25821-biffuncs.h"
+
++#include <linux/printk.h>
++
+ /*
+ * medusa_enable_bluefield_output()
+ *
+--- a/drivers/media/pci/cx25821/cx25821-video.c
++++ b/drivers/media/pci/cx25821/cx25821-video.c
+@@ -24,9 +24,11 @@
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
+ #include "cx25821-video.h"
++#include <linux/printk.h>
+
+ MODULE_DESCRIPTION("v4l2 driver module for cx25821 based TV cards");
+ MODULE_AUTHOR("Hiep Huynh <hiep.huynh@conexant.com>");
+--- a/drivers/media/pci/cx25821/cx25821-video-upstream.c
++++ b/drivers/media/pci/cx25821/cx25821-video-upstream.c
+@@ -20,11 +20,13 @@
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
+ #include "cx25821-video.h"
+ #include "cx25821-video-upstream.h"
+
++#include <linux/printk.h>
+ #include <linux/fs.h>
+ #include <linux/errno.h>
+ #include <linux/kernel.h>
+--- a/drivers/media/pci/cx25821/cx25821-video-upstream-ch2.c
++++ b/drivers/media/pci/cx25821/cx25821-video-upstream-ch2.c
+@@ -20,11 +20,13 @@
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
+ #include "cx25821-video.h"
+ #include "cx25821-video-upstream-ch2.h"
+
++#include <linux/printk.h>
+ #include <linux/fs.h>
+ #include <linux/errno.h>
+ #include <linux/kernel.h>
+--- a/drivers/media/rc/imon.c
++++ b/drivers/media/rc/imon.c
+@@ -26,8 +26,10 @@
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ":%s: " fmt, __func__
+
++#include <linux/printk.h>
+ #include <linux/errno.h>
+ #include <linux/init.h>
+ #include <linux/kernel.h>
+--- a/drivers/media/rc/fintek-cir.c
++++ b/drivers/media/rc/fintek-cir.c
+@@ -23,8 +23,10 @@
+ * USA
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/kernel.h>
+ #include <linux/module.h>
+ #include <linux/pnp.h>
+--- a/drivers/media/rc/nuvoton-cir.c
++++ b/drivers/media/rc/nuvoton-cir.c
+@@ -25,8 +25,10 @@
+ * USA
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/kernel.h>
+ #include <linux/module.h>
+ #include <linux/pnp.h>
+--- a/drivers/media/rc/ene_ir.c
++++ b/drivers/media/rc/ene_ir.c
+@@ -30,8 +30,10 @@
+ *
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/kernel.h>
+ #include <linux/module.h>
+ #include <linux/pnp.h>
+--- a/drivers/media/rc/winbond-cir.c
++++ b/drivers/media/rc/winbond-cir.c
+@@ -40,8 +40,10 @@
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/module.h>
+ #include <linux/pnp.h>
+ #include <linux/interrupt.h>
+--- a/drivers/media/pci/saa7146/hexium_orion.c
++++ b/drivers/media/pci/saa7146/hexium_orion.c
+@@ -21,11 +21,13 @@
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
+ #define DEBUG_VARIABLE debug
+
+ #include <media/saa7146_vv.h>
++#include <linux/printk.h>
+ #include <linux/module.h>
+
+ static int debug;
+--- a/drivers/media/pci/saa7146/hexium_gemini.c
++++ b/drivers/media/pci/saa7146/hexium_gemini.c
+@@ -21,12 +21,14 @@
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
+ #define DEBUG_VARIABLE debug
+
+ #include <media/saa7146_vv.h>
+ #include <linux/module.h>
++#include <linux/printk.h>
+
+ static int debug;
+ module_param(debug, int, 0);
+--- a/drivers/media/pci/ttpci/budget-av.c
++++ b/drivers/media/pci/ttpci/budget-av.c
+@@ -33,8 +33,10 @@
+ * the project's page is at http://www.linuxtv.org/
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include "budget.h"
+ #include "stv0299.h"
+ #include "stb0899_drv.h"
+--- a/drivers/media/pci/ttpci/av7110_v4l.c
++++ b/drivers/media/pci/ttpci/av7110_v4l.c
+@@ -25,8 +25,10 @@
+ * the project's page is at http://www.linuxtv.org/
+ */
+
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
++#include <linux/printk.h>
+ #include <linux/kernel.h>
+ #include <linux/types.h>
+ #include <linux/delay.h>
diff --git a/patches/collateral-evolutions/media/0002-dma_mmap_coherent-revert.patch b/patches/collateral-evolutions/media/0002-dma_mmap_coherent-revert.patch
new file mode 100644
index 00000000..4d3a77ee
--- /dev/null
+++ b/patches/collateral-evolutions/media/0002-dma_mmap_coherent-revert.patch
@@ -0,0 +1,58 @@
+Commit c60520fa needs to be reverted for older kernels because
+although we can backport some new DMA changes some other
+larger changes ended up extending some core dma data
+structures, for details see bca0fa5f as an example. We're
+aided with this revert by having added vb2_mmap_pfn_range() to
+compat. The main reason to revert is usage of the new
+dma_mmap_coherent() and core changes required via
+bca0fa5f.
+
+commit c60520fa50cd86d64bc8ebb34300ddc4ca91393d
+Author: Marek Szyprowski <m.szyprowski@samsung.com>
+Date: Thu Jun 14 11:32:21 2012 -0300
+
+ [media] v4l: vb2-dma-contig: let mmap method to use dma_mmap_coherent call
+
+ Let mmap method to use dma_mmap_coherent call. Moreover, this patch removes
+ vb2_mmap_pfn_range from videobuf2 helpers as it was suggested by Laurent
+ Pinchart. The function is no longer used in vb2 code.
+
+ Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
+ Signed-off-by: Tomasz Stanislawski <t.stanislaws@samsung.com>
+ Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
+ Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
+ Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
+
+--- a/drivers/media/v4l2-core/videobuf2-dma-contig.c
++++ b/drivers/media/v4l2-core/videobuf2-dma-contig.c
+@@ -186,6 +186,22 @@ static void *vb2_dc_alloc(void *alloc_ct
+ return buf;
+ }
+
++#if (LINUX_VERSION_CODE < KERNEL_VERSION(3,9,0))
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,2,0))
++static int vb2_dc_mmap(void *buf_priv, struct vm_area_struct *vma)
++{
++ struct vb2_dc_buf *buf = buf_priv;
++
++ if (!buf) {
++ printk(KERN_ERR "No buffer to map\n");
++ return -EINVAL;
++ }
++
++ return vb2_mmap_pfn_range(vma, buf->dma_addr, buf->size,
++ &vb2_common_vm_ops, &buf->handler);
++}
++#endif /* (LINUX_VERSION_CODE >= KERNEL_VERSION(3,2,0)) */
++#else
+ static int vb2_dc_mmap(void *buf_priv, struct vm_area_struct *vma)
+ {
+ struct vb2_dc_buf *buf = buf_priv;
+@@ -222,6 +238,7 @@ static int vb2_dc_mmap(void *buf_priv, s
+
+ return 0;
+ }
++#endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(3,9,0)) */
+
+ /*********************************************/
+ /* DMABUF ops for exporters */
diff --git a/patches/collateral-evolutions/media/0003-technisat-usb2-led-rename.patch b/patches/collateral-evolutions/media/0003-technisat-usb2-led-rename.patch
new file mode 100644
index 00000000..ddfc32ef
--- /dev/null
+++ b/patches/collateral-evolutions/media/0003-technisat-usb2-led-rename.patch
@@ -0,0 +1,83 @@
+This clashes with include/linux/leds.h namespace, fix this and
+also send this upstream eventually.
+
+--- a/drivers/media/usb/dvb-usb/technisat-usb2.c
++++ b/drivers/media/usb/dvb-usb/technisat-usb2.c
+@@ -214,10 +214,10 @@ static void technisat_usb2_frontend_reset(struct usb_device *udev)
+
+ /* LED control */
+ enum technisat_usb2_led_state {
+- LED_OFF,
+- LED_BLINK,
+- LED_ON,
+- LED_UNDEFINED
++ TECH_LED_OFF,
++ TECH_LED_BLINK,
++ TECH_LED_ON,
++ TECH_LED_UNDEFINED
+ };
+
+ static int technisat_usb2_set_led(struct dvb_usb_device *d, int red, enum technisat_usb2_led_state state)
+@@ -229,14 +229,14 @@ static int technisat_usb2_set_led(struct dvb_usb_device *d, int red, enum techni
+ 0
+ };
+
+- if (disable_led_control && state != LED_OFF)
++ if (disable_led_control && state != TECH_LED_OFF)
+ return 0;
+
+ switch (state) {
+- case LED_ON:
++ case TECH_LED_ON:
+ led[1] = 0x82;
+ break;
+- case LED_BLINK:
++ case TECH_LED_BLINK:
+ led[1] = 0x82;
+ if (red) {
+ led[2] = 0x02;
+@@ -251,7 +251,7 @@ static int technisat_usb2_set_led(struct dvb_usb_device *d, int red, enum techni
+ break;
+
+ default:
+- case LED_OFF:
++ case TECH_LED_OFF:
+ led[1] = 0x80;
+ break;
+ }
+@@ -310,11 +310,11 @@ static void technisat_usb2_green_led_control(struct work_struct *work)
+ goto schedule;
+
+ if (ber > 1000)
+- technisat_usb2_set_led(state->dev, 0, LED_BLINK);
++ technisat_usb2_set_led(state->dev, 0, TECH_LED_BLINK);
+ else
+- technisat_usb2_set_led(state->dev, 0, LED_ON);
++ technisat_usb2_set_led(state->dev, 0, TECH_LED_ON);
+ } else
+- technisat_usb2_set_led(state->dev, 0, LED_OFF);
++ technisat_usb2_set_led(state->dev, 0, TECH_LED_OFF);
+ }
+
+ schedule:
+@@ -365,9 +365,9 @@ static int technisat_usb2_power_ctrl(struct dvb_usb_device *d, int level)
+ return 0;
+
+ /* green led is turned off in any case - will be turned on when tuning */
+- technisat_usb2_set_led(d, 0, LED_OFF);
++ technisat_usb2_set_led(d, 0, TECH_LED_OFF);
+ /* red led is turned on all the time */
+- technisat_usb2_set_led(d, 1, LED_ON);
++ technisat_usb2_set_led(d, 1, TECH_LED_ON);
+ return 0;
+ }
+
+@@ -667,7 +667,7 @@ static int technisat_usb2_rc_query(struct dvb_usb_device *d)
+ return 0;
+
+ if (!disable_led_control)
+- technisat_usb2_set_led(d, 1, LED_BLINK);
++ technisat_usb2_set_led(d, 1, TECH_LED_BLINK);
+
+ return 0;
+ }