1. 25 11月, 2014 6 次提交
  2. 05 11月, 2014 1 次提交
  3. 04 11月, 2014 1 次提交
  4. 29 10月, 2014 1 次提交
    • H
      [media] v4l2-ctrls: fix sparse warning · 7a7f1ab3
      Hans Verkuil 提交于
      The warning is simple:
      
      drivers/media/v4l2-core/v4l2-ctrls.c:1685:15: warning: incorrect type in assignment (different address spaces)
      
      but the fix isn't.
      
      The core problem was that the conversion from user to kernelspace was
      done at too low a level and that needed to be moved up. That made it possible
      to drop pointers to v4l2_ext_control from set_ctrl and validate_new and
      clean up this sparse warning because those functions now always operate
      on kernelspace pointers.
      Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@osg.samsung.com>
      7a7f1ab3
  5. 24 10月, 2014 1 次提交
  6. 26 9月, 2014 1 次提交
    • M
      v4l2-pci-skeleton: Only build if PCI is available · 19f94f97
      Mark Brown 提交于
      Currently arm64 does not support PCI but it does support v4l2. Since the
      PCI skeleton driver is built unconditionally as a module with no dependency
      on PCI this causes build failures for arm64 allmodconfig. Fix this by
      defining a symbol VIDEO_PCI_SKELETON for the skeleton and conditionalising
      the build on that.
      Signed-off-by: NMark Brown <broonie@linaro.org>
      Signed-off-by: Randy Dunlap <rdunlap@infradead.org> [added VIDEO dependencies]
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      19f94f97
  7. 24 9月, 2014 2 次提交
  8. 22 9月, 2014 9 次提交
  9. 04 9月, 2014 1 次提交
  10. 03 9月, 2014 3 次提交
    • H
      [media] v4l2-compat-ioctl32: fix sparse warnings · 8ae632b1
      Hans Verkuil 提交于
      A lot of these warnings are caused by the fact that we don't generally use
      __user in videodev2.h. Normally the video_usercopy function will copy anything
      pointed to by pointers into kernel space, so having __user in the struct will only
      cause lots of warnings in the drivers. But the flip side of that is that you
      need to add __force casts here.
      
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:337:26: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:337:30: warning: incorrect type in argument 2 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:338:31: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:338:49: warning: incorrect type in argument 2 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:343:21: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:346:21: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:349:35: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:349:46: warning: incorrect type in argument 2 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:352:35: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:352:54: warning: incorrect type in argument 2 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:363:26: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:363:32: warning: incorrect type in argument 2 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:364:31: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:364:51: warning: incorrect type in argument 2 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:371:35: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:371:56: warning: incorrect type in argument 2 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:376:35: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:376:48: warning: incorrect type in argument 2 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:430:30: warning: incorrect type in assignment (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:433:48: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:433:56: warning: incorrect type in argument 2 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:501:24: warning: incorrect type in assignment (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:507:48: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:507:56: warning: incorrect type in argument 2 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:565:18: warning: incorrect type in assignment (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:670:22: warning: incorrect type in assignment (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:680:29: warning: incorrect type in assignment (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:692:55: warning: incorrect type in initializer (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:773:18: warning: incorrect type in assignment (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:786:30: warning: incorrect type in argument 1 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:786:44: warning: incorrect type in argument 2 (different address spaces)
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:674:37: warning: dereference of noderef expression
      drivers/media/v4l2-core/v4l2-compat-ioctl32.c:718:37: warning: dereference of noderef expression
      Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      8ae632b1
    • H
      [media] v4l2-ioctl: fix sparse warnings · 4d1afa51
      Hans Verkuil 提交于
      drivers/media/v4l2-core/v4l2-ioctl.c:1156:53: warning: incorrect type in initializer (different address spaces)
      drivers/media/v4l2-core/v4l2-ioctl.c:1158:42: warning: incorrect type in initializer (different address spaces)
      drivers/media/v4l2-core/v4l2-ioctl.c:1161:34: warning: incorrect type in assignment (different address spaces)
      drivers/media/v4l2-core/v4l2-ioctl.c:1163:35: warning: incorrect type in assignment (different address spaces)
      Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      4d1afa51
    • H
      [media] vb2: fix multiplanar read() with non-zero data_offset · 529a53c6
      Hans Verkuil 提交于
      If this is a multiplanar buf_type and the plane we want to read has a
      non-zero data_offset, then that data_offset was not taken into account.
      
      Note that read() or write() for formats with more than one plane is currently
      not allowed, hence the use of 'planes[0]' since this is only relevant for a
      single-plane format.
      Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      529a53c6
  11. 22 8月, 2014 6 次提交
    • H
      [media] vb2: use pr_info instead of pr_debug · 0821344d
      Hans Verkuil 提交于
      Modern kernels enable dynamic printk support, which is fine, except when it is
      combined with a debug module option. Enabling debug in videobuf2-core now produces
      no debugging unless it is also enabled through the dynamic printk support in debugfs.
      
      Either use a debug module option + pr_info, or use pr_debug without a debug module
      option. In this case the fact that you can set various debug levels is very useful,
      so I believe that for videobuf2-core.c we should use pr_info.
      
      The mix of the two is very confusing: I've spent too much time already trying to
      figure out why I am not seeing any debug output in the kernel log when I do:
      
      	echo 1 >/sys/modules/videobuf2_core/parameters/debug
      Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      0821344d
    • H
      [media] videobuf2: fix lockdep warning · f035eb4e
      Hans Verkuil 提交于
      The following lockdep warning has been there ever since commit a517cca6
      one year ago:
      
      [  403.117947] ======================================================
      [  403.117949] [ INFO: possible circular locking dependency detected ]
      [  403.117953] 3.16.0-rc6-test-media #961 Not tainted
      [  403.117954] -------------------------------------------------------
      [  403.117956] v4l2-ctl/15377 is trying to acquire lock:
      [  403.117959]  (&dev->mutex#3){+.+.+.}, at: [<ffffffffa005a6c3>] vb2_fop_mmap+0x33/0x90 [videobuf2_core]
      [  403.117974]
      [  403.117974] but task is already holding lock:
      [  403.117976]  (&mm->mmap_sem){++++++}, at: [<ffffffff8118291f>] vm_mmap_pgoff+0x6f/0xc0
      [  403.117987]
      [  403.117987] which lock already depends on the new lock.
      [  403.117987]
      [  403.117990]
      [  403.117990] the existing dependency chain (in reverse order) is:
      [  403.117992]
      [  403.117992] -> #1 (&mm->mmap_sem){++++++}:
      [  403.117997]        [<ffffffff810d733c>] validate_chain.isra.39+0x5fc/0x9a0
      [  403.118006]        [<ffffffff810d8bc3>] __lock_acquire+0x4d3/0xd30
      [  403.118010]        [<ffffffff810d9da7>] lock_acquire+0xa7/0x160
      [  403.118014]        [<ffffffff8118c9ec>] might_fault+0x7c/0xb0
      [  403.118018]        [<ffffffffa0028a25>] video_usercopy+0x425/0x610 [videodev]
      [  403.118028]        [<ffffffffa0028c25>] video_ioctl2+0x15/0x20 [videodev]
      [  403.118034]        [<ffffffffa0022764>] v4l2_ioctl+0x184/0x1a0 [videodev]
      [  403.118040]        [<ffffffff811d77d0>] do_vfs_ioctl+0x2f0/0x4f0
      [  403.118307]        [<ffffffff811d7a51>] SyS_ioctl+0x81/0xa0
      [  403.118311]        [<ffffffff8199dc69>] system_call_fastpath+0x16/0x1b
      [  403.118319]
      [  403.118319] -> #0 (&dev->mutex#3){+.+.+.}:
      [  403.118324]        [<ffffffff810d6a96>] check_prevs_add+0x746/0x9f0
      [  403.118329]        [<ffffffff810d733c>] validate_chain.isra.39+0x5fc/0x9a0
      [  403.118333]        [<ffffffff810d8bc3>] __lock_acquire+0x4d3/0xd30
      [  403.118336]        [<ffffffff810d9da7>] lock_acquire+0xa7/0x160
      [  403.118340]        [<ffffffff81999664>] mutex_lock_interruptible_nested+0x64/0x640
      [  403.118344]        [<ffffffffa005a6c3>] vb2_fop_mmap+0x33/0x90 [videobuf2_core]
      [  403.118349]        [<ffffffffa0022122>] v4l2_mmap+0x62/0xa0 [videodev]
      [  403.118354]        [<ffffffff81197270>] mmap_region+0x3d0/0x5d0
      [  403.118359]        [<ffffffff8119778d>] do_mmap_pgoff+0x31d/0x400
      [  403.118363]        [<ffffffff81182940>] vm_mmap_pgoff+0x90/0xc0
      [  403.118366]        [<ffffffff81195cef>] SyS_mmap_pgoff+0x1df/0x2a0
      [  403.118369]        [<ffffffff810085c2>] SyS_mmap+0x22/0x30
      [  403.118376]        [<ffffffff8199dc69>] system_call_fastpath+0x16/0x1b
      [  403.118381]
      [  403.118381] other info that might help us debug this:
      [  403.118381]
      [  403.118383]  Possible unsafe locking scenario:
      [  403.118383]
      [  403.118385]        CPU0                    CPU1
      [  403.118387]        ----                    ----
      [  403.118388]   lock(&mm->mmap_sem);
      [  403.118391]                                lock(&dev->mutex#3);
      [  403.118394]                                lock(&mm->mmap_sem);
      [  403.118397]   lock(&dev->mutex#3);
      [  403.118400]
      [  403.118400]  *** DEADLOCK ***
      [  403.118400]
      [  403.118403] 1 lock held by v4l2-ctl/15377:
      [  403.118405]  #0:  (&mm->mmap_sem){++++++}, at: [<ffffffff8118291f>] vm_mmap_pgoff+0x6f/0xc0
      [  403.118411]
      [  403.118411] stack backtrace:
      [  403.118415] CPU: 0 PID: 15377 Comm: v4l2-ctl Not tainted 3.16.0-rc6-test-media #961
      [  403.118418] Hardware name: VMware, Inc. VMware Virtual Platform/440BX Desktop Reference Platform, BIOS 6.00 07/31/2013
      [  403.118420]  ffffffff82a6c9d0 ffff8800af37fb00 ffffffff819916a2 ffffffff82a6c9d0
      [  403.118425]  ffff8800af37fb40 ffffffff810d5715 ffff8802308e4200 0000000000000000
      [  403.118429]  ffff8802308e4a48 ffff8802308e4a48 ffff8802308e4200 0000000000000001
      [  403.118433] Call Trace:
      [  403.118441]  [<ffffffff819916a2>] dump_stack+0x4e/0x7a
      [  403.118445]  [<ffffffff810d5715>] print_circular_bug+0x1d5/0x2a0
      [  403.118449]  [<ffffffff810d6a96>] check_prevs_add+0x746/0x9f0
      [  403.118455]  [<ffffffff8119c172>] ? find_vmap_area+0x42/0x70
      [  403.118459]  [<ffffffff810d733c>] validate_chain.isra.39+0x5fc/0x9a0
      [  403.118463]  [<ffffffff810d8bc3>] __lock_acquire+0x4d3/0xd30
      [  403.118468]  [<ffffffff810d9da7>] lock_acquire+0xa7/0x160
      [  403.118472]  [<ffffffffa005a6c3>] ? vb2_fop_mmap+0x33/0x90 [videobuf2_core]
      [  403.118476]  [<ffffffffa005a6c3>] ? vb2_fop_mmap+0x33/0x90 [videobuf2_core]
      [  403.118480]  [<ffffffff81999664>] mutex_lock_interruptible_nested+0x64/0x640
      [  403.118484]  [<ffffffffa005a6c3>] ? vb2_fop_mmap+0x33/0x90 [videobuf2_core]
      [  403.118488]  [<ffffffffa005a6c3>] ? vb2_fop_mmap+0x33/0x90 [videobuf2_core]
      [  403.118493]  [<ffffffff810d8055>] ? mark_held_locks+0x75/0xa0
      [  403.118497]  [<ffffffffa005a6c3>] vb2_fop_mmap+0x33/0x90 [videobuf2_core]
      [  403.118502]  [<ffffffffa0022122>] v4l2_mmap+0x62/0xa0 [videodev]
      [  403.118506]  [<ffffffff81197270>] mmap_region+0x3d0/0x5d0
      [  403.118510]  [<ffffffff8119778d>] do_mmap_pgoff+0x31d/0x400
      [  403.118513]  [<ffffffff81182940>] vm_mmap_pgoff+0x90/0xc0
      [  403.118517]  [<ffffffff81195cef>] SyS_mmap_pgoff+0x1df/0x2a0
      [  403.118521]  [<ffffffff810085c2>] SyS_mmap+0x22/0x30
      [  403.118525]  [<ffffffff8199dc69>] system_call_fastpath+0x16/0x1b
      
      The reason is that vb2_fop_mmap and vb2_fop_get_unmapped_area take the core lock
      while they are called with the mmap_sem semaphore held. But elsewhere in the code
      the core lock is taken first but calls to copy_to/from_user() can take the mmap_sem
      semaphore as well, potentially causing a classical A-B/B-A deadlock.
      
      However, the mmap/get_unmapped_area calls really shouldn't take the core lock
      at all. So what would happen if they don't take the core lock anymore?
      
      There are two situations that need to be taken into account: calling mmap while
      new buffers are being added and calling mmap while buffers are being deleted.
      
      The first case works almost fine without a lock: in all cases mmap relies on
      correctly filled-in q->num_buffers/q->num_planes values and those are only
      updated by reqbufs and create_buffers *after* any new buffers have been
      initialized completely. Except in one case: if an error occurred while allocating
      the buffers it will increase num_buffers and rely on __vb2_queue_free to
      decrease it again. So there is a short period where the buffer information
      may be wrong.
      
      The second case definitely does pose a problem: buffers may be in the process
      of being deleted, without the internal structure being updated.
      
      In order to fix this a new mutex is added to vb2_queue that is taken when
      buffers are allocated or deleted, and in vb2_mmap. That way vb2_mmap won't
      get stale buffer data. Note that this is a problem only for MEMORY_MMAP, so
      even though __qbuf_userptr and __qbuf_dmabuf also mess around with buffers
      (mem_priv in particular), this doesn't clash with vb2_mmap or
      vb2_get_unmapped_area since those are MMAP specific.
      
      As an additional bonus the hack in __buf_prepare, the USERPTR case, can be
      removed as well since mmap() no longer takes the core lock.
      
      All in all a much cleaner solution.
      Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
      Acked-by: NLaurent Pinchart <laurent.pinchart@ideasonboard.com>
      Acked-by: NMarek Szyprowski <m.szyprowski@samsung.com>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      f035eb4e
    • D
      [media] vmalloc_sg: off by one in error handling · 23d3090f
      Dan Carpenter 提交于
      The "i--" needs to happen at the start of the loop or it will try to
      release something bogus (probably it will crash) and it won't release
      the first ->vaddr_page[].
      
      Fixes: 7b4eeed1 ('[media] vmalloc_sg: make sure all pages in vmalloc area are really DMA-ready')
      Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com>
      Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      23d3090f
    • L
      [media] v4l: subdev: Extend default link validation to cover field order · 24acf8b2
      Laurent Pinchart 提交于
      The field order must match between the source and sink pads, or the sink
      pad field order must be NONE. This allows connecting an interlaced
      source to a bridge that has no hardware support for interlaced formats.
      Signed-off-by: NLaurent Pinchart <laurent.pinchart@ideasonboard.com>
      Tested-by: NEnrico Butera <ebutera@users.sourceforge.net>
      Acked-by: NSakari Ailus <sakari.ailus@iki.fi>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      24acf8b2
    • S
      [media] v4l: Add test pattern colour component controls · 0fc87864
      Sakari Ailus 提交于
      In many cases the test pattern has selectable values for each colour
      component. Implement controls for raw bayer components. Additional controls
      should be defined for colour components that are not covered by these
      controls.
      Signed-off-by: NSakari Ailus <sakari.ailus@linux.intel.com>
      Acked-by: NHans Verkuil <hans.verkuil@cisco.com>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      0fc87864
    • M
      [media] dvb-frontend: add core support for tuner suspend/resume · 59d7889a
      Mauro Carvalho Chehab 提交于
      While several tuners have some sort of suspend/resume
      implementation, this is currently mangled with an optional
      .sleep callback that it is also used to put the device on
      low power mode.
      
      Not all drivers implement it, as returning the driver from
      low power may require to re-load the firmware, with takes
      some time. Also, some drivers may delay it.
      
      So, the more coherent is to add two new optional callbacks
      that will let the tuners to directy implement suspend and
      resume callbacks if they need.
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      59d7889a
  12. 28 7月, 2014 1 次提交
    • H
      [media] v4l2-ctrls: fix rounding calculation · 9c9cb1fa
      Hans Verkuil 提交于
      Commit 958c7c7e ("[media] v4l2-ctrls: fix corner case in round-to-range code") broke
      controls that use a negative range.
      
      The cause was a s32/u32 mixup: ctrl->step is unsigned while all others are signed. So
      the result type of the expression '(ctrl)->maximum - ((ctrl)->step / 2)' became unsigned,
      making 'val >= (ctrl)->maximum - ((ctrl)->step / 2)' true, since '((u32)-128) > 128'
      (if val = -128, maximum = 128 and step = 1).
      
      So carefully cast (step / 2) to s32.
      
      There was one cast of step to s32 where it should have been u32 because both offset and
      step are unsigned, so casting to signed makes no sense there. You do need a cast to u32
      there, because otherwise architectures that have no 64-bit division start complaining
      (step is a u64).
      Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
      Reported-by: NFrank Schäfer <fschaefer.oss@googlemail.com>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      9c9cb1fa
  13. 26 7月, 2014 5 次提交
  14. 22 7月, 2014 2 次提交
    • M
      [media] v4l2-mem2mem: export v4l2_m2m_try_schedule · 1190a419
      Michael Olbrich 提交于
      Some drivers might allow to decode remaining frames from an internal ringbuffer
      after a decoder stop command. Allow those to call v4l2_m2m_try_schedule
      directly.
      Signed-off-by: NMichael Olbrich <m.olbrich@pengutronix.de>
      Signed-off-by: NPhilipp Zabel <p.zabel@pengutronix.de>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      1190a419
    • M
      [media] v4l2-subdev: Fix compilation when !VIDEO_V4L2_SUBDEV_API · d352bcc9
      Mauro Carvalho Chehab 提交于
      As reported by Kbuildtest:
      
         drivers/media/v4l2-core/v4l2-subdev.c: In function 'check_format':
         drivers/media/v4l2-core/v4l2-subdev.c:136:23: error: 'struct v4l2_subdev' has no member named 'entity'
           if (format->pad >= sd->entity.num_pads)
                                ^
         drivers/media/v4l2-core/v4l2-subdev.c: In function 'check_crop':
         drivers/media/v4l2-core/v4l2-subdev.c:148:21: error: 'struct v4l2_subdev' has no member named 'entity'
           if (crop->pad >= sd->entity.num_pads)
                              ^
         drivers/media/v4l2-core/v4l2-subdev.c: In function 'check_selection':
         drivers/media/v4l2-core/v4l2-subdev.c:161:20: error: 'struct v4l2_subdev' has no member named 'entity'
           if (sel->pad >= sd->entity.num_pads)
                             ^
         drivers/media/v4l2-core/v4l2-subdev.c: In function 'check_edid':
         drivers/media/v4l2-core/v4l2-subdev.c:169:21: error: 'struct v4l2_subdev' has no member named 'entity'
           if (edid->pad >= sd->entity.num_pads)
                              ^
         drivers/media/v4l2-core/v4l2-subdev.c: In function 'subdev_do_ioctl':
      >> drivers/media/v4l2-core/v4l2-subdev.c:186:6: warning: unused variable 'rval' [-Wunused-variable]
           int rval;
               ^
         drivers/media/v4l2-core/v4l2-subdev.c: At top level:
         drivers/media/v4l2-core/v4l2-subdev.c:129:12: warning: 'check_format' defined but not used [-Wunused-function]
          static int check_format(struct v4l2_subdev *sd,
                     ^
         drivers/media/v4l2-core/v4l2-subdev.c:142:12: warning: 'check_crop' defined but not used [-Wunused-function]
          static int check_crop(struct v4l2_subdev *sd, struct v4l2_subdev_crop *crop)
                     ^
         drivers/media/v4l2-core/v4l2-subdev.c:154:12: warning: 'check_selection' defined but not used [-Wunused-function]
          static int check_selection(struct v4l2_subdev *sd,
                     ^
         drivers/media/v4l2-core/v4l2-subdev.c:167:12: warning: 'check_edid' defined but not used [-Wunused-function]
          static int check_edid(struct v4l2_subdev *sd, struct v4l2_subdev_edid *edid)
      
      The above warnins happen because those functions are used only
      when the V4L2 subdev API is enabled.
      Reported-by: Nkbuild test robot <fengguang.wu@intel.com>
      Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      d352bcc9