newbie: dynamic partition creation possible
hello...
i would like to know if it is possible to create flash dynamic partitions (i mean other way than directly in the sources). in the howto ive read it is impossible, but in some sources i found part_type="static" -- and so i've concluded "dynamic" is also an option? if this is possible can somebody explain the way to do it please.
thanks in advance ... Michael Palme
Signature · 11 lines
------------------------------- Dipl.-Ing. (FH) Michael Palme software engineer Goepel electronic GmbH mailto: [email protected] phone: +493641689682 fax: +493641689644 inet: http://www.goepel.com -------------------------------
Quoted 5 lines · Michael Palme
i would like to know if it is possible to create flash dynamic partitions (i mean other way than directly in the sources). in the howto ive read it is impossible, but in some sources i found part_type="static" -- and so i've concluded "dynamic" is also an option? if this is possible can somebody explain the way to do it please.
What exactly do you mean by "dynamic"?
There are two methods to create partitions:
- Use a partition table parser and create a partition table.
- Provide a mapping driver and hard-code the partition layout in the driver.
Do you mean partition table?
Jörn
Signature · 3 lines
When you close your hand, you own nothing. When you open it up, you own the whole world. -- Li Mu Bai in Tiger & Dragon
thanks for the answer...
i am not sure about the terms, but i can explain what i need in more clear way: i would like to have support for writing binary images into the flash devices (no filesystem etc.). i need different "partitions" on the flash and i dont want to hardcode that -- i have seen in cmdline.c that this is possible via kernel parameters.
i'm not absolutely sure what kernel options are needed and what are unnecessary.
cheers ... Michael
Quoted 20 lines · Jörn Engel
Quoted 3 lines · Michael Palme
i would like to know if it is possible to create flash dynamic partitions (i mean other way than directly in the sources). in the howto ive read it is impossible, but in some sources i found part_type="static" -- and so i've concluded "dynamic" is also an option? if this is possible can somebody explain the way to do it please.
What exactly do you mean by "dynamic"?
There are two methods to create partitions:
- Use a partition table parser and create a partition table.
- Provide a mapping driver and hard-code the partition layout in the driver.Do you mean partition table?
Jörn
Quoted 5 lines · Michael Palme
the flash devices (no filesystem etc.). i need different "partitions" on the flash and i dont want to hardcode that --
i have seen incmdline.cthat this is possible via kernel parameters. i'm not absolutely sure what kernel options are needed and what are unnecessary.
What is unclear with it? cmdline.c contains examples how to use it. Actually it can be very simple. For instance, the following term will give you two partitions, one with 1 MiB and another with all the rest. Both will be read-write and will receive standard labels:
mtdparts=my-mtd-id:1m,-
However, you may have to adapt the mapping driver to use the cmdline partitioning. Here's how:
int num_mtd_parts, result;
struct mtd_partition *mtd_parts;
struct mtd_info mtd;
num_mtd_parts = parse_cmdline_partitions(&mtd, &mtd_parts, "my-mtd-id"); result = add_mtd_partitions (&mtd, mtd_parts, num_mtd_parts);
As an aside: it is good (but rare) practice to use the various CONFIG_ options for partitioning features.
Regards,
Marius
-----------------------------------------------------------------------------
Marius Groeger SYSGO Real-Time Solutions GmbH [email protected] Software Engineering Embedded and Real-Time Software www.sysgo.de Voice: +49-6136-9948-0 Am Pfaffenstein 14 www.osek.de FAX: +49-6136-9948-10 55270 Klein-Winternheim, Germany www.elinos.com