linux/arch/mn10300/unit-asb2305
Mark Salter d22a001bf6 mn10300: fix kernel build failures when using gcc-4.x
Fix some build failures when using gcc-4.x for MN10300.

Firstly, __get_user() fails to build because the pointer points to a const and
__gu_val ends up being read-only:

In file included from include/linux/mempolicy.h:62,
                 from init/main.c:50:
include/linux/pagemap.h: In function 'fault_in_pages_readable':
include/linux/pagemap.h:394: error: read-only variable '__gu_val' used as 'asm' output
include/linux/pagemap.h:394: error: read-only variable '__gu_val' used as 'asm' output
include/linux/pagemap.h:394: error: read-only variable '__gu_val' used as 'asm' output
include/linux/pagemap.h:400: error: read-only variable '__gu_val' used as 'asm' output
include/linux/pagemap.h:400: error: read-only variable '__gu_val' used as 'asm' output
include/linux/pagemap.h:400: error: read-only variable '__gu_val' used as 'asm' output
make[1]: *** [init/main.o] Error 1

Secondly, gcc-4 doesn't allow casts of lvalues:

  UPD     include/linux/compile.h
arch/mn10300/kernel/rtc.c: In function 'calibrate_clock':
arch/mn10300/kernel/rtc.c:170: error: lvalue required as left operand of assignment
arch/mn10300/kernel/rtc.c:172: error: lvalue required as left operand of assignment
make[1]: *** [arch/mn10300/kernel/rtc.o] Error 1

These are seen with gcc 4.2.1.

Signed-off-by: Mark Salter <msalter@redhat.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-10-01 16:11:12 -07:00
..
include/unit mn10300: fix kernel build failures when using gcc-4.x 2009-10-01 16:11:12 -07:00
Makefile
leds.c Separate out the proc- and unit-specific header directories from the general 2009-04-10 14:33:48 +01:00
pci-asb2305.c
pci-asb2305.h
pci-iomap.c iomap: fix 64 bits resources on 32 bits 2008-04-29 08:06:02 -07:00
pci-irq.c
pci.c mn10300: fix typo && -> || in arch/mn10300/unit-asb2305/pci.c 2009-02-20 17:57:48 -08:00
unit-init.c Separate out the proc- and unit-specific header directories from the general 2009-04-10 14:33:48 +01:00