Home Home > GIT Browse > openSUSE-42.3
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichal Kubecek <mkubecek@suse.cz>2018-02-01 20:28:26 +0100
committerMichal Kubecek <mkubecek@suse.cz>2018-02-01 20:28:26 +0100
commit4309ff9db7b7bfbfab5c72b8102147f4d24c63a6 (patch)
tree52a11c7785d490904fe5f20a3034ee79856b1792
parent09e0d6046b29fee2748f15fa5849dd72c69dd072 (diff)
parentd99ea183cf3b15726cecc91b5601db6fd100e1fa (diff)
Merge branch 'users/msuchanek/SLE12-SP3/for-next' into users/mkubecek/SLE12-SP3/for-nextrpm-4.4.114-94.11
Pull ppc64le fixes from Michal Suchanek.
-rw-r--r--patches.drivers/ibmvnic-Wait-for-device-response-when-changing-MAC.patch103
-rw-r--r--patches.suse/powerpc-pseries-rfi-flush-Call-setup_rfi_flush-after.patch18
-rw-r--r--series.conf1
3 files changed, 115 insertions, 7 deletions
diff --git a/patches.drivers/ibmvnic-Wait-for-device-response-when-changing-MAC.patch b/patches.drivers/ibmvnic-Wait-for-device-response-when-changing-MAC.patch
new file mode 100644
index 0000000000..d3a858163d
--- /dev/null
+++ b/patches.drivers/ibmvnic-Wait-for-device-response-when-changing-MAC.patch
@@ -0,0 +1,103 @@
+From f813614f531114db796ad66ced75c5dc8db7aa3a Mon Sep 17 00:00:00 2001
+From: Thomas Falcon <tlfalcon@linux.vnet.ibm.com>
+Date: Mon, 29 Jan 2018 13:45:05 -0600
+Subject: [PATCH] ibmvnic: Wait for device response when changing MAC
+
+References: bsc#1078681
+Patch-mainline: v4.16-rc1
+Git-commit: f813614f531114db796ad66ced75c5dc8db7aa3a
+
+Wait for a response from the VNIC server before exiting after setting
+the MAC address. The resolves an issue with bonding a VNIC client in
+ALB or TLB modes. The bonding driver was changing the MAC address more
+rapidly than the device could respond, causing the following errors.
+
+"bond0: the hw address of slave eth2 is in use by the bond;
+couldn't find a slave with a free hw address to give it
+(this should not have happened)"
+
+If the function waits until the change is finalized, these errors are
+avoided.
+
+Signed-off-by: Thomas Falcon <tlfalcon@linux.vnet.ibm.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Acked-by: Michal Suchanek <msuchanek@suse.de>
+---
+ drivers/net/ethernet/ibm/ibmvnic.c | 21 ++++++++++++++-------
+ 1 file changed, 14 insertions(+), 7 deletions(-)
+
+diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/ibm/ibmvnic.c
+index 8f2a77ecf4fb..8c3058d5d191 100644
+--- a/drivers/net/ethernet/ibm/ibmvnic.c
++++ b/drivers/net/ethernet/ibm/ibmvnic.c
+@@ -1548,15 +1548,19 @@ static int __ibmvnic_set_mac(struct net_device *netdev, struct sockaddr *p)
+ crq.change_mac_addr.first = IBMVNIC_CRQ_CMD;
+ crq.change_mac_addr.cmd = CHANGE_MAC_ADDR;
+ ether_addr_copy(&crq.change_mac_addr.mac_addr[0], addr->sa_data);
++
++ init_completion(&adapter->fw_done);
+ ibmvnic_send_crq(adapter, &crq);
++ wait_for_completion(&adapter->fw_done);
+ /* netdev->dev_addr is changed in handle_change_mac_rsp function */
+- return 0;
++ return adapter->fw_done_rc ? -EIO : 0;
+ }
+
+ static int ibmvnic_set_mac(struct net_device *netdev, void *p)
+ {
+ struct ibmvnic_adapter *adapter = netdev_priv(netdev);
+ struct sockaddr *addr = p;
++ int rc;
+
+ if (adapter->state == VNIC_PROBED) {
+ memcpy(&adapter->desired.mac, addr, sizeof(struct sockaddr));
+@@ -1564,9 +1568,9 @@ static int ibmvnic_set_mac(struct net_device *netdev, void *p)
+ return 0;
+ }
+
+- __ibmvnic_set_mac(netdev, addr);
++ rc = __ibmvnic_set_mac(netdev, addr);
+
+- return 0;
++ return rc;
+ }
+
+ /**
+@@ -3569,8 +3573,8 @@ static void handle_error_indication(union ibmvnic_crq *crq,
+ ibmvnic_reset(adapter, VNIC_RESET_NON_FATAL);
+ }
+
+-static void handle_change_mac_rsp(union ibmvnic_crq *crq,
+- struct ibmvnic_adapter *adapter)
++static int handle_change_mac_rsp(union ibmvnic_crq *crq,
++ struct ibmvnic_adapter *adapter)
+ {
+ struct net_device *netdev = adapter->netdev;
+ struct device *dev = &adapter->vdev->dev;
+@@ -3579,10 +3583,13 @@ static void handle_change_mac_rsp(union ibmvnic_crq *crq,
+ rc = crq->change_mac_addr_rsp.rc.code;
+ if (rc) {
+ dev_err(dev, "Error %ld in CHANGE_MAC_ADDR_RSP\n", rc);
+- return;
++ goto out;
+ }
+ memcpy(netdev->dev_addr, &crq->change_mac_addr_rsp.mac_addr[0],
+ ETH_ALEN);
++out:
++ complete(&adapter->fw_done);
++ return rc;
+ }
+
+ static void handle_request_cap_rsp(union ibmvnic_crq *crq,
+@@ -4042,7 +4049,7 @@ static void ibmvnic_handle_crq(union ibmvnic_crq *crq,
+ break;
+ case CHANGE_MAC_ADDR_RSP:
+ netdev_dbg(netdev, "Got MAC address change Response\n");
+- handle_change_mac_rsp(crq, adapter);
++ adapter->fw_done_rc = handle_change_mac_rsp(crq, adapter);
+ break;
+ case ERROR_INDICATION:
+ netdev_dbg(netdev, "Got Error Indication\n");
+--
+2.13.6
+
diff --git a/patches.suse/powerpc-pseries-rfi-flush-Call-setup_rfi_flush-after.patch b/patches.suse/powerpc-pseries-rfi-flush-Call-setup_rfi_flush-after.patch
index b8e1573d0a..131117b874 100644
--- a/patches.suse/powerpc-pseries-rfi-flush-Call-setup_rfi_flush-after.patch
+++ b/patches.suse/powerpc-pseries-rfi-flush-Call-setup_rfi_flush-after.patch
@@ -1,8 +1,8 @@
-From 50f7ad602d40fcad9d501dc20198083005f876e4 Mon Sep 17 00:00:00 2001
+From 2470dca4aa4029f53ad9b1b746b676898c80efe5 Mon Sep 17 00:00:00 2001
From: Michal Suchanek <msuchanek@suse.de>
Date: Thu, 11 Jan 2018 14:43:07 +0100
-Subject: [PATCH 16/19] powerpc/pseries: rfi-flush: Call setup_rfi_flush()
- after LPM migration
+Subject: [PATCH] powerpc/pseries: rfi-flush: Call setup_rfi_flush() after LPM
+ migration
References: bsc#1068032, bsc#1075087
Patch-mainline: no, under development
@@ -15,11 +15,11 @@ Signed-off-by: Ram Pai <linuxram@us.ibm.com>
Signed-off-by: Michal Suchanek <msuchanek@suse.de>
---
arch/powerpc/include/asm/setup.h | 2 +-
- arch/powerpc/kernel/setup_64.c | 32 +++++++++++++++++++++++++++----
+ arch/powerpc/kernel/setup_64.c | 34 +++++++++++++++++++++++++++----
arch/powerpc/platforms/pseries/mobility.c | 3 +++
arch/powerpc/platforms/pseries/pseries.h | 2 ++
arch/powerpc/platforms/pseries/setup.c | 2 +-
- 5 files changed, 35 insertions(+), 6 deletions(-)
+ 5 files changed, 37 insertions(+), 6 deletions(-)
diff --git a/arch/powerpc/include/asm/setup.h b/arch/powerpc/include/asm/setup.h
index 7916b56f2e60..3733195be997 100644
@@ -35,7 +35,7 @@ index 7916b56f2e60..3733195be997 100644
#endif /* !__ASSEMBLY__ */
diff --git a/arch/powerpc/kernel/setup_64.c b/arch/powerpc/kernel/setup_64.c
-index eca171f34036..468e215ed44b 100644
+index eca171f34036..31914b06f193 100644
--- a/arch/powerpc/kernel/setup_64.c
+++ b/arch/powerpc/kernel/setup_64.c
@@ -893,11 +893,24 @@ void rfi_flush_enable(bool enable)
@@ -64,8 +64,12 @@ index eca171f34036..468e215ed44b 100644
l1d_size = ppc64_caches.dsize;
limit = min(safe_stack_limit(), ppc64_rma_size);
-@@ -927,11 +940,22 @@ static void init_fallback_flush(void)
+@@ -925,13 +938,26 @@ static void init_fallback_flush(void)
+ paca_aux->l1d_flush_congruence = c;
+ paca_aux->l1d_flush_sets = c / 128;
}
++
++ return true;
}
-void __init setup_rfi_flush(enum l1d_flush_type types, bool enable)
diff --git a/series.conf b/series.conf
index 0178500414..f0f9462c66 100644
--- a/series.conf
+++ b/series.conf
@@ -13561,6 +13561,7 @@
patches.drivers/ibmvnic-Increase-maximum-number-of-RX-TX-queues.patch
patches.drivers/ibmvnic-Include-header-descriptor-support-for-ARP-pa.patch
patches.drivers/ibmvnic-Don-t-handle-RX-interrupts-when-not-up.patch
+ patches.drivers/ibmvnic-Wait-for-device-response-when-changing-MAC.patch
# out-of-tree patches
patches.drivers/0002-hns-set-relation-between-hns_roce-and-hns_enet_drv.patch