Changeset 45d6add in mainline


Ignore:
Timestamp:
2006-03-13T19:58:52Z (19 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
25d7709
Parents:
6d9c49a
Message:

run ppc32 kernel above 2 GB

Location:
arch
Files:
1 added
4 edited

Legend:

Unmodified
Added
Removed
  • arch/ia32/include/mm/page.h

    r6d9c49a r45d6add  
    3434
    3535#ifndef __ASM__
    36 # define KA2PA(x)       (((__address) (x)) - 0x80000000)
    37 # define PA2KA(x)       (((__address) (x)) + 0x80000000)
     36#       define KA2PA(x) (((__address) (x)) - 0x80000000)
     37#       define PA2KA(x) (((__address) (x)) + 0x80000000)
    3838#else
    39 # define KA2PA(x)       ((x) - 0x80000000)
    40 # define PA2KA(x)       ((x) + 0x80000000)
     39#       define KA2PA(x) ((x) - 0x80000000)
     40#       define PA2KA(x) ((x) + 0x80000000)
    4141#endif
    4242
  • arch/ppc32/_link.ld.in

    r6d9c49a r45d6add  
    88
    99#define __ASM__
     10#include <arch/boot/boot.h>
     11#include <arch/mm/page.h>
    1012
    1113ENTRY(kernel_image_start)
    1214
    1315SECTIONS {
    14         .image 0x400000: AT (0x400000) {
     16        .image PA2KA(BOOT_OFFSET): AT (0) {
    1517                ktext_start = .;
    1618                *(K_TEXT_START)
     
    3133                LONG(kdata_end - kdata_start);
    3234                hardcoded_load_address = .;
    33                 LONG(0x400000);
     35                LONG(PA2KA(BOOT_OFFSET));
    3436                *(.bss);                /* uninitialized static variables */   
    3537                *(COMMON);              /* global variables */
  • arch/ppc32/include/mm/as.h

    r6d9c49a r45d6add  
    3232#include <arch/types.h>
    3333
    34 #define KERNEL_ADDRESS_SPACE_START_ARCH         (__address) 0x00000000
    35 #define KERNEL_ADDRESS_SPACE_END_ARCH           (__address) 0xffffffff 
    36 #define USER_ADDRESS_SPACE_START_ARCH           (__address) 0x00000000
    37 #define USER_ADDRESS_SPACE_END_ARCH             (__address) 0x7fffffff
     34#define KERNEL_ADDRESS_SPACE_START_ARCH         ((__address) 0x80000000)
     35#define KERNEL_ADDRESS_SPACE_END_ARCH           ((__address) 0xffffffff)
     36#define USER_ADDRESS_SPACE_START_ARCH           ((__address) 0x00000000)
     37#define USER_ADDRESS_SPACE_END_ARCH             ((__address) 0x7fffffff)
    3838
    3939#define USTACK_ADDRESS_ARCH     (0x7fffffff-(PAGE_SIZE-1))
  • arch/ppc32/include/mm/page.h

    r6d9c49a r45d6add  
    3030#define __ppc32_PAGE_H__
    3131
    32 #include <mm/page.h>
    33 #include <arch/mm/frame.h>
    34 #include <arch/types.h>
    35 
    3632#define PAGE_WIDTH      FRAME_WIDTH
    3733#define PAGE_SIZE       FRAME_SIZE
    3834
    39 #define KA2PA(x)        ((__address)(x))
    40 #define PA2KA(x)        ((__address)(x))
     35#ifndef __ASM__
     36#       define KA2PA(x) (((__address) (x)) - 0x80000000)
     37#       define PA2KA(x) (((__address) (x)) + 0x80000000)
     38#else
     39#       define KA2PA(x) ((x) - 0x80000000)
     40#       define PA2KA(x) ((x) + 0x80000000)
     41#endif
    4142
    4243#define PTL0_ENTRIES_ARCH               0
     
    7475#define PTE_VALID_ARCH(p)               1
    7576
     77#ifndef __ASM__
     78
     79#include <mm/page.h>
     80#include <arch/mm/frame.h>
     81#include <arch/types.h>
     82
    7683extern void page_arch_init(void);
    7784
     85#endif /* __ASM__ */
     86
    7887#endif
Note: See TracChangeset for help on using the changeset viewer.