Re: how does kernel get the "current" task struct?

From: H. Peter Anvin (hpa@transmeta.com)
Date: Thu Feb 03 2000 - 13:56:06 EST


Manfred Spraul wrote:
>
> "H. Peter Anvin" wrote:
> > Wrong. It's %esp with a whole bunch of bits *MASKED*. This works
> > because the per-task area -- which includes the kernel stack -- is 8K
> > in size and aligned on an 8K boundary.
> >
>
> Could you check the buddy allocator?
> I think that the zoned buddy allocator aligns memory allocations
> relative to the beginning of the zone, and not relative to the physical
> address.
>
> I.e. if a zone starts at 0x00001000, then an 8K allocation will be
> unaligned. This could be a problem for CONFIG_DISCONTIG_MEM computers
> [normal i386 zones start at 0, 16MB, 4GB --> no alignment problems]
>

This is i386-specific though; effectively a way to deal with its
register-starved set. This isn't done with kmalloc(), as far as I know:
kmalloc() doesn't even *exist* at that point...

        -hpa

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



This archive was generated by hypermail 2b29 : Mon Feb 07 2000 - 21:00:10 EST