[U-Boot] [PATCH v3 1/4] Add support new arch: c6x

Tom Rini
2012-06-25T22:04:34Z

On Mon, Jun 25, 2012 at 10:02:38PM +0400, Dmitry Bondar wrote:

> C6X (C6000) is Texas Instruments architecture of fixed and floating-point DSPs.
> This patch add basic support.
> Many of code in arch/c6x/include/asm come from c6x-linux project (http://linux-c6x.org)
>
> Signed-off-by: Dmitry Bondar <bond@inmys.ru>
> Cc: Tom Rini <trini@ti.com>

Please cite the exact commit from upstream where this comes from (I
imagine you could even use kernel.org proper, but I didn't check all
files just a few) and say for example:
Backport from linux commit 27406e978f596a646b87941cba5247eb0ccc8916

> +#ifndef __ASM_GBL_DATA_H

Tabs instead of spaces. I don't know why checkpatch didn't complain but
please give all of the files a quick check for things like <tab><space>
and '#define<tab>' and '#ifndef<tab>.

I spot-checked a few of the library files and they seem to match the
kernel which is important so I'll set aside disliking ';' as a comment
char.

[snip]
> diff --git a/common/cmd_bdinfo.c b/common/cmd_bdinfo.c
> index 42f08fd..faf534b 100644
> --- a/common/cmd_bdinfo.c
> +++ b/common/cmd_bdinfo.c
> @@ -513,6 +513,11 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
>
> return 0;
> }
> +#elif defined(CONFIG_C6X)
> +int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
> +{
> + return 0;
> +}

You should be able to define a minimal set of prints here, see the
OpenRISC example above it.

> diff --git a/common/image.c b/common/image.c
> index 91954ac..0fff687 100644
> --- a/common/image.c
> +++ b/common/image.c
> @@ -456,8 +456,12 @@ phys_size_t getenv_bootm_size(void)
> #if defined(CONFIG_ARM)
> return gd->bd->bi_dram[0].size - tmp;
> #else
> +#if defined(CONFIG_C6X)
> + return gd->bd->bi_dram[0].size - tmp;

Here and possibly another place or two in the file, just change the
check from defined(CONFIG_ARM) to defined(CONFIG_ARM) ||
defined(CONFIG_C6X).

Thanks!

--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20120625/36b53cc5/attachment.pgp>