Re: [PATCH} H8/300 update (2/9) ldscripts fix
From: Andrew Morton
Date: Tue May 11 2004 - 19:56:57 EST
Yoshinori Sato <ysato@xxxxxxxxxxxxxxxxxxxx> wrote:
>
> +#if defined(CONFIG_H8300) || defined(CONFIG_V850)
> +#define SYMBOL(_sym_) _##_sym_
> +#else
> +#define SYMBOL(_sym_) _sym_
> +#endif
> +
Adding arch-specific stuff to an include/asm-generic/ header file is
not nice.
However, having to create an arch-specific version of the header
just becasue you need this wrapper is also not nice.
And "SYMBOL" is a too generic identifier: it may clash with other things.
Could I suggest that you change asm-generic/vmlinux.lds.h to do:
#ifndef VMLINUX_SYMBOL
#define VMLINUX_SYMBOL(_sym_) _sym_
#endif
...
- __start___ksymtab = .; \
+ VMLINUX_SYMBOL(__start___ksymtab) = .; \
Then, in some h8300-specific file, do:
#define VMLINUX_SYMBOL(_sym_) _##_sym_
#include <asm-generic/vmlinux.lds.h>
and include that file instead of asm-generic/vmlinux.lds.h?
(I am unable to find where h8300 actually includes vmlinux.lds.h.
Confused).
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/