* MTD partitions
@ 2004-04-16 7:33 Tobias Arp
0 siblings, 0 replies; 8+ messages in thread
From: Tobias Arp @ 2004-04-16 7:33 UTC (permalink / raw)
To: linux-mtd
Hi,
on my old kernel (2.4.21 and the arm linux patch rmk2) it was possible to configure the
remapping of the flash in the xconfig/menuconfig files. I have created the mtd partitions in
physmap.c. So when i have made:
cat /proc/mtd
i got these outputs
dev: size erasesize name
mtd0: 00400000 00010000 ""physically mapped flash"
mtd1: 00060000 00010000 ""USER fs"
My flash has a size of 4 MBytes and typically 64kbytes sector size. It started physically at
offset 0x10000000 and is connected via a 16 bit bus. These were also the configuration
paramter which i added to my config files. This must be mtd0. The mtd1 device is the partition
which i have configured in physmap.c.
After applieing the mtd snapshot(mtd-snapshot-20040407.tar.bz2) i have used
physmap_configure with the same data:
physmap_configure(0x10000000,0x00400000,2,NULL);
0x10000000 = physical flash base
0x00400000 = Flash size
2 = 16 Bit Buswidth
Then i have used
physmap_set_partitions(at91_mtd_parts,1);
to add my USER fs
static struct mtd_partition at91_mtd_parts[] __initdata = {
{
.name = "USER fs",
.offset = 0x00380000,
.size = 0x00060000,
}
};
Now i get following outputs when i make cat proc/mtd
dev: size erasesize name
mtd0: 00060000 00010000 ""USER fs"
where is the "old mtd0" device with the whole flashsize ?
And how can i remove these messages from the startup of the kernel:
>cfi_cmdset_0002: Disabling erase-suspend-program due to code brokenness.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
- Is there any patch for this problem ? -
>kmod: failed to exec /sbin/modprobe -s -k cmdlinepart, errno = 2
>cmdlinepart partition parsing not available
>kmod: failed to exec /sbin/modprobe -s -k RedBoot, errno = 2
>RedBoot partition parsing not available
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
- Is there any reason for these messages ? -
Regards
Tobias Arp
_____________________________________________________________________
Der WEB.DE Virenschutz schuetzt Ihr Postfach vor dem Wurm Netsky.A-P!
Kostenfrei fuer alle FreeMail Nutzer. http://f.web.de/?mc=021157
^ permalink raw reply [flat|nested] 8+ messages in thread
* MTD Partitions
@ 2006-09-22 22:26 Nikhil Bansal (nikbansa)
2006-09-23 0:08 ` Josh Boyer
2006-09-24 18:19 ` Michael Trimarchi
0 siblings, 2 replies; 8+ messages in thread
From: Nikhil Bansal (nikbansa) @ 2006-09-22 22:26 UTC (permalink / raw)
To: linux-mtd
Hi,
>From what I understand you need to provide the partitioning details of
MTD devices at the compile time. I was wondering if there is any way to
partition a flash device at runtime based on the sectors. For Example:
partition 1 from sector 1 to sector 10, partition 2 from sector 11 to
sector 20.
The thing is that we have a board with a flash chip on it and
configuration of this chip may vary based on several factors. I don't
have the luxury of compiling the kernel for each such requirement :( I
think I read somewhere that at this point, partitioning can be done at
compile time only but just wanted to confirm.
By the way, we can keep the number of partitions fixed but size needs to
be varied. Please let me know if it can be done.
Thanks in advance,
Nikhil
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: MTD Partitions
2006-09-22 22:26 MTD Partitions Nikhil Bansal (nikbansa)
@ 2006-09-23 0:08 ` Josh Boyer
2006-09-24 18:19 ` Michael Trimarchi
1 sibling, 0 replies; 8+ messages in thread
From: Josh Boyer @ 2006-09-23 0:08 UTC (permalink / raw)
To: Nikhil Bansal (nikbansa); +Cc: linux-mtd
On 9/22/06, Nikhil Bansal (nikbansa) <nikbansa@cisco.com> wrote:
> Hi,
>
> >From what I understand you need to provide the partitioning details of
> MTD devices at the compile time. I was wondering if there is any way to
> partition a flash device at runtime based on the sectors. For Example:
> partition 1 from sector 1 to sector 10, partition 2 from sector 11 to
> sector 20.
>
> The thing is that we have a board with a flash chip on it and
> configuration of this chip may vary based on several factors. I don't
> have the luxury of compiling the kernel for each such requirement :( I
> think I read somewhere that at this point, partitioning can be done at
> compile time only but just wanted to confirm.
>
> By the way, we can keep the number of partitions fixed but size needs to
> be varied. Please let me know if it can be done.
You might want to take a look at UBI. It can do much of what you are
looking for, depending on how complex things are. It's still a work
in progress, but it's usable.
http://linux-mtd.infradead.org/doc/ubi.html
josh
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: MTD Partitions
2006-09-22 22:26 MTD Partitions Nikhil Bansal (nikbansa)
2006-09-23 0:08 ` Josh Boyer
@ 2006-09-24 18:19 ` Michael Trimarchi
1 sibling, 0 replies; 8+ messages in thread
From: Michael Trimarchi @ 2006-09-24 18:19 UTC (permalink / raw)
To: Nikhil Bansal (nikbansa); +Cc: linux-mtd
Nikhil Bansal (nikbansa) wrote:
>Hi,
>
>>From what I understand you need to provide the partitioning details of
>MTD devices at the compile time. I was wondering if there is any way to
>partition a flash device at runtime based on the sectors. For Example:
>partition 1 from sector 1 to sector 10, partition 2 from sector 11 to
>sector 20.
>
>The thing is that we have a board with a flash chip on it and
>configuration of this chip may vary based on several factors. I don't
>have the luxury of compiling the kernel for each such requirement :( I
>think I read somewhere that at this point, partitioning can be done at
>compile time only but just wanted to confirm.
>
>By the way, we can keep the number of partitions fixed but size needs to
>be varied. Please let me know if it can be done.
>
>Thanks in advance,
>Nikhil
>
>______________________________________________________
>Linux MTD discussion mailing list
>http://lists.infradead.org/mailman/listinfo/linux-mtd/
>
>
>
Hi,
I think that you can use cmdline partition option in the kernel. I use
it in the IXDP465
Regards Michael
^ permalink raw reply [flat|nested] 8+ messages in thread
* MTD partitions
@ 2008-03-12 10:06 Tim Chen
2008-03-12 10:16 ` David Brownell
0 siblings, 1 reply; 8+ messages in thread
From: Tim Chen @ 2008-03-12 10:06 UTC (permalink / raw)
To: linux-omap
Hi,
I'm trying to add MTD NAND partitions to my OMAP850 based board.
I saw NAND partitions information in arch/arm/mach-omap1/board-h3.c,
But after some survey, I found *.c files in drivers/mtd/maps, there're
also files containing MTD partitions information.
What file should I add MTD partitions information to?
Files in arch/arm/mach-omap1/ or drivers/mtd/maps?
Thanks.
--
--
Regards,
Tim.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: MTD partitions
2008-03-12 10:06 MTD partitions Tim Chen
@ 2008-03-12 10:16 ` David Brownell
2008-03-13 3:34 ` Tim Chen
[not found] ` <9c1eb1b90803122032j2d1c83adk175e4ade0bf2fcab@mail.gmail.com>
0 siblings, 2 replies; 8+ messages in thread
From: David Brownell @ 2008-03-12 10:16 UTC (permalink / raw)
To: Tim Chen; +Cc: linux-omap
On Wednesday 12 March 2008, Tim Chen wrote:
> What file should I add MTD partitions information to?
> Files in arch/arm/mach-omap1/ or drivers/mtd/maps?
Platform data in .../mach-omap1/board-$(MYBOARD).c should
give default partition data to the relevant NAND driver.
- Dave
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: MTD partitions
2008-03-12 10:16 ` David Brownell
@ 2008-03-13 3:34 ` Tim Chen
[not found] ` <9c1eb1b90803122032j2d1c83adk175e4ade0bf2fcab@mail.gmail.com>
1 sibling, 0 replies; 8+ messages in thread
From: Tim Chen @ 2008-03-13 3:34 UTC (permalink / raw)
Cc: linux-omap
Thanks, David,
I added the MTD partition information to board-($MYBOARD).c,
But kernel didn't show any MTD partition information during booting.
If I have to create the MTD partitions using MTD commands in u-boot first?
My u-boot is old, no MTD support, if that's the case, I'll port the
newer u-boot, then try again.
Thanks.
On Wed, Mar 12, 2008 at 6:16 PM, David Brownell <david-b@pacbell.net> wrote:
> On Wednesday 12 March 2008, Tim Chen wrote:
> > What file should I add MTD partitions information to?
> > Files in arch/arm/mach-omap1/ or drivers/mtd/maps?
>
> Platform data in .../mach-omap1/board-$(MYBOARD).c should
> give default partition data to the relevant NAND driver.
>
> - Dave
>
>
--
--
Regards,
Tim.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: MTD partitions
[not found] ` <200803122119.46453.david-b@pacbell.net>
@ 2008-03-13 10:24 ` Tim Chen
0 siblings, 0 replies; 8+ messages in thread
From: Tim Chen @ 2008-03-13 10:24 UTC (permalink / raw)
To: David Brownell, linux-omap
Hi David,
Solved,
Finally, I checked out a new GIT tree, the previous I used is
linux-2.6.23-rc3-omap1(might be quite old).
As you said, I modified the board-(MYBOARD).c file.
Also, The NAND flash part is the Samsung K5E1212ACB MCP(64MB NAND
flash/64MB DDR), as the IDs shown below,
NAND device: Manufacturer ID: 0xec, Chip ID: 0x36 (Samsung NAND 64MiB 1,8V 8-bit
)
Scanning device for bad blocks
Bad eraseblock 753 at 0x00bc4000
Bad eraseblock 1007 at 0x00fbc000
Bad eraseblock 1112 at 0x01160000
Bad eraseblock 1281 at 0x01404000
Bad eraseblock 1948 at 0x01e70000
Bad eraseblock 2158 at 0x021b8000
Bad eraseblock 2328 at 0x02460000
Bad eraseblock 2941 at 0x02df4000
Creating 5 MTD partitions on "omapnand.0":
0x00000000-0x00010000 : "xloader"
mtd: Giving out device 0 to xloader
0x00010000-0x00050000 : "bootloader"
mtd: Giving out device 1 to bootloader
0x00050000-0x00080000 : "params"
mtd: Giving out device 2 to params
0x00080000-0x00280000 : "kernel"
mtd: Giving out device 3 to kernel
0x00280000-0x04000000 : "filesystem"
mtd: Giving out device 4 to filesystem
On Thu, Mar 13, 2008 at 12:19 PM, David Brownell <david-b@pacbell.net> wrote:
> On Wednesday 12 March 2008, you wrote:
> > I added the MTD partition information to board-($MYBOARD).c,
> > But kernel didn't show any MTD partition information during booting.
>
> That means you didn't connect something correctly. Is the right
> platform device present? Is its driver loaded? Is it successfully
> probing? Did you enable partitions? You can enable MTD debug to
> see most of that.
>
>
>
> > If I have to create the MTD partitions using MTD commands in u-boot first?
> > My u-boot is old, no MTD support, if that's the case, I'll port the newer
> > u-boot, then try again.
>
> That would only matter if you're trying to boot from e.g. a JFFS2
> partition using u-boot. Or, depending on what you mean, load the
> kernel from flash.
>
> What you need to do first is make sure that the kernel sees the
> flash chip, and then make sure the partition info is used.
>
>
>
>
--
--
Regards,
Tim.
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2008-03-13 10:24 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-04-16 7:33 MTD partitions Tobias Arp
-- strict thread matches above, loose matches on Subject: below --
2006-09-22 22:26 MTD Partitions Nikhil Bansal (nikbansa)
2006-09-23 0:08 ` Josh Boyer
2006-09-24 18:19 ` Michael Trimarchi
2008-03-12 10:06 MTD partitions Tim Chen
2008-03-12 10:16 ` David Brownell
2008-03-13 3:34 ` Tim Chen
[not found] ` <9c1eb1b90803122032j2d1c83adk175e4ade0bf2fcab@mail.gmail.com>
[not found] ` <200803122119.46453.david-b@pacbell.net>
2008-03-13 10:24 ` Tim Chen
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.