mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-26 10:49:33 +00:00
[PATCH] s390: setup.c cleanup + build fix
Cleanup & fix 31 bit compilation: CC arch/s390/kernel/setup.o arch/s390/kernel/setup.c:83: error: initializer element is not computable at load time arch/s390/kernel/setup.c:83: error: (near initialization for 'code_resource.start') Not sure which patch in the -mm tree breaks this, but since this can be considered a cleanup it can be merged anyway. Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
bb12b76e2d
commit
cc13ad6217
1 changed files with 6 additions and 9 deletions
|
@ -47,6 +47,7 @@
|
||||||
#include <asm/irq.h>
|
#include <asm/irq.h>
|
||||||
#include <asm/page.h>
|
#include <asm/page.h>
|
||||||
#include <asm/ptrace.h>
|
#include <asm/ptrace.h>
|
||||||
|
#include <asm/sections.h>
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Machine setup..
|
* Machine setup..
|
||||||
|
@ -65,11 +66,6 @@ volatile int __cpu_logical_map[NR_CPUS]; /* logical cpu to cpu address */
|
||||||
unsigned long __initdata zholes_size[MAX_NR_ZONES];
|
unsigned long __initdata zholes_size[MAX_NR_ZONES];
|
||||||
static unsigned long __initdata memory_end;
|
static unsigned long __initdata memory_end;
|
||||||
|
|
||||||
/*
|
|
||||||
* Setup options
|
|
||||||
*/
|
|
||||||
extern int _text,_etext, _edata, _end;
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* This is set up by the setup-routine at boot-time
|
* This is set up by the setup-routine at boot-time
|
||||||
* for S390 need to find out, what we have to setup
|
* for S390 need to find out, what we have to setup
|
||||||
|
@ -80,15 +76,11 @@ extern int _text,_etext, _edata, _end;
|
||||||
|
|
||||||
static struct resource code_resource = {
|
static struct resource code_resource = {
|
||||||
.name = "Kernel code",
|
.name = "Kernel code",
|
||||||
.start = (unsigned long) &_text,
|
|
||||||
.end = (unsigned long) &_etext - 1,
|
|
||||||
.flags = IORESOURCE_BUSY | IORESOURCE_MEM,
|
.flags = IORESOURCE_BUSY | IORESOURCE_MEM,
|
||||||
};
|
};
|
||||||
|
|
||||||
static struct resource data_resource = {
|
static struct resource data_resource = {
|
||||||
.name = "Kernel data",
|
.name = "Kernel data",
|
||||||
.start = (unsigned long) &_etext,
|
|
||||||
.end = (unsigned long) &_edata - 1,
|
|
||||||
.flags = IORESOURCE_BUSY | IORESOURCE_MEM,
|
.flags = IORESOURCE_BUSY | IORESOURCE_MEM,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -422,6 +414,11 @@ setup_resources(void)
|
||||||
struct resource *res;
|
struct resource *res;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
|
code_resource.start = (unsigned long) &_text;
|
||||||
|
code_resource.end = (unsigned long) &_etext - 1;
|
||||||
|
data_resource.start = (unsigned long) &_etext;
|
||||||
|
data_resource.end = (unsigned long) &_edata - 1;
|
||||||
|
|
||||||
for (i = 0; i < MEMORY_CHUNKS && memory_chunk[i].size > 0; i++) {
|
for (i = 0; i < MEMORY_CHUNKS && memory_chunk[i].size > 0; i++) {
|
||||||
res = alloc_bootmem_low(sizeof(struct resource));
|
res = alloc_bootmem_low(sizeof(struct resource));
|
||||||
res->flags = IORESOURCE_BUSY | IORESOURCE_MEM;
|
res->flags = IORESOURCE_BUSY | IORESOURCE_MEM;
|
||||||
|
|
Loading…
Reference in a new issue