lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CY5PR11MB636624BE90152D1119EC75A8ED41A@CY5PR11MB6366.namprd11.prod.outlook.com>
Date: Tue, 1 Jul 2025 10:13:05 +0000
From: "Usyskin, Alexander" <alexander.usyskin@...el.com>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
CC: "Abliyev, Reuven" <reuven.abliyev@...el.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [char-misc-next v2 4/5] mei: more prints with client prefix

> Subject: Re: [char-misc-next v2 4/5] mei: more prints with client prefix
> 
> On Mon, Jun 30, 2025 at 12:19:41PM +0300, Alexander Usyskin wrote:
> > Use client-aware print macro instead of
> > usual device print in more places.
> 
> Why?  This changes the output of the driver.
> 

This adds prefix to the existing outputs, below I've
added more explanations.

> >
> > Signed-off-by: Alexander Usyskin <alexander.usyskin@...el.com>
> > ---
> >  drivers/misc/mei/hbm.c       | 14 ++++-----
> >  drivers/misc/mei/interrupt.c |  2 +-
> >  drivers/misc/mei/main.c      | 55 +++++++++++++++++-------------------
> >  3 files changed, 34 insertions(+), 37 deletions(-)
> >
> > diff --git a/drivers/misc/mei/hbm.c b/drivers/misc/mei/hbm.c
> > index 026b1f686c16..4fe9a2752d43 100644
> > --- a/drivers/misc/mei/hbm.c
> > +++ b/drivers/misc/mei/hbm.c
> > @@ -510,7 +510,7 @@ int mei_hbm_cl_notify_req(struct mei_device *dev,
> >
> >  	ret = mei_hbm_write_message(dev, &mei_hdr, &req);
> >  	if (ret)
> > -		dev_err(dev->dev, "notify request failed: ret = %d\n", ret);
> > +		cl_err(dev, cl, "notify request failed: ret = %d\n", ret);
> 
> Why do you have a mei-specific debug printk macro anyway?  You really
> shouldn't do that :(
> 
> This feels like a step backwards.
> 

cl_err is the wrapper for dev_err with additional prefix of current transaction.
This helps to understand to what flow this print belongs when multiple
transactions are executed in parallel.
Same for cl_dbg.
This greatly increases driver debuggability in complex scenarios.
Some of these prints are introduced before specific macro was invented,
some are misses from the newer patches.
 This patch helps to normalize output and makes consecutive patches smaller.

> thanks,
> 
> greg k-h

- - 
Thanks,
Sasha


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ