Re: [PATCH] media: staging: zoran: refactor printk debugging function
Ian Cowan <[email protected]> Thu, 21 Apr 2022 20:30:25 -0400
| Newsgroups | gmane.linux.drivers.video-input-infrastructure,gmane.comp.video.mjpeg.user |
|---|---|
| Message-ID | <YmH3IZhUrvEzZlZU@fedora> |
On Thu, Apr 21, 2022 at 06:52:04PM +0300, Dan Carpenter wrote: > On Thu, Apr 21, 2022 at 11:22:00AM -0400, Ian Cowan wrote: > > > > For using the dev_dbg() macro, do you define this in the header file > > (i.e. for this it would be videocodec.h), or where should this be > > included from? > > dev_dbg() is defined in include/linux/dev_printk.h. Look around at how > it's used. pr_debug() might be an option, but I don't know if we will > accept that, we prefer dev_dbg(). > > regards, > dan carpenter > I'm about to submit the modified patch, but I went and looked and we cannot use dev_dbg() because these specific drivers do not have any association with a device struct. The best we can do is use the pr_X() functions which I have updated in the modified patch. That still removes the module params and the repetitive dprintk() definition. --- Ian Cowan