Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9548b209 authored by Ivan Kokshaysky's avatar Ivan Kokshaysky Committed by Linus Torvalds
Browse files

alpha: build fixes



This fixes some of the alpha-specific build problems, except a) modpost
warning about COMMON symbol "saved_config" and b) nasty final link
failure with gcc-4.x, -Os and scsi-disk driver configured built-in
(due to jump table in .rodata referencing discarded .exit.text).

- build failure with gcc-4.2.x: fix up casts in cia_io* routines to avoid
  warnings ('discards qualifiers from pointer target type'), which are
  failures, thanks to -Werror;
- modpost warnings: add missing __init qualifier for titan and marvel;
  for non-generic build, move machine vectors from .data to .data.init.refok
  section;
- unbreak CPU-specific optimization: rearrange cpuflags-y assignments
  so that extended -mcpu value (ev56, pca56, ev67) overrides basic
  one (ev5, ev6) and not vice versa.

Signed-off-by: default avatarIvan Kokshaysky <ink@jurassic.park.msu.ru>
Cc: Richard Henderson <rth@twiddle.net>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent b47b6f38
Loading
Loading
Loading
Loading
+5 −5
Original line number Original line Diff line number Diff line
@@ -14,13 +14,13 @@ LDFLAGS_vmlinux := -static -N #-relax
CHECKFLAGS	+= -D__alpha__ -m64
CHECKFLAGS	+= -D__alpha__ -m64
cflags-y	:= -pipe -mno-fp-regs -ffixed-8 -msmall-data
cflags-y	:= -pipe -mno-fp-regs -ffixed-8 -msmall-data


cpuflags-$(CONFIG_ALPHA_EV67)		:= -mcpu=ev67
cpuflags-$(CONFIG_ALPHA_EV4)		:= -mcpu=ev4
cpuflags-$(CONFIG_ALPHA_EV6)		:= -mcpu=ev6
cpuflags-$(CONFIG_ALPHA_EV5)		:= -mcpu=ev5
cpuflags-$(CONFIG_ALPHA_EV56)		:= -mcpu=ev56
cpuflags-$(CONFIG_ALPHA_POLARIS)	:= -mcpu=pca56
cpuflags-$(CONFIG_ALPHA_POLARIS)	:= -mcpu=pca56
cpuflags-$(CONFIG_ALPHA_SX164)		:= -mcpu=pca56
cpuflags-$(CONFIG_ALPHA_SX164)		:= -mcpu=pca56
cpuflags-$(CONFIG_ALPHA_EV56)		:= -mcpu=ev56
cpuflags-$(CONFIG_ALPHA_EV6)		:= -mcpu=ev6
cpuflags-$(CONFIG_ALPHA_EV5)		:= -mcpu=ev5
cpuflags-$(CONFIG_ALPHA_EV67)		:= -mcpu=ev67
cpuflags-$(CONFIG_ALPHA_EV4)		:= -mcpu=ev4
# If GENERIC, make sure to turn off any instruction set extensions that
# If GENERIC, make sure to turn off any instruction set extensions that
# the host compiler might have on by default.  Given that EV4 and EV5
# the host compiler might have on by default.  Given that EV4 and EV5
# have the same instruction set, prefer EV5 because an EV5 schedule is
# have the same instruction set, prefer EV5 because an EV5 schedule is
+1 −1
Original line number Original line Diff line number Diff line
@@ -273,7 +273,7 @@ ev7_process_pal_subpacket(struct el_subpacket *header)
struct el_subpacket_handler ev7_pal_subpacket_handler =
struct el_subpacket_handler ev7_pal_subpacket_handler =
	SUBPACKET_HANDLER_INIT(EL_CLASS__PAL, ev7_process_pal_subpacket);
	SUBPACKET_HANDLER_INIT(EL_CLASS__PAL, ev7_process_pal_subpacket);


void
void __init
ev7_register_error_handlers(void)
ev7_register_error_handlers(void)
{
{
	int i;
	int i;
+1 −1
Original line number Original line Diff line number Diff line
@@ -1152,7 +1152,7 @@ marvel_machine_check(u64 vector, u64 la_ptr)
	mb();
	mb();
}
}


void
void __init
marvel_register_error_handlers(void)
marvel_register_error_handlers(void)
{
{
	ev7_register_error_handlers();
	ev7_register_error_handlers();
+1 −1
Original line number Original line Diff line number Diff line
@@ -564,7 +564,7 @@ static struct el_subpacket_handler titan_subpacket_handler =
	SUBPACKET_HANDLER_INIT(EL_CLASS__REGATTA_FAMILY, 
	SUBPACKET_HANDLER_INIT(EL_CLASS__REGATTA_FAMILY, 
			       el_process_regatta_subpacket);
			       el_process_regatta_subpacket);


void
void __init
titan_register_error_handlers(void)
titan_register_error_handlers(void)
{
{
	size_t i;
	size_t i;
+1 −1
Original line number Original line Diff line number Diff line
@@ -134,7 +134,7 @@
#define __initmv __initdata
#define __initmv __initdata
#define ALIAS_MV(x)
#define ALIAS_MV(x)
#else
#else
#define __initmv
#define __initmv __initdata_refok


/* GCC actually has a syntax for defining aliases, but is under some
/* GCC actually has a syntax for defining aliases, but is under some
   delusion that you shouldn't be able to declare it extern somewhere
   delusion that you shouldn't be able to declare it extern somewhere
Loading