1. 05 5月, 2011 1 次提交
  2. 23 3月, 2011 2 次提交
  3. 22 3月, 2011 3 次提交
  4. 19 1月, 2011 2 次提交
    • H
      [media] v4l2-device: fix 'use-after-freed' oops · 672dcd54
      Hans Verkuil 提交于
      Fix a bug in v4l2_device_unregister where the sd pointer can be dereferenced
      after it was freed.
      
      Normally the i2c adapter is removed before this function is called. Removing
      the adapter will also unregister all subdevs on that adapter, so generally
      v4l2_device_unregister has nothing to do. However, in the case of a platform
      i2c bus that bus is generally not freed.
      
      In that case, after freeing the i2c subdevice the code will fall into the
      second block when it tests if the subdev is a SPI device. But by that time
      the subdev is already freed and the kernel oopses.
      
      The fix is trivial: continue with the loop after freeing the i2c or spi
      subdevice.
      Signed-off-by: NHans Verkuil <hverkuil@xs4all.nl>
      Reported-by: NDaniel Drake <dsd@laptop.org>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
      672dcd54
    • H
      [media] v4l2-subdev: add (un)register internal ops · 45f6f84a
      Hans Verkuil 提交于
      Some subdevs need to call into the board code after they are registered
      and have a valid struct v4l2_device pointer. The s_config op was abused
      for this, but now that it is removed we need a cleaner way of solving this.
      
      So this patch adds a struct with internal ops that the v4l2 core can call.
      
      Currently only two ops exist: register and unregister. Subdevs can implement
      these to call the board code and pass it the v4l2_device pointer, which the
      board code can then use to get access to the struct that embeds the
      v4l2_device.
      
      It is expected that in the future open and close ops will also be added.
      Signed-off-by: NHans Verkuil <hverkuil@xs4all.nl>
      Acked-by: NLaurent Pinchart <laurent.pinchart@ideasonboard.com>
      Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
      45f6f84a
  5. 02 12月, 2010 1 次提交
  6. 09 8月, 2010 1 次提交
  7. 18 5月, 2010 1 次提交
  8. 17 6月, 2009 4 次提交
  9. 30 3月, 2009 3 次提交
  10. 25 3月, 2009 1 次提交
  11. 08 1月, 2009 1 次提交
  12. 30 12月, 2008 1 次提交