1. 23 4月, 2014 2 次提交
    • H
      [media] vb2: fix compiler warning · ce9c2244
      Hans Verkuil 提交于
      When compiling this for older kernels using the compatibility build
      the compiler complains about uninitialized variables:
      
      In file included from include/linux/kernel.h:20:0,
                       from include/linux/cache.h:4,
                       from include/linux/time.h:7,
                       from include/linux/input.h:13,
                       from /home/hans/work/build/media_build/v4l/compat.h:9,
                       from <command-line>:0:
      /home/hans/work/build/media_build/v4l/videobuf2-core.c: In function 'vb2_mmap':
      include/linux/dynamic_debug.h:60:9: warning: 'plane' may be used uninitialized in this function [-Wmaybe-uninitialized]
         printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__);  \
               ^
      /home/hans/work/build/media_build/v4l/videobuf2-core.c:2381:23: note: 'plane' was declared here
        unsigned int buffer, plane;
                             ^
      In file included from include/linux/kernel.h:20:0,
                       from include/linux/cache.h:4,
                       from include/linux/time.h:7,
                       from include/linux/input.h:13,
                       from /home/hans/work/build/media_build/v4l/compat.h:9,
                       from <command-line>:0:
      include/linux/dynamic_debug.h:60:9: warning: 'buffer' may be used uninitialized in this function [-Wmaybe-uninitialized]
         printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__);  \
               ^
      /home/hans/work/build/media_build/v4l/videobuf2-core.c:2381:15: note: 'buffer' was declared here
        unsigned int buffer, plane;
                     ^
      
      While these warnings are bogus (the call to __find_plane_by_offset will
      set buffer and plane), it doesn't hurt to initialize these variables.
      Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      ce9c2244
    • H
      [media] vb2: stop_streaming should return void · e37559b2
      Hans Verkuil 提交于
      The vb2 core ignores any return code from the stop_streaming op.
      And there really isn't anything it can do anyway in case of an error.
      So change the return type to void and update any drivers that implement it.
      
      The int return gave drivers the idea that this operation could actually
      fail, but that's really not the case.
      
      The pwc amd sdr-msi3101 drivers both had this construction:
      
              if (mutex_lock_interruptible(&s->v4l2_lock))
                      return -ERESTARTSYS;
      
      This has been updated to just call mutex_lock(). The stop_streaming op
      expects this to really stop streaming and I very much doubt this will
      work reliably if stop_streaming just returns without really stopping the
      DMA.
      Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
      Acked-by: NPawel Osciak <pawel@osciak.com>
      Acked-by: NSakari Ailus <sakari.ailus@linux.intel.com>
      Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
      e37559b2
  2. 17 4月, 2014 12 次提交
  3. 11 3月, 2014 14 次提交
  4. 06 3月, 2014 5 次提交
  5. 04 2月, 2014 1 次提交
  6. 07 1月, 2014 6 次提交