[i2c] [PATCH] Enable PEC on ICH6+ SMBus
Gaston, Jason D
jason.d.gaston at intel.com
Mon Dec 4 19:37:22 CET 2006
Have you tested with this patch? My only concern is that the ICHx
datasheets specify conditions when the PEC bit should and should not be
set.
Example from ICH8 Datasheet: "The I2C Read command with the PEC_EN bit
set produces undefined results. Software must force both the PEC_EN and
AAC bit to 0 when running this command."
Thanks,
Jason
>-----Original Message-----
>From: Jean Delvare [mailto:khali at linux-fr.org]
>Sent: Monday, December 04, 2006 6:42 AM
>To: Gaston, Jason D
>Cc: Linux I2C
>Subject: [PATCH] Enable PEC on ICH6+ SMBus
>
>Hi Jason,
>
>While reviewing your patches that added support for the ICH9 SMBus to
>the i2c-i801 driver, I noticed that we do not currently enable PEC
>support for the ICH6 and later Intel chips. I see no good reason not to
>enable it (although the actual use of PEC in Linux is admittedly
>limited), so I propose the following patch. Is it OK with you?
>
>
>Enable PEC on recent Intel SMBus controllers (ICH6, ICH7, ICH8, ICH9
>and ESB2.)
>
>Signed-off-by: Jean Delvare <khali at linux-fr.org>
>---
> drivers/i2c/busses/i2c-i801.c | 16 ++++++++++++----
> 1 file changed, 12 insertions(+), 4 deletions(-)
>
>--- linux-2.6.19-git.orig/drivers/i2c/busses/i2c-i801.c
2006-12-03
>15:52:22.000000000 +0100
>+++ linux-2.6.19-git/drivers/i2c/busses/i2c-i801.c 2006-12-03
>17:05:00.000000000 +0100
>@@ -470,12 +470,20 @@
> int err;
>
> I801_dev = dev;
>- if ((dev->device == PCI_DEVICE_ID_INTEL_82801DB_3) ||
>- (dev->device == PCI_DEVICE_ID_INTEL_82801EB_3) ||
>- (dev->device == PCI_DEVICE_ID_INTEL_ESB_4))
>+ switch (dev->device) {
>+ case PCI_DEVICE_ID_INTEL_82801DB_3:
>+ case PCI_DEVICE_ID_INTEL_82801EB_3:
>+ case PCI_DEVICE_ID_INTEL_ESB_4:
>+ case PCI_DEVICE_ID_INTEL_ICH6_16:
>+ case PCI_DEVICE_ID_INTEL_ICH7_17:
>+ case PCI_DEVICE_ID_INTEL_ESB2_17:
>+ case PCI_DEVICE_ID_INTEL_ICH8_5:
>+ case PCI_DEVICE_ID_INTEL_ICH9_6:
> isich4 = 1;
>- else
>+ break;
>+ default:
> isich4 = 0;
>+ }
>
> err = pci_enable_device(dev);
> if (err) {
>
>
>--
>Jean Delvare
More information about the i2c
mailing list