Commit Graph

9 Commits (6c7cbf1420a3a1757ce62d94bb89c71564b38ba0)

Author SHA1 Message Date
Álvaro Fernández Rojas 6c7cbf1420 kernel: mtdsplit: bcm_wfi: always add img partitions
This is useful when booting OpenWrt from ramdisks in order to have both
images partitions defined.
Furthermore, instead of always using img2 for the inactive image, let's use
img1 or img2 accordingly.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
4 years ago
Álvaro Fernández Rojas 18d2eeab8e kernel: mtdsplit: support Broadcom WFI bootflags
When firmware is flashed, cferam.000 extension is renamed to the next number.
When booting, CFE scans the NAND and picks the partition with the highest
cferam extension and ignores the other one.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
4 years ago
Álvaro Fernández Rojas 1fd3dabfaf kernel: mtdsplit: improve JFFS2 scan
Allow retrieving full file name and length by parameters.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
4 years ago
Álvaro Fernández Rojas eed8a927ee kernel: mtdsplit: bcm_wfi: refactor code
Create new parse_bcm_wfi function with common code from current parsers.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
4 years ago
Álvaro Fernández Rojas 4b2fe12953 kernel: mtdsplit: bcm_wfi: remove brcm,wfi-sercomm compatibility
The only Sercomm WFI user has been migrated to a dedicated firmware parser.
Keep support for no cferam partition based on a boolean DT property.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
4 years ago
Álvaro Fernández Rojas fce7380e0e kernel: mtdsplit: bcm_wfi: support Sercomm bootflags
Sercomm uses 2 bootflag partitions and boots the firmware with the highest
bootflag. Support splitting the firmware partition while keeping support for
unsplitted layout.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
4 years ago
Álvaro Fernández Rojas cd81d105d5 kernel: mtdsplit: bcm_wfi: code refactoring
- Rename master to mtd.
- Pass mtd size as an argument.
- Rename of_match_table.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
4 years ago
Álvaro Fernández Rojas 5d3bb7ea9a kernel: mtdsplit: bcm_wfi: add sercomm support
SERCOMM creates separates partitions for cferam.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
4 years ago
Álvaro Fernández Rojas cca13d8e82 kernel: mtdsplit: add BCM WFI support
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
4 years ago