|
|
dc1fe0 |
From 0a200d937e63554c38db577961ef4f09c836cb2f Mon Sep 17 00:00:00 2001
|
|
|
dc1fe0 |
From: Igor Mammedov <imammedo@redhat.com>
|
|
|
dc1fe0 |
Date: Tue, 1 Mar 2022 10:11:58 -0500
|
|
|
dc1fe0 |
Subject: [PATCH 01/14] pci: expose TYPE_XIO3130_DOWNSTREAM name
|
|
|
dc1fe0 |
|
|
|
dc1fe0 |
RH-Author: Igor Mammedov <imammedo@redhat.com>
|
|
|
dc1fe0 |
RH-MergeRequest: 124: RHEL-9.0 Fix broken PCIe device after migration
|
|
|
dc1fe0 |
RH-Commit: [1/2] 38a5fef15d0b6c231b5ac268aad7d541e5303a7e
|
|
|
dc1fe0 |
RH-Bugzilla: 2053584
|
|
|
dc1fe0 |
RH-Acked-by: Vitaly Kuznetsov <vkuznets@redhat.com>
|
|
|
dc1fe0 |
RH-Acked-by: MST <None>
|
|
|
dc1fe0 |
RH-Acked-by: Gerd Hoffmann <kraxel@redhat.com>
|
|
|
dc1fe0 |
|
|
|
dc1fe0 |
Type name will be used in followup patch for cast check
|
|
|
dc1fe0 |
in pcihp code.
|
|
|
dc1fe0 |
|
|
|
dc1fe0 |
Signed-off-by: Igor Mammedov <imammedo@redhat.com>
|
|
|
dc1fe0 |
Message-Id: <20220301151200.3507298-2-imammedo@redhat.com>
|
|
|
dc1fe0 |
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
|
|
|
dc1fe0 |
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
|
|
|
dc1fe0 |
(cherry picked from commit c41481af9a5d0d463607cc45b45c510875570817)
|
|
|
dc1fe0 |
Signed-off-by: Igor Mammedov <imammedo@redhat.com>
|
|
|
dc1fe0 |
---
|
|
|
dc1fe0 |
hw/pci-bridge/xio3130_downstream.c | 3 ++-
|
|
|
dc1fe0 |
include/hw/pci-bridge/xio3130_downstream.h | 15 +++++++++++++++
|
|
|
dc1fe0 |
2 files changed, 17 insertions(+), 1 deletion(-)
|
|
|
dc1fe0 |
create mode 100644 include/hw/pci-bridge/xio3130_downstream.h
|
|
|
dc1fe0 |
|
|
|
dc1fe0 |
diff --git a/hw/pci-bridge/xio3130_downstream.c b/hw/pci-bridge/xio3130_downstream.c
|
|
|
dc1fe0 |
index 04aae72cd6..b17cafd359 100644
|
|
|
dc1fe0 |
--- a/hw/pci-bridge/xio3130_downstream.c
|
|
|
dc1fe0 |
+++ b/hw/pci-bridge/xio3130_downstream.c
|
|
|
dc1fe0 |
@@ -28,6 +28,7 @@
|
|
|
dc1fe0 |
#include "migration/vmstate.h"
|
|
|
dc1fe0 |
#include "qapi/error.h"
|
|
|
dc1fe0 |
#include "qemu/module.h"
|
|
|
dc1fe0 |
+#include "hw/pci-bridge/xio3130_downstream.h"
|
|
|
dc1fe0 |
|
|
|
dc1fe0 |
#define PCI_DEVICE_ID_TI_XIO3130D 0x8233 /* downstream port */
|
|
|
dc1fe0 |
#define XIO3130_REVISION 0x1
|
|
|
dc1fe0 |
@@ -173,7 +174,7 @@ static void xio3130_downstream_class_init(ObjectClass *klass, void *data)
|
|
|
dc1fe0 |
}
|
|
|
dc1fe0 |
|
|
|
dc1fe0 |
static const TypeInfo xio3130_downstream_info = {
|
|
|
dc1fe0 |
- .name = "xio3130-downstream",
|
|
|
dc1fe0 |
+ .name = TYPE_XIO3130_DOWNSTREAM,
|
|
|
dc1fe0 |
.parent = TYPE_PCIE_SLOT,
|
|
|
dc1fe0 |
.class_init = xio3130_downstream_class_init,
|
|
|
dc1fe0 |
.interfaces = (InterfaceInfo[]) {
|
|
|
dc1fe0 |
diff --git a/include/hw/pci-bridge/xio3130_downstream.h b/include/hw/pci-bridge/xio3130_downstream.h
|
|
|
dc1fe0 |
new file mode 100644
|
|
|
dc1fe0 |
index 0000000000..1d10139aea
|
|
|
dc1fe0 |
--- /dev/null
|
|
|
dc1fe0 |
+++ b/include/hw/pci-bridge/xio3130_downstream.h
|
|
|
dc1fe0 |
@@ -0,0 +1,15 @@
|
|
|
dc1fe0 |
+/*
|
|
|
dc1fe0 |
+ * TI X3130 pci express downstream port switch
|
|
|
dc1fe0 |
+ *
|
|
|
dc1fe0 |
+ * Copyright (C) 2022 Igor Mammedov <imammedo@redhat.com>
|
|
|
dc1fe0 |
+ *
|
|
|
dc1fe0 |
+ * SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
dc1fe0 |
+ */
|
|
|
dc1fe0 |
+
|
|
|
dc1fe0 |
+#ifndef HW_PCI_BRIDGE_XIO3130_DOWNSTREAM_H
|
|
|
dc1fe0 |
+#define HW_PCI_BRIDGE_XIO3130_DOWNSTREAM_H
|
|
|
dc1fe0 |
+
|
|
|
dc1fe0 |
+#define TYPE_XIO3130_DOWNSTREAM "xio3130-downstream"
|
|
|
dc1fe0 |
+
|
|
|
dc1fe0 |
+#endif
|
|
|
dc1fe0 |
+
|
|
|
dc1fe0 |
--
|
|
|
dc1fe0 |
2.31.1
|
|
|
dc1fe0 |
|