Skip to contentSkip to conversation

A little fix

PATCH Michael Sokolov 2 participants 2 messages Nov 27, 2001 – Nov 28, 2001

lore
Share & tools
lore
#0 lore raw

OK, I goofed. It's struct bi_record, not struct bootinfo. I have no idea how I could have screwed it up and how could the compiler have missed it. Is it another gcc extension to allow struct never_heard_of * as OK? The patch below fixes it. It also fixes a remaining bit of the kernel=>platforms rename.

MS

arch/ppc/boot/common/misc-simple.c +2 -2
diff --minimal -Nru a/arch/ppc/boot/common/misc-simple.c b/arch/ppc/boot/common/misc-simple.c
@@ -58,13 +58,13 @@
 extern void gunzip(void *, int, unsigned char *, int *);
 extern void setup_legacy(void);
 
-struct bootinfo *
+struct bi_record *
 decompress_kernel(unsigned long load_addr, int num_words, unsigned long cksum)
 {
 	int timer = 0;
 	char *cp, ch;
 	struct bi_record *rec;
-	struct bootinfo *birecs;
+	struct bi_record *birecs;
 
 	setup_legacy();
 	com_port = serial_init(0, NULL);
arch/ppc/platforms/adir_setup.c +1 -1
diff --minimal -Nru a/arch/ppc/platforms/adir_setup.c b/arch/ppc/platforms/adir_setup.c
@@ -181,7 +181,7 @@
 	/*
 	 * On the Adirondack we use bi_recs and pass the pointer to them in R3.
 	 */
-	parse_bootinfo((struct bootinfo *) (r3 + KERNELBASE));
+	parse_bootinfo((struct bi_record *) (r3 + KERNELBASE));
 
 	/* Remember, isa_io_base is virtual but isa_mem_base is physical! */
 	isa_io_base = ADIR_PCI32_VIRT_IO_BASE;
arch/ppc/platforms/k2.h +3 -3
diff --minimal -Nru a/arch/ppc/platforms/k2.h b/arch/ppc/platforms/k2.h
@@ -13,8 +13,8 @@
  * option) any later version.
  */
 
-#ifndef __PPC_KERNEL_K2_H
-#define __PPC_KERNEL_K2_H
+#ifndef __PPC_PLATFORMS_K2_H
+#define __PPC_PLATFORMS_K2_H
 
 /*
  * SBS K2 definitions
@@ -81,4 +81,4 @@
 
 #define K2_SYS_SLOT_MASK	0x08
 
-#endif /* __PPC_KERNEL_K2_H */
+#endif /* __PPC_PLATFORMS_K2_H */
arch/ppc/platforms/k2_setup.c +1 -1
diff --minimal -Nru a/arch/ppc/platforms/k2_setup.c b/arch/ppc/platforms/k2_setup.c
@@ -346,7 +346,7 @@
 void __init platform_init(unsigned long r3, unsigned long r4,
 		unsigned long r5, unsigned long r6, unsigned long r7)
 {
-	parse_bootinfo((struct bootinfo *) (r3 + KERNELBASE));
+	parse_bootinfo((struct bi_record *) (r3 + KERNELBASE));
 
 	isa_io_base = K2_ISA_IO_BASE;
 	isa_mem_base = K2_ISA_MEM_BASE;

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

#1 lore raw
Quoted 5 lines · Michael Sokolov

OK, I goofed. It's struct bi_record, not struct bootinfo. I have no idea how I could have screwed it up and how could the compiler have missed it. Is it another gcc extension to allow struct never_heard_of * as OK? The patch below fixes it. It also fixes a remaining bit of the kernel=>platforms rename.

That's not a GCC extension, it's standard C, actually. It's an opaque type.

--
Daniel Jacobowitz Carnegie Mellon University
MontaVista Software Debian GNU/Linux Developer

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/