Skip to contentSkip to conversation

s390x/s390-virtio-ccw: Reset PCI devices during subsystem reset

PATCH Applied Matthew Rosato 5 participants 7 messages Oct 15, 2020 – Oct 20, 2020

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 s390x/s390-virtio-ccw: Reset PCI devices during subsystem reset

Currently, a subsystem reset event leaves PCI devices enabled, causing issues post-reset in the guest (an example would be after a kexec). These devices need to be reset during a subsystem reset, allowing them to be properly re-enabled afterwards. Add the S390 PCI host bridge to the list of qdevs to be reset during subsystem reset.

---
 hw/s390x/s390-virtio-ccw.c | 1 +
 1 file changed, 1 insertion(+)
hw/s390x/s390-virtio-ccw.c +1 -0
index e52182f..2e90033 100644
@@ -101,6 +101,7 @@ static const char *const reset_dev_types[] = {
     "s390-sclp-event-facility",
     "s390-flic",
     "diag288",
+    TYPE_S390_PCI_HOST_BRIDGE,
 };
 
 static void subsystem_reset(void)
Signature · 1 line
1.8.3.1
Acked-by on v1 1/1
#1 lore raw
Quoted 8 lines · Matthew Rosato

Currently, a subsystem reset event leaves PCI devices enabled, causing issues post-reset in the guest (an example would be after a kexec). These devices need to be reset during a subsystem reset, allowing them to be properly re-enabled afterwards. Add the S390 PCI host bridge to the list of qdevs to be reset during subsystem reset.

Makese sense.

Quoted 17 lines
---
 hw/s390x/s390-virtio-ccw.c | 1 +
 1 file changed, 1 insertion(+)
hw/s390x/s390-virtio-ccw.c +1 -0
index e52182f..2e90033 100644
@@ -101,6 +101,7 @@ static const char *const reset_dev_types[] = {
     "s390-sclp-event-facility",
     "s390-flic",
     "diag288",
+    TYPE_S390_PCI_HOST_BRIDGE,
 };
 
 static void subsystem_reset(void)
#2 lore raw
Quoted 9 lines · Christian Borntraeger
Quoted 6 lines · Matthew Rosato

Currently, a subsystem reset event leaves PCI devices enabled, causing issues post-reset in the guest (an example would be after a kexec). These devices need to be reset during a subsystem reset, allowing them to be properly re-enabled afterwards. Add the S390 PCI host bridge to the list of qdevs to be reset during subsystem reset.

Quoted 5 lines
Quoted 2 lines

Makese sense.

A question. Is this a stable candidate?

Quoted 19 lines
Quoted 19 lines

---
 hw/s390x/s390-virtio-ccw.c | 1 +
 1 file changed, 1 insertion(+)
hw/s390x/s390-virtio-ccw.c +1 -0
index e52182f..2e90033 100644
@@ -101,6 +101,7 @@ static const char *const reset_dev_types[] = {
     "s390-sclp-event-facility",
     "s390-flic",
     "diag288",
+    TYPE_S390_PCI_HOST_BRIDGE,
 };
 
 static void subsystem_reset(void)
#3 lore raw
Quoted 12 lines · Christian Borntraeger
Quoted 9 lines · Christian Borntraeger
Quoted 6 lines · Matthew Rosato

Currently, a subsystem reset event leaves PCI devices enabled, causing issues post-reset in the guest (an example would be after a kexec). These devices need to be reset during a subsystem reset, allowing them to be properly re-enabled afterwards. Add the S390 PCI host bridge to the list of qdevs to be reset during subsystem reset.

Quoted 7 lines
Quoted 5 lines
Quoted 2 lines

Makese sense.

A question. Is this a stable candidate?

As this can prevent a SUSE guest (which does kexec during boot because of grub) from seeing any PCI devices I'd say yes.

Quoted 20 lines
Quoted 20 lines
Quoted 20 lines


---
 hw/s390x/s390-virtio-ccw.c | 1 +
 1 file changed, 1 insertion(+)
hw/s390x/s390-virtio-ccw.c +1 -0
index e52182f..2e90033 100644
@@ -101,6 +101,7 @@ static const char *const reset_dev_types[] = {
     "s390-sclp-event-facility",
     "s390-flic",
     "diag288",
+    TYPE_S390_PCI_HOST_BRIDGE,
 };
 
 static void subsystem_reset(void)
#4 lore raw
Quoted 18 lines · Niklas Schnelle
Quoted 15 lines · Christian Borntraeger
Quoted 12 lines · Christian Borntraeger
Quoted 8 lines · Matthew Rosato

Currently, a subsystem reset event leaves PCI devices enabled, causing issues post-reset in the guest (an example would be after a kexec). These devices need to be reset during a subsystem reset, allowing them to be properly re-enabled afterwards. Add the S390 PCI host bridge to the list of qdevs to be reset during subsystem reset.

Quoted 8 lines
Quoted 4 lines
Quoted 2 lines

Makese sense.

A question. Is this a stable candidate?

As this can prevent a SUSE guest (which does kexec during boot because of grub) from seeing any PCI devices I'd say yes.

Yes, agreed.

Quoted 20 lines
Quoted 20 lines
Quoted 20 lines
Quoted 20 lines


---
  hw/s390x/s390-virtio-ccw.c | 1 +
  1 file changed, 1 insertion(+)
hw/s390x/s390-virtio-ccw.c +1 -0
index e52182f..2e90033 100644
@@ -101,6 +101,7 @@ static const char *const reset_dev_types[] = {
      "s390-sclp-event-facility",
      "s390-flic",
      "diag288",
+    TYPE_S390_PCI_HOST_BRIDGE,
  };
 
  static void subsystem_reset(void)
Acked-by on v1 1/1
#5 lore raw
In reply to Matthew Rosato
Quoted 8 lines · On Thu, 15 Oct 2020 09:16:07 -0400 Matthew Rosato <[email protected]>…

Currently, a subsystem reset event leaves PCI devices enabled, causing issues post-reset in the guest (an example would be after a kexec). These devices need to be reset during a subsystem reset, allowing them to be properly re-enabled afterwards. Add the S390 PCI host bridge to the list of qdevs to be reset during subsystem reset.

Quoted 16 lines
---
 hw/s390x/s390-virtio-ccw.c | 1 +
 1 file changed, 1 insertion(+)
hw/s390x/s390-virtio-ccw.c +1 -0
index e52182f..2e90033 100644
@@ -101,6 +101,7 @@ static const char *const reset_dev_types[] = {
     "s390-sclp-event-facility",
     "s390-flic",
     "diag288",
+    TYPE_S390_PCI_HOST_BRIDGE,
 };
 
 static void subsystem_reset(void)
#6 lore raw
In reply to Matthew Rosato
Quoted 17 lines · On Thu, 15 Oct 2020 09:16:07 -0400 Matthew Rosato <[email protected]>…

Currently, a subsystem reset event leaves PCI devices enabled, causing issues post-reset in the guest (an example would be after a kexec). These devices need to be reset during a subsystem reset, allowing them to be properly re-enabled afterwards. Add the S390 PCI host bridge to the list of qdevs to be reset during subsystem reset.

---
 hw/s390x/s390-virtio-ccw.c | 1 +
 1 file changed, 1 insertion(+)
hw/s390x/s390-virtio-ccw.c +0 -0
index e52182f..2e90033 100644

hw/s390x/s390-virtio-ccw.c static const char *const reset_dev_types[] = { · line 107

Quoted 7 lines
hw/s390x/s390-virtio-ccw.c +1 -0
@@ -101,6 +101,7 @@ static const char *const reset_dev_types[] = {
     "s390-sclp-event-facility",
     "s390-flic",
     "diag288",
+    TYPE_S390_PCI_HOST_BRIDGE,
 };
 
 static void subsystem_reset(void)

Thanks, applied (with cc:stable added.)