Re: [PATCH] matroxfb: New framebuffer_alloc API and class_dev
From: Kronos <hidden>
Date: 2003-09-15 20:43:19
Il Mon, Sep 15, 2003 at 10:24:29PM +0200, Petr Vandrovec ha scritto:
Besides that, what's the point of this change? Making driver slower, scattering its data over random memory places (so no cache locality...), or is there some benefit it brings in and which I missed?
There is a class_dev embedded in struct fb_info, framebuffer_register registers it with the driver model. In this way drivers can export whatever they want using sysfs. A dynamically allocated fb_info is needed because the release function calls kfree on the container of class_dev and can't tell weather a struct fb_info is statically allocated or not. I see your point though. Note that framebuffer_alloc uses a single kmalloc call for fb_info and fb_info->par and they are both aligned to sizeof(long)... I'm not really scattering data "over random memory places". Of course I didn't want to screw your driver :) Luca -- Reply-To: kronos@kronoz.cjb.net Home: http://kronoz.cjb.net La somma dell'intelligenza sulla terra e` una costante. La popolazione e` in aumento. ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf