lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 5 Sep 2008 15:11:57 +0200
From:	Jean Delvare <khali@...ux-fr.org>
To:	"Francis Moreau" <francis.moro@...il.com>
Cc:	"Linux Kernel Mailing List" <linux-kernel@...r.kernel.org>,
	i2c@...sensors.org
Subject: Re: qestion about I2C_CLASS_HWMON flag

On Fri, 5 Sep 2008 14:44:30 +0200, Francis Moreau wrote:
> On Fri, Sep 5, 2008 at 11:20 AM, Jean Delvare <khali@...ux-fr.org> wrote:
> > Nothing prevents you from setting the class flags based on
> > platform-specific information if you have a need for that.
> 
> Just to be sure, do you mean by hacking the adapter source code ?

It's not about hacking, it can be done cleanly. Just have the adapter
driver code check for information in the platform data, and if class
information is provided, use that instead of the default value. Or if
all users will provide the information, don't even have a default in
the driver. Again, the class flags are a (needed) mechanism, the policy
is left for driver authors and platform maintainers to establish.

> > That being said, in cases where you have that level of information
> > about which devices are present on the I2C bus,
> 
> Isn't the case for most of all embedded platforms ?

Indeed.

> > you probably want to
> > declare the I2C devices at the platform level, and not rely on probing
> > at all (so .class is 0).
> 
> do you mean by using I2C_BOARD_INFO ?

Exactly. Except on powerpc where they have a different mechanism, I
think.

-- 
Jean Delvare
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ