aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/octeon/patches-5.4/110-er200-ethernet_probe_order.patch
diff options
context:
space:
mode:
authorDaniel Engberg <daniel.engberg.lists@pyret.net>2020-04-17 21:53:14 +0200
committerAdrian Schmutzler <freifunk@adrianschmutzler.de>2020-04-23 18:38:19 +0200
commit91594cb137154c2936853f293db1da19d125d28c (patch)
treefb241da5c7521047a9992cbebdff78ec945f4564 /target/linux/octeon/patches-5.4/110-er200-ethernet_probe_order.patch
parentdf27e949fbbf13e1e2ab4db49f608165ef0ba9fe (diff)
downloadupstream-91594cb137154c2936853f293db1da19d125d28c.tar.gz
upstream-91594cb137154c2936853f293db1da19d125d28c.tar.bz2
upstream-91594cb137154c2936853f293db1da19d125d28c.zip
octeon: copy files to kernel 5.4
Copy config and patches to kernel 5.4. Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net> [split patch, fix patches-5.4 dirname, add description] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Diffstat (limited to 'target/linux/octeon/patches-5.4/110-er200-ethernet_probe_order.patch')
-rw-r--r--target/linux/octeon/patches-5.4/110-er200-ethernet_probe_order.patch34
1 files changed, 34 insertions, 0 deletions
diff --git a/target/linux/octeon/patches-5.4/110-er200-ethernet_probe_order.patch b/target/linux/octeon/patches-5.4/110-er200-ethernet_probe_order.patch
new file mode 100644
index 0000000000..93d1e93505
--- /dev/null
+++ b/target/linux/octeon/patches-5.4/110-er200-ethernet_probe_order.patch
@@ -0,0 +1,34 @@
+--- a/drivers/staging/octeon/ethernet.c
++++ b/drivers/staging/octeon/ethernet.c
+@@ -670,6 +670,7 @@ static int cvm_oct_probe(struct platform
+ int interface;
+ int fau = FAU_NUM_PACKET_BUFFERS_TO_FREE;
+ int qos;
++ int i;
+ struct device_node *pip;
+ int mtu_overhead = ETH_HLEN + ETH_FCS_LEN;
+
+@@ -793,13 +794,19 @@ static int cvm_oct_probe(struct platform
+ }
+
+ num_interfaces = cvmx_helper_get_number_of_interfaces();
+- for (interface = 0; interface < num_interfaces; interface++) {
+- cvmx_helper_interface_mode_t imode =
+- cvmx_helper_interface_get_mode(interface);
+- int num_ports = cvmx_helper_ports_on_interface(interface);
++ for (i = 0; i < num_interfaces; i++) {
++ cvmx_helper_interface_mode_t imode;
++ int interface;
++ int num_ports;
+ int port;
+ int port_index;
+
++ interface = i;
++ if (cvmx_sysinfo_get()->board_type == CVMX_BOARD_TYPE_UBNT_E200)
++ interface = num_interfaces - (i + 1);
++
++ num_ports = cvmx_helper_ports_on_interface(interface);
++ imode = cvmx_helper_interface_get_mode(interface);
+ for (port_index = 0,
+ port = cvmx_helper_get_ipd_port(interface, 0);
+ port < cvmx_helper_get_ipd_port(interface, num_ports);