Refresh 2.5G-SGMII patch due to recent PHY backport that cause
compilation warning for case not handled in phy_interface_num_ports.
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
From the symbol help message:
> SLUB has extensive debug support features. Disabling these can result
> in significant savings in code size.
There seems to be no need to enable those debugging features for
standard use.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
At this moment, 702-phy-Add-2.5G-SGMII-interface-mode.patch cause error
durring kernel compilation:
CC drivers/net/phy/phylink.o
drivers/net/phy/phylink.c: In function 'phylink_get_capabilities':
drivers/net/phy/phylink.c:443:9: error: enumeration value 'PHY_INTERFACE_MODE_2500SGMII' not handled in switch [-Werror=switch]
443 | switch (interface) {
| ^~~~~~
cc1: all warnings being treated as errors
NXP take care of it. Let's port their patch.
Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
Patches recreated from NXP 6.1 tree:
400-LF-20-3-mtd-spi-nor-Use-1-bit-mode-of-spansion-s25fs.patch
701-staging-add-fsl_ppfe-driver.patch
702-phy-Add-2.5G-SGMII-interface-mode.patch
Patch 703 includes changes made by Christian Marangi, extracted from commit
0d4a547905.
Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
Import commits from upstream Linux replacing some downstream patches.
Move accepted patches from pending-{5.15,6.1} to backport-{5.15,6.1}.
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
All the tools (e.g fw_setenv, ubiupdatevol) and config (fw_env.config)
needed for sysupgrade are already included in /lib/upgrade/stage2
Signed-off-by: Mathew McBride <matt@traverse.com.au>
The Traverse LS1043 boards were not publicly released,
all the production has been going to OEM customers who
do not use the image format defined in the OpenWrt tree.
Only a few samples were circulated outside Traverse
and our OEM customers. The public release (then called
Five64) of this series was cancelled in favour of our
LS1088A based design (Ten64).
It is best to remove these boards to avoid wasting
OpenWrt project and contributor resources.
Signed-off-by: Mathew McBride <matt@traverse.com.au>
This is required for managed operation of the SFP ports on
the Ten64 (LS1088A) and other boards.
The two issues resolved are:
- Validation of 10G SFP link modes fail as Linux did not
consider the equivalence of modes like XFI, 10GBase-R
- Fix a locking issue that prevented the system rebooting
when SFP ports were controlled by the SFP driver.
Please note, these patches are replaced by upstream ones
in 6.x, see: commit 61ec9a8154 ("armvirt: add SFP support
patches for NXP Layerscape DPAA2 platforms") in OpenWrt for
the relevant patches.
Signed-off-by: Mathew McBride <matt@traverse.com.au>
The Ten64 board[1] is based around NXP's Layerscape LS1088A SoC.
It is capable of booting both standard Linux distributions
from disk devices, using EFI, and booting OpenWrt
from NAND.
See the online manual for more information, including the
flash layout[2].
This patchset adds support for generating Ten64 images
for NAND boot.
For disk boot, one can use the EFI support that was
recently added to the armvirt target.
We previously supported NAND users by building
inside our armvirt/EFI target[3], but this approach
is not suitable for OpenWrt upstream. Users who
used our supplied NAND images will be able to upgrade
to this via sysupgrade.
Signed-off-by: Mathew McBride <matt@traverse.com.au>
[1] - https://www.traverse.com.au/hardware/ten64
[2] - https://ten64doc.traverse.com.au/hardware/flash/
[3] - Example:
285e4360e1
source.codeaurora.org project has been shut down and the nxp
repositories has been moved to github. Update the link reference to the
new location.
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
Backport initial LEDs hw control support. Currently this is limited to
only rx/tx and link events for the netdev trigger but the API got
accepted and the additional modes are working on and will be backported
later.
Refresh every patch and add the additional config flag for QCA8K new
LEDs support.
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
This set the CONFIG_FRAME_WARN option depending on some target settings.
It will use the default from the upstream kernel and not the hard coded
value of 1024 now.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Management Complex (MC) userspace support is required for userspace
helpers working with DPAA2 objects exported by the Management Complex BUS.
Without it, there is the error:
```
root@OpenWrt:/# ls-addni dpmac.1
error: Did not find a device file
Restool wrapper scripts only support the latest major MC version
that currently is MC10.x. Use with caution.
error: Did not find a device file
```
This patch fixes it.
Suggested-by: Alexandra Alth <alexandra@alth.de>
Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
This allows loading modules with large memory requirements, recently needed
while testing on armvirt/32. Past forum discussions [1] and bug reports [2]
also raised this and the ipq806x target already set it in response [3].
Given this increases kernel image size by only ~1KB, is generally useful on
multi-platform kernels, and enabled by default on upstream arm32 Linux, add
it to the generic config.
The setting has similar utility on arm64, is a requirement for KASLR, and
already enabled on most OpenWrt aarch64 targets, so pull this into the
top-level generic config.
[1]: https://forum.openwrt.org/t/vmap-allocation-for-size-442368-failed-use-vmalloc-size-to-increase-size/34545/7
[2]: https://github.com/openwrt/openwrt/issues/8282
[3]: f81e148eb6 ("ipq806x: update 4.19 kernel config").
Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
All targets are bumped to 5.15. Remove the old 5.10 patches, configs
and files using:
find target/linux -iname '*-5.10' -exec rm -r {} \;
Further, remove the 5.10 include.
Signed-off-by: Nick Hainke <vincent@systemli.org>
Rework some desc dump and dummy pkt function to fix compilation warning.
Fix compilation warning:
drivers/staging/fsl_ppfe/pfe_hif.c: In function 'send_dummy_pkt_to_hif':
drivers/staging/fsl_ppfe/pfe_hif.c:118:19: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast]
118 | ddr_ptr = (void *)((u64)readl(BMU2_BASE_ADDR + BMU_ALLOC_CTRL));
| ^
drivers/staging/fsl_ppfe/pfe_hif.c:122:20: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast]
122 | lmem_ptr = (void *)((u64)readl(BMU1_BASE_ADDR + BMU_ALLOC_CTRL));
| ^
drivers/staging/fsl_ppfe/pfe_hif.c: In function 'pfe_hif_desc_dump':
drivers/staging/fsl_ppfe/pfe_hif.c:195:24: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
195 | desc_p = (u32)((u64)desc - (u64)hif->descr_baseaddr_v +
| ^
drivers/staging/fsl_ppfe/pfe_hif.c:195:36: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
195 | desc_p = (u32)((u64)desc - (u64)hif->descr_baseaddr_v +
| ^
drivers/staging/fsl_ppfe/pfe_hif.c:207:19: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
207 | desc_p = ((u64)desc - (u64)hif->descr_baseaddr_v +
| ^
drivers/staging/fsl_ppfe/pfe_hif.c:207:31: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
207 | desc_p = ((u64)desc - (u64)hif->descr_baseaddr_v +
| ^
cc1: all warnings being treated as errors
In file included from ./include/linux/kernel.h:19,
from ./include/linux/list.h:9,
from ./include/linux/wait.h:7,
from ./include/linux/eventfd.h:13,
from drivers/staging/fsl_ppfe/pfe_cdev.c:11:
drivers/staging/fsl_ppfe/pfe_cdev.c: In function 'pfe_cdev_read':
./include/linux/kern_levels.h:5:25: error: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'int' [-Werror=format=]
5 | #define KERN_SOH "\001" /* ASCII Start Of Header */
| ^~~~~~
./include/linux/printk.h:422:25: note: in definition of macro 'printk_index_wrap'
422 | _p_func(_fmt, ##__VA_ARGS__); \
| ^~~~
./include/linux/printk.h:132:17: note: in expansion of macro 'printk'
132 | printk(fmt, ##__VA_ARGS__); \
| ^~~~~~
./include/linux/printk.h:580:9: note: in expansion of macro 'no_printk'
580 | no_printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~
./include/linux/kern_levels.h:15:25: note: in expansion of macro 'KERN_SOH'
15 | #define KERN_DEBUG KERN_SOH "7" /* debug-level messages */
| ^~~~~~~~
./include/linux/printk.h:580:19: note: in expansion of macro 'KERN_DEBUG'
580 | no_printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~~
drivers/staging/fsl_ppfe/pfe_cdev.c:42:17: note: in expansion of macro 'pr_debug'
42 | pr_debug("%u %lu", link_states[ret].phy_id,
| ^~~~~~~~
./include/linux/kern_levels.h:5:25: error: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'size_t' {aka 'unsigned int'} [-Werror=format=]
5 | #define KERN_SOH "\001" /* ASCII Start Of Header */
| ^~~~~~
./include/linux/printk.h:422:25: note: in definition of macro 'printk_index_wrap'
422 | _p_func(_fmt, ##__VA_ARGS__); \
| ^~~~
./include/linux/printk.h:493:9: note: in expansion of macro 'printk'
493 | printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~
./include/linux/kern_levels.h:11:25: note: in expansion of macro 'KERN_SOH'
11 | #define KERN_ERR KERN_SOH "3" /* error conditions */
| ^~~~~~~~
./include/linux/printk.h:493:16: note: in expansion of macro 'KERN_ERR'
493 | printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~
drivers/staging/fsl_ppfe/pfe_cdev.c:50:17: note: in expansion of macro 'pr_err'
50 | pr_err("Failed to send (%d)bytes of (%lu) requested.\n",
| ^~~~~~
./include/linux/kern_levels.h:5:25: error: format '%lu' expects argument of type 'long unsigned int', but argument 2 has type 'unsigned int' [-Werror=format=]
5 | #define KERN_SOH "\001" /* ASCII Start Of Header */
| ^~~~~~
./include/linux/printk.h:422:25: note: in definition of macro 'printk_index_wrap'
422 | _p_func(_fmt, ##__VA_ARGS__); \
| ^~~~
./include/linux/printk.h:132:17: note: in expansion of macro 'printk'
132 | printk(fmt, ##__VA_ARGS__); \
| ^~~~~~
./include/linux/printk.h:580:9: note: in expansion of macro 'no_printk'
580 | no_printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~
./include/linux/kern_levels.h:15:25: note: in expansion of macro 'KERN_SOH'
15 | #define KERN_DEBUG KERN_SOH "7" /* debug-level messages */
| ^~~~~~~~
./include/linux/printk.h:580:19: note: in expansion of macro 'KERN_DEBUG'
580 | no_printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~~
drivers/staging/fsl_ppfe/pfe_cdev.c:57:9: note: in expansion of macro 'pr_debug'
57 | pr_debug("Read of (%lu) bytes performed.\n", sizeof(link_states));
| ^~~~~~~~
cc1: all warnings being treated as errors
In file included from ./include/uapi/linux/posix_types.h:5,
from ./include/uapi/linux/types.h:14,
from ./include/linux/types.h:6,
from ./include/linux/list.h:5,
from ./include/linux/module.h:12,
from drivers/staging/fsl_ppfe/pfe_sysfs.c:7:
drivers/staging/fsl_ppfe/pfe_sysfs.c: In function 'pfe_set_util':
./include/linux/stddef.h:8:14: error: passing argument 2 of 'kstrtoul' makes integer from pointer without a cast [-Werror=int-conversion]
8 | #define NULL ((void *)0)
| ^~~~~~~~~~~
| |
| void *
drivers/staging/fsl_ppfe/pfe_sysfs.c:538:39: note: in expansion of macro 'NULL'
538 | util_do_clear = kstrtoul(buf, NULL, 0);
| ^~~~
In file included from ./include/linux/kernel.h:13,
from ./include/linux/list.h:9:
./include/linux/kstrtox.h:30:69: note: expected 'unsigned int' but argument is of type 'void *'
30 | static inline int __must_check kstrtoul(const char *s, unsigned int base, unsigned long *res)
| ~~~~~~~~~~~~~^~~~
cc1: all warnings being treated as errors
With UTIL compiled on, fix compilation warning:
drivers/staging/fsl_ppfe/pfe_hal.c: In function 'pe_load_ddr_section':
drivers/staging/fsl_ppfe/pfe_hal.c:617:19: error: 'else' without a previous 'if'
617 | } else {
| ^~~~
drivers/staging/fsl_ppfe/pfe_hal.c:622:17: error: break statement not within loop or switch
622 | break;
| ^~~~~
drivers/staging/fsl_ppfe/pfe_hal.c:624:9: error: case label not within a switch statement
624 | case SHT_NOBITS:
| ^~~~
drivers/staging/fsl_ppfe/pfe_hal.c:627:17: error: break statement not within loop or switch
627 | break;
| ^~~~~
drivers/staging/fsl_ppfe/pfe_hal.c:629:9: error: 'default' label not within a switch statement
629 | default:
| ^~~~~~~
drivers/staging/fsl_ppfe/pfe_hal.c: At top level:
drivers/staging/fsl_ppfe/pfe_hal.c:635:9: error: expected identifier or '(' before 'return'
635 | return 0;
| ^~~~~~
drivers/staging/fsl_ppfe/pfe_hal.c:636:1: error: expected identifier or '(' before '}' token
636 | }
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
Fix compilation warning for PHY_INTERFACE_MODE_2500SGMII patch.
Fix compilation warning:
drivers/net/phy/phylink.c: In function 'phylink_get_linkmodes':
drivers/net/phy/phylink.c:360:9: error: enumeration value 'PHY_INTERFACE_MODE_2500SGMII' not handled in switch [-Werror=switch]
360 | switch (interface) {
| ^~~~~~
cc1: all warnings being treated as errors
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
Fix following error when building 32bit arm targets with kmod-crypto-sha512
ERROR: module '/home/user/openwrt/build_dir/target-arm_xscale_musl_eabi/linux-kirkwood_generic/linux-5.15.109/arch/arm/crypto/sha512-arm.ko' is missing.
Signed-off-by: Lu jicong <jiconglu58@gmail.com>
Add support for NXP LS1028ARDB reference board. It's a dual core
Coretex-A53 board with 4G RAM and 5 Eternet ports (4 ports are
connected to MSCC Felix switch).
The original layout of NXP board has been kept but firmware
images are adapted to be more sysupgrade friendly. At the moment
NOR and SD boots are supported.
NOR flash instructions:
* make sd card with sdboot image
* boot
* write firmware image to spi flash
$ mtd write /tmp/openwrt-layerscape-armv8_64b-fsl_ls1028a-rdb-
squashfs-firmware.bin /dev/mtd0
* change jumper to NOR boot and reset
V3:
* Added board specific network defaults for lan/wan
v2:
* Added INA220 curent monitor, PCF2129 RTC clock and NXP
SA56004ED temperature sensor to default packages
* removed compat fixups for thist board
Signed-off-by: Wojciech Dubowik <Wojciech.Dubowik@protonmail.ch>
The kernel configuration option is now available on kernel 5.10 and
5.15, add it to the config for 5.15 too.
Fixes: 8dfe69cdfc ("kernel: update nvmem subsystem to the latest upstream")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
This converts the trusted firmware arm build Makefile to make use of
the common trusted-firmware-a.mk file. This also fixes the build with
binutils 2.39.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
In 8274451cb86 kmod-ppfe was changed to built-in because CONFIG_FSL_PPFE
was binary. In 5.10 and 5.15 kernel, PPFE driver can be build as module.
This patch switch kmod-ppfe from build-in to loadable module.
Loadable module helps to avoid hazard: driver is looking for firmware
file before mount root.
Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
Let's test layerscape with 5.15 kernel.
Run tested: LS1012A-FRDM, LS1046A-RDB (nor and sd-boot images),
LS1021A-IOT (By @ArtelMike with u-boot fix)
Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
At this moment LS1012A-FRDM have uncompressed initramfs image.
Error was caused, because gzip extract area overlap image.
Let's change loadaddr and enable gzip initramfs images again.
Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
For some reason LS1012A and LS1046A devboards don't work well with
Spansion SPI NOR flash. It cause read and write errors like:
[ 27.285887] jffs2: Newly-erased block contained word 0xc20031985 at offset 0x025ae000
[ 27.468922] jffs2: Newly-erased block contained word 0x0 at offset 0x02573000
[ 27.502615] jffs2: Newly-erased block contained word 0xe723f41e5823f110 at offset 0x02572000
[ 27.541550] jffs2: Newly-erased block contained word 0x1a7d266ee6 at offset 0x02571000
[ 27.577195] jffs2: Newly-erased block contained word 0x5d000bae8d52fec6 at offset 0x02570000
[ 27.611800] jffs2: Newly-erased block contained word 0x63515aee63515a4b at offset 0x0256f000
[ 27.651749] jffs2: Newly-erased block contained word 0xc20031985 at offset 0x0256e000
[ 27.825593] jffs2: Newly-erased block contained word 0xc20031985 at offset 0x0252e000
NXP have found workarround and applied in their vendor kernel version.
They force 1x tx and 1x rx lines in qspi. That method fix issues.
This patch ports patches from NXP LSDK tree.
Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>