Re: [PATCH 2/2] mtd: m25p80: consider max_transfer_size when reading

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

 



On Thu, May 05, 2016 at 04:57:00PM -0700, Brian Norris wrote:
> On Thu, Apr 07, 2016 at 09:09:56PM +0200, Heiner Kallweit wrote:

> > 2. At least in the case of fsl-espi the size limit refers to one
> >    physical transfer (including the command) and therefore to the sum
> >    of all transfers.
> > We should change
> > +	t[1].len = min_t(size_t, len, spi_max_transfer_size(spi));
> > to
> > +	t[1].len = min(len, spi_max_transfer_size(spi) - t[0].len);
> > 
> > Apart from that the patch set looks good to me.

> That's not what Mark specified here:

> http://lists.infradead.org/pipermail/linux-mtd/2015-November/063616.html

> and that's not what the API's very *name* means; it says max transfer
> size (where a spi_transfer is a very well-defined concept). You need to
> fix the driver or take up the API issues with Mark if you want to
> suggest we interpret this differently.

Yes, it's called the maximum transfer size because it is the maximum
size of a transfer, not because it's the maximum size of a message.

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux