<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/i2c/busses/i2c-nforce2.c, branch v3.5-rc4</title>
<subtitle>Linux Kernel (branches are rebased on master from time to time)</subtitle>
<id>https://sre.ring0.de/linux/atom?h=v3.5-rc4</id>
<link rel='self' href='https://sre.ring0.de/linux/atom?h=v3.5-rc4'/>
<link rel='alternate' type='text/html' href='https://sre.ring0.de/linux/'/>
<updated>2012-01-12T19:32:04Z</updated>
<entry>
<title>i2c: Convert to DEFINE_PCI_DEVICE_TABLE</title>
<updated>2012-01-12T19:32:04Z</updated>
<author>
<name>Axel Lin</name>
<email>axel.lin@gmail.com</email>
</author>
<published>2012-01-12T19:32:04Z</published>
<link rel='alternate' type='text/html' href='https://sre.ring0.de/linux/commit/?id=3527bd5045aacb4e4072f9cacb8eb9a433fbad39'/>
<id>urn:sha1:3527bd5045aacb4e4072f9cacb8eb9a433fbad39</id>
<content type='text'>
Convert static struct pci_device_id *[] to static DEFINE_PCI_DEVICE_TABLE
tables.

Use DEFINE_PCI_DEVICE_TABLE ensures we make the pci_device_id table const
and marked as __devinitconst.

This also fixes some warnings from checkpatch:
e.g.
WARNING: Use DEFINE_PCI_DEVICE_TABLE for struct pci_device_id
#1096: FILE: i2c/busses/i2c-intel-mid.c:1096:
+static struct pci_device_id intel_mid_i2c_ids[] = {

Signed-off-by: Axel Lin &lt;axel.lin@gmail.com&gt;
Cc: Rudolf Marek &lt;r.marek@assembler.cz&gt;
Cc: Ben Dooks &lt;ben-linux@fluff.org&gt;
Acked-by: Olof Johansson &lt;olof@lixom.net&gt;
Cc: "Mark M. Hoffman" &lt;mhoffman@lightlink.com&gt;
Acked-by: Dirk Brandewie &lt;dirk.brandewie@gmail.com&gt;
Cc: Tomoya MORINAGA &lt;tomoya-linux@dsn.lapis-semi.com&gt;
Acked-by: Wolfram Sang &lt;w.sang@pengutronix.de&gt;
Cc: Feng Tang &lt;feng.tang@intel.com&gt;
Cc: Sebastian Andrzej Siewior &lt;bigeasy@linutronix.de&gt;
Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
</content>
</entry>
<entry>
<title>i2c: Fix error value returned by several bus drivers</title>
<updated>2012-01-12T19:32:03Z</updated>
<author>
<name>Jean Delvare</name>
<email>khali@linux-fr.org</email>
</author>
<published>2012-01-12T19:32:03Z</published>
<link rel='alternate' type='text/html' href='https://sre.ring0.de/linux/commit/?id=7c1f59c9d5caf3a84f35549b5d58f3c055a68da5'/>
<id>urn:sha1:7c1f59c9d5caf3a84f35549b5d58f3c055a68da5</id>
<content type='text'>
When adding checks for ACPI resource conflicts to many bus drivers,
not enough attention was paid to the error paths, and for several
drivers this causes 0 to be returned on error in some cases. Fix this
by properly returning a non-zero value on every error.

Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
Cc: stable@kernel.org
</content>
</entry>
<entry>
<title>i2c-nforce2: Remove unnecessary cast of pci_get_drvdata</title>
<updated>2011-01-10T21:11:22Z</updated>
<author>
<name>Joe Perches</name>
<email>joe@perches.com</email>
</author>
<published>2011-01-10T21:11:22Z</published>
<link rel='alternate' type='text/html' href='https://sre.ring0.de/linux/commit/?id=b18a5c80eb2e7e9c72d23f1960b09d78ddf7e5b0'/>
<id>urn:sha1:b18a5c80eb2e7e9c72d23f1960b09d78ddf7e5b0</id>
<content type='text'>
Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
</content>
</entry>
<entry>
<title>i2c-nforce2: Remove redundant error messages on ACPI conflict</title>
<updated>2010-05-21T16:41:01Z</updated>
<author>
<name>Chase Douglas</name>
<email>chase.douglas@canonical.com</email>
</author>
<published>2010-05-21T16:41:01Z</published>
<link rel='alternate' type='text/html' href='https://sre.ring0.de/linux/commit/?id=7c4fda1aa15fdbbd2563e7e652cd3745f92a16da'/>
<id>urn:sha1:7c4fda1aa15fdbbd2563e7e652cd3745f92a16da</id>
<content type='text'>
The ACPI subsystem strictly checks for resource conflicts. When there's
a conflict, it outputs a warning message with all the details needed to
properly diagnose the underlying issue. However, the i2c-nforce2 driver
also prints its own message. Not only is the message redundant, it is at
the KERN_ERR level, which overrides some bootsplash screens for no good
reason. This change removes the two lines that print out the error
messages.

Signed-off-by: Chase Douglas &lt;chase.douglas@canonical.com&gt;
Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
</content>
</entry>
<entry>
<title>i2c: Use &lt;linux/io.h&gt; instead of &lt;asm/io.h&gt;</title>
<updated>2010-05-21T16:41:01Z</updated>
<author>
<name>H Hartley Sweeten</name>
<email>hartleys@visionengravers.com</email>
</author>
<published>2010-05-21T16:41:01Z</published>
<link rel='alternate' type='text/html' href='https://sre.ring0.de/linux/commit/?id=2178218027e4da0608219fae1d02e5c88f4e560d'/>
<id>urn:sha1:2178218027e4da0608219fae1d02e5c88f4e560d</id>
<content type='text'>
As warned by checkpatch.pl, &lt;linux/io.h&gt; should be used instead of
&lt;asm/io.h&gt;.

Signed-off-by: H Hartley Sweeten &lt;hsweeten@visionengravers.com&gt;
Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
</content>
</entry>
<entry>
<title>include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h</title>
<updated>2010-03-30T13:02:32Z</updated>
<author>
<name>Tejun Heo</name>
<email>tj@kernel.org</email>
</author>
<published>2010-03-24T08:04:11Z</published>
<link rel='alternate' type='text/html' href='https://sre.ring0.de/linux/commit/?id=5a0e3ad6af8660be21ca98a971cd00f331318c05'/>
<id>urn:sha1:5a0e3ad6af8660be21ca98a971cd00f331318c05</id>
<content type='text'>
percpu.h is included by sched.h and module.h and thus ends up being
included when building most .c files.  percpu.h includes slab.h which
in turn includes gfp.h making everything defined by the two files
universally available and complicating inclusion dependencies.

percpu.h -&gt; slab.h dependency is about to be removed.  Prepare for
this change by updating users of gfp and slab facilities include those
headers directly instead of assuming availability.  As this conversion
needs to touch large number of source files, the following script is
used as the basis of conversion.

  http://userweb.kernel.org/~tj/misc/slabh-sweep.py

The script does the followings.

* Scan files for gfp and slab usages and update includes such that
  only the necessary includes are there.  ie. if only gfp is used,
  gfp.h, if slab is used, slab.h.

* When the script inserts a new include, it looks at the include
  blocks and try to put the new include such that its order conforms
  to its surrounding.  It's put in the include block which contains
  core kernel includes, in the same order that the rest are ordered -
  alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
  doesn't seem to be any matching order.

* If the script can't find a place to put a new include (mostly
  because the file doesn't have fitting include block), it prints out
  an error message indicating which .h file needs to be added to the
  file.

The conversion was done in the following steps.

1. The initial automatic conversion of all .c files updated slightly
   over 4000 files, deleting around 700 includes and adding ~480 gfp.h
   and ~3000 slab.h inclusions.  The script emitted errors for ~400
   files.

2. Each error was manually checked.  Some didn't need the inclusion,
   some needed manual addition while adding it to implementation .h or
   embedding .c file was more appropriate for others.  This step added
   inclusions to around 150 files.

3. The script was run again and the output was compared to the edits
   from #2 to make sure no file was left behind.

4. Several build tests were done and a couple of problems were fixed.
   e.g. lib/decompress_*.c used malloc/free() wrappers around slab
   APIs requiring slab.h to be added manually.

5. The script was run on all .h files but without automatically
   editing them as sprinkling gfp.h and slab.h inclusions around .h
   files could easily lead to inclusion dependency hell.  Most gfp.h
   inclusion directives were ignored as stuff from gfp.h was usually
   wildly available and often used in preprocessor macros.  Each
   slab.h inclusion directive was examined and added manually as
   necessary.

6. percpu.h was updated not to include slab.h.

7. Build test were done on the following configurations and failures
   were fixed.  CONFIG_GCOV_KERNEL was turned off for all tests (as my
   distributed build env didn't work with gcov compiles) and a few
   more options had to be turned off depending on archs to make things
   build (like ipr on powerpc/64 which failed due to missing writeq).

   * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
   * powerpc and powerpc64 SMP allmodconfig
   * sparc and sparc64 SMP allmodconfig
   * ia64 SMP allmodconfig
   * s390 SMP allmodconfig
   * alpha SMP allmodconfig
   * um on x86_64 SMP allmodconfig

8. percpu.h modifications were reverted so that it could be applied as
   a separate patch and serve as bisection point.

Given the fact that I had only a couple of failures from tests on step
6, I'm fairly confident about the coverage of this conversion patch.
If there is a breakage, it's likely to be something in one of the arch
headers which should be easily discoverable easily on most builds of
the specific arch.

Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Guess-its-ok-by: Christoph Lameter &lt;cl@linux-foundation.org&gt;
Cc: Ingo Molnar &lt;mingo@redhat.com&gt;
Cc: Lee Schermerhorn &lt;Lee.Schermerhorn@hp.com&gt;
</content>
</entry>
<entry>
<title>i2c: Make PCI device ids constant</title>
<updated>2010-03-02T11:23:37Z</updated>
<author>
<name>Márton Németh</name>
<email>nm127@freemail.hu</email>
</author>
<published>2010-03-02T11:23:37Z</published>
<link rel='alternate' type='text/html' href='https://sre.ring0.de/linux/commit/?id=4111ecd2178dbc262bf384c5e472de346d593341'/>
<id>urn:sha1:4111ecd2178dbc262bf384c5e472de346d593341</id>
<content type='text'>
The id_table field of the struct pci_driver is constant in &lt;linux/pci.h&gt;
so it is worth to make initialization data also constant.

The semantic match that finds this kind of pattern is as follows:
(http://coccinelle.lip6.fr/)

// &lt;smpl&gt;
@r@
disable decl_init,const_decl_init;
identifier I1, I2, x;
@@
	struct I1 {
	  ...
	  const struct I2 *x;
	  ...
	};
@s@
identifier r.I1, y;
identifier r.x, E;
@@
	struct I1 y = {
	  .x = E,
	};
@c@
identifier r.I2;
identifier s.E;
@@
	const struct I2 E[] = ... ;
@depends on !c@
identifier r.I2;
identifier s.E;
@@
+	const
	struct I2 E[] = ...;
// &lt;/smpl&gt;

Signed-off-by: Márton Németh &lt;nm127@freemail.hu&gt;
Cc: Julia Lawall &lt;julia@diku.dk&gt;
Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
</content>
</entry>
<entry>
<title>i2c: Timeouts off by 1</title>
<updated>2009-05-05T06:39:24Z</updated>
<author>
<name>Roel Kluin</name>
<email>roel.kluin@gmail.com</email>
</author>
<published>2009-05-05T06:39:24Z</published>
<link rel='alternate' type='text/html' href='https://sre.ring0.de/linux/commit/?id=4ccc28f725bc2b7b0a3bc27e9c15f4eaf63fb812'/>
<id>urn:sha1:4ccc28f725bc2b7b0a3bc27e9c15f4eaf63fb812</id>
<content type='text'>
with while (timeout++ &lt; MAX_TIMEOUT); timeout reaches MAX_TIMEOUT + 1
after the loop, so the tests below are off by one.

Signed-off-by: Roel Kluin &lt;roel.kluin@gmail.com&gt;
Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
</content>
</entry>
<entry>
<title>i2c-nforce2: Add support for MCP67, MCP73, MCP78S and MCP79</title>
<updated>2009-03-28T20:34:41Z</updated>
<author>
<name>Jean Delvare</name>
<email>khali@linux-fr.org</email>
</author>
<published>2009-03-28T20:34:41Z</published>
<link rel='alternate' type='text/html' href='https://sre.ring0.de/linux/commit/?id=d2dd14ac1847082d4bb955619e86ed315c0ecd20'/>
<id>urn:sha1:d2dd14ac1847082d4bb955619e86ed315c0ecd20</id>
<content type='text'>
The MCP78S and MCP79 appear to be compatible with the previous nForce
chips as far as the SMBus controller is concerned. The MCP67 and MCP73
were not tested yet but I'd be very surprised if they weren't
compatible too.

Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
Cc: Oleg Ryjkov &lt;olegr@olegr.ca&gt;
Cc: Malcolm Lalkaka &lt;mlalkaka@gmail.com&gt;
Cc: Zbigniew Luszpinski &lt;zbiggy@o2.pl&gt;
</content>
</entry>
<entry>
<title>i2c: Delete many unused adapter IDs</title>
<updated>2009-01-26T20:19:52Z</updated>
<author>
<name>Jean Delvare</name>
<email>khali@linux-fr.org</email>
</author>
<published>2009-01-26T20:19:52Z</published>
<link rel='alternate' type='text/html' href='https://sre.ring0.de/linux/commit/?id=1745522ccbabd990bfc7511861aa9fa98287cba0'/>
<id>urn:sha1:1745522ccbabd990bfc7511861aa9fa98287cba0</id>
<content type='text'>
Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
</content>
</entry>
</feed>
