mirror of
https://gitlab.com/qemu-project/openbios.git
synced 2024-02-13 08:34:06 +08:00
-20
git-svn-id: svn://coreboot.org/openbios/openbios-devel@40 f158a5a8-5612-0410-a976-696ce0be7e32
This commit is contained in:
@@ -263,7 +263,7 @@ ob_sd_open(__attribute__((unused))sd_private_t **sd)
|
|||||||
|
|
||||||
fword("my-unit");
|
fword("my-unit");
|
||||||
id = POP();
|
id = POP();
|
||||||
POP(); // unit id is 2 ints but we only need one.
|
//POP(); // unit id is 2 ints but we only need one.
|
||||||
*sd = &global_esp->sd[id];
|
*sd = &global_esp->sd[id];
|
||||||
|
|
||||||
#ifdef CONFIG_DEBUG_ESP
|
#ifdef CONFIG_DEBUG_ESP
|
||||||
|
|||||||
@@ -195,15 +195,10 @@ map_io(unsigned pa, int size)
|
|||||||
return (void *)((unsigned int)va + off);
|
return (void *)((unsigned int)va + off);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* Switch page tables.
|
|
||||||
*/
|
|
||||||
void
|
void
|
||||||
init_mmu_swift(unsigned long base)
|
ob_init_mmu(unsigned long base)
|
||||||
{
|
{
|
||||||
extern unsigned int qemu_mem_size;
|
extern unsigned int qemu_mem_size;
|
||||||
unsigned int addr, i;
|
|
||||||
unsigned long pa, va;
|
|
||||||
|
|
||||||
push_str("/memory");
|
push_str("/memory");
|
||||||
fword("find-device");
|
fword("find-device");
|
||||||
@@ -264,6 +259,16 @@ init_mmu_swift(unsigned long base)
|
|||||||
fword("encode+");
|
fword("encode+");
|
||||||
push_str("available");
|
push_str("available");
|
||||||
fword("property");
|
fword("property");
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Switch page tables.
|
||||||
|
*/
|
||||||
|
void
|
||||||
|
init_mmu_swift(unsigned long base)
|
||||||
|
{
|
||||||
|
unsigned int addr, i;
|
||||||
|
unsigned long pa, va;
|
||||||
|
|
||||||
mem_init(&cio, (char *)&_end, (char *)&_iomem);
|
mem_init(&cio, (char *)&_end, (char *)&_iomem);
|
||||||
|
|
||||||
|
|||||||
@@ -38,6 +38,7 @@ void *mem_alloc(struct mem *t, int size, int align);
|
|||||||
void *mem_zalloc(struct mem *t, int size, int align);
|
void *mem_zalloc(struct mem *t, int size, int align);
|
||||||
int map_page(unsigned long va, unsigned long epa, int type);
|
int map_page(unsigned long va, unsigned long epa, int type);
|
||||||
void *map_io(unsigned pa, int size);
|
void *map_io(unsigned pa, int size);
|
||||||
|
void ob_init_mmu(unsigned long base);
|
||||||
void init_mmu_swift(unsigned long base);
|
void init_mmu_swift(unsigned long base);
|
||||||
void *dvma_alloc(int size, unsigned int *pphys);
|
void *dvma_alloc(int size, unsigned int *pphys);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user