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] [day] [month] [year] [list]
Date:   Sat, 23 Oct 2021 21:19:14 +0800
From:   Chen Yu <yu.c.chen@...el.com>
To:     Andy Shevchenko <andriy.shevchenko@...el.com>
Cc:     linux-acpi@...r.kernel.org,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        "Rafael J. Wysocki" <rafael@...nel.org>,
        Ard Biesheuvel <ardb@...nel.org>, Len Brown <lenb@...nel.org>,
        Ashok Raj <ashok.raj@...el.com>,
        Mike Rapoport <rppt@...nel.org>,
        Aubrey Li <aubrey.li@...el.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v5 4/4] tools: Introduce power/acpi/pfru/pfru

On Fri, Oct 22, 2021 at 11:12:20PM +0300, Andy Shevchenko wrote:
> On Sat, Oct 23, 2021 at 01:10:32AM +0800, Chen Yu wrote:
> > Introduce a user space tool to make use of the interface exposed by
> > Platform Firmware Runtime Update and Telemetry drivers. The users
> > can use this tool to do firmware code injection, driver update and
> > to retrieve the telemetry data.
> 
> ...
> 
> >  #include <linux/ioctl.h>
> > +#ifdef __KERNEL__
> >  #include <linux/uuid.h>
> > +#else
> > +#include <uuid/uuid.h>
> > +#include <linux/types.h>
> > +#endif
> 
> This is exactly my point why you mustn't use uuid.h in uAPI headers.
>
Ok, will remove uuid.h. 
> > +	while (1) {
> 
> Why not  while ((c = getopt_long(...)) != -1) ?
> 
Ok, changed it to this form.
> > +		int option_index = 0;
> > +
> > +		c = getopt_long(argc, argv, option_string,
> > +				long_options, &option_index);
> > +		if (c == -1)
> > +			break;
> 
> > +		}
> > +	}
> > +}
> 
> ...
> 
> > +	char *uuid = malloc(37);
> 
> libuuid doesn't have helpers for this?
> 
There's no helper for uuid allocation AFAIK.
> Split assignment so if will be closer to its user.
> 
Ok, will do.

thanks,
Chenyu

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ