lkml.org 
[lkml]   [2014]   [Sep]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH v6 07/12] usb: chipidea: add a usb2 driver for ci13xxx
Date
On Tuesday 30 September 2014 08:12:07 Peter Chen wrote:
> > +
> > + if (dev->of_node) {
> > + ret = ci_hdrc_usb2_dt_probe(dev, ci_pdata);
> > + if (ret)
> > + goto clk_err;
> > + } else {
> > + ret = dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32));
> > + if (ret)
> > + goto clk_err;
> > + }
>
> My suggestion:
>
> - call dma_coerce_mask_and_coherent(&dev->dev, DMA_BIT_MASK(32)) for both
> dt and non-dt

No, as I explained before, hardcoding the dma mask is always wrong, don't
do that. Call dma_set_mask_and_coherent and check the return value.
It's not wrong to do that for both DT and ATAGS.

Arnd


\
 
 \ /
  Last update: 2014-09-30 12:41    [W:0.226 / U:0.772 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site