On Tue, Dec 22, 2015 at 3:22 AM, Al Viro <v...@zeniv.linux.org.uk> wrote:
>> And if the code really explicitly wants a page (or set of aligned pages)
>> for some vm reason, I suspect having the cast there isn't a bad thing. It's
>> clearly not just a random pointer allocation if the bit pattern of the
>> pointer matters.
>
> BTW, I'm not sure we don't have code that would assume that
> kmalloc(PAGE_SIZE,...) always returns something PAGE_SIZE-aligned.

Yeah, needs-to-be-PAGE_SIZE-aligned is probably one of the main
reasons of not calling kmalloc().

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- ge...@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to