Re: [PATCH] i2c-i801: Don't depend on other kernel driver config options

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi David,

On Fri, 13 May 2011 11:23:06 +0100, Woodhouse, David wrote:
> On Fri, 2011-05-13 at 11:01 +0100, Jean Delvare wrote:
> > Don't let other driver config options influence us, as it makes the
> > code more complex and fragile for a small benefit. There's nothing
> > wrong with instantiating I2C devices even if they don't have a driver.
> > And we're talking about 835 extra bytes in the binary on x86-64,
> > that's hardly worth arguing about. 
> 
> Looks sane to me; thanks. Should it be CONFIG_DMI instead of (or in
> addition to) CONFIG_X86?

Instead of, no. IA64 has DMI but doesn't want this code.

In addition to, yes, that would make sense. I expected the extra code to
transparently vanish when CONFIG_DMI isn't set, but gcc is apparently
not smart enough for this, so it could use some help.

BTW, it may be desirable to make the apanel part depend on DMI, even if
DMI is technically not needed to find the slave address. Scanning the
BIOS memory for an arbitrary string is costly (a minimum of 4096 calls
to check_signature(), which in turn calls readb() at least once, in the
negative case.) Checking for the DMI vendor first should be way less
costly for the negative case.

I'll submit a new patch set later today, thanks for the suggestions.

-- 
Jean Delvare
--
To unsubscribe from this list: send the line "unsubscribe linux-i2c" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux GPIO]     [Linux SPI]     [Linux Hardward Monitoring]     [LM Sensors]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux