Thread (8 messages) 8 messages, 2 authors, 2021-10-06

Re: [PATCH] serial: 8250_dw: Mark acpi match table as maybe unused

From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Date: 2021-10-05 12:14:41
Also in: lkml

On Fri, Oct 01, 2021 at 09:16:24AM +0900, Daniel Palmer wrote:
On Fri, 1 Oct 2021 at 06:04, Andy Shevchenko
[off-list ref] wrote:
quoted
quoted
Doesn't this mean the ACPI table ends up in kernels that will never use ACPI?
Yes. Is it a problem (*)? If so, you need to use ifdeffery, since __maybe_unused is
not for the ID tables.
Ok, is there a reason it's not for the ID tables? Does it break something?
It will look ugly. Why we define a table that may or may not be used?
Sounds fishy.

On top of that why you should tell linker to waste resources on something
that you may well know beforehand will be thrown away?
quoted
*) while justifying this you also need to show why it's a problem specific
to the ACPI IDs and not a problem for OF ones, which we have tons of in the
Linux kernel without any guards (ifdeffery).
To be honest I don't care about this too much. I just wanted to cut
down some of the noise when I build my patch backlog so that warnings
in the stuff I'm trying to mainline are more visible.
Which is good intention and thanks for doing this!
For what it's worth I think the OF ids are a bit wasteful.
Exactly my point, but fixing one driver of zillions does not solve the issue
in general.
For some
drivers where there are tons of broken variations they add a few K of
unneeded data. But since everyone now has gigabytes of memory I doubt
they care...
Some actually cares.
I'm working with 64MB. :)
Then I would imagine that you already using as less kernel configuration as
possible and have as many modules as you want for the hardware that might
appear to be connected to that board, right? Then again one driver with 100+
bytes doesn't affect really your case. Disabling, for example PRINTK, will
win much more for you.

-- 
With Best Regards,
Andy Shevchenko

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help