[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220421091409.3b7ea7ac@xps13>
Date: Thu, 21 Apr 2022 09:14:09 +0200
From: Miquel Raynal <miquel.raynal@...tlin.com>
To: Pratyush Yadav <p.yadav@...com>
Cc: Mark Brown <broonie@...nel.org>,
Tudor Ambarus <tudor.ambarus@...rochip.com>,
Michael Walle <michael@...le.cc>,
Takahiro Kuwano <tkuw584924@...il.com>,
<linux-spi@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2] spi: spi-mem: check if data buffers are on stack
Hey,
p.yadav@...com wrote on Thu, 21 Apr 2022 12:40:56 +0530:
> On 20/04/22 02:04PM, Mark Brown wrote:
> > On Wed, Apr 20, 2022 at 03:50:22PM +0530, Pratyush Yadav wrote:
> > > The buffers passed in the data phase must be DMA-able. Programmers often
> > > don't realise this requirement and pass in buffers that reside on the
> > > stack. This can be hard to spot when reviewing code. Reject ops if their
> > > data buffer is on the stack to avoid this.
> > >
> > > Signed-off-by: Pratyush Yadav <p.yadav@...com>
> > > Acked-by: Mark Brown <broonie@...nel.org>
> > > ---
> > >
> > > Changes in v2:
> > > - Include task_stack.h. It might not get included indirectly on some
> > > platforms and can cause build failures.
> > > - Add a WARN_ON_ONCE() for debuggability.
> > > - Add Mark's Ack.
> >
> > Since this is now an isolated patch does that mean whatever meant that I
> > acked rather than applying this patch has gone in and I can now apply it
> > directly?
>
> Yes, you should be able to apply it directly. Miquel's spi-mem-ecc
> branch is now in 5.18-rc1 and later. Though this patch never conflicted
> with that branch to begin with. The spi-mem-ecc branch does not touch
> spi_mem_check_op() as far as I can see.
It did during a few version AFAIR, but not the final ones anymore.
But it's upstream now, so please feel free to apply.
Thanks,
Miquèl
Powered by blists - more mailing lists