[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20150105155049.GF19336@saruman>
Date: Mon, 5 Jan 2015 09:50:49 -0600
From: Felipe Balbi <balbi@...com>
To: Arnd Bergmann <arnd@...db.de>
CC: <balbi@...com>, Sneeker Yeh <sneeker.yeh@...il.com>,
Rob Herring <robh+dt@...nel.org>,
Pawel Moll <pawel.moll@....com>,
Mark Rutland <mark.rutland@....com>,
Ian Campbell <ijc+devicetree@...lion.org.uk>,
Kumar Gala <galak@...eaurora.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Mathias Nyman <mathias.nyman@...el.com>,
Grant Likely <grant.likely@...aro.org>,
Alan Stern <stern@...land.harvard.edu>,
Paul Bolle <pebolle@...cali.nl>,
Hans de Goede <hdegoede@...hat.com>,
Thomas Pugliese <thomas.pugliese@...il.com>,
David Mosberger <davidm@...uge.net>,
Peter Griffin <peter.griffin@...aro.org>,
Sylwester Nawrocki <s.nawrocki@...sung.com>,
Andrew Bresticker <abrestic@...omium.org>,
Gregory CLEMENT <gregory.clement@...e-electrons.com>,
Yoshihiro Shimoda <yoshihiro.shimoda.uh@...esas.com>,
<devicetree@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
<linux-usb@...r.kernel.org>, <linux-omap@...r.kernel.org>,
Andy Green <andy.green@...aro.org>,
Jassi Brar <jaswinder.singh@...aro.org>,
Sneeker Yeh <Sneeker.Yeh@...fujitsu.com>
Subject: Re: [PATCH 2/3] usb: dwc3: add Fujitsu Specific Glue layer
Hi,
On Mon, Jan 05, 2015 at 04:28:34PM +0100, Arnd Bergmann wrote:
> On Friday 02 January 2015 19:21:28 Felipe Balbi wrote:
> >
> > On Tue, Dec 30, 2014 at 11:12:51AM +0100, Arnd Bergmann wrote:
> > > On Monday 29 December 2014 01:52:04 Sneeker Yeh wrote:
> > > > > > +static int dwc3_mb86s70_remove_child(struct device *dev, void *unused)
> > > > > > +{
> > > > > > + struct platform_device *pdev = to_platform_device(dev);
> > > > > > +
> > > > > > + of_device_unregister(pdev);
> > > > > > +
> > > > > > + return 0;
> > > > > > +}
> > > > > > +
> > > > > > +static u64 dwc3_mb86s70_dma_mask = DMA_BIT_MASK(32);
> > > > >
> > > > > why ? Use dma_coerce_mask_and_coherent().
> > > > >
> > > >
> > > > okay.
> > >
> > > Actually that is still wrong: we use dma_coerce_mask_and_coherent() to
> > > annotate drivers that have traditionally been forcing their own dma mask
> > > by some other means and that need to be changed to something proper (after
> > > finding out why they did it in the first place).
> > >
> > > Since this is about a child device, the correct interface is to use
> > > platform_device_register_full().
> >
> > no, that's wrong. He's essentially fixing the default set by OF core,
> > which is always 32-bits anyway, so this can actually be removed. Your
> > suggestion would just make it worse.
>
> Ah, so this was for a device that gets probed from DT? Yes, then no
> change is needed here at all.
right.
> Note that I'm working on a patch set to change the DT initialization to
> be a little smarter about the mask. Specifically any device whose parent
> has a smaller dma-ranges window than 4GB needs to start out with the
> smaller mask, and the dma_set_mask function that is called to allow 64-bit
> DMA on a device will check if the bus can actually support it.
please make sure have that patch soaking in linux-next for weeks before
attempting to merge it upstream. I would target v3.21 with such a patch.
At least keystone might be a little weird about what you describe
considering the thing boots from HIGHMEM. Also needs to consider LPAE,
etc.
--
balbi
Download attachment "signature.asc" of type "application/pgp-signature" (820 bytes)
Powered by blists - more mailing lists