public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Tom Rini <trini@ti.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] When to create a SoC directory for ARM
Date: Thu, 26 Sep 2013 17:39:38 -0400	[thread overview]
Message-ID: <5244A99A.10405@ti.com> (raw)
In-Reply-To: <5244A7D3.1060603@freescale.com>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 09/26/2013 05:32 PM, York Sun wrote:
> On 09/26/2013 02:26 PM, Scott Wood wrote:
>> On Thu, 2013-09-26 at 14:07 -0700, York Sun wrote:
>>> On 09/26/2013 02:03 PM, Tom Rini wrote:
>>>> On 09/26/2013 04:59 PM, Scott Wood wrote:
>>>>> On Thu, 2013-09-26 at 16:49 -0400, Tom Rini wrote:
>>>>>> On 09/26/2013 04:44 PM, Scott Wood wrote:
>>>>>>> On Thu, 2013-09-26 at 12:57 -0700, York Sun wrote:
>>>>>>>> On 09/26/2013 12:55 PM, Scott Wood wrote:
>>>>>>>>> On Thu, 2013-09-26 at 12:48 -0700, York Sun wrote:
>>>>>>>>>> On 09/26/2013 12:46 PM, Sharma Bhupesh-B45370
>>>>>>>>>> wrote:
>>>>>>>>>>> 
>>>>>>>>>>>> -----Original Message----- From: 
>>>>>>>>>>>> u-boot-bounces at lists.denx.de 
>>>>>>>>>>>> [mailto:u-boot-bounces at lists.denx.de] On
>>>>>>>>>>>> Behalf Of Scott Wood Sent: Friday, September
>>>>>>>>>>>> 27, 2013 12:53 AM To: FengHua Cc: trini; sun
>>>>>>>>>>>> york-R58495; u-boot Subject: Re: [U-Boot]
>>>>>>>>>>>> When to create a SoC directory for ARM
>>>>>>>>>>>> 
>>>>>>>>>>>> On Thu, 2013-09-26 at 13:23 +0800, FengHua
>>>>>>>>>>>> wrote:
>>>>>>>>>>>>> all SOC specific include file should be in
>>>>>>>>>>>>>  arch/arm/include/asm/arch-SOC/ or some
>>>>>>>>>>>>> common directory(like
>>>>>>>>>>>>> include/asm/imx-common). Currently, u-boot
>>>>>>>>>>>>> only link SOC specific(arch-SOC) include 
>>>>>>>>>>>>> directory. You could touch a mmu.h file in
>>>>>>>>>>>>>  arch/arm/include/asm/arch-ls2/ and include
>>>>>>>>>>>>>  arch/arm/include/asm/arch-armv8/mmu.h. or
>>>>>>>>>>>>> move arch-armv8/mmu.h to
>>>>>>>>>>>>> arch/arm/include/asm/ to make it as a
>>>>>>>>>>>>> generic file. Maybe we should distinguish 
>>>>>>>>>>>>> architecture specific include directory and
>>>>>>>>>>>>> SOC specific include directory.
>>>>>>>>>>>> 
>>>>>>>>>>>> Is the XXX arch-XXX supposed to be an SoC
>>>>>>>>>>>> family or a CPU family/architectutre?
>>>>>>>>>>>> 
>>>>>>>>>>> 
>>>>>>>>>>> Usually in 'arch/arm/include/asm' we have both:
>>>>>>>>>>> - arch-armv7 (Arch specific. Houses stuff
>>>>>>>>>>> common to ARMv7 CPU, e.g. Global timer, SP805
>>>>>>>>>>> WDT..) - arch-mx6 (SoC family specific. Houses
>>>>>>>>>>> stuff like SoC specific IOMUX pads..)
>>>>>>>>> 
>>>>>>>>> Which one does "#inculde <asm/arch/foo.h>" refer
>>>>>>>>> to?
>>>>>>>>> 
>>>>>>>> 
>>>>>>>> arm/arch is a symbolic link created at compiling
>>>>>>>> time. It points to arm/arch-$(soc), if $(soc) is not
>>>>>>>> defined, then it points to asm/arch-$(arch). That's
>>>>>>>> my understanding.
>>>>>>> 
>>>>>>> How is that supposed to work when both arch-$(soc) and 
>>>>>>> arch-$(arch) are present?  Why are SoC and CPU arch
>>>>>>> confused in this way?
>>>>>> 
>>>>>> Primarily because it hasn't been an issue until now
>>>>>> really. What's wrong with just saying
>>>>>> <asm/arch-armv[78]/foo.h> as needed ?
>>>> 
>>>>> Hmm, the only relevant <asm/arch/mmu.h> are in
>>>>> armv8-specific files, so I suppose we could do that.  Why
>>>>> not just rename it asm/armv[78], though?  There are only a
>>>>> handful of files in both armv7 and armv8, so it shouldn't
>>>>> be too much of a problem.  Then there's no question of
>>>>> where the symlink points.
>>>> 
>>>> That should also be fine, after a quick git grep around..
>>>> 
>>> How about arch/arm/include/asm/gpio.h? it includes
>>> <asm/arch/gpio.h>.
>> 
>> gpio.h doesn't belong in the armv8 directory.
>> 
> 
> No, it doesn't. But oddly we have a lot of them. And since it is 
> including <asm/arch/gpio.h>, we have to make it happy.

No, we have to move it from asm/arch-armv8/gpio.h to
asm/arch-soc/gpio.h for that family.

- -- 
Tom
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIcBAEBAgAGBQJSRKmaAAoJENk4IS6UOR1WHWsQAJFfQLT7zDAQ/QODxKFecwZH
yJyXQaENoHtyF3Rvbzxt6mbupjJ3gviVJrhFQUSZ9jmTokbeLRC+26g7FPqtGeWh
EfpfcRHaEJ5hMkZxa/V97357DOrfitX68uCXpBMmzQcj2l1DF6SPJ3CcV8+XjoCO
5ZjKQpahBC2Pxd++cH3oPEGvy00DH55giOpVxwdBHKZGP3X/ySqoY5C54Nojg6+P
r7d33vceIKLBVh4kln8bZPjFNR3BqoYfRBphgNRP6AyhEBDvuTbF0JjT107Ym1yX
awo3wcmm+oGl3/ptUZh9nk8rsIbLkirhx84UZJUrb812QZnO5ORwxgExp5IRgO9T
Y0ofH9bLFy2jBZwyNVzp0QPi5bhBPe8ehYTW0aFIK9eydhbNTIuxMjDXdp8TaSjC
w3pq+iE13clfoFL51iI/gm09RDH4/vpb2G5VRO9tCwVCzPIxO5hG3NJ0FE3S0sJR
SItirnxs+ekH/vCCC5elJRrI89kAK8OJwe0KyhQAZJYfY9R6jwmrwJxcFEvw6qwU
rRrc3u6yiHUgbgnuNwUZQKoGLmVh4/5TFpE8h12zzMlI7XZmq5QnEPbSfOeiR1Np
vCZZKbyMbsdc/+UNiQYABGvpOJV8OIO7fkGhhS3+LChehWYsYnff23E522QPnKn6
Kcnvd4U5EP3erixNFWc7
=A+o+
-----END PGP SIGNATURE-----

  reply	other threads:[~2013-09-26 21:39 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-26  5:23 [U-Boot] When to create a SoC directory for ARM FengHua
2013-09-26  5:31 ` sun york-R58495
2013-09-26 10:49   ` FengHua
2013-09-26 15:22     ` York Sun
2013-09-26 19:18     ` York Sun
2013-09-26 19:23 ` Scott Wood
2013-09-26 19:46   ` Sharma Bhupesh-B45370
2013-09-26 19:48     ` York Sun
2013-09-26 19:55       ` Scott Wood
2013-09-26 19:57         ` York Sun
2013-09-26 20:44           ` Scott Wood
2013-09-26 20:46             ` York Sun
2013-09-26 20:48               ` Scott Wood
2013-09-26 20:49             ` Tom Rini
2013-09-26 20:59               ` Scott Wood
2013-09-26 21:03                 ` Tom Rini
2013-09-26 21:07                   ` York Sun
2013-09-26 21:26                     ` Scott Wood
2013-09-26 21:32                       ` York Sun
2013-09-26 21:39                         ` Tom Rini [this message]
2013-09-26 19:55       ` Sharma Bhupesh-B45370
  -- strict thread matches above, loose matches on Subject: below --
2013-09-17 15:59 [U-Boot] How do ARM platform initialize DDR? York Sun
2013-09-19 20:57 ` Tom Rini
2013-09-19 21:08   ` York Sun
2013-09-19 21:39     ` Wolfgang Denk
2013-09-25 23:30       ` [U-Boot] When to create a SoC directory for ARM York Sun
2013-09-25 23:52         ` Scott Wood
2013-09-26  1:04           ` sun york-R58495
2013-09-26  1:10             ` Scott Wood
2013-09-26  9:58         ` Wolfgang Denk

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=5244A99A.10405@ti.com \
    --to=trini@ti.com \
    --cc=u-boot@lists.denx.de \
    /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