Re: [PATCH v4 14/14] mmc: queue: create dev->dma_parms before call dma_set_max_seg_size()

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

 



On Wed, 4 Mar 2020 at 17:28, Christoph Hellwig <hch@xxxxxx> wrote:
>
> On Wed, Mar 04, 2020 at 02:32:42PM +0100, Ulf Hansson wrote:
> > + Christoph, Arnd
> >
> > On Wed, 19 Feb 2020 at 09:31, <haibo.chen@xxxxxxx> wrote:
> > >
> > > From: Haibo Chen <haibo.chen@xxxxxxx>
> > >
> > > To make dma_set_max_seg_size() work, need to create dev->dma_parms.
> > >
> > > Find this issue on i.MX8QM mek board, this platform config the
> > > max_segment_size to 65535, but this dma_set_max_seg_size do not
> > > actuall work, find sometimes the segment size is 65536, exceed
> > > the hardware max segment limitation, trigger ADMA error.
> >
> > Sounds like we want something along the lines of this to be tagged for
> > stable as well.
>
> It really is not the job of the upper level driver to allocate the
> dma params.  This should be done by the bus driver.

I agree that allocating the dma_parms doesn't belong in the mmc block
queue layer.

However, it seems silly that each an every mmc host driver needs to do
this themselves. So, perhaps we could manage this from
mmc_alloc_host(), which is a common interface that mmc host drivers
calls during initialization.

Would that make sense - or is there some reasons to why a host driver
really don't want to do the allocation you think?

Kind regards
Uffe



[Index of Archives]     [Linux Memonry Technology]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux