From: Alexander Clouter <alex@digriz.org.uk>
To: linux-mtd@lists.infradead.org
Cc: linux-mips@linux-mips.org
Subject: Re: [PATCH 4/4] MTD: include ar7part in the list of partitions parsers
Date: Wed, 6 Jan 2010 20:28:10 +0000 [thread overview]
Message-ID: <qb8f17-41q.ln1@chipmunk.wormnet.eu> (raw)
In-Reply-To: 201001050941.42161.florian@openwrt.org
In gmane.linux.ports.mips.general Florian Fainelli <florian@openwrt.org> wrote:
>
>> [snipped]
>>
>> It simply pulls apart the 'PROM' (aka ADAM2) config and uses that to
>> build the partition table.
>
> This is indeed simple but if I recall right the rationale behind ar7part was
> to create a sane partition layout no matter if the bootloader was ADAM2 or
> PSPBoot and the root filesystem type. JFFS2 and squashfs do not have the same
> erase-block size alignment constraints, ar7part deals with that too.
>
I am not convinced that is a good idea, one main reason is ar7part.c has
gotten terribly wrong the partition table ('loader' is too small[1] and
'rootfs' overlaps with the 'linux' partition').
This is what I have from ADAM2's perspective:
----
Adam2_AR7WRD > printenv
[snipped]
mtd0 0x900e0000,0x903f0000 <-- rootfs
mtd1 0x90020000,0x900e0000 <-- kernel
mtd2 0x90000000,0x90020000 <-- adam2 bootloader
mtd3 0x903f0000,0x90400000 <-- configuration
mtd4 0x90020000,0x903f0000 <-- kernel + rootfs
----
Linux spits out:
----
physmap platform flash device: 00800000 at 10000000
physmap-flash.0: Found 1 x16 devices at 0x0 in 16-bit bank
Amd/Fujitsu Extended Query Table at 0x0040
physmap-flash.0: Swapping erase regions for broken CFI table.
number of CFI chips: 1
cmdlinepart partition parsing not available
RedBoot partition parsing not available
4 ar7part partitions found on MTD device physmap-flash.0
Creating 4 MTD partitions on "physmap-flash.0":
0x000000000000-0x000000010000 : "loader"
0x0000003f0000-0x000000400000 : "config"
0x000000020000-0x0000003f0000 : "linux"
0x0000000d0000-0x0000003f0000 : "rootfs"
----
My patch munched on whatever prom_getenv() returned, which from what I
can tell looking at arch/mips/ar7/prom.c will work for both PSPBoot and
ADAM2?
Are there some strange mtd environment variables I am yet to see out in
the wild or does my patch simply not work for PSPBoot primed kit? If
not can you give me some 'spiel' to play around with?
Cheers
[1] okay, ADAM2 weighs in at less than 64kiB however it is not outside
the realm of possibility someone will port u-boot to AR7 which
would benefit from the full 128kiB of space?
--
Alexander Clouter
.sigmonster says: A man who turns green has eschewed protein.
next prev parent reply other threads:[~2010-01-06 21:10 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-03 20:17 [PATCH 4/4] MTD: include ar7part in the list of partitions parsers Florian Fainelli
2010-01-03 20:56 ` David Woodhouse
2010-01-03 21:31 ` Alexander Clouter
2010-01-05 8:41 ` Florian Fainelli
2010-01-06 20:28 ` Alexander Clouter [this message]
2010-01-04 7:09 ` Florian Fainelli
2010-01-10 9:11 ` Artem Bityutskiy
2010-01-10 9:13 ` Artem Bityutskiy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=qb8f17-41q.ln1@chipmunk.wormnet.eu \
--to=alex@digriz.org.uk \
--cc=linux-mips@linux-mips.org \
--cc=linux-mtd@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox