Messages in this thread | | | Date | Fri, 18 Jan 2008 09:22:23 +0100 | From | Michael Opdenacker <> | Subject | Re: [PATCH] x86: fix unconditional arch/x86/kernel/pcspeaker.c compiling |
| |
On 01/18/2008 04:16 AM, Taral wrote: > On 1/17/08, Michael Opdenacker <michael-lists@free-electrons.com> wrote: > >> Another issue would be that we would no longer be able >> to load the speaker driver module from a kernel which >> wasn't originally compiled with support for this module. >> > > Have you looked at pcspeaker.o? As far as I can tell, it does *nothing*. > Do you mean "almost nothing"? It still allocates and adds a platform device, and the corresponding function always gets called at boot time.
I know that not compiling this piece of code just reduces the uncompressed kernel size by just a few bytes (218). However, many small contributions of this kind can have a significant impact on embedded systems (or on boot media or on Linux based bootloaders).
As I said earlier, I'm starting to think that this trick should only be used when CONFIG_EMBEDDED is set. In the non-embedded case, it's probably not acceptable not to declare a platform device that is always present in the system (while it's perfectly fine not to load the corresponding driver).
Your comments and suggestions are more than welcome!
Michael.
-- Michael Opdenacker, Free Electrons Free Embedded Linux Training Materials on http://free-electrons.com/training (More than 1500 pages!)
| |