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: <Y1ecOl+UGdBV1ce3@smile.fi.intel.com>
Date:   Tue, 25 Oct 2022 11:20:10 +0300
From:   Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
To:     Alexey Dobriyan <adobriyan@...il.com>
Cc:     mingo@...nel.org, akpm@...ux-foundation.org,
        linux-kernel@...r.kernel.org
Subject: Re: [rft, PATCH v1 4/4] kernel.h: Split out ARRAY_SZIE()

On Mon, Oct 24, 2022 at 09:14:29PM +0300, Alexey Dobriyan wrote:
> On Mon, Oct 24, 2022 at 07:05:18PM +0300, Andy Shevchenko wrote:
> > On Mon, Oct 24, 2022 at 06:44:50PM +0300, Alexey Dobriyan wrote:
> > > > include/linux/array_size.h | 13 +++++++++++++
> > > 
> > > All of this is pessimisation unless you're removing
> > > 
> > > 	+#include <linux/array_size.h>
> > > 
> > > from kernel.h which you aren't doing.
> > > 
> > > container_of.h is just as silly.
> > > 
> > > kernel.h might need _some_ cleanup (like panic and tainted stuff) which
> > > is rarely used but ARRAY_SIZE()?
> > 
> > Are you suggesting to slow down compilation with inclusion of tons of unneeded
> > stuff in the zillions of drivers?
> > 
> > Or you are talking that we need to abandon most of the headers and combine
> > everything into kernel.h? I think this is what is silly.
> 
> It hard to escape kernel.h so you will be including it anyway.

It's very important to not include it in the headers.

And this split helps to it a lot. We have container_of() or array_size() used
in macros and/or inliners that are usually appears in the headers. And if you
know what dependency hell means, the kernel.h brings to it a huge mess.

So, try to be constructive, okay?

> Unless you delete, say, kstrtox.h from kernel.h, it is pointless busywork.

-- 
With Best Regards,
Andy Shevchenko


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ