public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
* [Linux-ia64] Header dependencies
@ 2002-10-31 16:48 Matthew Wilcox
  2002-10-31 17:46 ` David Mosberger
  0 siblings, 1 reply; 2+ messages in thread
From: Matthew Wilcox @ 2002-10-31 16:48 UTC (permalink / raw)
  To: linux-ia64

I took a look at converting to the asm-offsets.c method for generating
offsets.h that the other architectures are using.  Basically, I ran
into the same problem Keith Owens alluded to earlier with the circular
dependencies:

asm/thread-info.h declares:
#define current_thread_info() ((struct thread_info *) ((char *) current + IA64_TASK_SIZE))
To get IA64_TASK_SIZE, it includes asm/offsets.h
To build asm/offsets.h, we need include linux/sched.h which includes
linux/thread_info.h which includes asm/thread_info.h.

I think the basic problem is that thread_info and task_struct are the
wrong way round on the stack.  If we put thread_info first then we don't
need IA64_TASK_SIZE in current_thread_info's definition.  What would
people think to this rearrangement?  I guess some asm code might need
to be changed, and I'm still scared of ia64 assembler ;-)

-- 
Revolutions do not require corporate support.


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Linux-ia64] Header dependencies
  2002-10-31 16:48 [Linux-ia64] Header dependencies Matthew Wilcox
@ 2002-10-31 17:46 ` David Mosberger
  0 siblings, 0 replies; 2+ messages in thread
From: David Mosberger @ 2002-10-31 17:46 UTC (permalink / raw)
  To: linux-ia64

>>>>> On Thu, 31 Oct 2002 16:48:35 +0000, Matthew Wilcox <willy@debian.org> said:

  Matthew> I think the basic problem is that thread_info and
  Matthew> task_struct are the wrong way round on the stack.  If we
  Matthew> put thread_info first then we don't need IA64_TASK_SIZE in
  Matthew> current_thread_info's definition.  What would people think
  Matthew> to this rearrangement?  I guess some asm code might need to
  Matthew> be changed, and I'm still scared of ia64 assembler ;-)

I think I tried that back when the thread_info ugliness was
introduced.  Making it work would require more changes to the platform
independent portions of the kernel (which may well be the right thing
to do).  But my memory may be wrong---if you can make it work, I'd be
OK with the change.

	--david


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-10-31 17:46 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-10-31 16:48 [Linux-ia64] Header dependencies Matthew Wilcox
2002-10-31 17:46 ` David Mosberger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox