Commit 88b4c146 authored by Jeremy Fitzhardinge's avatar Jeremy Fitzhardinge Committed by Ingo Molnar

x86: use early_memremap() in setup.c

The remappings in setup.c are all just ordinary memory, so use
early_memremap() rather than early_ioremap().
Signed-off-by: default avatarJeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
parent 14941779
...@@ -302,7 +302,7 @@ static void __init relocate_initrd(void) ...@@ -302,7 +302,7 @@ static void __init relocate_initrd(void)
if (clen > MAX_MAP_CHUNK-slop) if (clen > MAX_MAP_CHUNK-slop)
clen = MAX_MAP_CHUNK-slop; clen = MAX_MAP_CHUNK-slop;
mapaddr = ramdisk_image & PAGE_MASK; mapaddr = ramdisk_image & PAGE_MASK;
p = early_ioremap(mapaddr, clen+slop); p = early_memremap(mapaddr, clen+slop);
memcpy(q, p+slop, clen); memcpy(q, p+slop, clen);
early_iounmap(p, clen+slop); early_iounmap(p, clen+slop);
q += clen; q += clen;
...@@ -379,7 +379,7 @@ static void __init parse_setup_data(void) ...@@ -379,7 +379,7 @@ static void __init parse_setup_data(void)
return; return;
pa_data = boot_params.hdr.setup_data; pa_data = boot_params.hdr.setup_data;
while (pa_data) { while (pa_data) {
data = early_ioremap(pa_data, PAGE_SIZE); data = early_memremap(pa_data, PAGE_SIZE);
switch (data->type) { switch (data->type) {
case SETUP_E820_EXT: case SETUP_E820_EXT:
parse_e820_ext(data, pa_data); parse_e820_ext(data, pa_data);
...@@ -402,7 +402,7 @@ static void __init e820_reserve_setup_data(void) ...@@ -402,7 +402,7 @@ static void __init e820_reserve_setup_data(void)
return; return;
pa_data = boot_params.hdr.setup_data; pa_data = boot_params.hdr.setup_data;
while (pa_data) { while (pa_data) {
data = early_ioremap(pa_data, sizeof(*data)); data = early_memremap(pa_data, sizeof(*data));
e820_update_range(pa_data, sizeof(*data)+data->len, e820_update_range(pa_data, sizeof(*data)+data->len,
E820_RAM, E820_RESERVED_KERN); E820_RAM, E820_RESERVED_KERN);
found = 1; found = 1;
...@@ -428,7 +428,7 @@ static void __init reserve_early_setup_data(void) ...@@ -428,7 +428,7 @@ static void __init reserve_early_setup_data(void)
return; return;
pa_data = boot_params.hdr.setup_data; pa_data = boot_params.hdr.setup_data;
while (pa_data) { while (pa_data) {
data = early_ioremap(pa_data, sizeof(*data)); data = early_memremap(pa_data, sizeof(*data));
sprintf(buf, "setup data %x", data->type); sprintf(buf, "setup data %x", data->type);
reserve_early(pa_data, pa_data+sizeof(*data)+data->len, buf); reserve_early(pa_data, pa_data+sizeof(*data)+data->len, buf);
pa_data = data->next; pa_data = data->next;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment