[U-Boot] [PATCH 1/3] Add nitrogen6x board

Eric Nelson eric.nelson at boundarydevices.com
Fri Oct 5 22:03:10 CEST 2012


On 10/05/2012 12:00 PM, Tom Rini wrote:
> On Fri, Oct 05, 2012 at 11:42:19AM -0700, Eric Nelson wrote:
>> On 10/05/2012 10:24 AM, Albert ARIBAUD wrote:
>>> Hi Eric,
>>>
>>> On Thu,  4 Oct 2012 12:49:07 -0700, Eric Nelson
>>> <eric.nelson at boundarydevices.com>   wrote:
>>>
>>>> Signed-off-by: Eric Nelson<eric.nelson at boundarydevices.com>
>>>> ---
>>>>   board/boundary/nitrogen6x/Makefile     |   41 ++
>>>>   board/boundary/nitrogen6x/README       |   77 +++
>>>>   board/boundary/nitrogen6x/nitrogen6x.c |  840 ++++++++++++++++++++++++++++++++
>>>>   boards.cfg                             |    1 +
>>>>   include/configs/nitrogen6x.h           |  242 +++++++++
>>>>   5 files changed, 1201 insertions(+), 0 deletions(-)
>>>>   create mode 100644 board/boundary/nitrogen6x/Makefile
>>>>   create mode 100644 board/boundary/nitrogen6x/README
>>>>   create mode 100644 board/boundary/nitrogen6x/nitrogen6x.c
>>>>   create mode 100644 include/configs/nitrogen6x.h
>>>
>>> If this is essentially a copy of sabrelite, I am surprised that git
>>> does not report any copies. Did you use -C with git format-patch ?
>>>
>>
>> Hi Albert,
>>
>> I didn't use '-C' (didn't know about it: thanks for the tip!).
>>
>> It wouldn't have detected copies though, because I made slight
>> changes in each of these files, replacing the board names and
>> file names in board/boundary/ and altering the default environment
>> (policy bits) in nitrogen6x.h.
>
> And we can't deal with this by factoring the code differently?
>
Hi Tom,

There are two bits to this question:
	- Can we represent the policy differences outside of a
	board structure? These differences are all inside of
	include/configs/nitrogen6x.

	I'm not certain how, but I suspect that we can get
	a different _config to work for this.

	- Can we represent the board differences without a
	board structure? This is a bit harder, since the
	boards are slightly different. The Nitrogen6X has
	a different ethernet PHY reset pin and an optional
	SDIO Wi-Fi module.

	We could add code to SABRE Lite to accommodate these,
	but it seems that sets a bad precedent. Would this
	be done for every vendor that bases a design on
	SABRE Lite?

The precise diffs for the configs and sources is attached for
reference.

I've also been pondering how to simply re-use the code within
the board setup file (mx6qsabrelite.c), but I haven't figured
anything out. Clearly a lot of the code is duplicated, but at
the same time it's board-specific.

For example, we could create a common module that sets up
the SD card pads "like SABRE Lite", and a similar one to
configure ethernet pads. Since SABRE Lite is a reference design,
perhaps that makes sense.

Does anybody have thoughts about how and where this might be
sliced?


Regards,


Eric
-------------- next part --------------
A non-text attachment was scrubbed...
Name: config-diffs.patch
Type: text/x-patch
Size: 3444 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20121005/7299194e/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: board-diffs.patch
Type: text/x-patch
Size: 3044 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20121005/7299194e/attachment-0001.bin>


More information about the U-Boot mailing list