Only add them where they are actually required.
Should help with compatibility issues with stock U-Boot images that
access UBI
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Previous version was based on code from kernel 2.6.22 with Broadcom two
trivial modifications. This updates the copy to the version from current
kernel and refreshes the patch.
This was tested for regressions on Netgear R6250 (BCM4708A0), D-Link
DIR-885L (BCM4709C0) and Tenda AC9 (BCM47189B0).
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
We finally got kernel booting on this device and LAN ports are working,
so it won't "brick" the device. One more big missing thing is WAN port
support. It requires fix for BCM53125 to get switch port 5 working.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Over a year ago in a commit ac96a1665a ("bcm53xx: update Disable MMU
and Dcache during decompression") we switched to Florian's patch for
workarounding CFE bug. The main difference was using a part of existing
__armv7_mmu_cache_flush instead of implementing flushing separately.
This worked well for Northstar devices but doesn't work for BCM53573 as
these devices simply don't start booting with Florian's patch. It's
because of the ldmfd ASM instruction in the __armv7_mmu_cache_flush.
So this commit switches back to using standalone implementation. This
time instead of copying Broadcom's copy of cache-v7.S, we just make a
copy of the original file on our own. Unfortunately we can't cross-dir
compile cache-v7.S from ../../mm/ as that one also adds __INITDATA with
define_cache_functions v7 which would just trigger
> Error: unrecognized/unsupported machine ID (r1 = 0x0000007f).
The only real change Broadcom did in copied .S file was modifying mcr
instruction to use c6 instead of c14. It isn't clear to me if we really
need it, but let's use it for now.
By the way we also update commit message of the
[PATCH] ARM: BCM5301X: Disable MMU and Dcache during decompression
This makes kernel booting on BCM53573 successfully.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
It was adding unused variable:
drivers/mtd/devices/m25p80.c: In function 'm25p80_write':
drivers/mtd/devices/m25p80.c:85:6: warning: unused variable 'i' [-Wunused-variable]
int i;
^
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
It adds and uses ILP clock that requires some other work (in progress)
for upstreaming it. Other than that it adds a quick fix for bcma to add
serial flash before trying to read SPROM.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
It wasn't accepted upstream as there was a discusson on Northstar vs.
BCM53573. Once we get a new ARM arch Kconfig entry it should be
possible to upstream it.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
This generates proper images when using CONFIG_TARGET_MULTI_PROFILE and
CONFIG_TARGET_PER_DEVICE_ROOTFS.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Thanks to this images for SoftMAC devices don't get brcmfmac anymore and
b43 is added for devices with (quite poor) support only.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
This allows building images for selected devices with brcmfmac only
(without b43 which is for SoftMAC devices).
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Reviewed-by: Jo-Philipp Wich <jo@mein.io>
It is used by a core build template, so the variable should be
initialized and added to DEVICE_VARS in the core.
Same for DEVICE_DTS_DIR
Signed-off-by: Felix Fietkau <nbd@nbd.name>
We call all commands normally, with standard echoing. It's useful for
debugging with V=s. Don't make lzma compression an exception, it's a bit
confusing this way.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
We don't want checksum to cover any part of UBI as even its part with
SquashFS may be changed due to e.g. flash wearing.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
This reverts commit b3be33f135.
CFE is known to fail in some non-standard cases, e.g. when using kernel
or format different that what was tested by Broadcom. This kernel change
triggered some problem with booting OpenWrt kernel stored in Seama.
As long as Seama checksum was covering enough data, it was working fine.
We need to change it however, because calculating MD5 over part of UBI
containing SquashFS is unsafe. UBI may move PEBs depending on flash
wearing level which would break CFE booting the image.
For some reason this kernel change was breaking CFE. Calculating MD5
over 0x47ffc0 B data or less (there is 0x40 B long header) was stopping
booting process at:
Starting program at 0x00008000
As our kernel is usually 0x3fffc0 B it was affected by this problem.
Reverting this change fixes sysupgrade (which already uses kernel size
for MD5 calculation) and will allow us to adjust "fixseama" command call
on the first boot.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>