Re: [PATCH] staging: nvec: convert to use platform register andmfd cells

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

 



On Fri, 2011-08-05 at 21:03 +0200, Marc Dietrich wrote:
> Hi Joe,

Hello Marc.

> On Sunday 24 July 2011 23:01:19 Joe Perches wrote:
> > On Sun, 2011-07-24 at 21:56 +0200, Marc Dietrich wrote:
> > > This patch converts the nvec to use mfd cells and improves the
> > > registration of the platform driver. The child drivers are also
> > > converted to use mfd cells and platform registration.
> > trivia:
> > > diff --git a/drivers/staging/nvec/nvec.c b/drivers/staging/nvec/nvec.c
> > []
> > > @@ -23,6 +23,7 @@
> > []
> > >  static unsigned char EC_DISABLE_EVENT_REPORTING[]
> > >  =	{'\x04','\x00','\x00'};
> > Please use const where appropriate.
> while these message strings are constant most of the time, there are
> places where they aren't. So the nvec_write_{a}sync functions (which
> are feeded by these strings) cannot be called with a const argument.

That doesn't matter.

nvec_write_async should be changed to:

void nvec_write_async(struct nvec_chip *nvec, const unsigned char *data, short size)

and nvec_write_sync should be:

static struct nvec_msg *nvec_write_sync(struct nvec_chip *nvec, const unsigned char *data, short size)

> I know this looks ugly and I plan to replace these with some macros
> which build up the string. This will also help to explain the deeper
> meaning of them.

Clearer is better.

cheers, Joe

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/devel


[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux