[Mjpeg-users] [PATCH 2/4] staging: media: zoran: setup videocodec header for debugging macros

2022-04-25 Thread Ian Cowan
This adds inline functions in the videocodec header file to convert the videocodec and videocodec_master structs to their respective contained zoran struct. This will be used to pass the zoran struct to the zrdev_XXX() macros defined in the zoran header. In the zoran header, the new include is add

[Mjpeg-users] [PATCH 1/4] staging: media: zoran: add logging macros

2022-04-25 Thread Ian Cowan
This adds the zrdev_dbg() (pointing to pci_dbg()), zrdev_err() (pointing to pci_err()), and zrdev_info() (pointing to pci_info()) macros to the zoran drivers. These are the preferred method for debugging and this will allow to extract the device from the zoran struct to make the call. Signed-off-b

Re: [Mjpeg-users] [PATCH 1/4] staging: media: zoran: add zrdev_dbg() macros

2022-04-25 Thread Ian Cowan
On Sun, Apr 24, 2022 at 09:17:22PM +0200, LABBE Corentin wrote: > Hello > > Thanks for your patchs, removing dprintk is a good idea. > Please use pci_xxx() instead of dev_xxx() to be consistent with the rest of > the driver. > The comment title is misleading, zrdev_err is not about debugging. Wha

Re: [Mjpeg-users] [PATCH 1/4] staging: media: zoran: add zrdev_dbg() macros

2022-04-25 Thread LABBE Corentin
Le Sat, Apr 23, 2022 at 01:17:45AM -0400, Ian Cowan a écrit : > This adds the zrdev_dbg() (pointing to dev_dbg()), zrdev_err() (pointing > to dev_err()), and zrdev_info() (pointing to dev_info()) macros to the > zoran drivers. These are the preferred method for debugging and this > will allow to ex

[Mjpeg-users] [PATCH v2 1/4] staging: media: zoran: add logging macros

2022-04-25 Thread Ian Cowan
This adds the zrdev_dbg() (pointing to pci_dbg()), zrdev_err() (pointing to pci_err()), and zrdev_info() (pointing to pci_info()) macros to the zoran drivers. These are the preferred method for debugging and this will allow to extract the device from the zoran struct to make the call. Signed-off-b

[Mjpeg-users] [PATCH v2 3/4] staging: media: zoran: replace all pr_err() with zrdev_err()

2022-04-25 Thread Ian Cowan
This replaces all of the pr_err() calls to the preferred zrdev_err() macro that calls the dev_dbg() macro. Signed-off-by: Ian Cowan --- drivers/staging/media/zoran/videocodec.c | 32 +--- drivers/staging/media/zoran/zr36016.c| 28 + drivers/staging/med

Re: [Mjpeg-users] [PATCH 1/4] staging: media: zoran: add zrdev_dbg() macros

2022-04-25 Thread Greg KH
On Sun, Apr 24, 2022 at 09:22:30PM -0400, Ian Cowan wrote: > On Sun, Apr 24, 2022 at 09:17:22PM +0200, LABBE Corentin wrote: > > Hello > > > > Thanks for your patchs, removing dprintk is a good idea. > > Please use pci_xxx() instead of dev_xxx() to be consistent with the rest of > > the driver. >

Re: [Mjpeg-users] [PATCH 2/4] staging: media: zoran: setup videocodec header for debugging macros

2022-04-25 Thread Ian Cowan
This adds inline functions in the videocodec header file to convert the videocodec and videocodec_master structs to their respective contained zoran struct. This will be used to pass the zoran struct to the zrdev_XXX() macros defined in the zoran header. In the zoran header, the new include is add

[Mjpeg-users] [PATCH v2 2/4] staging: media: zoran: setup videocodec header for debugging macros

2022-04-25 Thread Ian Cowan
This adds inline functions in the videocodec header file to convert the videocodec and videocodec_master structs to their respective contained zoran struct. This will be used to pass the zoran struct to the zrdev_XXX() macros defined in the zoran header. In the zoran header, the new include is add

[Mjpeg-users] [PATCH v2 4/4] staging: media: zoran: replace dprintk with new debugging macros

2022-04-25 Thread Ian Cowan
This replaces all of the dprintk() macro calls to the zrdev_dbg(), zrdev_info(), or zrdev_err() calls as appropriate. This allows for the removal of the dprintk() macro from each file it is defined in, along with removal of the module params that track the debugging level. In the case that a debug