Re: the memory align about return value of kmalloc?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



hi:

2010/7/25 shailesh jain <coolworldofshail@xxxxxxxxx>:
> Nope. kmalloc uses slab allocator underneath it. So, No addresses will
> not be 4k aligned.
>
> If you care about 4k aligned addresses you should use
> __get_free_page() rather than kmalloc().
> kmalloc's are used for small allocations - think about wastage of
> memory if we try to place 4k alignment
> requirements.
thanks for your reply.
so you mean we will have no idea what the alignment of memory address
returned by kmalloc?
thank you,
vichy

--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx
Please read the FAQ at http://kernelnewbies.org/FAQ



[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux