diff options
author | DENG Qingfang <dengqf6@mail2.sysu.edu.cn> | 2020-03-01 17:06:45 +0800 |
---|---|---|
committer | Chuanhong Guo <gch981213@gmail.com> | 2020-04-04 12:04:13 +0800 |
commit | 6be0da90a165912da7bd56e7bd4d7b2d978b4706 (patch) | |
tree | 00d4d9ccd7a62bfb84a0b27819c6c2145f759af1 /target/linux/ramips/patches-5.4/0031-uvc-add-iPassion-iP2970-support.patch | |
parent | d75c9b8f81b1a4f65132a5fed81f0a3fbbbd8fee (diff) | |
download | upstream-6be0da90a165912da7bd56e7bd4d7b2d978b4706.tar.gz upstream-6be0da90a165912da7bd56e7bd4d7b2d978b4706.tar.bz2 upstream-6be0da90a165912da7bd56e7bd4d7b2d978b4706.zip |
ramips: refresh patches
Removed upstreamed/solved elsewhere upstream:
- 0001-MIPS-ralink-Add-rt3352-SPI_CS1-pinmux.patch
- 0002-MIPS-pci-rt2880-set-pci-controller-of_node.patch
- 0004-MIPS-ralink-add-MT7621-pcie-driver.patch
- 0009-PCI-MIPS-enable-PCIe-on-MT7688.patch
- 0025-pinctrl-ralink-add-pinctrl-driver.patch
- 0028-GPIO-ralink-add-mt7621-gpio-controller.patch
- 0043-spi-add-mt7621-support.patch
- 0045-i2c-add-mt7621-driver.patch
- 0047-DMA-ralink-add-rt2880-dma-engine.patch
- 0053-mtd-spi-nor-add-w25q256-3b-mode-switch.patch
- 0054-mtd-spi-nor-w25q256-respect-default-mode.patch
- 0099-pci-mt7620.patch
- 304-spi-nor-enable-4B-opcodes-for-mx25l25635f.patch
Removed because of the new NAND driver:
- 0038-Revert-mtd-nand-Remove-unused-chip-write_page-hook.patch
- 0039-mtd-add-mt7621-nand-support.patch
- 0040-nand-hack.patch
Remove patch that no longer applies (needs rework):
- 0034-NET-multi-phy-support.patch
Signed-off-by: DENG Qingfang <dengqf6@mail2.sysu.edu.cn>
Diffstat (limited to 'target/linux/ramips/patches-5.4/0031-uvc-add-iPassion-iP2970-support.patch')
-rw-r--r-- | target/linux/ramips/patches-5.4/0031-uvc-add-iPassion-iP2970-support.patch | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/target/linux/ramips/patches-5.4/0031-uvc-add-iPassion-iP2970-support.patch b/target/linux/ramips/patches-5.4/0031-uvc-add-iPassion-iP2970-support.patch index 7ed1a616f6..084b655483 100644 --- a/target/linux/ramips/patches-5.4/0031-uvc-add-iPassion-iP2970-support.patch +++ b/target/linux/ramips/patches-5.4/0031-uvc-add-iPassion-iP2970-support.patch @@ -13,10 +13,10 @@ Signed-off-by: John Crispin <blogic@openwrt.org> --- a/drivers/media/usb/uvc/uvc_driver.c +++ b/drivers/media/usb/uvc/uvc_driver.c -@@ -2749,6 +2749,18 @@ static const struct usb_device_id uvc_id +@@ -2908,6 +2908,18 @@ static const struct usb_device_id uvc_id .bInterfaceSubClass = 1, .bInterfaceProtocol = 0, - .driver_info = UVC_QUIRK_FORCE_Y8 }, + .driver_info = UVC_INFO_META(V4L2_META_FMT_D4XX) }, + /* iPassion iP2970 */ + { .match_flags = USB_DEVICE_ID_MATCH_DEVICE + | USB_DEVICE_ID_MATCH_INT_INFO, @@ -34,15 +34,15 @@ Signed-off-by: John Crispin <blogic@openwrt.org> { USB_INTERFACE_INFO(USB_CLASS_VIDEO, 1, UVC_PC_PROTOCOL_15) }, --- a/drivers/media/usb/uvc/uvc_status.c +++ b/drivers/media/usb/uvc/uvc_status.c -@@ -139,6 +139,7 @@ static void uvc_status_complete(struct u - switch (dev->status[0] & 0x0f) { - case UVC_STATUS_TYPE_CONTROL: - uvc_event_control(dev, dev->status, len); +@@ -223,6 +223,7 @@ static void uvc_status_complete(struct u + if (uvc_event_control(urb, status, len)) + /* The URB will be resubmitted in work context. */ + return; + dev->motion = 1; break; + } - case UVC_STATUS_TYPE_STREAMING: -@@ -182,6 +183,7 @@ int uvc_status_init(struct uvc_device *d +@@ -271,6 +272,7 @@ int uvc_status_init(struct uvc_device *d } pipe = usb_rcvintpipe(dev->udev, ep->desc.bEndpointAddress); @@ -52,7 +52,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org> * an exponent of two. Some developers forgot about it. --- a/drivers/media/usb/uvc/uvc_video.c +++ b/drivers/media/usb/uvc/uvc_video.c -@@ -21,6 +21,11 @@ +@@ -16,6 +16,11 @@ #include <linux/wait.h> #include <linux/atomic.h> #include <asm/unaligned.h> @@ -64,8 +64,8 @@ Signed-off-by: John Crispin <blogic@openwrt.org> #include <media/v4l2-common.h> -@@ -1101,9 +1106,149 @@ static void uvc_video_decode_data(struct - } +@@ -1156,9 +1161,149 @@ static void uvc_video_decode_data(struct + uvc_urb->async_operations++; } +struct bh_priv { @@ -196,7 +196,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org> + +#define MOTION_FLAG_OFFSET 4 static void uvc_video_decode_end(struct uvc_streaming *stream, - struct uvc_buffer *buf, const __u8 *data, int len) + struct uvc_buffer *buf, const u8 *data, int len) { + if ((stream->dev->quirks & UVC_QUIRK_MOTION) && + (data[len - 2] == 0xff) && (data[len - 1] == 0xd9)) { @@ -214,7 +214,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org> /* Mark the buffer as done if the EOF marker is set. */ if (data[1] & UVC_STREAM_EOF && buf->bytesused != 0) { uvc_trace(UVC_TRACE_FRAME, "Frame complete (EOF found).\n"); -@@ -1518,6 +1663,8 @@ static int uvc_init_video_isoc(struct uv +@@ -1715,6 +1860,8 @@ static int uvc_init_video_isoc(struct uv if (npackets == 0) return -ENOMEM; @@ -222,13 +222,13 @@ Signed-off-by: John Crispin <blogic@openwrt.org> + npackets = 1; size = npackets * psize; - for (i = 0; i < UVC_URBS; ++i) { + for_each_uvc_urb(uvc_urb, stream) { --- a/drivers/media/usb/uvc/uvcvideo.h +++ b/drivers/media/usb/uvc/uvcvideo.h -@@ -186,7 +186,9 @@ - #define UVC_QUIRK_RESTRICT_FRAME_RATE 0x00000200 +@@ -199,7 +199,9 @@ #define UVC_QUIRK_RESTORE_CTRLS_ON_INIT 0x00000400 #define UVC_QUIRK_FORCE_Y8 0x00000800 + #define UVC_QUIRK_FORCE_BPP 0x00001000 - +#define UVC_QUIRK_MOTION 0x00001000 +#define UVC_QUIRK_SINGLE_ISO 0x00002000 @@ -236,11 +236,11 @@ Signed-off-by: John Crispin <blogic@openwrt.org> /* Format flags */ #define UVC_FMT_FLAG_COMPRESSED 0x00000001 #define UVC_FMT_FLAG_STREAM 0x00000002 -@@ -584,6 +586,7 @@ struct uvc_device { - __u8 *status; +@@ -666,6 +668,7 @@ struct uvc_device { + u8 *status; struct input_dev *input; char input_phys[64]; + int motion; - }; - enum uvc_handle_state { + struct uvc_ctrl_work { + struct work_struct work; |