build: specify CPU only when it is necessary

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Makefile: drop arch/*/include/asm/proc from make mrproper pattern

Commit 7d89982b stopped creating symbolic link
arch/${arch}/include/asm/proc.

We do not need to delete it by "make mrproper" any more.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Vasili Galka <vvv444@gmail.com>
zynq: disable -Wstrict-prototypes option for ps7_init.c

The files ps7_init.c and ps7_init.h are supposed to be generated by
hw projects such as Vivado, PlanAhead and then to be copied into
board/xilinx/zynq directory.

But some prototypes in them cause annoying warning messages:

  CC      spl/board/xilinx/zynq/ps7_init.o
In file included from board/xilinx/zynq/ps7_init.c:50:0:
board/xilinx/zynq/ps7_init.h:137:1: warning: function declaration isn't a prototype [-Wstrict-prototypes]
board/xilinx/zynq/ps7_init.h:138:1: warning: function declaration isn't a prototype [-Wstrict-prototypes]
board/xilinx/zynq/ps7_init.h:139:1: warning: function declaration isn't a prototype [-Wstrict-prototypes]
board/xilinx/zynq/ps7_init.h:145:1: warning: function declaration isn't a prototype [-Wstrict-prototypes]
board/xilinx/zynq/ps7_init.c:12602:1: warning: function declaration isn't a prototype [-Wstrict-prototypes]
board/xilinx/zynq/ps7_init.c:12723:1: warning: function declaration isn't a prototype [-Wstrict-prototypes]
board/xilinx/zynq/ps7_init.c:12742:1: warning: function declaration isn't a prototype [-Wstrict-prototypes]
board/xilinx/zynq/ps7_init.c:12761:1: warning: function declaration isn't a prototype [-Wstrict-prototypes]
board/xilinx/zynq/ps7_init.c:12854:6: warning: function declaration isn't a prototype [-Wstrict-prototypes]

The prototypes should be

  int ps7_init(void);
  int ps7_post_config(void);
  int ps7_debug(void);

rather than

  int ps7_init();
  int ps7_post_config();
  int ps7_debug();

We do not want to be bothered because of automatically generated files.
But we cannot touch the external projects for now.
What we can do is to disable -Wstrict-prototypes for ps7_init.c

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Michal Simek <michal.simek@xilinx.com>
Tested-by: Michal Simek <michal.simek@xilinx.com>
Series-to: uboot
Series-version: 2
Series-changes: 2
   No change in code. Some changes in git-log
  - Fix a typo:  s/causes/cause/
  - Add Tested-by credit
mpc8xx: remove qs850, qs860t board support

These boards are old enough and have no maintainers.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Series-to: uboot
Series-cc: wd
Cover-letter:
powerpc: Remove mpc8xx boards without maintainers

Various global changes are happening to U-boot:
Generic board, driver model, Kconfig, ...

The more boards we have, the more efforts we need
for those future changes.

This series removes MPC8xx boards which have no maintainers.
I guess they are old enough and almost dead.

I built all the other boards and
I confirmed this series has no impact on them.

END
mpc8xx: remove RPXlite_dw, quantum board support

These boards are old enough and have no maintainers.
mpc8xx: remove rbc823 board support

This board is old enough and has no maintainer.
mpc8xx: remove netta, netta2, netphone board support

These boards are old enough and have no maintainers.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
mpc8xx: remove fads board support

These boards are old enough and have no maintainers.
mpc8xx: remove v37 board support

This board is old enough and has no maintainer.
mpc8xx: remove spc1920 board support

This board is old enough and has no maintainer.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
sparc: merge LEON3 linker scripts

The linker scripts of LEON3

 - board/gaisler/grsim/u-boot.lds
 - board/gaisler/gr_cpci_ax2000/u-boot.lds
 - board/gaisler/gr_ep2s60/u-boot.lds
 - board/gaisler/gr_xc3s_1500/u-boot.lds

are the same (except cosmetic differences such as indentation).

This commit merges them into arch/sparc/cpu/leon3/u-boot.lds.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Daniel Hellstrom <daniel@gaisler.com>
Series-to: uboot
Series-cc: Daniel Hellstrom <daniel@gaisler.com>
Cover-letter:
Merge all SPARC linker scripts into a single file

In the other architecutres, the default linker scripts are placed at
arch/${ARCH}/cpu/u-boot.lds or arch/${ARCH}/cpu/${CPU}/u-boot.lds.

On the other hand, SPARC does not have arch-default linker script
but has almost the same linker scripts under each board directory.

They can be easily merged.

I built all SPARC boards and compared MD5SUM.
The same binaries are produced before/after this series.
So I am sure this clean-up is correct.

END
sparc: merge LEON2 and LEON3 linker scripts

There is only one line diff between LEON2 and LEON3 linker scripts:

  -             arch/sparc/cpu/leon2/start.o (.text)
  +             arch/sparc/cpu/leon3/start.o (.text)

They can be written in the same way:

                */start.o (.text)

So, board/gaisler/grsim_leon2/u-boot.lds
and arch/sparc/cpu/leon3/u-boot.lds
can be merged into arch/sparc/cpu/u-boot.lds.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Daniel Hellstrom <daniel@gaisler.com>
sh: unify sh2/sh3/sh4 linker scripts

The linker scripts of sh2/sh3/sh4 are almost the same.
The difference among them is essentially only one line.

They can be consolidated into a single file, arch/sh/cpu/u-boot.lds
by re-writing the diffrent line as follows:

	KEEP(*/start.o	(.text))

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
Series-to: uboot
Commit-notes:

I built all SuperH boards and comprared MD5SUM.
I confirmed the same output binaries are produced with/without
this patch.

END
kbuild: move extra gcc checks to scripts/Makefile.extrawarn

This commit was imported from Linux Kernel:
commit a86fe353 written by me.

W=... provides extra gcc checks.

Having such code in scripts/Makefile.build results in the same flags
being added to KBUILD_CFLAGS multiple times becuase
scripts/Makefile.build is invoked every time Kbuild descends into
the subdirectories.

Since the top Makefile is already too cluttered, this commit moves
all of extra gcc check stuff to a new file scripts/Makefile.extrawarn,
which is included from the top Makefile.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Series-to: uboot
Cover-letter:
Kbuild: sync with Linux 3.16-rc1

The merge window for Linux 3.16 is closed and Linux 3.16-rc1 is out now.

During the merge window, various Kbuild-related updates were merged into
the upstream.

This series imports them to U-Boot.

END
boards.cfg: keep it sorted filling the board field

awk '$6 == "-" { $6 = $7 } { print }' boards.cfg \
  |  tools/reformat.py -i -d '-' -s 8  > boards0.cfg; \
  mv boards0.cfg boards.cfg

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
tools/reformat.py: refactor ignore-case option handling

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
reformat.py: natural sort
kbuild: sync mixed targets handling with Linux 3.16-rc1

"make %_config all" was supported for the first time in U-Boot:
  commit 53bca5ab
  kbuild: support simultaneous board configuration and "make all"

Surprisingly it had not been working in Linux Kernel for a long time.

So I sent back the patch to the Linux Kbuild community and it was
accepted with a little code improvement, at commit 9319f453.

Now, you can do "make defconfig all" or "make %_defconfig all"
in Linux too.

This commit updates some scripts to fill the code-diff
between Linux and U-Boot.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
scripts: objdiff: sync with Linux 3.16-rc1

Import scripts/objdiff improvements from Linux v3.16-rc1, which
consists of 7 commits written by me.

  commit 7fa0e6db3cedc9b70d68a4170f1352e2b1aa0f90
  scripts: objdiff: support directories for the augument of record command

  commit 8ac28bee76eec006aac5ba5c418878a607d53a9b
  scripts: objdiff: fix a comment

  commit 8b5d0f20d64f00ffd5685879f8eb3659379f5aaa
  scripts: objdiff: change the extension of disassembly from .o to .dis

  commit 18165efa8203a34d82f60a1831ea290e7304c654
  scripts: objdiff: improve path flexibility for record command

  commit 1ecc8e489abfdaa6d8d1689f7ff62fdf1adda30c
  scripts: objdiff: remove unnecessary code

  commit 5ab370e91af70d5f1b1dbaec78798a2ff236a2d5
  scripts: objdiff: direct error messages to stderr

  commit fd6e12423311697860f30d10398a0f9eb91977d2
  scripts: objdiff: get the path to .tmp_objdiff more simply

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
kbuild: Use relative path when possible

Import 3 useful commits by Michal Marek <mmarek@suse.cz>
from Linux 3.16-rc1.

  commit 9da0763bdd82572be243fcf5161734f11568960f
  kbuild: Use relative path when building in a subdir of the source tree

  commit 890676c65d699db3ad82e7dddd0cf8fb449031af
  kbuild: Use relative path when building in the source tree

  commit 7e1c04779efd51154baf652e653ceb24ce68939b
  kbuild: Use relative path for $(objtree)

mkconfig and tools/Makefile must be adjusted to use relative path
for srctree.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>