Skip to contentSkip to conversation

linux-2.4.11-pre4/drivers/mtd/bootldr.c does not compile

DISCUSSION Adam J. Richter 6 participants 10 messages Oct 5, 2001 – Oct 6, 2001

lore
Share & tools
lore
#0 lore raw

Attempting to compile linux-2.4.11-pre4/drivers/mtd/bootldr.c
fails with a bunch of compiler errors, including a complaint that "struct tag" is not defined anywhere. Presumably this is the result of an incompletely applied patch.

Reverting drivers/mtd/bootldr.c to the linux-2.4.11-pre3
version makes it compile without problems.

Adam J. Richter     __     ______________   4880 Stevens Creek Blvd, Suite 104
[email protected]     \ /                  San Jose, California 95129-1034
+1 408 261-6630         | g g d r a s i l   United States of America

fax +1 408 261-6631 "Free Software For The Rest Of Us."

#1 lore raw
Quoted 4 lines · Adam J. Richter

Attempting to compile linux-2.4.11-pre4/drivers/mtd/bootldr.c
fails with a bunch of compiler errors, including a complaint that "struct tag" is not defined anywhere. Presumably this is the result of an incompletely applied patch.

Firstly, its ARM only. Secondly, Compaq decided that a partition table in flash isn't a good idea, so they're passing it from the boot loader, which is a set of tagged lists.

Unfortunately, they haven't even sent me a patch to add the entries into the ARM tree, so even I have to reverse this from my MTD update. ;(

--
Russell King ([email protected]) The developer of ARM Linux
http://www.arm.linux.org.uk/personal/aboutme.html

#2 lore raw
Quoted 1 line · Russell King

Firstly, its ARM only. Secondly, Compaq decided that a partition table in

Can it be set up so that the MTD stuff only shows up for ARM and not for x86?

mrc

Signature · 3 lines
     Mike Castle      [email protected]      www.netcom.com/~dalgoda/
    We are all of us living in the shadow of Manhattan.  -- Watchmen
fatal ("You are in a maze of twisty compiler features, all different"); -- gcc
#3 lore raw
In reply to Russell King
Quoted 5 lines · Mike Castle
Quoted 1 line · Russell King

Firstly, its ARM only. Secondly, Compaq decided that a partition table in

Can it be set up so that the MTD stuff only shows up for ARM and not for x86?

It's setup that way in the latest MTD CVS tree. Hopefully, it should be sync'd to Linus/Alan pretty soon (I think Alan already has it actually).

--
Russell King ([email protected]) The developer of ARM Linux
http://www.arm.linux.org.uk/personal/aboutme.html

#5 lore raw
In reply to Adam J. Richter
Quoted 8 lines · Russell King
Quoted 4 lines · Adam J. Richter

Attempting to compile linux-2.4.11-pre4/drivers/mtd/bootldr.c
fails with a bunch of compiler errors, including a complaint that "struct tag" is not defined anywhere. Presumably this is the result of an incompletely applied patch.

Firstly, its ARM only. Secondly, Compaq decided that a partition table in

Not so. I got this error on i386. I used 'make oldconfig' and was offered
some new options in the JFFS2 area (which I always accept, just to check the build).

--
Eyal Lebedinsky ([email protected]) <http://samba.anu.edu.au/eyal/>

#7 lore raw
In reply to Adam J. Richter
Quoted 9 lines · Russell King
Quoted 4 lines · Adam J. Richter

Attempting to compile linux-2.4.11-pre4/drivers/mtd/bootldr.c
fails with a bunch of compiler errors, including a complaint that "struct tag" is not defined anywhere. Presumably this is the result of an incompletely applied patch.

Firstly, its ARM only. Secondly, Compaq decided that a partition table in flash isn't a good idea, so they're passing it from the boot loader, which is a set of tagged lists.

Did you ever get a motivation on why they want to pass it from the boot loader? It sounds like a particularly bad idea to me.

We can't allocate memory in the tagged list parser so you need to have it statically allocated in the kernel. That means that there is a maximum number of partitions, or that we're wasting memory if we don't use all partition table entries. This can of course be (partly) solved by putting the partition table in the __initdata section, but in that case you can't use the partition data if you have the MTD subsystem as modules.

I wonder what was wrong with the previous solution where the kernel just read the partition table directly from flash? If the bootloader can read the partition table, why can't the kernel?

Erik

Signature · 5 lines
J.A.K. (Erik) Mouw, Information and Communication Theory Group, Department
of Electrical Engineering, Faculty of Information Technology and Systems,
Delft University of Technology, PO BOX 5031,  2600 GA Delft, The Netherlands
Phone: +31-15-2783635  Fax: +31-15-2781843  Email: [email protected]
WWW: http://www-ict.its.tudelft.nl/~erik/
#9 lore raw
In reply to Adam J. Richter
Quoted 5 lines · Russell King
Quoted 2 lines · Erik Mouw

Did you ever get a motivation on why they want to pass it from the boot loader? It sounds like a particularly bad idea to me.

See Jamey Hicks mail on linux-arm-kernel of the 24th September.

Hmm, I missed that one. I'll followup on linux-arm-kernel.

Erik

Signature · 5 lines
J.A.K. (Erik) Mouw, Information and Communication Theory Group, Department
of Electrical Engineering, Faculty of Information Technology and Systems,
Delft University of Technology, PO BOX 5031,  2600 GA Delft, The Netherlands
Phone: +31-15-2783635  Fax: +31-15-2781843  Email: [email protected]
WWW: http://www-ict.its.tudelft.nl/~erik/