Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 18351
b: refs/heads/master
c: 7ae69d2
h: refs/heads/master
i:
  18349: 210c8a8
  18347: e37da9a
  18343: afc1f61
  18335: 2943799
v: v3
  • Loading branch information
Tony Luck committed Jan 13, 2006
1 parent 7d2a03e commit 70cfaa2
Show file tree
Hide file tree
Showing 348 changed files with 5,601 additions and 27,633 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: e7de369050534025b33aab1033358bf47a577e4d
refs/heads/master: 7ae69d2aa4ed3ee8cef18a072346366f019d6a4a
13 changes: 0 additions & 13 deletions trunk/MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -2519,19 +2519,6 @@ P: Romain Lievin
M: roms@lpg.ticalc.org
S: Maintained

TIPC NETWORK LAYER
P: Per Liden
M: per.liden@nospam.ericsson.com
P: Jon Maloy
M: jon.maloy@nospam.ericsson.com
P: Allan Stephens
M: allan.stephens@nospam.windriver.com
L: tipc-discussion@lists.sourceforge.net
W: http://tipc.sourceforge.net/
W: http://tipc.cslab.ericsson.net/
T: git tipc.cslab.ericsson.net:/pub/git/tipc.git
S: Maintained

TLAN NETWORK DRIVER
P: Samuel Chessman
M: chessman@tux.org
Expand Down
1 change: 1 addition & 0 deletions trunk/arch/ia64/kernel/fsys.S
Original file line number Diff line number Diff line change
Expand Up @@ -903,5 +903,6 @@ fsyscall_table:
data8 0
data8 0
data8 0
data8 0 // 1280

.org fsyscall_table + 8*NR_syscalls // guard against failures to increase NR_syscalls
7 changes: 5 additions & 2 deletions trunk/arch/powerpc/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -139,14 +139,17 @@ drivers-$(CONFIG_CPM2) += arch/ppc/8260_io/

drivers-$(CONFIG_OPROFILE) += arch/powerpc/oprofile/

# Default to zImage, override when needed
defaultimage-y := zImage
defaultimage-$(CONFIG_PPC32) := zImage
defaultimage-$(CONFIG_PPC_ISERIES) := vmlinux
defaultimage-$(CONFIG_PPC_PSERIES) := zImage
KBUILD_IMAGE := $(defaultimage-y)
all: $(KBUILD_IMAGE)

CPPFLAGS_vmlinux.lds := -Upowerpc

# All the instructions talk about "make bzImage".
bzImage: zImage

BOOT_TARGETS = zImage zImage.initrd znetboot znetboot.initrd vmlinux.sm uImage

.PHONY: $(BOOT_TARGETS)
Expand Down
49 changes: 15 additions & 34 deletions trunk/arch/powerpc/boot/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ HOSTCC := gcc
BOOTCFLAGS := $(HOSTCFLAGS) -fno-builtin -nostdinc -isystem \
$(shell $(CROSS32CC) -print-file-name=include) -fPIC
BOOTAFLAGS := -D__ASSEMBLY__ $(BOOTCFLAGS) -traditional -nostdinc
BOOTLFLAGS := -T $(srctree)/$(src)/zImage.lds
OBJCOPYFLAGS := contents,alloc,load,readonly,data
OBJCOPY_COFF_ARGS := -O aixcoff-rs6000 --set-start 0x500000

zlib := infblock.c infcodes.c inffast.c inflate.c inftrees.c infutil.c
zlibheader := infblock.h infcodes.h inffast.h inftrees.h infutil.h
Expand All @@ -35,7 +35,7 @@ zliblinuxheader := zlib.h zconf.h zutil.h
$(addprefix $(obj)/,$(zlib) main.o): $(addprefix $(obj)/,$(zliblinuxheader)) $(addprefix $(obj)/,$(zlibheader))
#$(addprefix $(obj)/,main.o): $(addprefix $(obj)/,zlib.h)

src-boot := crt0.S string.S prom.c stdio.c main.c div64.S
src-boot := string.S prom.c main.c div64.S crt0.S
src-boot += $(zlib)
src-boot := $(addprefix $(obj)/, $(src-boot))
obj-boot := $(addsuffix .o, $(basename $(src-boot)))
Expand Down Expand Up @@ -70,7 +70,7 @@ quiet_cmd_bootas = BOOTAS $@
cmd_bootas = $(CROSS32CC) -Wp,-MD,$(depfile) $(BOOTAFLAGS) -c -o $@ $<

quiet_cmd_bootld = BOOTLD $@
cmd_bootld = $(CROSS32LD) -T $(srctree)/$(src)/$(3) -o $@ $(2)
cmd_bootld = $(CROSS32LD) $(BOOTLFLAGS) -o $@ $(2)

$(patsubst %.c,%.o, $(filter %.c, $(src-boot))): %.o: %.c
$(call if_changed_dep,bootcc)
Expand All @@ -87,14 +87,12 @@ obj-sec = $(foreach section, $(1), $(patsubst %,$(obj)/kernel-%.o, $(section)))
src-sec = $(foreach section, $(1), $(patsubst %,$(obj)/kernel-%.c, $(section)))
gz-sec = $(foreach section, $(1), $(patsubst %,$(obj)/kernel-%.gz, $(section)))

hostprogs-y := addnote addRamDisk hack-coff

targets += zImage.vmode zImage.initrd.vmode zImage zImage.initrd \
zImage.coff zImage.initrd.coff \
$(patsubst $(obj)/%,%, $(call obj-sec, $(required) $(initrd))) \
$(patsubst $(obj)/%,%, $(call src-sec, $(required) $(initrd))) \
$(patsubst $(obj)/%,%, $(call gz-sec, $(required) $(initrd))) \
vmlinux.initrd
hostprogs-y := addnote addRamDisk
targets += zImage.vmode zImage.initrd.vmode zImage zImage.initrd \
$(patsubst $(obj)/%,%, $(call obj-sec, $(required) $(initrd))) \
$(patsubst $(obj)/%,%, $(call src-sec, $(required) $(initrd))) \
$(patsubst $(obj)/%,%, $(call gz-sec, $(required) $(initrd))) \
vmlinux.initrd
extra-y := initrd.o

quiet_cmd_ramdisk = RAMDISK $@
Expand All @@ -116,10 +114,6 @@ quiet_cmd_addsection = ADDSEC $@
quiet_cmd_addnote = ADDNOTE $@
cmd_addnote = $(obj)/addnote $@

quiet_cmd_gencoff = COFF $@
cmd_gencoff = $(OBJCOPY) $(OBJCOPY_COFF_ARGS) $@ && \
$(obj)/hack-coff $@

$(call gz-sec, $(required)): $(obj)/kernel-%.gz: %
$(call if_changed,gzip)

Expand All @@ -133,35 +127,22 @@ $(call obj-sec, $(required) $(initrd)): $(obj)/kernel-%.o: $(obj)/kernel-%.c
$(call if_changed_dep,bootcc)
$(call cmd,addsection)

$(obj)/zImage.vmode $(obj)/zImage.coff: obj-boot += $(call obj-sec, $(required))
$(obj)/zImage.vmode: obj-boot += $(call obj-sec, $(required))
$(obj)/zImage.vmode: $(call obj-sec, $(required)) $(obj-boot) $(srctree)/$(src)/zImage.lds
$(call cmd,bootld,$(obj-boot),zImage.lds)
$(call cmd,bootld,$(obj-boot))

$(obj)/zImage.initrd.vmode $(obj)/zImage.initrd.coff: obj-boot += $(call obj-sec, $(required) $(initrd))
$(obj)/zImage.initrd.vmode: obj-boot += $(call obj-sec, $(required) $(initrd))
$(obj)/zImage.initrd.vmode: $(call obj-sec, $(required) $(initrd)) $(obj-boot) $(srctree)/$(src)/zImage.lds
$(call cmd,bootld,$(obj-boot),zImage.lds)

# For 32-bit powermacs, build the COFF images as well as the ELF images.
coffimage-$(CONFIG_PPC_PMAC)-$(CONFIG_PPC32) := $(obj)/zImage.coff
coffrdimg-$(CONFIG_PPC_PMAC)-$(CONFIG_PPC32) := $(obj)/zImage.initrd.coff
$(call cmd,bootld,$(obj-boot))

$(obj)/zImage: $(obj)/zImage.vmode $(obj)/addnote $(coffimage-y-y)
$(obj)/zImage: $(obj)/zImage.vmode $(obj)/addnote
@cp -f $< $@
$(call if_changed,addnote)

$(obj)/zImage.initrd: $(obj)/zImage.initrd.vmode $(obj)/addnote $(coffrdimg-y-y)
$(obj)/zImage.initrd: $(obj)/zImage.initrd.vmode $(obj)/addnote
@cp -f $< $@
$(call if_changed,addnote)

$(obj)/zImage.coff: $(call obj-sec, $(required)) $(obj-boot) $(srctree)/$(src)/zImage.coff.lds $(obj)/hack-coff
$(call cmd,bootld,$(obj-boot),zImage.coff.lds)
$(call cmd,gencoff)

$(obj)/zImage.initrd.coff: $(call obj-sec, $(required) $(initrd)) $(obj-boot) \
$(srctree)/$(src)/zImage.coff.lds $(obj)/hack-coff
$(call cmd,bootld,$(obj-boot),zImage.coff.lds)
$(call cmd,gencoff)

#-----------------------------------------------------------
# build u-boot images
#-----------------------------------------------------------
Expand Down
21 changes: 8 additions & 13 deletions trunk/arch/powerpc/boot/crt0.S
Original file line number Diff line number Diff line change
Expand Up @@ -12,23 +12,17 @@
#include "ppc_asm.h"

.text
/* a procedure descriptor used when booting this as a COFF file */
_zimage_start_opd:
.long _zimage_start, 0, 0, 0

.globl _zimage_start
_zimage_start:
/* Work out the offset between the address we were linked at
and the address where we're running. */
bl 1f
1: mflr r0

1:
mflr r0
lis r9,1b@ha
addi r9,r9,1b@l
subf. r0,r9,r0
beq 3f /* if running at same address as linked */
beq 3f

/* The .got2 section contains a list of addresses, so add
the address offset onto each entry. */
lis r9,__got2_start@ha
addi r9,r9,__got2_start@l
lis r8,__got2_end@ha
Expand All @@ -38,14 +32,15 @@ _zimage_start:
srwi. r8,r8,2
mtctr r8
add r9,r0,r9
2: lwz r8,0(r9)
2:
lwz r8,0(r9)
add r8,r8,r0
stw r8,0(r9)
addi r9,r9,4
bdnz 2b

/* Do a cache flush for our text, in case OF didn't */
3: lis r9,_start@h
3:
lis r9,_start@h
add r9,r0,r9
lis r8,_etext@ha
addi r8,r8,_etext@l
Expand Down
84 changes: 0 additions & 84 deletions trunk/arch/powerpc/boot/hack-coff.c

This file was deleted.

46 changes: 24 additions & 22 deletions trunk/arch/powerpc/boot/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ extern void flush_cache(void *, unsigned long);


/* Value picked to match that used by yaboot */
#define PROG_START 0x01400000 /* only used on 64-bit systems */
#define RAM_END (512<<20) /* Fixme: use OF */
#define PROG_START 0x01400000
#define RAM_END (512<<20) // Fixme: use OF */
#define ONE_MB 0x100000

extern char _start[];
Expand Down Expand Up @@ -160,17 +160,6 @@ static int is_elf64(void *hdr)
elfoffset = (unsigned long)elf64ph->p_offset;
vmlinux.size = (unsigned long)elf64ph->p_filesz + elfoffset;
vmlinux.memsize = (unsigned long)elf64ph->p_memsz + elfoffset;

#if defined(PROG_START)
/*
* Maintain a "magic" minimum address. This keeps some older
* firmware platforms running.
*/

if (claim_base < PROG_START)
claim_base = PROG_START;
#endif

return 1;
}

Expand Down Expand Up @@ -217,18 +206,12 @@ void start(unsigned long a1, unsigned long a2, void *promptr, void *sp)
exit();
if (getprop(chosen_handle, "stdout", &stdout, sizeof(stdout)) != 4)
exit();
stderr = stdout;
if (getprop(chosen_handle, "stdin", &stdin, sizeof(stdin)) != 4)
exit();

printf("\n\rzImage starting: loaded at 0x%p (sp: 0x%p)\n\r", _start, sp);

/*
* The first available claim_base must be above the end of the
* the loaded kernel wrapper file (_start to _end includes the
* initrd image if it is present) and rounded up to a nice
* 1 MB boundary for good measure.
*/

claim_base = _ALIGN_UP((unsigned long)_end, ONE_MB);

vmlinuz.addr = (unsigned long)_vmlinux_start;
vmlinuz.size = (unsigned long)(_vmlinux_end - _vmlinux_start);

Expand All @@ -245,6 +228,25 @@ void start(unsigned long a1, unsigned long a2, void *promptr, void *sp)
exit();
}

/*
* The first available claim_base must be above the end of the
* the loaded kernel wrapper file (_start to _end includes the
* initrd image if it is present) and rounded up to a nice
* 1 MB boundary for good measure.
*/

claim_base = _ALIGN_UP((unsigned long)_end, ONE_MB);

#if defined(PROG_START)
/*
* Maintain a "magic" minimum address. This keeps some older
* firmware platforms running.
*/

if (claim_base < PROG_START)
claim_base = PROG_START;
#endif

/* We need to claim the memsize plus the file offset since gzip
* will expand the header (file offset), then the kernel, then
* possible rubbish we don't care about. But the kernel bss must
Expand Down
Loading

0 comments on commit 70cfaa2

Please sign in to comment.