devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ray Jui <rjui-dY08KVG/lbpWk0Htik3J/w@public.gmane.org>
To: Arnd Bergmann <arnd-r2nGTMty4D4@public.gmane.org>
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	Florian Fainelli
	<f.fainelli-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	Rob Herring <robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	Mark Rutland <mark.rutland-5wv7dgnIgG8@public.gmane.org>,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Pawel Moll <pawel.moll-5wv7dgnIgG8@public.gmane.org>,
	Ian Campbell
	<ijc+devicetree-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org>,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	bcm-kernel-feedback-list-dY08KVG/lbpWk0Htik3J/w@public.gmane.org,
	Kumar Gala <galak-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>
Subject: Re: [PATCH v2 5/9] ARM: dts: Move all Cygnus peripherals into soc bus
Date: Wed, 23 Sep 2015 14:55:34 -0700	[thread overview]
Message-ID: <56031FD6.3070306@broadcom.com> (raw)
In-Reply-To: <1969821.ZhaOpCV2D1@wuerfel>



On 9/23/2015 2:29 PM, Arnd Bergmann wrote:
> On Friday 18 September 2015 15:11:27 Ray Jui wrote:
>> On 9/18/2015 2:34 PM, Arnd Bergmann wrote:
>>> On Friday 18 September 2015 14:24:10 Ray Jui wrote:
>>>> +       soc {
>>>> +               compatible = "simple-bus";
>>>> +               ranges;
>>>> +               #address-cells = <1>;
>>>> +               #size-cells = <1>;
>>>
>>>> +               pinctrl: pinctrl@0301d0c8 {
>>>>
>>>
>>> Similarly to the core bus, this seems to have address ranges 0x03xxxxxx and
>>> 0x18xxxxxx on it, so put those into the ranges.
>>>
>>
>> Okay we have an issue here. For whatever reason, the Cygnus ASIC team
>> decided to put registers for the same block in random locations. We see
>> similar issues in all of our other iProc based SoCs. We have
>> communicated this to our ASIC team, and hopefully they can revert the
>> trend for the next SoC.
>>
>> For example, the gpio_ccm has registers in the following regions:
>>
>> gpio_ccm: gpio@1800a000 {
>>     compatible = "brcm,cygnus-ccm-gpio";
>>     reg = <0x1800a000 0x50>,
>>           <0x0301d164 0x20>;
>>
>> NAND is worse, it has registers in 3 different separate regions:
>>
>> nand: nand@18046000 {
>>     compatible = "brcm,nand-iproc", "brcm,brcmnand-v6.1",
>>                  "brcm,brcmnand";
>>     reg = <0x18046000 0x600>, <0xf8105408 0x600>,
>>           <0x18046f00 0x20>;
>>
>> As you can see, this makes it impossible to define a proper address
>> range for the bus; therefore, I'll have to keep the ranges undefined and
>> a simple 1:1 mapping under this bus.
> 
> Hmm, you could still try to list them as non-overlapping with other
> buses on the root node like
> 
> 	ranges = <0x03000000 0x03000000 0x01000000>,
> 		 <0x18000000 0x18000000 0x01000000>,
> 		 <0xf8000000 0xf8000000 0x01000000>;
> 
> which clarifies how the bus is wired up in hardware.
> 
> Alternatively, you could make a more elaborate mapping, if there
> are in fact multiple hardware ranges, like
> 
> 	#address-cells = <2>; # space:offset
> 	ranges = <1 0  0x03000000 0x01000000>,
> 		 <2 0  0x18000000 0x01000000>,
> 		 <3 0  0xf8000000 0x01000000>;
> 
> It really depends on what the hardware designers were thinking. If
> the AXI bus actually decodes the entire 32-bit address range and devices
> are just located at random addresses in there, your current scheme is
> probably closest to reality.
> 

I see. Let me talk to our ASIC team to get this clarified. If in the end
the AXI bus decodes the entire 32-bit address space, no change will be
made. Otherwise, I'll submit another patch to list the actual address
space that the AXI bus decodes.

Thanks for the review. It's very helpful!

Ray
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2015-09-23 21:55 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-18 21:24 [PATCH v2 0/9] Broadcom Cygnus device tree changes Ray Jui
     [not found] ` <1442611454-16331-1-git-send-email-rjui-dY08KVG/lbpWk0Htik3J/w@public.gmane.org>
2015-09-18 21:24   ` [PATCH v2 1/9] ARM: dts: consolidate aliases for Cygnus dt files Ray Jui
     [not found]     ` <1442611454-16331-2-git-send-email-rjui-dY08KVG/lbpWk0Htik3J/w@public.gmane.org>
2015-09-18 21:27       ` Arnd Bergmann
2015-09-18 21:44         ` Ray Jui
     [not found]           ` <55FC85D6.7050506-dY08KVG/lbpWk0Htik3J/w@public.gmane.org>
2015-09-23 21:31             ` Arnd Bergmann
2015-09-23 21:46               ` Ray Jui
     [not found]                 ` <56031DAF.5070503-dY08KVG/lbpWk0Htik3J/w@public.gmane.org>
2015-09-23 21:48                   ` Florian Fainelli
2015-09-24 22:23                     ` Ray Jui
2015-09-18 21:24   ` [PATCH v2 4/9] ARM: dts: Put Cygnus core components under core bus Ray Jui
     [not found]     ` <1442611454-16331-5-git-send-email-rjui-dY08KVG/lbpWk0Htik3J/w@public.gmane.org>
2015-09-18 21:30       ` Arnd Bergmann
2015-09-18 21:57         ` Ray Jui
2015-09-18 21:24 ` [PATCH v2 2/9] ARM: dts: Use label for device nodes in Cygnus dts Ray Jui
2015-09-18 21:24 ` [PATCH v2 3/9] ARM: dts: Remove unused PCI I/O resource in Cygnus Ray Jui
2015-09-18 21:28   ` Arnd Bergmann
2015-09-18 21:53     ` Ray Jui
2015-09-18 21:24 ` [PATCH v2 5/9] ARM: dts: Move all Cygnus peripherals into soc bus Ray Jui
     [not found]   ` <1442611454-16331-6-git-send-email-rjui-dY08KVG/lbpWk0Htik3J/w@public.gmane.org>
2015-09-18 21:34     ` Arnd Bergmann
2015-09-18 22:11       ` Ray Jui
2015-09-23 21:29         ` Arnd Bergmann
2015-09-23 21:55           ` Ray Jui [this message]
2015-09-24  5:54             ` Ray Jui
2015-09-18 21:24 ` [PATCH v2 6/9] ARM: dts: Reorder Cygnus peripherals Ray Jui
2015-09-18 21:24 ` [PATCH v2 7/9] ARM: dts: Enable various peripherals on bcm958305k Ray Jui
2015-09-18 21:24 ` [PATCH v2 8/9] ARM: dts: Enable NAND support on bcm911360_entphn Ray Jui
2015-09-18 21:24 ` [PATCH v2 9/9] ARM: dts: enable touchscreen support on Cygnus Ray Jui

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=56031FD6.3070306@broadcom.com \
    --to=rjui-dy08kvg/lbpwk0htik3j/w@public.gmane.org \
    --cc=arnd-r2nGTMty4D4@public.gmane.org \
    --cc=bcm-kernel-feedback-list-dY08KVG/lbpWk0Htik3J/w@public.gmane.org \
    --cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=f.fainelli-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=galak-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org \
    --cc=ijc+devicetree-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org \
    --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mark.rutland-5wv7dgnIgG8@public.gmane.org \
    --cc=pawel.moll-5wv7dgnIgG8@public.gmane.org \
    --cc=robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).