[GIT PULL FOR v3.9] Davinci VPFE Media Controller capture driver for DM365

2012-12-21 Thread Prabhakar Lad
Hi Mauro,

Please pull the following patches for DaVinci VPFE driver for DM365.
The patches have gone through good amount of reviews, and
Acked by Laurent, Hans and Sakari and is agreed to be part of the staging.

Regards,
--Prabhakar


The following changes since commit 4bb891ebf60eb43ebd04e09bbcad24013067873f:

  [media] ivtv: ivtv-driver: Replace 'flush_work_sync()' (2012-12-20
15:22:30 -0200)

are available in the git repository at:
  git://linuxtv.org/mhadli/v4l-dvb-davinci_devices.git vpfe_driver_staging

Manjunath Hadli (9):
  davinci: vpfe: add v4l2 capture driver with media interface
  davinci: vpfe: add v4l2 video driver support
  davinci: vpfe: dm365: add IPIPEIF driver based on media framework
  davinci: vpfe: dm365: add ISIF driver based on media framework
  davinci: vpfe: dm365: add IPIPE support for media controller driver
  davinci: vpfe: dm365: add IPIPE hardware layer support
  davinci: vpfe: dm365: resizer driver based on media framework
  davinci: vpfe: dm365: add build infrastructure for capture driver
  davinci: vpfe: Add documentation and TODO

 drivers/staging/media/Kconfig  |2 +
 drivers/staging/media/Makefile |1 +
 drivers/staging/media/davinci_vpfe/Kconfig |9 +
 drivers/staging/media/davinci_vpfe/Makefile|3 +
 drivers/staging/media/davinci_vpfe/TODO|   37 +
 .../staging/media/davinci_vpfe/davinci-vpfe-mc.txt |  154 ++
 .../staging/media/davinci_vpfe/davinci_vpfe_user.h | 1290 
 drivers/staging/media/davinci_vpfe/dm365_ipipe.c   | 1863 +
 drivers/staging/media/davinci_vpfe/dm365_ipipe.h   |  179 ++
 .../staging/media/davinci_vpfe/dm365_ipipe_hw.c| 1048 ++
 .../staging/media/davinci_vpfe/dm365_ipipe_hw.h|  559 ++
 drivers/staging/media/davinci_vpfe/dm365_ipipeif.c | 1071 ++
 drivers/staging/media/davinci_vpfe/dm365_ipipeif.h |  233 +++
 .../media/davinci_vpfe/dm365_ipipeif_user.h|   93 +
 drivers/staging/media/davinci_vpfe/dm365_isif.c| 2104 
 drivers/staging/media/davinci_vpfe/dm365_isif.h|  203 ++
 .../staging/media/davinci_vpfe/dm365_isif_regs.h   |  294 +++
 drivers/staging/media/davinci_vpfe/dm365_resizer.c | 1999 +++
 drivers/staging/media/davinci_vpfe/dm365_resizer.h |  244 +++
 drivers/staging/media/davinci_vpfe/vpfe.h  |   86 +
 .../staging/media/davinci_vpfe/vpfe_mc_capture.c   |  740 +++
 .../staging/media/davinci_vpfe/vpfe_mc_capture.h   |   97 +
 drivers/staging/media/davinci_vpfe/vpfe_video.c| 1620 +++
 drivers/staging/media/davinci_vpfe/vpfe_video.h|  155 ++
 24 files changed, 14084 insertions(+), 0 deletions(-)
 create mode 100644 drivers/staging/media/davinci_vpfe/Kconfig
 create mode 100644 drivers/staging/media/davinci_vpfe/Makefile
 create mode 100644 drivers/staging/media/davinci_vpfe/TODO
 create mode 100644 drivers/staging/media/davinci_vpfe/davinci-vpfe-mc.txt
 create mode 100644 drivers/staging/media/davinci_vpfe/davinci_vpfe_user.h
 create mode 100644 drivers/staging/media/davinci_vpfe/dm365_ipipe.c
 create mode 100644 drivers/staging/media/davinci_vpfe/dm365_ipipe.h
 create mode 100644 drivers/staging/media/davinci_vpfe/dm365_ipipe_hw.c
 create mode 100644 drivers/staging/media/davinci_vpfe/dm365_ipipe_hw.h
 create mode 100644 drivers/staging/media/davinci_vpfe/dm365_ipipeif.c
 create mode 100644 drivers/staging/media/davinci_vpfe/dm365_ipipeif.h
 create mode 100644 drivers/staging/media/davinci_vpfe/dm365_ipipeif_user.h
 create mode 100644 drivers/staging/media/davinci_vpfe/dm365_isif.c
 create mode 100644 drivers/staging/media/davinci_vpfe/dm365_isif.h
 create mode 100644 drivers/staging/media/davinci_vpfe/dm365_isif_regs.h
 create mode 100644 drivers/staging/media/davinci_vpfe/dm365_resizer.c
 create mode 100644 drivers/staging/media/davinci_vpfe/dm365_resizer.h
 create mode 100644 drivers/staging/media/davinci_vpfe/vpfe.h
 create mode 100644 drivers/staging/media/davinci_vpfe/vpfe_mc_capture.c
 create mode 100644 drivers/staging/media/davinci_vpfe/vpfe_mc_capture.h
 create mode 100644 drivers/staging/media/davinci_vpfe/vpfe_video.c
 create mode 100644 drivers/staging/media/davinci_vpfe/vpfe_video.h
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Build of media_build in Mandriva 2011

2012-12-21 Thread Herman Viaene

Hallo,

I tried to build these drivers in order to get my Hauppauge PVR-500 card 
to work
Note: I had the card working on previous releases thanks to the info in 
ivtvdrivers.org, but this site is empty now.


The packages needed have the same name as for Redhat, and I have been 
able to build apparently successfully.


BUT

When I booted the next day, the boot process blocked. By rebooting and 
using the verbose mode, I saw some message passing by mentioning ivtv, 
plus 10 (or more) lines of codes (the ivtv message scrolled off the 
screen) and at last Fixing recursive fault, but this requires reboot.
So I rebooted two more times, and then I could start the PC, but I did 
not check the video device, I had not enough time for that.


The next day, I had the same booting problem again, and I gave up after 
10 reboots, and re-installed Mandriva. After that, I could not find 
anything on the events in the logs (I have /var on a separate partition, 
so it does not get completely wiped out by a re-installation).


I will check the Mandriva User group on this, and keep you informed if 
anything comes out of it.


Regards

Herman Viaene

--
Veel mensen danken hun goed geweten aan hun slecht geheugen. (G. Bomans)

Lots of people owe their good conscience to their bad memory (G. Bomans)

--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH v2] s5p-mfc: Fix interrupt error handling routine

2012-12-21 Thread Kamil Debski
New context states were added but handling in s5p_mfc_handle_error for
these states was not. After this patch these states are be handled
correctly.

Signed-off-by: Kamil Debski k.deb...@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
Hi,

This is exatly the same patch as https://patchwork.kernel.org/patch/1865541/
with an additional comment added as suggested by Sachin Kamat.

This patch was tested by me and Arun. Unfortunately Sachin and Pawel could
not join in and run their tests.

Best wishes,
Kamil Debski
---
 drivers/media/platform/s5p-mfc/s5p_mfc.c |   88 +-
 1 file changed, 37 insertions(+), 51 deletions(-)

diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc.c 
b/drivers/media/platform/s5p-mfc/s5p_mfc.c
index 3afe879..5448ad1 100644
--- a/drivers/media/platform/s5p-mfc/s5p_mfc.c
+++ b/drivers/media/platform/s5p-mfc/s5p_mfc.c
@@ -412,62 +412,48 @@ leave_handle_frame:
 }
 
 /* Error handling for interrupt */
-static void s5p_mfc_handle_error(struct s5p_mfc_ctx *ctx,
-unsigned int reason, unsigned int err)
+static void s5p_mfc_handle_error(struct s5p_mfc_dev *dev,
+   struct s5p_mfc_ctx *ctx, unsigned int reason, unsigned int err)
 {
-   struct s5p_mfc_dev *dev;
unsigned long flags;
 
-   /* If no context is available then all necessary
-* processing has been done. */
-   if (ctx == NULL)
-   return;
-
-   dev = ctx-dev;
mfc_err(Interrupt Error: %08x\n, err);
-   s5p_mfc_hw_call(dev-mfc_ops, clear_int_flags, dev);
-   wake_up_dev(dev, reason, err);
 
-   /* Error recovery is dependent on the state of context */
-   switch (ctx-state) {
-   case MFCINST_INIT:
-   /* This error had to happen while acquireing instance */
-   case MFCINST_GOT_INST:
-   /* This error had to happen while parsing the header */
-   case MFCINST_HEAD_PARSED:
-   /* This error had to happen while setting dst buffers */
-   case MFCINST_RETURN_INST:
-   /* This error had to happen while releasing instance */
-   clear_work_bit(ctx);
-   wake_up_ctx(ctx, reason, err);
-   if (test_and_clear_bit(0, dev-hw_lock) == 0)
-   BUG();
-   s5p_mfc_clock_off();
-   ctx-state = MFCINST_ERROR;
-   break;
-   case MFCINST_FINISHING:
-   case MFCINST_FINISHED:
-   case MFCINST_RUNNING:
-   /* It is higly probable that an error occured
-* while decoding a frame */
-   clear_work_bit(ctx);
-   ctx-state = MFCINST_ERROR;
-   /* Mark all dst buffers as having an error */
-   spin_lock_irqsave(dev-irqlock, flags);
-   s5p_mfc_hw_call(dev-mfc_ops, cleanup_queue, ctx-dst_queue,
-   ctx-vq_dst);
-   /* Mark all src buffers as having an error */
-   s5p_mfc_hw_call(dev-mfc_ops, cleanup_queue, ctx-src_queue,
-   ctx-vq_src);
-   spin_unlock_irqrestore(dev-irqlock, flags);
-   if (test_and_clear_bit(0, dev-hw_lock) == 0)
-   BUG();
-   s5p_mfc_clock_off();
-   break;
-   default:
-   mfc_err(Encountered an error interrupt which had not been 
handled\n);
-   break;
+   if (ctx != NULL) {
+   /* Error recovery is dependent on the state of context */
+   switch (ctx-state) {
+   case MFCINST_RES_CHANGE_INIT:
+   case MFCINST_RES_CHANGE_FLUSH:
+   case MFCINST_RES_CHANGE_END:
+   case MFCINST_FINISHING:
+   case MFCINST_FINISHED:
+   case MFCINST_RUNNING:
+   /* It is higly probable that an error occured
+* while decoding a frame */
+   clear_work_bit(ctx);
+   ctx-state = MFCINST_ERROR;
+   /* Mark all dst buffers as having an error */
+   spin_lock_irqsave(dev-irqlock, flags);
+   s5p_mfc_hw_call(dev-mfc_ops, cleanup_queue,
+   ctx-dst_queue, ctx-vq_dst);
+   /* Mark all src buffers as having an error */
+   s5p_mfc_hw_call(dev-mfc_ops, cleanup_queue,
+   ctx-src_queue, ctx-vq_src);
+   spin_unlock_irqrestore(dev-irqlock, flags);
+   wake_up_ctx(ctx, reason, err);
+   break;
+   default:
+   clear_work_bit(ctx);
+   ctx-state = MFCINST_ERROR;
+   wake_up_ctx(ctx, reason, err);
+   break;
+   }
}
+   if (test_and_clear_bit(0, 

Re: [RFC v2 0/5] Common Display Framework

2012-12-21 Thread Tomasz Figa
Hi Vikas,

On Tuesday 18 of December 2012 08:31:30 Vikas Sajjan wrote:
  Hi Laurent,
 
 Thanks for the reply.
 
 On 17 December 2012 20:55, Laurent Pinchart 
 
 laurent.pinch...@ideasonboard.com wrote:
  Hi Vikas,
  
  Sorry for the late reply. I now have more time to work on CDF, so
  delays should be much shorter.
  
  On Thursday 06 December 2012 10:51:15 Vikas Sajjan wrote:
   Hi Laurent,
   
   I was thinking of porting CDF to samsung EXYNOS 5250 platform, what
   I
  
  found
  
   is that, the exynos display controller is MIPI DSI based controller.
   
   But if I look at CDF patches, it has only support for MIPI DBI based
  
  Display
  
   controller.
   
   So my question is, do we have any generic framework for MIPI DSI
   based
   display controller? basically I wanted to know, how to go about
   porting
  
  CDF
  
   for such kind of display controller.
  
  MIPI DSI support is not available yet. The only reason for that is
  that I don't have any MIPI DSI hardware to write and test the code
  with :-)
  
  The common display framework should definitely support MIPI DSI. I
  think the
  existing MIPI DBI code could be used as a base, so the implementation
  shouldn't be too high.
  
  Yeah, i was also thinking in similar lines, below is my though for
  MIPI
 
 DSI support in CDF.
 
 o   MIPI DSI support as part of CDF framework will expose
 
 §  mipi_dsi_register_device(mpi_device) (will be called mach-xxx-dt.c
 file )
 
 §  mipi_dsi_register_driver(mipi_driver, bus ops) (will be called from
 platform specific init driver call )
 
 ·bus ops will be
 
 o   read data
 
 o   write data
 
 o   write command
 
 §  MIPI DSI will be registered as bus_register()
 
 When MIPI DSI probe is called, it (e.g., Exynos or OMAP MIPI DSI) will
 initialize the MIPI DSI HW IP.
 
  This probe will also parse the DT file for MIPI DSI based panel, add
 the panel device (device_add() ) to kernel and register the display
 entity with its control and  video ops with CDF.
 
 I can give this a try.

I am currently in progress of reworking Exynos MIPI DSIM code and s6e8ax0 
LCD driver to use the v2 RFC of Common Display Framework. I have most of 
the work done, I have just to solve several remaining problems.

Best regards,
-- 
Tomasz Figa
Samsung Poland RD Center
SW Solution Development, Linux Platform

--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[GIT PULL FOR v3.9] Davinci VPBE Trivial Fixes

2012-12-21 Thread Prabhakar Lad
Hi Mauro,

Please pull the following patches for DaVinci VPBE driver.
One of the patch has ARM changes and is Acked-by the ARM
maintainer.

Thanks and Regards,
--Prabhakar Lad


The following changes since commit 4bb891ebf60eb43ebd04e09bbcad24013067873f:

  [media] ivtv: ivtv-driver: Replace 'flush_work_sync()' (2012-12-20
15:22:30 -0200)

are available in the git repository at:
  git://linuxtv.org/mhadli/v4l-dvb-davinci_devices.git davinci_media

Lad, Prabhakar (2):
  davinci: vpbe: pass different platform names to handle different ip's
  media: davinci: vpbe: enable building of vpbe driver for DM355 and DM365

Wei Yongjun (3):
  media: davinci: vpbe: fix return value check in vpbe_display_reqbufs()
  media: davinci: vpbe: return error code on error in vpbe_display_g_crop()
  davinci: vpbe: remove unused variable in vpbe_initialize()

 arch/arm/mach-davinci/board-dm644x-evm.c  |8 ++--
 arch/arm/mach-davinci/dm644x.c|   10 +---
 drivers/media/platform/davinci/Kconfig|   22 ++--
 drivers/media/platform/davinci/Makefile   |4 +-
 drivers/media/platform/davinci/vpbe.c |6 +--
 drivers/media/platform/davinci/vpbe_display.c |9 ++--
 drivers/media/platform/davinci/vpbe_osd.c |   35 ++
 drivers/media/platform/davinci/vpbe_venc.c|   65 +
 include/media/davinci/vpbe_osd.h  |5 +-
 include/media/davinci/vpbe_venc.h |5 +-
 10 files changed, 95 insertions(+), 74 deletions(-)
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/1] gspca: Use module_usb_driver macro

2012-12-21 Thread Hans de Goede

Hi,

On 12/12/2012 09:58 AM, Sachin Kamat wrote:

module_usb_driver eliminates a lot of boilerplate by replacing
module_init() and module_exit() calls.

Signed-off-by: Sachin Kamat sachin.ka...@linaro.org


Thanks I've added this patch to my tree, and it will be included
in my fixes pull-req for 3.8 to Mauro later today.

Regards,

Hans


---
Compile tested with linux-next
---
  drivers/media/usb/gspca/jl2005bcd.c |   18 +-
  1 files changed, 1 insertions(+), 17 deletions(-)

diff --git a/drivers/media/usb/gspca/jl2005bcd.c 
b/drivers/media/usb/gspca/jl2005bcd.c
index 62ba80d..fdaeeb1 100644
--- a/drivers/media/usb/gspca/jl2005bcd.c
+++ b/drivers/media/usb/gspca/jl2005bcd.c
@@ -536,20 +536,4 @@ static struct usb_driver sd_driver = {
  #endif
  };

-/* -- module insert / remove -- */
-static int __init sd_mod_init(void)
-{
-   int ret;
-
-   ret = usb_register(sd_driver);
-   if (ret  0)
-   return ret;
-   return 0;
-}
-static void __exit sd_mod_exit(void)
-{
-   usb_deregister(sd_driver);
-}
-
-module_init(sd_mod_init);
-module_exit(sd_mod_exit);
+module_usb_driver(sd_driver);


--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] [media] gspca_kinect: add Kinect for Windows USB id

2012-12-21 Thread Hans de Goede

Hi,

On 12/10/2012 12:18 AM, Antonio Ospite wrote:

From: Jacob Schloss jacob.schl...@unlimitedautomata.com

Add the USB ID for the Kinect for Windows RGB camera so it can be used
with the gspca_kinect driver.

Signed-off-by: Jacob Schloss jacob.schl...@unlimitedautomata.com
Signed-off-by: Antonio Ospite osp...@studenti.unina.it
---

Thanks Jacob, I took the liberty to rebase the patch on top of
linux-3.7.0-rc7 as the gspca location has changed from
drivers/media/video/gspca to drivers/media/usb/gspca

It will be a little easier for HdG to apply it.


Thanks I've added this patch to my tree, and it will be included
in my fixes pull-req for 3.8 to Mauro later today.

Regards,

Hans



Regards,
Antonio

  drivers/media/usb/gspca/kinect.c |1 +
  1 file changed, 1 insertion(+)

diff --git a/drivers/media/usb/gspca/kinect.c b/drivers/media/usb/gspca/kinect.c
index 40ad668..3773a8a 100644
--- a/drivers/media/usb/gspca/kinect.c
+++ b/drivers/media/usb/gspca/kinect.c
@@ -381,6 +381,7 @@ static const struct sd_desc sd_desc = {
  /* -- module initialisation -- */
  static const struct usb_device_id device_table[] = {
{USB_DEVICE(0x045e, 0x02ae)},
+   {USB_DEVICE(0x045e, 0x02bf)},
{}
  };



--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PULL] dvb-frontends: use %*ph[N] to dump small buffers

2012-12-21 Thread Michael Krufky
Mauro,

updated pwclient script and pull request follows:

pwclient update -s 'superseded' 15687
pwclient update -s 'superseded' 15688
pwclient update -s 'superseded' 15933

The following changes since commit 5b7d8de7d2328f7b25fe4645eafee7e48f9b7df3:

  [media] au0828: break au0828_card_setup() down into smaller
functions (2012-12-17 14:34:27 -0200)

are available in the git repository at:

  git://git.linuxtv.org/mkrufky/tuners frontends

for you to fetch changes up to cf866aea2dd6730b20be9ad69f8829675b0e6234:

  or51211: apply pr_fmt and use pr_* macros instead of printk
(2012-12-18 08:20:28 -0500)


Andy Shevchenko (3):
  or51211: use %*ph[N] to dump small buffers
  ix2505v: use %*ph[N] to dump small buffers
  or51211: apply pr_fmt and use pr_* macros instead of printk

 drivers/media/dvb-frontends/ix2505v.c |2 +-
 drivers/media/dvb-frontends/or51211.c |   99
---
 2 files changed, 45 insertions(+), 56 deletions(-)

Cheers,

Mike

On Mon, Dec 17, 2012 at 9:16 PM, Michael Krufky mkru...@linuxtv.org wrote:
 Mauro,

 Please apply the following to update status in patchwork along with
 the following merge request...

 pwclient update -s 'superseded' 15687
 pwclient update -s 'changes requested' 15688

 I am marking 15687 as superseded because I broke the patch into two
 separate patches.  (see merge request below)
 15688 causes new build warnings, so I've asked Andy to resubmit.

 Please merge:

 The following changes since commit 5b7d8de7d2328f7b25fe4645eafee7e48f9b7df3:

   [media] au0828: break au0828_card_setup() down into smaller
 functions (2012-12-17 14:34:27 -0200)

 are available in the git repository at:

   git://git.linuxtv.org/mkrufky/tuners frontends

 for you to fetch changes up to 34c87fa2214d134c0028c97d7aab3dd769bb3bf0:

   ix2505v: use %*ph[N] to dump small buffers (2012-12-17 20:12:29 -0500)

 
 Andy Shevchenko (2):
   or51211: use %*ph[N] to dump small buffers
   ix2505v: use %*ph[N] to dump small buffers

  drivers/media/dvb-frontends/ix2505v.c |2 +-
  drivers/media/dvb-frontends/or51211.c |5 +
  2 files changed, 2 insertions(+), 5 deletions(-)

 Cheers,

 Mike
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PULL] dvb-frontends: use %*ph[N] to dump small buffers

2012-12-21 Thread Michael Krufky
rebased against today's tip, as per your request :-)

pwclient update -s 'superseded' 15687
pwclient update -s 'superseded' 15688
pwclient update -s 'superseded' 15933
pwclient update -s 'accepted' 15938
pwclient update -s 'superseded' 15970


The following changes since commit 1b5901331ff3af4bdc1b998a056a248c9924e2d1:

  [media] exynos-gsc: modify number of output/capture buffers
(2012-12-21 10:26:44 -0200)

are available in the git repository at:

  git://git.linuxtv.org/mkrufky/tuners frontends-andy

for you to fetch changes up to d81eae5f62d705b786e8e1ad13eac78ffa95cf18:

  or51211: apply pr_fmt and use pr_* macros instead of printk
(2012-12-21 08:25:09 -0500)


Andy Shevchenko (3):
  or51211: use %*ph[N] to dump small buffers
  ix2505v: use %*ph[N] to dump small buffers
  or51211: apply pr_fmt and use pr_* macros instead of printk

 drivers/media/dvb-frontends/ix2505v.c |2 +-
 drivers/media/dvb-frontends/or51211.c |   99
---
 2 files changed, 45 insertions(+), 56 deletions(-)


On Fri, Dec 21, 2012 at 8:12 AM, Michael Krufky mkru...@linuxtv.org wrote:
 Argh!  I forgot one pwclient command:

 pwclient update -s 'accepted' 15938

 Thanks again,

 Mike

 On Fri, Dec 21, 2012 at 8:10 AM, Michael Krufky mkru...@linuxtv.org wrote:
 Mauro,

 updated pwclient script and pull request follows:

 pwclient update -s 'superseded' 15687
 pwclient update -s 'superseded' 15688
 pwclient update -s 'superseded' 15933

 The following changes since commit 5b7d8de7d2328f7b25fe4645eafee7e48f9b7df3:

   [media] au0828: break au0828_card_setup() down into smaller
 functions (2012-12-17 14:34:27 -0200)

 are available in the git repository at:

   git://git.linuxtv.org/mkrufky/tuners frontends

 for you to fetch changes up to cf866aea2dd6730b20be9ad69f8829675b0e6234:

   or51211: apply pr_fmt and use pr_* macros instead of printk
 (2012-12-18 08:20:28 -0500)

 
 Andy Shevchenko (3):
   or51211: use %*ph[N] to dump small buffers
   ix2505v: use %*ph[N] to dump small buffers
   or51211: apply pr_fmt and use pr_* macros instead of printk

  drivers/media/dvb-frontends/ix2505v.c |2 +-
  drivers/media/dvb-frontends/or51211.c |   99
 ---
  2 files changed, 45 insertions(+), 56 deletions(-)

 Cheers,

 Mike

 On Mon, Dec 17, 2012 at 9:16 PM, Michael Krufky mkru...@linuxtv.org wrote:
 Mauro,

 Please apply the following to update status in patchwork along with
 the following merge request...

 pwclient update -s 'superseded' 15687
 pwclient update -s 'changes requested' 15688

 I am marking 15687 as superseded because I broke the patch into two
 separate patches.  (see merge request below)
 15688 causes new build warnings, so I've asked Andy to resubmit.

 Please merge:

 The following changes since commit 5b7d8de7d2328f7b25fe4645eafee7e48f9b7df3:

   [media] au0828: break au0828_card_setup() down into smaller
 functions (2012-12-17 14:34:27 -0200)

 are available in the git repository at:

   git://git.linuxtv.org/mkrufky/tuners frontends

 for you to fetch changes up to 34c87fa2214d134c0028c97d7aab3dd769bb3bf0:

   ix2505v: use %*ph[N] to dump small buffers (2012-12-17 20:12:29 -0500)

 
 Andy Shevchenko (2):
   or51211: use %*ph[N] to dump small buffers
   ix2505v: use %*ph[N] to dump small buffers

  drivers/media/dvb-frontends/ix2505v.c |2 +-
  drivers/media/dvb-frontends/or51211.c |5 +
  2 files changed, 2 insertions(+), 5 deletions(-)

 Cheers,

 Mike
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] tda10071: make sure both tuner and demod i2c addresses are specified

2012-12-21 Thread Michael Krufky
rebased against today's tip, as per your request :-)


pwclient update -s 'superseded' 15923
pwclient update -s 'superseded' 15930


The following changes since commit 1b5901331ff3af4bdc1b998a056a248c9924e2d1:

  [media] exynos-gsc: modify number of output/capture buffers
(2012-12-21 10:26:44 -0200)

are available in the git repository at:

  git://git.linuxtv.org/mkrufky/tuners tda10071

for you to fetch changes up to d562d77132333f0a7b1d704edc992a092d6d6bbe:

  tda10071: make sure both tuner and demod i2c addresses are specified
(2012-12-21 08:29:49 -0500)

Cheers,

Mike

On Fri, Dec 21, 2012 at 8:32 AM, Michael Krufky mkru...@kernellabs.com wrote:
 rebased against today's tip, as per your request :-)


 pwclient update -s 'superseded' 15923
 pwclient update -s 'superseded' 15930


 The following changes since commit 1b5901331ff3af4bdc1b998a056a248c9924e2d1:

   [media] exynos-gsc: modify number of output/capture buffers
 (2012-12-21 10:26:44 -0200)

 are available in the git repository at:

   git://git.linuxtv.org/mkrufky/tuners tda10071

 for you to fetch changes up to d562d77132333f0a7b1d704edc992a092d6d6bbe:

   tda10071: make sure both tuner and demod i2c addresses are specified
 (2012-12-21 08:29:49 -0500)

 
 Michael Krufky (1):
   tda10071: make sure both tuner and demod i2c addresses are specified

  drivers/media/dvb-frontends/tda10071.c  |   18 +++---
  drivers/media/dvb-frontends/tda10071.h  |4 ++--
  drivers/media/pci/cx23885/cx23885-dvb.c |2 +-
  drivers/media/usb/em28xx/em28xx-dvb.c   |3 ++-
  4 files changed, 20 insertions(+), 7 deletions(-)

 Cheers,

 Mike

 On Mon, Dec 17, 2012 at 10:10 AM, Michael Krufky mkru...@linuxtv.org wrote:
 As discussed on irc, the following pwclient commands should update the
 status of the patches in patchwork to correspond with this merge
 request:

 pwclient update -s 'superseded' 15923
 pwclient update -s 'accepted' 15930


 Cheers,

 Mike

 On Mon, Dec 17, 2012 at 10:09 AM, Michael Krufky mkru...@linuxtv.org wrote:
 Mauro,

 Please merge:

 The following changes since commit 4c8e64232d4a71e68d68b9093506966c0244a526:

   cx23885: add basic DVB-S2 support for Hauppauge HVR-4400 (2012-12-16
 12:27:25 -0500)

 are available in the git repository at:

   git://linuxtv.org/mkrufky/tuners tda10071

 for you to fetch changes up to 326e65af0104faf8a243e534eb8bfdb35b73f4ed:

   tda10071: make sure both tuner and demod i2c addresses are specified
 (2012-12-16 18:05:02 -0500)

 
 Michael Krufky (1):
   tda10071: make sure both tuner and demod i2c addresses are specified

  drivers/media/dvb-frontends/tda10071.c  |   18 +++---
  drivers/media/dvb-frontends/tda10071.h  |4 ++--
  drivers/media/pci/cx23885/cx23885-dvb.c |2 +-
  drivers/media/usb/em28xx/em28xx-dvb.c   |3 ++-
  4 files changed, 20 insertions(+), 7 deletions(-)

 Cheers,

 Mike

 On Sun, Dec 16, 2012 at 8:12 PM, Michael Krufky mkru...@linuxtv.org wrote:
 display an error message if either tuner_i2c_addr or demod_i2c_addr
 are not specified in the tda10071_config structure

 Signed-off-by: Michael Krufky mkru...@linuxtv.org
 ---
  drivers/media/dvb-frontends/tda10071.c  |   18 +++---
  drivers/media/dvb-frontends/tda10071.h  |4 ++--
  drivers/media/pci/cx23885/cx23885-dvb.c |2 +-
  drivers/media/usb/em28xx/em28xx-dvb.c   |3 ++-
  4 files changed, 20 insertions(+), 7 deletions(-)

 diff --git a/drivers/media/dvb-frontends/tda10071.c 
 b/drivers/media/dvb-frontends/tda10071.c
 index 7103629..02f9234 100644
 --- a/drivers/media/dvb-frontends/tda10071.c
 +++ b/drivers/media/dvb-frontends/tda10071.c
 @@ -30,7 +30,7 @@ static int tda10071_wr_regs(struct tda10071_priv *priv, 
 u8 reg, u8 *val,
 u8 buf[len+1];
 struct i2c_msg msg[1] = {
 {
 -   .addr = priv-cfg.i2c_address,
 +   .addr = priv-cfg.demod_i2c_addr,
 .flags = 0,
 .len = sizeof(buf),
 .buf = buf,
 @@ -59,12 +59,12 @@ static int tda10071_rd_regs(struct tda10071_priv 
 *priv, u8 reg, u8 *val,
 u8 buf[len];
 struct i2c_msg msg[2] = {
 {
 -   .addr = priv-cfg.i2c_address,
 +   .addr = priv-cfg.demod_i2c_addr,
 .flags = 0,
 .len = 1,
 .buf = reg,
 }, {
 -   .addr = priv-cfg.i2c_address,
 +   .addr = priv-cfg.demod_i2c_addr,
 .flags = I2C_M_RD,
 .len = sizeof(buf),
 .buf = buf,
 @@ -1202,6 +1202,18 @@ struct dvb_frontend *tda10071_attach(const struct 
 tda10071_config *config,
 goto error;
 }

 +   /* make sure demod 

Re: [PATCH] tda10071: make sure both tuner and demod i2c addresses are specified

2012-12-21 Thread Michael Krufky
rebased against today's tip, as per your request :-)


pwclient update -s 'superseded' 15923
pwclient update -s 'superseded' 15930


The following changes since commit 1b5901331ff3af4bdc1b998a056a248c9924e2d1:

  [media] exynos-gsc: modify number of output/capture buffers
(2012-12-21 10:26:44 -0200)

are available in the git repository at:

  git://git.linuxtv.org/mkrufky/tuners tda10071

for you to fetch changes up to d562d77132333f0a7b1d704edc992a092d6d6bbe:

  tda10071: make sure both tuner and demod i2c addresses are specified
(2012-12-21 08:29:49 -0500)


Michael Krufky (1):
  tda10071: make sure both tuner and demod i2c addresses are specified

 drivers/media/dvb-frontends/tda10071.c  |   18 +++---
 drivers/media/dvb-frontends/tda10071.h  |4 ++--
 drivers/media/pci/cx23885/cx23885-dvb.c |2 +-
 drivers/media/usb/em28xx/em28xx-dvb.c   |3 ++-
 4 files changed, 20 insertions(+), 7 deletions(-)

Cheers,

Mike

On Mon, Dec 17, 2012 at 10:10 AM, Michael Krufky mkru...@linuxtv.org wrote:
 As discussed on irc, the following pwclient commands should update the
 status of the patches in patchwork to correspond with this merge
 request:

 pwclient update -s 'superseded' 15923
 pwclient update -s 'accepted' 15930


 Cheers,

 Mike

 On Mon, Dec 17, 2012 at 10:09 AM, Michael Krufky mkru...@linuxtv.org wrote:
 Mauro,

 Please merge:

 The following changes since commit 4c8e64232d4a71e68d68b9093506966c0244a526:

   cx23885: add basic DVB-S2 support for Hauppauge HVR-4400 (2012-12-16
 12:27:25 -0500)

 are available in the git repository at:

   git://linuxtv.org/mkrufky/tuners tda10071

 for you to fetch changes up to 326e65af0104faf8a243e534eb8bfdb35b73f4ed:

   tda10071: make sure both tuner and demod i2c addresses are specified
 (2012-12-16 18:05:02 -0500)

 
 Michael Krufky (1):
   tda10071: make sure both tuner and demod i2c addresses are specified

  drivers/media/dvb-frontends/tda10071.c  |   18 +++---
  drivers/media/dvb-frontends/tda10071.h  |4 ++--
  drivers/media/pci/cx23885/cx23885-dvb.c |2 +-
  drivers/media/usb/em28xx/em28xx-dvb.c   |3 ++-
  4 files changed, 20 insertions(+), 7 deletions(-)

 Cheers,

 Mike

 On Sun, Dec 16, 2012 at 8:12 PM, Michael Krufky mkru...@linuxtv.org wrote:
 display an error message if either tuner_i2c_addr or demod_i2c_addr
 are not specified in the tda10071_config structure

 Signed-off-by: Michael Krufky mkru...@linuxtv.org
 ---
  drivers/media/dvb-frontends/tda10071.c  |   18 +++---
  drivers/media/dvb-frontends/tda10071.h  |4 ++--
  drivers/media/pci/cx23885/cx23885-dvb.c |2 +-
  drivers/media/usb/em28xx/em28xx-dvb.c   |3 ++-
  4 files changed, 20 insertions(+), 7 deletions(-)

 diff --git a/drivers/media/dvb-frontends/tda10071.c 
 b/drivers/media/dvb-frontends/tda10071.c
 index 7103629..02f9234 100644
 --- a/drivers/media/dvb-frontends/tda10071.c
 +++ b/drivers/media/dvb-frontends/tda10071.c
 @@ -30,7 +30,7 @@ static int tda10071_wr_regs(struct tda10071_priv *priv, 
 u8 reg, u8 *val,
 u8 buf[len+1];
 struct i2c_msg msg[1] = {
 {
 -   .addr = priv-cfg.i2c_address,
 +   .addr = priv-cfg.demod_i2c_addr,
 .flags = 0,
 .len = sizeof(buf),
 .buf = buf,
 @@ -59,12 +59,12 @@ static int tda10071_rd_regs(struct tda10071_priv *priv, 
 u8 reg, u8 *val,
 u8 buf[len];
 struct i2c_msg msg[2] = {
 {
 -   .addr = priv-cfg.i2c_address,
 +   .addr = priv-cfg.demod_i2c_addr,
 .flags = 0,
 .len = 1,
 .buf = reg,
 }, {
 -   .addr = priv-cfg.i2c_address,
 +   .addr = priv-cfg.demod_i2c_addr,
 .flags = I2C_M_RD,
 .len = sizeof(buf),
 .buf = buf,
 @@ -1202,6 +1202,18 @@ struct dvb_frontend *tda10071_attach(const struct 
 tda10071_config *config,
 goto error;
 }

 +   /* make sure demod i2c address is specified */
 +   if (!config-demod_i2c_addr) {
 +   dev_dbg(i2c-dev, %s: invalid demod i2c address!\n, 
 __func__);
 +   goto error;
 +   }
 +
 +   /* make sure tuner i2c address is specified */
 +   if (!config-tuner_i2c_addr) {
 +   dev_dbg(i2c-dev, %s: invalid tuner i2c address!\n, 
 __func__);
 +   goto error;
 +   }
 +
 /* setup the priv */
 priv-i2c = i2c;
 memcpy(priv-cfg, config, sizeof(struct tda10071_config));
 diff --git a/drivers/media/dvb-frontends/tda10071.h 
 b/drivers/media/dvb-frontends/tda10071.h
 index a20d5c4..bff1c38 100644
 --- 

[GIT-PULL fixes for 3.8] Various USB webcam fixes

2012-12-21 Thread Hans de Goede

Hi Mauro,

Note this pullreq superceeds my previous pullreq.

Please pull from my tree for some assorted USB webcam fixes for 3.8

The following changes since commit 49cc629df16f2a15917800a8579bd9c25c41b634:

  [media] MAINTAINERS: add si470x-usb+common and si470x-i2c entries (2012-12-11 
18:16:13 -0200)

are available in the git repository at:

  git://linuxtv.org/hgoede/gspca.git media-for_v3.8

for you to fetch changes up to 4fcbd77b664f9acd540ec410a255a963b039fa21:

  gspca_sonixj: Add a small delay after i2c_w1 (2012-12-21 15:19:19 +0100)


Erik Andrén (1):
  gspca_stv06xx: Disable flip controls for vv6410 sensor

Hans de Goede (6):
  gspca-pac207: Add a led_invert module parameter
  stk-webcam: Add an upside down dmi table, and add the Asus G1 to it
  Documentation/media: Remove docs for obsoleted and removed v4l1 drivers
  gspca_t613: Fix compiling with GSPCA_DEBUG defined
  gspca_sonixb: Properly wait between i2c writes
  gspca_sonixj: Add a small delay after i2c_w1

Jacob Schloss (1):
  gspca_kinect: add Kinect for Windows USB id

Jean-François Moine (1):
  gspca - stv06xx: Fix a regression with the bridge/sensor vv6410

Sachin Kamat (1):
  gspca: Use module_usb_driver macro

 Documentation/video4linux/et61x251.txt   | 315 
 Documentation/video4linux/ibmcam.txt | 323 
 Documentation/video4linux/m5602.txt  |  12 -
 Documentation/video4linux/ov511.txt  | 288 --
 Documentation/video4linux/se401.txt  |  54 ---
 Documentation/video4linux/stv680.txt |  53 ---
 Documentation/video4linux/w9968cf.txt| 458 ---
 Documentation/video4linux/zc0301.txt | 270 -
 drivers/media/usb/gspca/jl2005bcd.c  |  18 +-
 drivers/media/usb/gspca/kinect.c |   1 +
 drivers/media/usb/gspca/pac207.c |  32 +-
 drivers/media/usb/gspca/sonixb.c |  13 +-
 drivers/media/usb/gspca/sonixj.c |   1 +
 drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c |  17 +-
 drivers/media/usb/gspca/t613.c   |   2 +-
 drivers/media/usb/stkwebcam/stk-webcam.c |  56 ++-
 16 files changed, 96 insertions(+), 1817 deletions(-)
 delete mode 100644 Documentation/video4linux/et61x251.txt
 delete mode 100644 Documentation/video4linux/ibmcam.txt
 delete mode 100644 Documentation/video4linux/m5602.txt
 delete mode 100644 Documentation/video4linux/ov511.txt
 delete mode 100644 Documentation/video4linux/se401.txt
 delete mode 100644 Documentation/video4linux/stv680.txt
 delete mode 100644 Documentation/video4linux/w9968cf.txt
 delete mode 100644 Documentation/video4linux/zc0301.txt

Thanks  Regards,

Hans
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] em28xx: input: fix oops on device removal

2012-12-21 Thread Frank Schäfer
Am 13.12.2012 17:34, schrieb Frank Schäfer:
 When em28xx_ir_init() fails du to an error in em28xx_ir_change_protocol(), it
 frees the memory of struct em28xx_IR *ir, but doesn't set the corresponding
 pointer in the device struct to NULL.
 On device removal, em28xx_ir_fini() gets called, which then calls
 rc_unregister_device() with a pointer to freed memory.

 Fixes bug 26572 (http://bugzilla.kernel.org/show_bug.cgi?id=26572)

 Signed-off-by: Frank Schäfer fschaefer@googlemail.com

 Cc: sta...@kernel.org # at least all kernels since 2.6.32 (incl.)
 ---
  drivers/media/usb/em28xx/em28xx-input.c |9 -
  1 Datei geändert, 4 Zeilen hinzugefügt(+), 5 Zeilen entfernt(-)

 diff --git a/drivers/media/usb/em28xx/em28xx-input.c 
 b/drivers/media/usb/em28xx/em28xx-input.c
 index 660bf80..5c7d768 100644
 --- a/drivers/media/usb/em28xx/em28xx-input.c
 +++ b/drivers/media/usb/em28xx/em28xx-input.c
 @@ -538,7 +538,7 @@ static int em28xx_ir_init(struct em28xx *dev)
   ir = kzalloc(sizeof(*ir), GFP_KERNEL);
   rc = rc_allocate_device();
   if (!ir || !rc)
 - goto err_out_free;
 + goto error;
  
   /* record handles to ourself */
   ir-dev = dev;
 @@ -559,7 +559,7 @@ static int em28xx_ir_init(struct em28xx *dev)
   rc_type = RC_BIT_UNKNOWN;
   err = em28xx_ir_change_protocol(rc, rc_type);
   if (err)
 - goto err_out_free;
 + goto error;
  
   /* This is how often we ask the chip for IR information */
   ir-polling = 100; /* ms */
 @@ -584,7 +584,7 @@ static int em28xx_ir_init(struct em28xx *dev)
   /* all done */
   err = rc_register_device(rc);
   if (err)
 - goto err_out_stop;
 + goto error;
  
   em28xx_register_i2c_ir(dev);
  
 @@ -597,9 +597,8 @@ static int em28xx_ir_init(struct em28xx *dev)
  
   return 0;
  
 - err_out_stop:
 +error:
   dev-ir = NULL;
 - err_out_free:
   rc_free_device(rc);
   kfree(ir);
   return err;

Ping !?
Mauro, this patch is really easy to review and it fixes a 2 years old bug...
Isn't this one of those patches that should be applied immediately ?

Regards,
Frank





--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCHv16 0/7] of: add display helper

2012-12-21 Thread Leela Krishna Amudala
Hello All,
Any comments for this patch set..?

Best Wishes,
Leela Krishna Amudala.

On Tue, Dec 18, 2012 at 10:34 PM, Steffen Trumtrar
s.trumt...@pengutronix.de wrote:

 Hi!

 Finally, right in time before the end of the world on friday, v16 of the
 display helpers.

 Changes since v15:
 - move include/linux/{videomode,display_timing}.h to include/video
 - move include/linux/of_{videomode,display_timing}.h to
 include/video
 - reimplement flags: add VESA flags and data flags
 - let pixelclock in struct videomode be unsigned long
 - rename of_display_timings_exists to of_display_timings_exist
 - revise logging/error messages: replace __func__ with
 np-full_name
 - rename pixelclk-inverted to pixelclk-active
 - revise comments in code

 Changes since v14:
 - fix const struct * warning
 (reported by: Leela Krishna Amudala
 l.kris...@samsung.com)
 - return -EINVAL when htotal or vtotal are zero
 - remove unreachable code in of_get_display_timings
 - include headers in .c files and not implicit in .h
 - sort includes alphabetically
 - fix lower/uppercase in binding documentation
 - rebase onto v3.7-rc7

 Changes since v13:
 - fix const struct * warning
 (reported by: Laurent Pinchart
 laurent.pinch...@ideasonboard.com)
 - prevent division by zero in fb_videomode_from_videomode

 Changes since v12:
 - rename struct display_timing to via_display_timing in via
 subsystem
 - fix refreshrate calculation
 - fix const struct * warnings
 (reported by: Manjunathappa, Prakash prakash...@ti.com)
 - some CodingStyle fixes
 - rewrite parts of commit messages and display-timings.txt
 - let display_timing_get_value get all values instead of just
 typical

 Changes since v11:
 - make pointers const where applicable
 - add reviewed-by Laurent Pinchart

 Changes since v10:
 - fix function name (drm_)display_mode_from_videomode
 - add acked-by, reviewed-by, tested-by

 Changes since v9:
 - don't leak memory when previous timings were correct
 - CodingStyle fixes
 - move blank lines around

 Changes since v8:
 - fix memory leaks
 - change API to be more consistent (foo_from_bar(struct bar,
 struct foo))
 - include headers were necessary
 - misc minor bugfixes

 Changes since v7:
 - move of_xxx to drivers/video
 - remove non-binding documentation from display-timings.txt
 - squash display_timings and videomode in one patch
 - misc minor fixes

 Changes since v6:
 - get rid of some empty lines etc.
 - move functions to their subsystems
 - split of_ from non-of_ functions
 - add at least some kerneldoc to some functions

 Changes since v5:
 - removed all display stuff and just describe timings

 Changes since v4:
 - refactored functions

 Changes since v3:
 - print error messages
 - free alloced memory
 - general cleanup

 Changes since v2:
 - use hardware-near property-names
 - provide a videomode structure
 - allow ranges for all properties (min,typ,max)
 - functions to get display_mode or fb_videomode

 Regards,
 Steffen



 Steffen Trumtrar (7):
   viafb: rename display_timing to via_display_timing
   video: add display_timing and videomode
   video: add of helper for display timings/videomode
   fbmon: add videomode helpers
   fbmon: add of_videomode helpers
   drm_modes: add videomode helpers
   drm_modes: add of_videomode helpers

  .../devicetree/bindings/video/display-timing.txt   |  109 +
  drivers/gpu/drm/drm_modes.c|   70 ++
  drivers/video/Kconfig  |   21 ++
  drivers/video/Makefile |4 +
  drivers/video/display_timing.c |   24 ++
  drivers/video/fbmon.c  |   94 
  drivers/video/of_display_timing.c  |  239
 
  drivers/video/of_videomode.c   |   54 +
  drivers/video/via/hw.c |6 +-
  drivers/video/via/hw.h |2 +-
  drivers/video/via/lcd.c|2 +-
  drivers/video/via/share.h  |2 +-
  drivers/video/via/via_modesetting.c|8 +-
  drivers/video/via/via_modesetting.h|6 +-
  drivers/video/videomode.c  |   39 
  include/drm/drmP.h |9 +
  include/linux/fb.h |8 +
  include/video/display_timing.h |  124 ++
  include/video/of_display_timing.h  |   20 ++
  

Re: [PATCH v2] media: coda: Fix H.264 header alignment.

2012-12-21 Thread Mauro Carvalho Chehab
Em Mon, 29 Oct 2012 13:34:59 +0100
javier.mar...@vista-silicon.com escreveu:

 From: Javier Martin javier.mar...@vista-silicon.com
 
 Length of H.264 headers is variable and thus it might not be
 aligned for the coda to append the encoded frame. This causes
 the first frame to overwrite part of the H.264 PPS.
 
 In order to solve that, a filler NAL must be added between
 the headers and the first frame to preserve alignment.
 
 Signed-off-by: Javier Martin javier.mar...@vista-silicon.com

Please next time check it with checkpatch.pl.

Also, please send us a patch adding yourself at MAINTAINERS for this
driver.

Regards,
Mauro

 ---
 Changes since v1:
  - Align to 64bits as requested by Philipp.
 
 ---
  drivers/media/platform/coda.c |   30 +-
  1 file changed, 29 insertions(+), 1 deletion(-)
 
 diff --git a/drivers/media/platform/coda.c b/drivers/media/platform/coda.c
 index a8c7a94..7febcd9 100644
 --- a/drivers/media/platform/coda.c
 +++ b/drivers/media/platform/coda.c
 @@ -177,6 +177,10 @@ struct coda_ctx {
   int idx;
  };
  
 +static const u8 coda_filler_nal[14] = { 0x00, 0x00, 0x00, 0x01, 0x0c, 0xff,
 + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x80 };
 +static const u8 coda_filler_size[8] = { 0, 7, 14, 13, 12, 11, 10, 9 };
 +
  static inline void coda_write(struct coda_dev *dev, u32 data, u32 reg)
  {
   v4l2_dbg(1, coda_debug, dev-v4l2_dev,
 @@ -938,6 +942,24 @@ static int coda_alloc_framebuffers(struct coda_ctx *ctx, 
 struct coda_q_data *q_d
   return 0;
  }
  
 +static int coda_h264_padding(int size, char *p)
 +{
 + int nal_size;
 + int diff;
 +
 + diff = size - (size  ~0x7);
 + if (diff == 0)
 + return 0;
 +
 + nal_size = coda_filler_size[diff];
 + memcpy(p, coda_filler_nal, nal_size);
 +
 + /* Add rbsp stop bit and trailing at the end */
 + *(p + nal_size - 1) = 0x80;
 +
 + return nal_size;
 +}
 +
  static int coda_start_streaming(struct vb2_queue *q, unsigned int count)
  {
   struct coda_ctx *ctx = vb2_get_drv_priv(q);
 @@ -1165,7 +1187,13 @@ static int coda_start_streaming(struct vb2_queue *q, 
 unsigned int count)
   coda_read(dev, CODA_CMD_ENC_HEADER_BB_START);
   memcpy(ctx-vpu_header[1][0], vb2_plane_vaddr(buf, 0),
  ctx-vpu_header_size[1]);
 - ctx-vpu_header_size[2] = 0;
 + /*
 +  * Length of H.264 headers is variable and thus it might not be
 +  * aligned for the coda to append the encoded frame. In that is
 +  * the case a filler NAL must be added to header 2.
 +  */
 + ctx-vpu_header_size[2] = 
 coda_h264_padding((ctx-vpu_header_size[0] +
 + ctx-vpu_header_size[1]), 
 ctx-vpu_header[2]);
   break;
   case V4L2_PIX_FMT_MPEG4:
   /*




Cheers,
Mauro
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [GIT-PULL fixes for 3.8] Various USB webcam fixes

2012-12-21 Thread Mauro Carvalho Chehab
Em Fri, 21 Dec 2012 15:29:23 +0100
Hans de Goede hdego...@redhat.com escreveu:

 Hi Mauro,
 
 Note this pullreq superceeds my previous pullreq.

Please, next time, be sure to reply to your old email or send a:
Nacked-by: 
(as patchwork catches this special meta-tag)

tag to the previous one, otherwise I'll be handling your new pull
request only after handling the previous one, just like what I did
today.

Regards,
Mauro
Cheers,
Mauro
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PULL] video_visstrim staging/ov7670_for_v3.7

2012-12-21 Thread Mauro Carvalho Chehab
Em Mon, 29 Oct 2012 17:15:01 +0100
Javier Martin javier.mar...@vista-silicon.com escreveu:

 Hi Mauro,
 since there was some confusion regarding my two last series
 for the ov7670 I've decided to send this pull request to 
 make things more clear and avoid merging order issues.

Thanks but you forgot to ad your SOB on the patches there. For example:

https://github.com/jmartinc/video_visstrim/commit/923befe62c190dfcab66d3402b450d8f26ad98cf

Could you please sign them?

Thanks!
Mauro



 
 It should apply properly in your current tree.
 
 The following changes since commit 1534e55974c7e2f57623457c0f6b4108c6ef4776:
 
   media: coda: Add Philipp's patches. (2012-09-24 17:30:53 +0200)
 
 are available in the git repository at:
 
   https://github.com/jmartinc/video_visstrim.git staging/ov7670_for_v3.7 
 
 for you to fetch changes up to 5a594e1b96d3363aedf74d9bd37a2d669beab0bc:
 
   ov7670: remove legacy ctrl callbacks. (2012-09-28 13:18:23 +0200)
 
 
 Javier Martin (9):
   media: ov7670: add support for ov7675.
   media: ov7670: make try_fmt() consistent with 'min_height' and 
 'min_width'.
   media: ov7670: calculate framerate properly for ov7675.
   media: ov7670: add possibility to bypass pll for ov7675.
   media: ov7670: Add possibility to disable pixclk during hblank.
   ov7670: use the control framework
   mcam-core: implement the control framework.
   via-camera: implement the control framework.
   ov7670: remove legacy ctrl callbacks.
 
  drivers/media/i2c/ov7670.c  |  587 
 +--
  drivers/media/platform/marvell-ccic/mcam-core.c |   54 +--
  drivers/media/platform/marvell-ccic/mcam-core.h |2 +
  drivers/media/platform/via-camera.c |   60 +--
  include/media/ov7670.h  |2 +
  5 files changed, 369 insertions(+), 336 deletions(-)
 --
 To unsubscribe from this list: send the line unsubscribe linux-media in
 the body of a message to majord...@vger.kernel.org
 More majordomo info at  http://vger.kernel.org/majordomo-info.html


-- 

Cheers,
Mauro
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] staging/media: Use dev_ printks in go7007/s2250-loader.c

2012-12-21 Thread Mauro Carvalho Chehab
Em Tue, 6 Nov 2012 09:14:39 +0900
Toshiaki Yamane yamaneto...@gmail.com escreveu:

 On Tue, Nov 6, 2012 at 12:25 AM, Joe Perches j...@perches.com wrote:
  On Mon, 2012-11-05 at 16:22 +0100, Greg Kroah-Hartman wrote:
  On Mon, Nov 05, 2012 at 07:11:11AM -0800, Joe Perches wrote:
   On Mon, 2012-11-05 at 14:11 +0100, Greg Kroah-Hartman wrote:
On Mon, Nov 05, 2012 at 08:34:42PM +0900, YAMANE Toshiaki wrote:
 fixed below checkpatch warnings.
 - WARNING: Prefer netdev_err(netdev, ... then dev_err(dev, ... then 
 pr_err(...  to printk(KERN_ERR ...
 - WARNING: Prefer netdev_info(netdev, ... then dev_info(dev, ... 
 then pr_info(...  to printk(KERN_INFO ...

 Signed-off-by: YAMANE Toshiaki yamaneto...@gmail.com
 ---
  drivers/staging/media/go7007/s2250-loader.c |   35 
 ++-
  1 file changed, 18 insertions(+), 17 deletions(-)
   
Please note that I don't touch the drivers/staging/media/* files, so
copying me on these patches doesn't do anything :)
  
   Maybe:
  
MAINTAINERS |1 +
1 files changed, 1 insertions(+), 0 deletions(-)
  
   diff --git a/MAINTAINERS b/MAINTAINERS
   index b062349..542a541 100644
   --- a/MAINTAINERS
   +++ b/MAINTAINERS
   @@ -6906,6 +6906,7 @@ T:git 
   git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git
L: de...@driverdev.osuosl.org
S: Supported
F: drivers/staging/
   +X: drivers/staging/media/
 
  Sure, that would be good, care to resend it with a signed-off-by: so I
  can apply it?
 
  It was just a nudge.
 
  You're the nominal staging maintainer, if you choose not to
  work on a specific directory under staging, I think you can
  mark it in MAINTAINERS just as easily yourself.
 
 Thanks for all.
 
 I wait Mauro-san will pick the patches.
 And I will send the patches to the correct destination from the next time.

I'm handling them today. Sorry for being a little late on it. Too much
stuff at the end of this year to handle.

Regards,
Mauro
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 2/2] staging/media: Fix trailing statements should be on next line in go7007/go7007-fw.c

2012-12-21 Thread Mauro Carvalho Chehab
Em Mon,  5 Nov 2012 20:39:33 +0900
YAMANE Toshiaki yamaneto...@gmail.com escreveu:

 fixed below checkpatch error.
 - ERROR: trailing statements should be on next line
 
 Signed-off-by: YAMANE Toshiaki yamaneto...@gmail.com
 ---
  drivers/staging/media/go7007/go7007-fw.c |3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)
 
 diff --git a/drivers/staging/media/go7007/go7007-fw.c 
 b/drivers/staging/media/go7007/go7007-fw.c
 index f99c05b..cfce760 100644
 --- a/drivers/staging/media/go7007/go7007-fw.c
 +++ b/drivers/staging/media/go7007/go7007-fw.c
 @@ -725,7 +725,8 @@ static int vti_bitlen(struct go7007 *go)
  {
   unsigned int i, max_time_incr = go-sensor_framerate / go-fps_scale;
  
 - for (i = 31; (max_time_incr  ((1  i) - 1)) == max_time_incr; --i);
 + for (i = 31; (max_time_incr  ((1  i) - 1)) == max_time_incr; --i)
 + ;

Nah, this doesn't sound right to me. IMO, in this specific case,
checkpatch.pl did a bad job.

At least on my eyes, the first line is easier to read than the other
two ones.

   return i + 1;
  }
  


Regards,
Mauro
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


cron job: media_tree daily build: ERRORS

2012-12-21 Thread Hans Verkuil
This message is generated daily by a cron job that builds media_tree for
the kernels and architectures in the list below.

Results of the daily build of media_tree:

date:Fri Dec 21 19:00:24 CET 2012
git hash:49cc629df16f2a15917800a8579bd9c25c41b634
gcc version:  i686-linux-gcc (GCC) 4.7.1
host hardware:x86_64
host os:  3.4.07-marune

linux-git-arm-eabi-davinci: WARNINGS
linux-git-arm-eabi-exynos: OK
linux-git-arm-eabi-omap: WARNINGS
linux-git-i686: WARNINGS
linux-git-m32r: OK
linux-git-mips: WARNINGS
linux-git-powerpc64: OK
linux-git-sh: OK
linux-git-x86_64: WARNINGS
linux-2.6.31.12-i686: WARNINGS
linux-2.6.32.6-i686: WARNINGS
linux-2.6.33-i686: WARNINGS
linux-2.6.34-i686: WARNINGS
linux-2.6.35.3-i686: WARNINGS
linux-2.6.36-i686: WARNINGS
linux-2.6.37-i686: WARNINGS
linux-2.6.38.2-i686: WARNINGS
linux-2.6.39.1-i686: WARNINGS
linux-3.0-i686: WARNINGS
linux-3.1-i686: WARNINGS
linux-3.2.1-i686: WARNINGS
linux-3.3-i686: WARNINGS
linux-3.4-i686: WARNINGS
linux-3.5-i686: WARNINGS
linux-3.6-i686: WARNINGS
linux-3.7-i686: ERRORS
linux-2.6.31.12-x86_64: WARNINGS
linux-2.6.32.6-x86_64: WARNINGS
linux-2.6.33-x86_64: WARNINGS
linux-2.6.34-x86_64: WARNINGS
linux-2.6.35.3-x86_64: WARNINGS
linux-2.6.36-x86_64: WARNINGS
linux-2.6.37-x86_64: WARNINGS
linux-2.6.38.2-x86_64: WARNINGS
linux-2.6.39.1-x86_64: WARNINGS
linux-3.0-x86_64: WARNINGS
linux-3.1-x86_64: WARNINGS
linux-3.2.1-x86_64: WARNINGS
linux-3.3-x86_64: WARNINGS
linux-3.4-x86_64: WARNINGS
linux-3.5-x86_64: WARNINGS
linux-3.6-x86_64: WARNINGS
linux-3.7-x86_64: ERRORS
apps: WARNINGS
spec-git: WARNINGS
sparse: ERRORS

Detailed results are available here:

http://www.xs4all.nl/~hverkuil/logs/Friday.log

Full logs are available here:

http://www.xs4all.nl/~hverkuil/logs/Friday.tar.bz2

The V4L-DVB specification from this daily build is here:

http://www.xs4all.nl/~hverkuil/spec/media.html
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: cron job: media_tree daily build: ERRORS

2012-12-21 Thread Mauro Carvalho Chehab
Em Fri, 21 Dec 2012 21:47:06 +0100 (CET)
Hans Verkuil hverk...@xs4all.nl escreveu:

 This message is generated daily by a cron job that builds media_tree for
 the kernels and architectures in the list below.
 
 Results of the daily build of media_tree:
 
 date:Fri Dec 21 19:00:24 CET 2012
 git hash:49cc629df16f2a15917800a8579bd9c25c41b634
 gcc version:  i686-linux-gcc (GCC) 4.7.1
 host hardware:x86_64
 host os:  3.4.07-marune
 
 linux-git-arm-eabi-davinci: WARNINGS
 linux-git-arm-eabi-exynos: OK
 linux-git-arm-eabi-omap: WARNINGS
 linux-git-i686: WARNINGS
 linux-git-m32r: OK
 linux-git-mips: WARNINGS
 linux-git-powerpc64: OK
 linux-git-sh: OK
 linux-git-x86_64: WARNINGS
 linux-2.6.31.12-i686: WARNINGS
 linux-2.6.32.6-i686: WARNINGS
 linux-2.6.33-i686: WARNINGS
 linux-2.6.34-i686: WARNINGS
 linux-2.6.35.3-i686: WARNINGS
 linux-2.6.36-i686: WARNINGS
 linux-2.6.37-i686: WARNINGS
 linux-2.6.38.2-i686: WARNINGS
 linux-2.6.39.1-i686: WARNINGS
 linux-3.0-i686: WARNINGS
 linux-3.1-i686: WARNINGS
 linux-3.2.1-i686: WARNINGS
 linux-3.3-i686: WARNINGS
 linux-3.4-i686: WARNINGS
 linux-3.5-i686: WARNINGS
 linux-3.6-i686: WARNINGS
 linux-3.7-i686: ERRORS
 linux-2.6.31.12-x86_64: WARNINGS
 linux-2.6.32.6-x86_64: WARNINGS
 linux-2.6.33-x86_64: WARNINGS
 linux-2.6.34-x86_64: WARNINGS
 linux-2.6.35.3-x86_64: WARNINGS
 linux-2.6.36-x86_64: WARNINGS
 linux-2.6.37-x86_64: WARNINGS
 linux-2.6.38.2-x86_64: WARNINGS
 linux-2.6.39.1-x86_64: WARNINGS
 linux-3.0-x86_64: WARNINGS
 linux-3.1-x86_64: WARNINGS
 linux-3.2.1-x86_64: WARNINGS
 linux-3.3-x86_64: WARNINGS
 linux-3.4-x86_64: WARNINGS
 linux-3.5-x86_64: WARNINGS
 linux-3.6-x86_64: WARNINGS
 linux-3.7-x86_64: ERRORS
 apps: WARNINGS
 spec-git: WARNINGS
 sparse: ERRORS
 
 Detailed results are available here:
 
 http://www.xs4all.nl/~hverkuil/logs/Friday.log

That can't be right!

Patch for it was applied earlier today:
linux-3.6-x86_64: WARNINGS

/home/hans/work/build/media_build/v4l/tm6000-video.c: In function 
'__check_keep_urb':
/home/hans/work/build/media_build/v4l/tm6000-video.c:1926:1: warning: 
return from incompatible pointer type [enabled by default]

Are you using the yesterday's tarball? If so, understandable.

But this one:
linux-3.7-x86_64: ERRORS

In file included from include/linux/usb/ch9.h:35:0,
 from include/linux/usb.h:5,
 from /home/hans/work/build/media_build/v4l/au0828.h:22,
 from 
/home/hans/work/build/media_build/v4l/au0828-i2c.c:28:
include/uapi/linux/usb/ch9.h:597:19: error: expected declaration 
specifiers or '...' before '(' token
In file included from include/linux/usb/ch9.h:35:0,
 from include/linux/usb.h:5,
 from /home/hans/work/build/media_build/v4l/au0828.h:22,
 from 
/home/hans/work/build/media_build/v4l/au0828-core.c:28:
include/uapi/linux/usb/ch9.h:597:19: error: expected declaration 
specifiers or '...' before '(' token
In file included from include/linux/usb/ch9.h:35:0,
 from include/linux/usb.h:5,
 from /home/hans/work/build/media_build/v4l/au0828.h:22,
 from 
/home/hans/work/build/media_build/v4l/au0828-cards.c:22:
include/uapi/linux/usb/ch9.h:597:19: error: expected declaration 
specifiers or '...' before '(' token

Is really really weird, as a fix for it was merged 27 hours ago:

http://git.linuxtv.org/media_build.git/commit/5a86bdd242d2489ad253c29df05663c8eda9eb9c

Could you please check what's going wrong?

Thanks!
Mauro
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: AverMedia Satelllite Hybrid+FM A706

2012-12-21 Thread Ondrej Zary
Update 2:
all I2C breakage is caused by i2c gates in CE6313 and TDA8290 so I just
commented-out the calls in tuner drivers for now.
Tuner detection in tda8290 breaks because it finds CE5039 at 0x60. Disabling
CE5039 using GPIO in board_init1() and enabling it in dvb_init() allows all
chips to initialize properly:

[  130.658813] saa7130/34: v4l2 driver version 0, 2, 17 loaded
[  130.662715] saa7133[0]: found at :02:01.0, rev: 209, irq: 9, latency: 
32, mmio: 0xf400
[  130.665879] saa7133[0]: subsystem: 1461:2055, board: AverMedia AverTV 
Satellite Hybrid+FM A706 [card=191,autodetected]
[  130.669347] saa7133[0]: board init: gpio is 3500
[  130.822347] saa7133[0]: i2c eeprom 00: 61 14 55 20 00 00 00 00 00 00 00 00 
00 00 00 00
[  130.825689] saa7133[0]: i2c eeprom 10: ff ff ff ff ff 20 ff ff ff ff ff ff 
ff ff ff ff
[  130.829008] saa7133[0]: i2c eeprom 20: 02 40 01 02 02 01 01 04 06 ff 00 57 
ff ff ff ff
[  130.832317] saa7133[0]: i2c eeprom 30: ff ff ff ff ff ff ff ff ff ff ff ff 
ff ff ff ff
[  130.835627] saa7133[0]: i2c eeprom 40: 60 a0 00 c6 96 ff 05 30 8b 05 ff 40 
ff ff ff ff
[  130.838932] saa7133[0]: i2c eeprom 50: ff ff ff ff ff ff ff ff ff ff ff ff 
ff ff ff ff
[  130.84] saa7133[0]: i2c eeprom 60: ff 89 00 c0 ff 1c 08 19 97 89 ff ff 
80 15 0a ff
[  130.845525] saa7133[0]: i2c eeprom 70: ff ff ff ff ff ff ff ff ff ff ff ff 
ff ff ff ff
[  130.848833] saa7133[0]: i2c eeprom 80: ff ff ff ff ff ff ff ff ff ff ff ff 
ff ff ff ff
[  130.852109] saa7133[0]: i2c eeprom 90: ff ff ff ff ff ff ff ff ff ff ff ff 
ff ff ff ff
[  130.855351] saa7133[0]: i2c eeprom a0: ff ff ff ff ff ff ff ff ff ff ff ff 
ff ff ff ff
[  130.858565] saa7133[0]: i2c eeprom b0: ff ff ff ff ff ff ff ff ff ff ff ff 
ff ff ff ff
[  130.861736] saa7133[0]: i2c eeprom c0: ff ff ff ff ff ff ff ff ff ff ff ff 
ff ff ff ff
[  130.864894] saa7133[0]: i2c eeprom d0: ff ff ff ff ff ff ff ff ff ff ff ff 
ff ff ff ff
[  130.868021] saa7133[0]: i2c eeprom e0: 00 01 81 b0 65 07 ff ff ff ff ff ff 
ff ff ff ff
[  130.871133] saa7133[0]: i2c eeprom f0: ff ff ff ff ff ff ff ff ff ff ff ff 
ff ff ff ff
[  130.930349] tuner 2-004b: Tuner -1 found with type(s) Radio TV.
[  130.974345] tda829x 2-004b: setting tuner address to 63
[  131.019535] tda18271 2-0063: creating new instance
[  131.030345] TDA18271HD/C2 detected @ 2-0063
[  131.454335] tda18271: performing RF tracking filter calibration
[  135.778283] tda18271: RF tracking filter calibration complete
[  135.786296] tda829x 2-004b: type set to tda8290+18271
[  138.635047] saa7133[0]: registered device video0 [v4l2]
[  138.639407] saa7133[0]: registered device vbi0
[  138.643130] saa7133[0]: registered device radio0
[  138.676190] dvb_init() allocating 1 frontend
[  139.730238] DVB: registering new adapter (saa7133[0])
[  139.733196] saa7134 :02:01.0: DVB: registering adapter 0 frontend 0 
(Zarlink ZL10313 DVB-S)...
[  140.321583] saa7134 ALSA driver for DMA sound loaded
[  140.325361] saa7133[0]/alsa: saa7133[0] at 0xf400 irq 9 registered as 
card -1

The card comes to life slowly: FM radio works for a couple of seconds!
With arecord | aplay, noise is played. When a radio station is tuned
(v4l2ctl -d /dev/radio0 -f something), I can hear it clearly for a 2-3 seconds,
then it fades to noise.

These errors appear in log:
[  521.281639] tda18271c2_rf_tracking_filters_correction: [2-0063|M] error -22 
on line 277
[  521.289675] tda18271_calc_ir_measure: [2-0063|M] error -34 on line 686
[  521.289682] tda18271_calc_bp_filter: [2-0063|M] error -34 on line 618
[  521.289686] tda18271_calc_rf_band: [2-0063|M] error -34 on line 652
[  521.289690] tda18271_calc_gain_taper: [2-0063|M] error -34 on line 669


-- 
Ondrej Zary
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH] em28xx: add two missing tuners at the Kconfig file

2012-12-21 Thread Mauro Carvalho Chehab
Those two tuners may also be needed.

Signed-off-by: Mauro Carvalho Chehab mche...@redhat.com
---
 drivers/media/usb/em28xx/Kconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/media/usb/em28xx/Kconfig b/drivers/media/usb/em28xx/Kconfig
index 617c6e4..094c4ec 100644
--- a/drivers/media/usb/em28xx/Kconfig
+++ b/drivers/media/usb/em28xx/Kconfig
@@ -46,6 +46,8 @@ config VIDEO_EM28XX_DVB
select DVB_A8293 if MEDIA_SUBDRV_AUTOSELECT
select DVB_MT352 if MEDIA_SUBDRV_AUTOSELECT
select DVB_S5H1409 if MEDIA_SUBDRV_AUTOSELECT
+   select MEDIA_TUNER_QT1010 if MEDIA_SUBDRV_AUTOSELECT
+   select MEDIA_TUNER_TDA18271 if MEDIA_SUBDRV_AUTOSELECT
select VIDEOBUF_DVB
---help---
  This adds support for DVB cards based on the
-- 
1.7.11.7

--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] em28xx: input: fix oops on device removal

2012-12-21 Thread Mauro Carvalho Chehab
Em Fri, 21 Dec 2012 16:32:54 +0100
Frank Schäfer fschaefer@googlemail.com escreveu:

 Am 13.12.2012 17:34, schrieb Frank Schäfer:
  When em28xx_ir_init() fails du to an error in em28xx_ir_change_protocol(), 
  it
  frees the memory of struct em28xx_IR *ir, but doesn't set the corresponding
  pointer in the device struct to NULL.
  On device removal, em28xx_ir_fini() gets called, which then calls
  rc_unregister_device() with a pointer to freed memory.
 
  Fixes bug 26572 (http://bugzilla.kernel.org/show_bug.cgi?id=26572)
 
  Signed-off-by: Frank Schäfer fschaefer@googlemail.com
 
  Cc: sta...@kernel.org   # at least all kernels since 2.6.32 (incl.)
  ---
   drivers/media/usb/em28xx/em28xx-input.c |9 -
   1 Datei geändert, 4 Zeilen hinzugefügt(+), 5 Zeilen entfernt(-)
 
  diff --git a/drivers/media/usb/em28xx/em28xx-input.c 
  b/drivers/media/usb/em28xx/em28xx-input.c
  index 660bf80..5c7d768 100644
  --- a/drivers/media/usb/em28xx/em28xx-input.c
  +++ b/drivers/media/usb/em28xx/em28xx-input.c
  @@ -538,7 +538,7 @@ static int em28xx_ir_init(struct em28xx *dev)
  ir = kzalloc(sizeof(*ir), GFP_KERNEL);
  rc = rc_allocate_device();
  if (!ir || !rc)
  -   goto err_out_free;
  +   goto error;
   
  /* record handles to ourself */
  ir-dev = dev;
  @@ -559,7 +559,7 @@ static int em28xx_ir_init(struct em28xx *dev)
  rc_type = RC_BIT_UNKNOWN;
  err = em28xx_ir_change_protocol(rc, rc_type);
  if (err)
  -   goto err_out_free;
  +   goto error;
   
  /* This is how often we ask the chip for IR information */
  ir-polling = 100; /* ms */
  @@ -584,7 +584,7 @@ static int em28xx_ir_init(struct em28xx *dev)
  /* all done */
  err = rc_register_device(rc);
  if (err)
  -   goto err_out_stop;
  +   goto error;
   
  em28xx_register_i2c_ir(dev);
   
  @@ -597,9 +597,8 @@ static int em28xx_ir_init(struct em28xx *dev)
   
  return 0;
   
  - err_out_stop:
  +error:
  dev-ir = NULL;
  - err_out_free:
  rc_free_device(rc);
  kfree(ir);
  return err;
 
 Ping !?
 Mauro, this patch is really easy to review and it fixes a 2 years old bug...
 Isn't this one of those patches that should be applied immediately ?

This one is not on my queue... Patchwork doesn't seem to catch it:

http://patchwork.linuxtv.org/project/linux-media/list/?submitter=44state=*

Hmm... perhaps it is due to the accent on your name. Weird that it got
other patches from you. You should likely thank python for discriminating
e-mails with accents.

Could you please try to re-submit it being sure that your email got
properly encoded with UTF-8?

Regards,
Mauro

PS.: my intention is to try to merge tomorrow all em28xx patches.
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 2/2] staging/media: Fix trailing statements should be on next line in go7007/go7007-fw.c

2012-12-21 Thread Joe Perches
On Fri, 2012-12-21 at 18:43 -0200, Mauro Carvalho Chehab wrote:
 Em Mon,  5 Nov 2012 20:39:33 +0900
 YAMANE Toshiaki yamaneto...@gmail.com escreveu:
 
  fixed below checkpatch error.
  - ERROR: trailing statements should be on next line
  
  Signed-off-by: YAMANE Toshiaki yamaneto...@gmail.com
  ---
   drivers/staging/media/go7007/go7007-fw.c |3 ++-
   1 file changed, 2 insertions(+), 1 deletion(-)
  
  diff --git a/drivers/staging/media/go7007/go7007-fw.c 
  b/drivers/staging/media/go7007/go7007-fw.c
  index f99c05b..cfce760 100644
  --- a/drivers/staging/media/go7007/go7007-fw.c
  +++ b/drivers/staging/media/go7007/go7007-fw.c
  @@ -725,7 +725,8 @@ static int vti_bitlen(struct go7007 *go)
   {
  unsigned int i, max_time_incr = go-sensor_framerate / go-fps_scale;
   
  -   for (i = 31; (max_time_incr  ((1  i) - 1)) == max_time_incr; --i);
  +   for (i = 31; (max_time_incr  ((1  i) - 1)) == max_time_incr; --i)
  +   ;
 
 Nah, this doesn't sound right to me. IMO, in this specific case,
 checkpatch.pl did a bad job.

Is this even guaranteed to exit the loop?
Maybe using ffs would be more sensible.


--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html