public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Mitchell Blank Jr <mitch@sfgoth.com>
To: "H. Peter Anvin" <hpa@zytor.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: include conventions /usr/include/linux/sys ?
Date: Wed, 22 Nov 2000 23:41:41 -0800	[thread overview]
Message-ID: <20001122234141.D69611@sfgoth.com> (raw)
In-Reply-To: <NBBBJGOOMDFADJDGDCPHOEKLCJAA.law@sgi.com> <8vhhnv$j0d$1@cesium.transmeta.com>
In-Reply-To: <8vhhnv$j0d$1@cesium.transmeta.com>; from hpa@zytor.com on Wed, Nov 22, 2000 at 02:35:43PM -0800

H. Peter Anvin wrote:
> I suggested include/kernel and include/arch with include/linux and
> include/asm being reserved for the kernel interfaces (ioctl and their
> structures mostly.)

That sounds good.  One other refinement I would like to see is that
architecture specific but always present header files don't get used
directly in architecture-independant .c flies.  Some common examples of
this are <asm/io.h> and <asm/uaccess.h>  The problem is that often there
is some code that is identical between some or all of the archs.  Then
one of two things happen:
  * The code gets duplicated in many *.h files with all the bad things that
    comde duplication causes - especially since they're all under seperate
    maintainership
  * We have a big ugly conversion like what happened with 'asm/spinlock.h' ->
    'linux/spinlock.h'

If we only have arch-independant *.c files only include things out of
<kernel/*> (which may, of course, include things in <arch/*>) we can
avoid these conversions in the future and promote code reuse between the
architectures.

Also we should probably consider implementing a reasonalbe hierarchy to
the proposed <kernel/*.h> directory - for instance <kernel/bus/pci.h>.

-Mitch
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

      parent reply	other threads:[~2000-11-23  8:12 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-11-22 20:45 include conventions /usr/include/linux/sys ? LA Walsh
2000-11-22 20:59 ` Arjan van de Ven
2000-11-22 22:35 ` H. Peter Anvin
2000-11-23  1:14   ` Andi Kleen
2000-11-23  7:41   ` Mitchell Blank Jr [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20001122234141.D69611@sfgoth.com \
    --to=mitch@sfgoth.com \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox