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: <20191011153638.GF32742@smile.fi.intel.com>
Date:   Fri, 11 Oct 2019 18:36:38 +0300
From:   Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
To:     Joe Perches <joe@...ches.com>
Cc:     Corey Minyard <minyard@....org>,
        openipmi-developer@...ts.sourceforge.net,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH v1] ipmi: use %*ph to print small buffer

On Fri, Oct 11, 2019 at 08:18:41AM -0700, Joe Perches wrote:
> On Fri, 2019-10-11 at 18:12 +0300, Andy Shevchenko wrote:
> > On Fri, Oct 11, 2019 at 07:58:14AM -0700, Joe Perches wrote:
> > > On Fri, 2019-10-11 at 17:52 +0300, Andy Shevchenko wrote:

> > > >  static void ipmi_debug_msg(const char *title, unsigned char *data,
...
> > > > +	pr_debug("%s: %*ph\n", title, len, buf);
...
> > > >  #else
> > > >  static void ipmi_debug_msg(const char *title, unsigned char *data,

> > > Now you might as well remove the #ifdef DEBUG above this
> > > and the empty function in the #else too.
> > 
> > It's up to maintainer.
> 
> That's like suggesting any function with a single pr_debug
> should have another duplicative empty function without.
> 
> Using code like the below is not good form as it's prone
> to defects when the arguments in one block is changed but
> not the other.
> 
> Also the first form doesn't work with dynamic debug.

I'm surprised to see my name in To:. I guess you intended to explain this to
Corey. I'm fine with either, since I have no idea what is in the IPMI going on.

-- 
With Best Regards,
Andy Shevchenko


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ