lkml.org 
[lkml]   [2021]   [Feb]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 4/6] MIPS: refactor the maybe coherent DMA indicators
On Tue, Feb 09, 2021 at 02:12:37PM +0100, Thomas Bogendoerfer wrote:
> > +#ifdef CONFIG_DMA_MAYBE_COHERENT
> > +extern bool dma_default_coherent;
> > static inline bool dev_is_dma_coherent(struct device *dev)
> > {
> > - return coherentio == IO_COHERENCE_ENABLED ||
> > - (coherentio == IO_COHERENCE_DEFAULT && hw_coherentio);
> > + return dma_default_coherent;
>
> this breaks overriding of coherentio via command line. plat_mem_setup/
> plat_setup_iocoherency is called before earlyparams are handled. So
> changing coherentio after that doesn't have any effect.

Hmm. In that case a manual override does actually work for alchemy,
as that initializes coherentio from plat_mem_setup(). But the
elaborate sanity checking that malta performs in plat_setup_iocoherency
is rather pointless then, as coherentio will always be set to
IO_COHERENCE_DISABLED at this point.

\
 
 \ /
  Last update: 2021-02-10 10:15    [W:0.070 / U:0.452 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site