diff options
author | Stefan Reinauer <stepan@coresystems.de> | 2009-06-30 15:17:49 +0000 |
---|---|---|
committer | Stefan Reinauer <stepan@openbios.org> | 2009-06-30 15:17:49 +0000 |
commit | 0867062412dd4bfe5a556e5f3fd85ba5b682d79b (patch) | |
tree | 81ca5db12b8567b48daaa23a541bfb8a5dc011f8 /src/arch/ppc/include | |
parent | 9702b6bf7ec5a4fb16934f1cf2724480e2460c89 (diff) |
This patch unifies the use of config options in v2 to all start with CONFIG_
It's basically done with the following script and some manual fixup:
VARS=`grep ^define src/config/Options.lb | cut -f2 -d\ | grep -v ^CONFIG | grep -v ^COREBOOT |grep -v ^CC`
for VAR in $VARS; do
find . -name .svn -prune -o -type f -exec perl -pi -e "s/(^|[^0-9a-zA-Z_]+)$VAR($|[^0-9a-zA-Z_]+)/\1CONFIG_$VAR\2/g" {} \;
done
Signed-off-by: Stefan Reinauer <stepan@coresystems.de>
Acked-by: Ronald G. Minnich <rminnich@gmail.com>
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@4381 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src/arch/ppc/include')
-rw-r--r-- | src/arch/ppc/include/arch/cpu.h | 16 | ||||
-rw-r--r-- | src/arch/ppc/include/arch/io.h | 24 | ||||
-rw-r--r-- | src/arch/ppc/include/arch/pirq_routing.h | 8 |
3 files changed, 24 insertions, 24 deletions
diff --git a/src/arch/ppc/include/arch/cpu.h b/src/arch/ppc/include/arch/cpu.h index e0ed4ff66a..3026486420 100644 --- a/src/arch/ppc/include/arch/cpu.h +++ b/src/arch/ppc/include/arch/cpu.h @@ -13,24 +13,24 @@ struct cpu_driver { struct cpu_device_id *id_table; }; -#ifndef STACK_SIZE -#error STACK_SIZE not defined +#ifndef CONFIG_STACK_SIZE +#error CONFIG_STACK_SIZE not defined #endif /* The basic logic comes from the Linux kernel. - * The invariant is that (1 << 31 - STACK_BITS) == STACK_SIZE + * The invariant is that (1 << 31 - STACK_BITS) == CONFIG_STACK_SIZE * I wish there was simpler way to support multiple stack sizes. * Oh well. */ -#if STACK_SIZE == 4096 +#if CONFIG_STACK_SIZE == 4096 #define STACK_BITS "19" -#elif STACK_SIZE == 8192 +#elif CONFIG_STACK_SIZE == 8192 #define STACK_BITS "18" -#elif STACK_SIZE == 16384 +#elif CONFIG_STACK_SIZE == 16384 #define STACK_BITS "17" -#elif STACK_SIZE == 32768 +#elif CONFIG_STACK_SIZE == 32768 #define STACK_BITS "16" -#elif STACK_SIZE == 65536 +#elif CONFIG_STACK_SIZE == 65536 #define STACK_BITS "15" #else #error Unimplemented stack size diff --git a/src/arch/ppc/include/arch/io.h b/src/arch/ppc/include/arch/io.h index fd0d1e4654..ba8ce4fa85 100644 --- a/src/arch/ppc/include/arch/io.h +++ b/src/arch/ppc/include/arch/io.h @@ -11,8 +11,8 @@ #define SLOW_DOWN_IO -#ifndef _IO_BASE -#define _IO_BASE 0 +#ifndef CONFIG_IO_BASE +#define CONFIG_IO_BASE 0 #endif #define readb(addr) in_8((volatile uint8_t *)(addr)) @@ -36,15 +36,15 @@ * are arrays of bytes, and byte-swapping is not appropriate in * that case. - paulus */ -#define insw(port, buf, ns) _insw_ns((uint16_t *)((port)+_IO_BASE), (buf), (ns)) -#define outsw(port, buf, ns) _outsw_ns((uint16_t *)((port)+_IO_BASE), (buf), (ns)) +#define insw(port, buf, ns) _insw_ns((uint16_t *)((port)+CONFIG_IO_BASE), (buf), (ns)) +#define outsw(port, buf, ns) _outsw_ns((uint16_t *)((port)+CONFIG_IO_BASE), (buf), (ns)) -#define inb(port) in_8((uint8_t *)((port)+_IO_BASE)) -#define outb(val, port) out_8((uint8_t *)((port)+_IO_BASE), (val)) -#define inw(port) in_le16((uint16_t *)((port)+_IO_BASE)) -#define outw(val, port) out_le16((uint16_t *)((port)+_IO_BASE), (val)) -#define inl(port) in_le32((uint32_t *)((port)+_IO_BASE)) -#define outl(val, port) out_le32((uint32_t *)((port)+_IO_BASE), (val)) +#define inb(port) in_8((uint8_t *)((port)+CONFIG_IO_BASE)) +#define outb(val, port) out_8((uint8_t *)((port)+CONFIG_IO_BASE), (val)) +#define inw(port) in_le16((uint16_t *)((port)+CONFIG_IO_BASE)) +#define outw(val, port) out_le16((uint16_t *)((port)+CONFIG_IO_BASE), (val)) +#define inl(port) in_le32((uint32_t *)((port)+CONFIG_IO_BASE)) +#define outl(val, port) out_le32((uint32_t *)((port)+CONFIG_IO_BASE), (val)) #define inb_p(port) inb((port)) #define outb_p(val, port) outb((val), (port)) @@ -56,8 +56,8 @@ /* * The *_ns versions below do byte-swapping. */ -#define insw_ns(port, buf, ns) _insw((uint16_t *)((port)+_IO_BASE), (buf), (ns)) -#define outsw_ns(port, buf, ns) _outsw((uint16_t *)((port)+_IO_BASE), (buf), (ns)) +#define insw_ns(port, buf, ns) _insw((uint16_t *)((port)+CONFIG_IO_BASE), (buf), (ns)) +#define outsw_ns(port, buf, ns) _outsw((uint16_t *)((port)+CONFIG_IO_BASE), (buf), (ns)) #define IO_SPACE_LIMIT ~0 diff --git a/src/arch/ppc/include/arch/pirq_routing.h b/src/arch/ppc/include/arch/pirq_routing.h index dad8531eb5..00c9556319 100644 --- a/src/arch/ppc/include/arch/pirq_routing.h +++ b/src/arch/ppc/include/arch/pirq_routing.h @@ -16,8 +16,8 @@ struct irq_info { u8 rfu; } __attribute__((packed)); -#if defined(IRQ_SLOT_COUNT) -#define IRQ_SLOTS_COUNT IRQ_SLOT_COUNT +#if defined(CONFIG_IRQ_SLOT_COUNT) +#define IRQ_SLOTS_COUNT CONFIG_IRQ_SLOT_COUNT #elif (__GNUC__ < 3) #define IRQ_SLOTS_COUNT 1 #else @@ -39,13 +39,13 @@ struct irq_routing_table { extern const struct irq_routing_table intel_irq_routing_table; -#if defined(DEBUG) && defined(HAVE_PIRQ_TABLE) +#if defined(CONFIG_DEBUG) && defined(CONFIG_HAVE_PIRQ_TABLE) void check_pirq_routing_table(void); #else #define check_pirq_routing_table() do {} while(0) #endif -#if defined(HAVE_PIRQ_TABLE) +#if defined(CONFIG_HAVE_PIRQ_TABLE) unsigned long copy_pirq_routing_table(unsigned long start); #else #define copy_pirq_routing_table(start) (start) |