[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150423180622.GC12637@datacom.ind.br>
Date: Thu, 23 Apr 2015 15:06:22 -0300
From: Jonatas Rech <jonatas.rech@...acom.ind.br>
To: Mark Brown <broonie@...nel.org>
Cc: linux-spi@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] spi: fsl-espi: fix behaviour for full-duplex xfers
On Wed, Apr 22, 2015 at 08:57:46PM +0100, Mark Brown wrote:
> On Wed, Apr 22, 2015 at 12:09:03PM -0300, DATACOM - Jonatas.Rech wrote:
>
> Don't top post (context is important for people to know what you are
> talking about) and please fix your mailer to word wrap within
> paragraphs so your mail can be read and replied to more readily.
>
I'm sorry for that, thanks for the heads-up.
> > The m25p80 driver can send down a message that's bigger than the
> > amount the spi-fsl-espi driver can handle in a single espi_transfer
> > (64KiB), when the application wants to read the whole memory content,
> > for instance. In this case, the Freescale driver splits the message in
> > 64KiB chunks, adding a "Read the next 64KiB" command in the TX buffer
> > so the flash memory can output data from the expected offset. In the
> > end, the m25p80 driver sees all the data as one big rx_buf, as it
> > expected in the first place.
>
> This is completely broken.
>
> > Unfortunately, I don't know how many protocol drivers currently rely
> > on this, or even how other controller drivers deal with this expected
> > behavior.
>
> This is not expected behaviour for anything and should be fixed
> urgently.
I agree, but please note that this came up while I was trying to fix the
full-duplex functionality, and it's a different problem. Fixing this would
impact protocol drivers, as stated earlier. It would take some time for me to
study other drivers and come up with the best solution for this driver plus
(at least) the m25p80, which supports the hardware I currently have access to.
I know this must be fixed, but wouldn't it be subject to a different patch?
Thanks in advance for the advice.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists