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: <50e81a87af1f832ae8e135b15aa41a87c08400e0.camel@perches.com>
Date:   Thu, 07 Oct 2021 10:46:59 -0700
From:   Joe Perches <joe@...ches.com>
To:     Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Cc:     Brendan Higgins <brendanhiggins@...gle.com>,
        Peter Zijlstra <peterz@...radead.org>,
        Thomas Gleixner <tglx@...utronix.de>,
        linux-kernel@...r.kernel.org, linux-kselftest@...r.kernel.org,
        kunit-dev@...glegroups.com, linux-media@...r.kernel.org,
        Ingo Molnar <mingo@...hat.com>, Will Deacon <will@...nel.org>,
        Waiman Long <longman@...hat.com>,
        Boqun Feng <boqun.feng@...il.com>,
        Sakari Ailus <sakari.ailus@...ux.intel.com>,
        Laurent Pinchart <laurent.pinchart@...asonboard.com>,
        Mauro Carvalho Chehab <mchehab@...nel.org>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Miguel Ojeda <miguel.ojeda.sandonis@...il.com>,
        jic23@...nel.org, linux@...musvillemoes.dk,
        Thorsten Leemhuis <regressions@...mhuis.info>
Subject: Re: [PATCH v4 6/7] plist: Replace kernel.h with the necessary
 inclusions

On Thu, 2021-10-07 at 20:32 +0300, Andy Shevchenko wrote:
> On Thu, Oct 07, 2021 at 10:26:05AM -0700, Joe Perches wrote:
> > On Thu, 2021-10-07 at 20:19 +0300, Andy Shevchenko wrote:
> > > On Thu, Oct 07, 2021 at 10:12:56AM -0700, Joe Perches wrote:
> > > > On Thu, 2021-10-07 at 18:44 +0300, Andy Shevchenko wrote:
> > > > > When kernel.h is used in the headers it adds a lot into dependency hell,
> > > > > especially when there are circular dependencies are involved.
> > > > > 
> > > > > Replace kernel.h inclusion with the list of what is really being used.
> > > > []
> > > > > diff --git a/include/linux/plist.h b/include/linux/plist.h
> > > > []
> > > > > @@ -73,8 +73,11 @@
> > > > []
> > > > > +#include <asm/bug.h>
> > > > 
> > > > why asm/bug.h and not linux/bug.h ?
> > > 
> > > The direct inclusion is from that one. Why linux/bug?
> > 
> > A general guideline is to avoid asm includes.
> 
> It's fine when it has any useful background. Doing cargo cult is not always
> a good idea. I plead for common sense.

Common sense isn't particularly common.
Someone is going to run checkpatch on it and submit a patch one day.
Maybe add a comment for the less common.

cheers, Joe


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ