[i2c] [PATCH] change to i2c-i801 driver to use internal 32-byte buffer on ICH4+
Jean Delvare
khali at linux-fr.org
Sat Jun 9 12:48:34 CEST 2007
On Fri, 8 Jun 2007 08:17:39 -0400, Mark M. Hoffman wrote:
> Hi Oleg, Jean:
>
> > On Thu, 7 Jun 2007 11:46:09 -0700, Oleg Ryjkov wrote:
> > > This patch adds an ability to utilize the internal SRAM buffer on ICH4
> > > and newer host controllers to speed up execution of block operations.
>
> (...)
>
> > > static int isich4;
>
> I never liked this variable name; humbly suggest 'has_block_buffer' or maybe
> just 'eb32' if you're a minimalist. The flag should indicate the feature
> itself, not the (arbitrary) name of the first in the series to support it.
It's not so easy. This flag now represents two features: block buffer
and PEC. Renaming it to just one of the features would probably add to
confusion more than help. If you really want to make things clean, then
make that variable a bitfield, with one bit per feature, as is done in
i2c-viapro. But that would be a separate patch, of course. This would
make it easier to later add support for I2C block read, too.
(Even cleaner would be to make that bitfield a per-device value rather
than a global, but it's probably more work than is worth.)
--
Jean Delvare
More information about the i2c
mailing list