[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <B256D81BAE5131468A838E5D7A2436413A057056@penmbx02>
Date: Tue, 8 Jan 2013 01:02:38 +0000
From: "Yang, Wenyou" <Wenyou.Yang@...el.com>
To: Joe Perches <joe@...ches.com>
CC: "linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"Ferre, Nicolas" <Nicolas.FERRE@...el.com>,
"plagnioj@...osoft.com" <plagnioj@...osoft.com>,
"richard.genoud@...il.com" <richard.genoud@...il.com>,
"Lin, JM" <JM.Lin@...el.com>,
"grant.likely@...retlab.ca" <grant.likely@...retlab.ca>,
"spi-devel-general@...ts.sourceforge.net"
<spi-devel-general@...ts.sourceforge.net>
Subject: RE: [v3 PATCH 06/12] spi/atmel_spi: add dmaengine support
> -----Original Message-----
> From: Joe Perches [mailto:joe@...ches.com]
> Sent: 2013年1月7日 10:10
> To: Yang, Wenyou
> Cc: linux-arm-kernel@...ts.infradead.org; linux-kernel@...r.kernel.org; Ferre,
> Nicolas; plagnioj@...osoft.com; richard.genoud@...il.com; Lin, JM;
> grant.likely@...retlab.ca; spi-devel-general@...ts.sourceforge.net
> Subject: Re: [v3 PATCH 06/12] spi/atmel_spi: add dmaengine support
>
> On Mon, 2013-01-07 at 09:50 +0800, Wenyou Yang wrote:
> > From: Nicolas Ferre <nicolas.ferre@...el.com>
> []
> > diff --git a/drivers/spi/spi-atmel.c b/drivers/spi/spi-atmel.c
> []
> > +static inline bool atmel_spi_use_dma(struct atmel_spi *as,
> > + struct spi_transfer *xfer)
> > +{
> > + if ((as->use_dma) && (xfer->len >= DMA_MIN_BYTES))
> > + return true;
> > + else
> > + return false;
> > +}
>
> Same unnecessary form.
>
> return as->use_dma && xfer->len >= DMA_MIN_BYTES;
>
> > +static inline bool atmel_spi_use_pdc(struct atmel_spi *as)
> > +{
> > + if (as->use_pdc)
> > + return true;
> > + else
> > + return false;
> > +}
>
> Does this function really need to exist at all?
>
Thanks a lot for your advice.
Powered by blists - more mailing lists