mirror of
https://github.com/ipxe/ipxe
synced 2025-12-22 21:11:03 +03:00
Removed incorrect comment; malloc() is inefficient only when the
alignment and size are both powers of two, and there's no way to specify an alignment through the malloc() interface anyway.
This commit is contained in:
@@ -195,11 +195,6 @@ void free_memblock ( void *ptr, size_t size ) {
|
|||||||
*
|
*
|
||||||
* Allocates memory with no particular alignment requirement. @c ptr
|
* Allocates memory with no particular alignment requirement. @c ptr
|
||||||
* will be aligned to at least a multiple of sizeof(void*).
|
* will be aligned to at least a multiple of sizeof(void*).
|
||||||
*
|
|
||||||
* Note that malloc() is very inefficient for allocating blocks where
|
|
||||||
* the size is a power of two; if you have many of these
|
|
||||||
* (e.g. descriptor rings, data buffers) you should use malloc_dma()
|
|
||||||
* instead.
|
|
||||||
*/
|
*/
|
||||||
void * malloc ( size_t size ) {
|
void * malloc ( size_t size ) {
|
||||||
size_t total_size;
|
size_t total_size;
|
||||||
|
|||||||
Reference in New Issue
Block a user