Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions | Variables
bootpz.c File Reference
#include <linux/kernel.h>
#include <linux/slab.h>
#include <linux/string.h>
#include <generated/utsrelease.h>
#include <linux/mm.h>
#include <asm/console.h>
#include <asm/hwrpb.h>
#include <asm/pgtable.h>
#include <asm/io.h>
#include <stdarg.h>
#include "kzsize.h"

Go to the source code of this file.

Macros

#define MALLOC_AREA_SIZE   0x200000 /* 2MB for now */
 
#define VPTB   ((unsigned long *) 0x200000000)
 
#define L1   ((unsigned long *) 0x200802000)
 
#define KERNEL_ORIGIN   ((((unsigned long)&_end) + 511) & ~511)
 
#define NEXT_PAGE(a)   (((a) | (PAGE_SIZE - 1)) + 1)
 
#define REAL_INITRD_SIZE   0
 
#define V_BOOT_IMAGE_START   BOOT_ADDR
 
#define V_BOOT_IMAGE_END   SP_on_entry
 
#define V_BOOTSTRAPPER_START   BOOT_ADDR
 
#define V_BOOTSTRAPPER_END   KERNEL_ORIGIN
 
#define V_DATA_START   KERNEL_ORIGIN
 
#define V_INITRD_START   (KERNEL_ORIGIN + KERNEL_Z_SIZE)
 
#define V_INTRD_END   (V_INITRD_START + REAL_INITRD_SIZE)
 
#define V_DATA_END   V_BOOT_IMAGE_END
 
#define K_KERNEL_DATA_START   ZERO_PGE
 
#define K_KERNEL_IMAGE_START   START_ADDR
 
#define K_KERNEL_IMAGE_END   (START_ADDR + KERNEL_SIZE)
 
#define K_COPY_IMAGE_START   NEXT_PAGE(K_KERNEL_IMAGE_END)
 
#define K_INITRD_START   NEXT_PAGE(K_COPY_IMAGE_START + KERNEL_SIZE + PAGE_SIZE)
 
#define K_COPY_IMAGE_END   (K_INITRD_START + REAL_INITRD_SIZE + MALLOC_AREA_SIZE)
 
#define K_COPY_IMAGE_SIZE   NEXT_PAGE(K_COPY_IMAGE_END - K_COPY_IMAGE_START)
 

Functions

unsigned long switch_to_osf_pal (unsigned long nr, struct pcb_struct *pcb_va, struct pcb_struct *pcb_pa, unsigned long *vptb)
 
int decompress_kernel (void *destination, void *source, size_t ksize, size_t kzsize)
 
void move_stack (unsigned long new_stack)
 
int check_range (unsigned long vstart, unsigned long vend, unsigned long kstart, unsigned long kend)
 
void pal_init (void)
 
void start_kernel (void)
 
void__kmalloc (size_t size, gfp_t flags)
 

Variables

struct hwrpb_structhwrpb = INIT_HWRPB
 
unsigned long SP_on_entry
 
char _end
 

Macro Definition Documentation

#define K_COPY_IMAGE_END   (K_INITRD_START + REAL_INITRD_SIZE + MALLOC_AREA_SIZE)

Definition at line 256 of file bootpz.c.

#define K_COPY_IMAGE_SIZE   NEXT_PAGE(K_COPY_IMAGE_END - K_COPY_IMAGE_START)

Definition at line 258 of file bootpz.c.

#define K_COPY_IMAGE_START   NEXT_PAGE(K_KERNEL_IMAGE_END)

Definition at line 252 of file bootpz.c.

#define K_INITRD_START   NEXT_PAGE(K_COPY_IMAGE_START + KERNEL_SIZE + PAGE_SIZE)

Definition at line 254 of file bootpz.c.

#define K_KERNEL_DATA_START   ZERO_PGE

Definition at line 240 of file bootpz.c.

#define K_KERNEL_IMAGE_END   (START_ADDR + KERNEL_SIZE)

Definition at line 242 of file bootpz.c.

#define K_KERNEL_IMAGE_START   START_ADDR

Definition at line 241 of file bootpz.c.

#define KERNEL_ORIGIN   ((((unsigned long)&_end) + 511) & ~511)

Definition at line 179 of file bootpz.c.

#define L1   ((unsigned long *) 0x200802000)

Definition at line 113 of file bootpz.c.

#define MALLOC_AREA_SIZE   0x200000 /* 2MB for now */

Definition at line 28 of file bootpz.c.

#define NEXT_PAGE (   a)    (((a) | (PAGE_SIZE - 1)) + 1)

Definition at line 183 of file bootpz.c.

#define REAL_INITRD_SIZE   0

Definition at line 188 of file bootpz.c.

#define V_BOOT_IMAGE_END   SP_on_entry

Definition at line 219 of file bootpz.c.

#define V_BOOT_IMAGE_START   BOOT_ADDR

Definition at line 218 of file bootpz.c.

#define V_BOOTSTRAPPER_END   KERNEL_ORIGIN

Definition at line 223 of file bootpz.c.

#define V_BOOTSTRAPPER_START   BOOT_ADDR

Definition at line 222 of file bootpz.c.

#define V_DATA_END   V_BOOT_IMAGE_END

Definition at line 232 of file bootpz.c.

#define V_DATA_START   KERNEL_ORIGIN

Definition at line 229 of file bootpz.c.

#define V_INITRD_START   (KERNEL_ORIGIN + KERNEL_Z_SIZE)

Definition at line 230 of file bootpz.c.

#define V_INTRD_END   (V_INITRD_START + REAL_INITRD_SIZE)

Definition at line 231 of file bootpz.c.

#define VPTB   ((unsigned long *) 0x200000000)

Definition at line 61 of file bootpz.c.

Function Documentation

void* __kmalloc ( size_t  size,
gfp_t  flags 
)

Definition at line 472 of file bootpz.c.

int check_range ( unsigned long  vstart,
unsigned long  vend,
unsigned long  kstart,
unsigned long  kend 
)

Definition at line 76 of file bootpz.c.

int decompress_kernel ( void destination,
void source,
size_t  ksize,
size_t  kzsize 
)

Definition at line 151 of file misc.c.

void move_stack ( unsigned long  new_stack)
void pal_init ( void  )

Definition at line 116 of file bootpz.c.

void start_kernel ( void  )

Definition at line 262 of file bootpz.c.

unsigned long switch_to_osf_pal ( unsigned long  nr,
struct pcb_struct pcb_va,
struct pcb_struct pcb_pa,
unsigned long vptb 
)

Variable Documentation

char _end

Definition at line 53 of file bootpz.c.

unsigned long SP_on_entry

Definition at line 173 of file bootpz.c.