Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9b6b563c authored by Paul Mackerras's avatar Paul Mackerras
Browse files

powerpc: Merge in the ppc64 version of the prom code.



This brings in the ppc64 version of prom_init.c, prom.c and btext.c
and makes them work for ppc32.  This also brings in the new calling
convention, where the first entry to the kernel (with r5 != 0) goes
to the prom_init code, which then restarts from the beginning (with
r5 == 0) after it has done its stuff.

For now this also brings in the ppc32 version of setup.c.  It also
merges lmb.h.

Signed-off-by: default avatarPaul Mackerras <paulus@samba.org>
parent b85a046a
Loading
Loading
Loading
Loading
+7 −4
Original line number Diff line number Diff line
@@ -5,10 +5,11 @@
ifeq ($(CONFIG_PPC64),y)
EXTRA_CFLAGS	+= -mno-minimal-toc
endif

ifeq ($(CONFIG_PPC32),y)
extra-$(CONFIG_PPC_STD_MMU)	:= head.o
CFLAGS_prom_init.o      += -fPIC
endif

extra-$(CONFIG_PPC_STD_MMU)	:= head.o
extra-$(CONFIG_PPC64)		:= head_64.o
extra-$(CONFIG_40x)		:= head_4xx.o
extra-$(CONFIG_44x)		:= head_44x.o
@@ -18,13 +19,15 @@ extra-$(CONFIG_6xx) += idle_6xx.o
extra-$(CONFIG_PPC_FPU)		+= fpu.o
extra-y				+= vmlinux.lds

obj-y				:= traps.o
obj-$(CONFIG_PPC32)		+= semaphore.o process.o
obj-y				:= traps.o prom.o semaphore.o
obj-$(CONFIG_PPC32)		+= setup.o process.o
obj-$(CONFIG_PPC64)		+= idle_power4.o
ifeq ($(CONFIG_PPC32),y)
obj-$(CONFIG_PPC_OF)		+= prom_init.o
obj-$(CONFIG_MODULES)		+= ppc_ksyms.o
endif
obj-$(CONFIG_ALTIVEC)		+= vecemu.o vector.o
obj-$(CONFIG_BOOTX_TEXT)	+= btext.o

ifeq ($(CONFIG_PPC_ISERIES),y)
arch/powerpc/kernel/head_64.o: arch/powerpc/platforms/iseries/lparmap.s
+852 −0

File added.

Preview size limit exceeded, changes collapsed.

+7 −9
Original line number Diff line number Diff line
@@ -134,11 +134,13 @@ __start:
 * because OF may have I/O devices mapped into that area
 * (particularly on CHRP).
 */
	mr	r31,r3			/* save parameters */
	cmpwi	0,r5,0
	beq	1f
	bl	prom_init
	trap

1:	mr	r31,r3			/* save parameters */
	mr	r30,r4
	mr	r29,r5
	mr	r28,r6
	mr	r27,r7
	li	r24,0			/* cpu # */

/*
@@ -204,8 +206,7 @@ __after_mmu_off:
 * On CHRP, we are loaded at 0x10000 since OF on CHRP uses
 * the exception vectors at 0 (and therefore this copy
 * overwrites OF's exception vectors with our own).
 * If the MMU is already turned on, we copy stuff to KERNELBASE,
 * otherwise we copy it to 0.
 * The MMU is off at this point.
 */
	bl	reloc_offset
	mr	r26,r3
@@ -1187,9 +1188,6 @@ start_here:
 */
	mr	r3,r31
	mr	r4,r30
	mr	r5,r29
	mr	r6,r28
	mr	r7,r27
	bl	machine_init
	bl	MMU_init

+0 −30
Original line number Diff line number Diff line
@@ -212,36 +212,6 @@ EXPORT_SYMBOL(_machine);
EXPORT_SYMBOL(sys_ctrler);
EXPORT_SYMBOL(pmac_newworld);
#endif
#ifdef CONFIG_PPC_OF
EXPORT_SYMBOL(find_devices);
EXPORT_SYMBOL(find_type_devices);
EXPORT_SYMBOL(find_compatible_devices);
EXPORT_SYMBOL(find_path_device);
EXPORT_SYMBOL(device_is_compatible);
EXPORT_SYMBOL(machine_is_compatible);
EXPORT_SYMBOL(find_all_nodes);
EXPORT_SYMBOL(get_property);
EXPORT_SYMBOL(request_OF_resource);
EXPORT_SYMBOL(release_OF_resource);
EXPORT_SYMBOL(pci_busdev_to_OF_node);
EXPORT_SYMBOL(pci_device_to_OF_node);
EXPORT_SYMBOL(pci_device_from_OF_node);
EXPORT_SYMBOL(of_find_node_by_name);
EXPORT_SYMBOL(of_find_node_by_type);
EXPORT_SYMBOL(of_find_compatible_node);
EXPORT_SYMBOL(of_find_node_by_path);
EXPORT_SYMBOL(of_find_all_nodes);
EXPORT_SYMBOL(of_get_parent);
EXPORT_SYMBOL(of_get_next_child);
EXPORT_SYMBOL(of_node_get);
EXPORT_SYMBOL(of_node_put);
#endif /* CONFIG_PPC_OF */
#if defined(CONFIG_BOOTX_TEXT)
EXPORT_SYMBOL(btext_update_display);
#endif
#if defined(CONFIG_SCSI) && defined(CONFIG_PPC_PMAC)
EXPORT_SYMBOL(note_scsi_host);
#endif
#ifdef CONFIG_VT
EXPORT_SYMBOL(kd_mksound);
#endif
+2141 −0

File added.

Preview size limit exceeded, changes collapsed.

Loading