public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Detlev Zundel <dzu@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v2] Separate EBV Socrates board from Altera Cyclone 5 board and from Virtual Target
Date: Thu, 05 Jun 2014 12:45:19 +0200	[thread overview]
Message-ID: <m2y4xbvdmo.fsf@lamuella.denx.de> (raw)
In-Reply-To: <1401692000.2651.17.camel@clsee-VirtualBox.altera.com> (Chin Liang See's message of "Mon, 2 Jun 2014 01:53:20 -0500")

Hi Chian,

> Hi guys,
>
>
> On Fri, 2014-05-30 at 11:41 +0200, Detlev Zundel wrote:
>> Hi Pavel,
>>
>> > On Wed 2014-05-28 16:29:50, Wolfgang Denk wrote:
>> >> In message <20140528124910.GA24478@amd.pavel.ucw.cz> you wrote:
>> >> >
>> >> > There are no differences between EBV socrates and socfpga boards,
>> >> > currently.
>> >>
>> >> Well, for one thing, the board vendor and the board name differ...
>> >
>> > I meant from current code in u-boot point of view...
>>
>> But as we all agree, this may change quickly and for multiple boards.
>
>
> Yup, some other board vendors are using different HW configuration. Some
> of the difference are Altera dev kit have EEPROM and using Micrel PHY
> for EMAC. I presume Socrates board should have their own board path such
> as board/socrates/socfpga.

We are using a "board/<vendor>" scheme, so it should be
"board/ebv/socrates", but otherwise we agree.

>> >> > > > AFAICT, one solution would be to put "-" in that column, and
>> >> > > > do "git
>> >> > > > mv board/altera/ board/socfpga/".
>> >> > >
>> >> > > Putting "-" in the vendor column just doesn't feel right.
>> >> >
>> >> > That's what mx6 did, AFAICT.
>> >>
>> >> I think Detlev is right here.  We do have specific board vendors
>> >> directories, and there are a number of reasons to keep this used
>> >> (just to give one example: say a vendor wants to use a similar look
>> >> and feel for the default environment settings etc. for all boards).
>> >
>> >> If there is code which is identical for several (or all?) boards we
>> >> should ask ourself if it really belongs into the board/ directory at
>> >> all?
>> >
>> > That might be the case. It seems that current code in board/altera is
>> > SoC-specific, as it works on both Altera and EBV boards.
>>
>> Then we are in agreement that it does not belong below board/ ;)
>
>
> Within board/altera, there are 2 types of files as below:
>
> 1. HW configuration handoff files (such as pinmux_config, pll_config).
>    Pinmux might be different as certain board might have different
> routing (normally to optimize the board layout and shorter PCB trace
> length).
>
> 2. Board specific code (socfpga_cyclone5.c)
>    These functions include board_init, board_early_init, checkboard.
>    I believe that the function print_cpuinfo and overwrite _console
> should goto arch/arm/cpu/armv7/socfpga/misc.c.
>    I will create the patch to change this later (as I already did this
> at rocketboard.org).

Thanks in advance!

>> >> > Actually.. there's nothing Altera specific in board/altera (it works
>> >> > on ebv just fine), so board/socfpga sounds like a better name. But I
>> >> > don't think such rename should be done lightly, so I still believe the
>> >> > patch as submitted is the best way to go.
>> >>
>> >> I think board/altera as such makes sense, with Altera being the vendor
>> >> of that specific board.  However, if there is common code there, this
>> >> code should be moved out of board/ .
>> >
>> > It seems there's currently 99.99% of SoC-specific code there.
>> >
>> > What would be the right place for that code?
>>
>> Depends on what exactly it implements.  Apart from that we can also take
>> a look at where the code is in a Linux tree and take that as an
>> example.  After all, we want people developing the Linux kernel to also
>> feel at home in the U-Boot sources.
>>
>> > arch/arm/cpu/armv7/socfpga/ ? But it is not really armv7-specific.
>> > drivers/misc ? Do we need to make a soc/ directory?
>>
>> We have arch/arm/imx-common for example, but I'm not so sure if this is
>> a good approach.  Maybe there is not a _single_ correct place, but we
>> have to distribute the files to multiple directories?
>>
>> > And then... who does the move? It is not going to make merging between
>> > rocketboards.org and mainline even trickier than it already is :-(.
>>
>> This is a good question and we should certainly not answer it lightly.
>> Usually we care only to a certain degree for non-mainline code, though.
>> Blocking ourselves because of non-mainline code would allow "external"
>> control which I think is not really helpful for the project.
>>
>
>
> As above, I can move some common function to
> arch/arm/cpu/armv7/socfpga/misc.c.

Sounds good.

Thanks
  Detlev
  
-- 
A statistician can have his head in an oven and his feet in ice, and
he will say that on the average he feels fine.
--
DENX Software Engineering GmbH,      MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich,  Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de

  reply	other threads:[~2014-06-05 10:45 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-11 19:26 [U-Boot] [PATCH] Separate EBV Socrates board from Altera Cyclone 5 board Pavel Machek
2013-11-11 20:32 ` Chin Liang See
2013-11-11 20:33 ` Tom Rini
2013-11-12  8:22   ` Michal Simek
2013-11-12  9:56     ` Detlev Zundel
2013-11-12 10:17       ` Michal Simek
2013-11-12 14:46         ` Chin Liang See
2013-11-12 15:17           ` Michal Simek
2013-11-13  0:07             ` Dinh Nguyen
2013-11-13 14:39             ` Chin Liang See
2013-11-13 15:55               ` Michal Simek
2013-11-13 17:57                 ` Chin Liang See
2013-11-14  7:23                   ` Michal Simek
2013-11-12 15:25       ` Tom Rini
2013-11-12  9:53   ` Detlev Zundel
2014-01-13  8:29 ` Albert ARIBAUD
2014-05-27 13:12   ` [U-Boot] [PATCH v2] Separate EBV Socrates board from Altera Cyclone 5 board and from Virtual Target Pavel Machek
2014-05-27 13:42     ` Detlev Zundel
2014-05-27 13:59       ` Pavel Machek
2014-05-28  8:53         ` Detlev Zundel
2014-05-28  9:56           ` Pavel Machek
2014-05-28 10:36             ` Detlev Zundel
2014-05-28 12:49               ` Pavel Machek
2014-05-28 14:29                 ` Wolfgang Denk
2014-05-28 18:26                   ` Pavel Machek
2014-05-30  9:41                     ` Detlev Zundel
2014-06-02  6:53                       ` Chin Liang See
2014-06-05 10:45                         ` Detlev Zundel [this message]
2014-06-02  7:22     ` Chin Liang See

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=m2y4xbvdmo.fsf@lamuella.denx.de \
    --to=dzu@denx.de \
    --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