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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZOYxGhZxpTDUpURQ@smile.fi.intel.com>
Date:   Wed, 23 Aug 2023 19:17:30 +0300
From:   Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
To:     Angel Iglesias <ang.iglesiasg@...il.com>
Cc:     linux-iio@...r.kernel.org, linux-kernel@...r.kernel.org,
        Jonathan Cameron <jic23@...nel.org>,
        Lars-Peter Clausen <lars@...afoo.de>
Subject: Re: [PATCH v2 1/3] iio: pressure: bmp280: Use uint8 to store chip ids

On Wed, Aug 23, 2023 at 07:10:33PM +0300, Andy Shevchenko wrote:
> On Wed, Aug 23, 2023 at 05:58:05PM +0200, Angel Iglesias wrote:
> > Represent the device id reg values using uint8 to optimize memory use.
> 
> This doesn't correspond to the code, in the code you used uint8_t.

...

> >  struct bmp280_chip_info {
> >  	unsigned int id_reg;
> > -	const unsigned int chip_id;
> > +	uint8_t chip_id;
> 
> While this will compile and even work properly in kernel we use uXX types,
> here u8.

Actually this patch doesn't optimize memory use. The alignment will create
a gap anyway.

That said, this patch is simply redundant.

-- 
With Best Regards,
Andy Shevchenko


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ