On Sat, Jul 21, 2018 at 2:54 PM, Marek Vasut <marek.vasut@xxxxxxxxx> wrote: > On 07/21/2018 11:47 PM, Olof Johansson wrote: >> Hi, > > Hi, > >> On Wed, May 30, 2018 at 3:11 AM, Marek Vasut <marek.vasut@xxxxxxxxx> wrote: >>> Drop the MTD partitioning from DT, since it does not describe HW >>> and to give way to a more flexible kernel command line partition >>> passing. >>> >>> To retain the original partitioning, assure you have enabled >>> CONFIG_MTD_CMDLINE_PARTS in your kernel config and add the >>> following to your kernel command line: >>> >>> lager: mtdparts=spi0.0:256k(loader),4m(user),-(flash) >>> stout: mtdparts=spi0.0:512k(loader),256k(uboot),256k(uboot-env),-(flash) >>> koelsch: mtdparts=spi0.0:512k(loader),5632k(user),-(flash) >>> porter: mtdparts=spi0.0:256k(loader_prg),4m(user_prg),-(flash_fs) >>> wheat: mtdparts=spi0.0:256k(loader),4m(user),-(flash) >>> gose: mtdparts=spi0.0:256k(loader),4m(user),-(flash) >>> alt: mtdparts=spi0.0:256k(loader),256k(system),-(user) >>> silk: mtdparts=spi0.0:256k(loader),4m(user),-(flash) >> >> Having to specify on command line is such a nasty hack. I wish we >> could remove that, and at the very least not add it for anything new. > > Do you have a better suggestion ? Yes, keep it in DT. >> You end up with user space tools trying to parse the kernel command >> line to figure out what's on the flash, and other really bad habits. >> :( > > You should just read /proc/mtd , see > http://www.linux-mtd.infradead.org/doc/general.html Sure, I know that but not everybody does, and they do it in bad ways if given the opportunity. >> I'd strongly advice you to keep this in the board files, unless you >> have an actual real motivation for changing it. This patch does not >> provide one. > > Partitioning is not hardware description, it should not be in DT. Read my reply again. It's part of _platform_ description, and belongs in DT. -Olof