* page-flags.h pollution?
@ 2002-08-30 5:56 David Mosberger
2002-08-30 6:37 ` Andrew Morton
0 siblings, 1 reply; 3+ messages in thread
From: David Mosberger @ 2002-08-30 5:56 UTC (permalink / raw)
To: linux-kernel; +Cc: davidm
In the 2.5.3x kernel, what's the point of defining pte_chain_lock()
and pte_chain_unlock() in page-flags.h? These two routines make it
impossible to include page-flags.h on it's own, because they require
"struct page" to be defined (and a forward declaration isn't
sufficient either). This can introduce rather annoying circular
include-file dependencies.
--david
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: page-flags.h pollution?
2002-08-30 5:56 page-flags.h pollution? David Mosberger
@ 2002-08-30 6:37 ` Andrew Morton
2002-09-01 21:34 ` Daniel Phillips
0 siblings, 1 reply; 3+ messages in thread
From: Andrew Morton @ 2002-08-30 6:37 UTC (permalink / raw)
To: davidm; +Cc: linux-kernel, davidm
David Mosberger wrote:
>
> In the 2.5.3x kernel, what's the point of defining pte_chain_lock()
> and pte_chain_unlock() in page-flags.h? These two routines make it
> impossible to include page-flags.h on it's own, because they require
> "struct page" to be defined (and a forward declaration isn't
> sufficient either). This can introduce rather annoying circular
> include-file dependencies.
It's a wart. The now-abandoned hashed spinlocking patch moves
them into <linux/rmap-locking.h>. We can do that anyway - only
two files need it.
Or maybe just put them in asm-generic/rmap.h. I'll fix it up.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: page-flags.h pollution?
2002-08-30 6:37 ` Andrew Morton
@ 2002-09-01 21:34 ` Daniel Phillips
0 siblings, 0 replies; 3+ messages in thread
From: Daniel Phillips @ 2002-09-01 21:34 UTC (permalink / raw)
To: Andrew Morton, davidm; +Cc: linux-kernel, davidm
On Friday 30 August 2002 08:37, Andrew Morton wrote:
> David Mosberger wrote:
> >
> > In the 2.5.3x kernel, what's the point of defining pte_chain_lock()
> > and pte_chain_unlock() in page-flags.h? These two routines make it
> > impossible to include page-flags.h on it's own, because they require
> > "struct page" to be defined (and a forward declaration isn't
> > sufficient either). This can introduce rather annoying circular
> > include-file dependencies.
>
> It's a wart. The now-abandoned hashed spinlocking patch moves
> them into <linux/rmap-locking.h>. We can do that anyway - only
> two files need it.
>
> Or maybe just put them in asm-generic/rmap.h. I'll fix it up.
Yup. As a matter of principle, headers for data should be separated from
headers for operations.
--
Daniel
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2002-09-01 21:28 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-08-30 5:56 page-flags.h pollution? David Mosberger
2002-08-30 6:37 ` Andrew Morton
2002-09-01 21:34 ` Daniel Phillips
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox