Re: [PATCH 4/8] staging: media: zoran: add debugfs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Le Sat, Sep 04, 2021 at 07:53:00AM +0200, Greg KH a écrit :
> On Fri, Sep 03, 2021 at 07:15:36PM +0000, Corentin Labbe wrote:
> > Add debugfs for displaying zoran debug and stats information.
> > 
> > Signed-off-by: Corentin Labbe <clabbe@xxxxxxxxxxxx>
> > ---
> >  drivers/staging/media/zoran/Kconfig      | 10 ++++++
> >  drivers/staging/media/zoran/zoran.h      |  5 +++
> >  drivers/staging/media/zoran/zoran_card.c | 39 ++++++++++++++++++++++++
> >  3 files changed, 54 insertions(+)
> > 
> > +#ifdef CONFIG_VIDEO_ZORAN_DEBUG
> > +	struct dentry *dbgfs_dir;
> > +	struct dentry *dbgfs_file;
> 
> No need for these, the file is never referenced and the directory can be
> looked up when you want to remove it.
> 
> > +#endif
[...]
> > +#ifdef CONFIG_VIDEO_ZORAN_DEBUG
> > +	zr->dbgfs_dir = debugfs_create_dir(ZR_DEVNAME(zr), NULL);
> > +	zr->dbgfs_file = debugfs_create_file("debug", 0444,
> > +					      zr->dbgfs_dir, zr,
> > +					      &zoran_debugfs_fops);
> > +#endif
> 
> Wait, when are you removing the files when the device is removed?
> 
> That needs to be fixed no matter what before this patch is accepted.
> 

Hello

Sorry to have forgotten this.
I will fix this.

Thanks
Regards




[Index of Archives]     [Linux Driver Development]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux