Subject: Re: [PATCH net-next 3/4] RDMA/ionic: Add debugfs support

From: Leon Romanovsky <[email-masked]>
Date: Thu, 14 May 2026 19:35:40 +0300

On Thu, May 14, 2026 at 09:04:08AM +0200, Greg Kroah-Hartman wrote:
> On Thu, May 14, 2026 at 09:00:48AM +0300, Leon Romanovsky wrote:
> > On Wed, May 13, 2026 at 05:23:14PM -0700, Jakub Kicinski wrote:
> > > On Wed, 13 May 2026 10:21:13 +0300 Leon Romanovsky wrote:
> > > > 3. The patch is too large and exposes too many details that should be
> > > >    gathered through the FW (fwctl).
> > > 
> > > Why? What's wrong with debugfs? Much easier for people to access.
> > 
> > There is nothing inherently wrong with debugfs. You can see recently
> > accepted debugfs patches from hns [1].
> > 
> > The issue here is what data is being dumped through debugfs, and in what
> > quantity. From a quick look, ionic_dev_info_show() appears to print
> > raw data coming straight from the FW.
> > 
> > In my view, debugfs should expose in‑kernel structures that are shaped
> > and controlled by the kernel itself. IMHO it is not the right place to
> > debug FW state. There can always be exceptions, of course, but in this
> > case the driver is effectively dumping everything from pds_core/FW in
> > the RDMA layer.
> 
> debugfs is for anything you want, there is nothing wrong with doing
> this in debugfs, in fact, it's preferred.  Don't spread debug info out
> into other areas, that makes it harder for admins and users to properly
> secure things from stuff they don't want users to have access to.

We are not discussing a general principle here, but this specific patchset,
which dumps information gathered and consumed by one subsystem into another.

If netdev wants to print raw firmware data, they are free to do so. I do not
want to see this in RDMA.

Thanks

> thanks,
> greg k-h