Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FS#2294 - ath79: dts firmware partition size also used as parition end for rootfs #7166

Closed
openwrt-bot opened this issue May 26, 2019 · 2 comments
Labels

Comments

@openwrt-bot
Copy link

cshoredaniel:

PCS CAP324 (ar9344, ath79)

NAME="OpenWrt"
VERSION="SNAPSHOT"
PRETTY_NAME="OpenWrt SNAPSHOT"
VERSION_ID="snapshot"
BUILD_ID="r10075-ace2410"
LEDE_BOARD="ath79/generic"
LEDE_ARCH="mips_24kc"
LEDE_RELEASE="OpenWrt SNAPSHOT r10075-ace2410"

partitions ending at 0xfa0000 should end at 0xfe0000.
It looks suspiciously like the size of the firmware partition is being used as the end of the rootfs partition.

[ 0.395749] m25p80 spi0.0: mx25l12805d (16384 Kbytes)
[ 0.401067] 4 fixed-partitions partitions found on MTD device spi0.0
[ 0.407631] Creating 4 MTD partitions on "spi0.0":
[ 0.412604] 0x000000000000-0x000000040000 : "u-boot"
[ 0.418554] 0x000000040000-0x000000050000 : "u-boot-env"
[ 0.424883] 0x000000050000-0x000000ff0000 : "firmware"
[ 0.433582] 2 uimage-fw partitions found on MTD device firmware
[ 0.439700] Creating 2 MTD partitions on "firmware":
[ 0.444877] 0x000000000000-0x0000001a0000 : "kernel"
[ 0.450862] 0x0000001a0000-0x000000fa0000 : "rootfs"
[ 0.456702] mtd: device 4 (rootfs) set to be root filesystem
[ 0.462629] 1 squashfs-split partitions found on MTD device rootfs
[ 0.469018] 0x0000004d0000-0x000000fa0000 : "rootfs_data"
[ 0.475393] 0x000000ff0000-0x000001000000 : "art"

https://github.com/openwrt/openwrt/blob/master/target/linux/ath79/dts/ar9344_pcs_cap324.dts

flash@0 {
compatible = "jedec,spi-nor";
reg = <0>;
spi-max-frequency = <25000000>;

	partitions {
		compatible = "fixed-partitions";
		#address-cells = <1>;
		#size-cells = <1>;

		uboot: partition@0 {
			label = "u-boot";
			reg = <0x000000 0x040000>;
			read-only;
		};

		partition@40000 {
			label = "u-boot-env";
			reg = <0x040000 0x010000>;
			read-only;
		};

		partition@50000 {
			compatible = "denx,uimage";
			label = "firmware";
			reg = <0x050000 0x0fa0000>;
		};

		art: partition@7f0000 {
			label = "art";
			reg = <0xff0000 0x010000>;
			read-only;
		};
	};

};

Also occurs similarly with CR5000 -- rootfs ends at 0x7a0000 instead of 0x7e0000

https://github.com/openwrt/openwrt/blob/master/target/linux/ath79/dts/ar9344_pcs_cr5000.dts

flash@0 {
compatible = "jedec,spi-nor";
reg = <0>;
spi-max-frequency = <25000000>;

	partitions {
		compatible = "fixed-partitions";
		#address-cells = <1>;
		#size-cells = <1>;

		uboot: partition@0 {
			label = "u-boot";
			reg = <0x000000 0x040000>;
			read-only;
		};

		partition@40000 {
			label = "u-boot-env";
			reg = <0x040000 0x010000>;
			read-only;
		};

		partition@50000 {
			compatible = "denx,uimage";
			label = "firmware";
			reg = <0x050000 0x07a0000>;
		};

		art: partition@7f0000 {
			label = "art";
			reg = <0x7f0000 0x010000>;
			read-only;
		};

};

/proc/cmdline is console=ttyS0,115200 rootfstype=squashfs,jffs2 so it's not reading from e.g. mtdparts

@openwrt-bot
Copy link
Author

cshoredaniel:

Sorry where I said end at 0xfe0000 it should end at 0xfeffff -- 0xff0000 - 0xffffff should be art.

@openwrt-bot
Copy link
Author

cshoredaniel:

nvm, I realized I was misreading. Can be closed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant