Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package xen for openSUSE:Factory checked in 
at 2025-03-06 14:47:58
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/xen (Old)
 and      /work/SRC/openSUSE:Factory/.xen.new.19136 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "xen"

Thu Mar  6 14:47:58 2025 rev:361 rq:1250427 version:4.20.0_08

Changes:
--------
--- /work/SRC/openSUSE:Factory/xen/xen.changes  2025-02-21 21:35:22.385753968 
+0100
+++ /work/SRC/openSUSE:Factory/.xen.new.19136/xen.changes       2025-03-06 
14:48:04.371789375 +0100
@@ -1,0 +2,15 @@
+Wed Mar  5 06:18:13 MST 2025 - carn...@suse.com
+
+- Update to Xen 4.20.0 FCS release (jsc#PED-8907)
+  * See release candidate changelog entries below for 4.20.0
+  * Reduce xenstore library dependencies.
+  * Enable CONFIG_UBSAN (Arm64, x86, PPC, RISC-V) for GitLab CI.
+  * Support for Intel EPT Paging-Write Feature.
+  * AMD Zen 5 CPU support, including for new hardware mitigations
+    for the SRSO speculative vulnerability.
+- bsc#1238043 - VUL-0: CVE-2025-1713: xen: deadlock potential with
+  VT-d and legacy PCI device pass-through (XSA-467)
+  This fix is part of the final tarball
+- Remove references to vm-install from README.SUSE
+
+-------------------------------------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ README.SUSE ++++++
--- /var/tmp/diff_new_pack.6sfMBO/_old  2025-03-06 14:48:06.239867716 +0100
+++ /var/tmp/diff_new_pack.6sfMBO/_new  2025-03-06 14:48:06.255868386 +0100
@@ -32,7 +32,6 @@
   virt-install     (Optional, to install VMs)
   virt-manager     (Optional, to manage VMs graphically)
   virt-viewer      (Optional, to view VMs outside virt-manager)
-  vm-install       (Optional, to install VMs with xl only)
 
 You then need to reboot your machine.  Instead of booting a normal Linux
 kernel, you will boot the Xen hypervisor and a slightly changed Linux kernel.
@@ -174,35 +173,6 @@
 supports it.
 
 
-Creating a VM with vm-install
------------------------------
-The vm-install program is also provided to create VMs.  Like virt-install,
-this optional program handles creating both the VM's libvirt XML definition
-and disk(s).  It also creates a legacy configuration file for use with 'xl'.
-It can help install any operating system, not just SUSE.
-
-From the command line, run "vm-install".  If the DISPLAY environment variable
-is set and the supporting packages (python-gtk) are installed, a graphical
-wizard will start.  Otherwise, a text wizard will start.  If vm-install is
-started with the '--use-xl' flag, it will not require libvirt nor attempt
-to communicate with libvirt when creating a VM and instead will only use the
-'xl' toolstack to start VM installations.
-
-Once you have the VM configured, click "OK".  The wizard will now create a
-configuration file for the VM, and create a disk image.  The disk image will
-exist in /var/lib/xen/images, and a corresponding configuration file will exist
-in /etc/xen/vm.  The operating system's installation program will then run
-within the VM.
-
-When the VM shuts down (because the installation -- or at least the first
-stage of it -- is done), the wizard finalizes the VM's configuration and
-restarts the VM.
-
-The creation of VMs can be automated; read the vm-install man page for more
-details.  The installation of an OS within the VM can be automated if the OS
-supports it.
-
-
 Creating a VM Manually
 ----------------------
 If you create a VM manually (as opposed to using virt-install, which is the
@@ -231,11 +201,11 @@
 -------------------------
 VMs can be managed from the command line using 'virsh' or from virt-manager.
 
-VMs created by virt-install or vm-install (without vm-install's --use-xl flag)
-will automatically be defined in libvirt.  VMs defined in libvirt may be 
managed
-by virt-manager or from the command line using the 'virsh' command.  However,
-if you copy a VM from another machine and manually create a VM XML 
configuration
-file, you will need to import it into libvirt with a command like:
+VMs created by virt-install will automatically be defined in libvirt.  VMs
+defined in libvirt may be managed by virt-manager or from the command line
+using the 'virsh' command.  However, if you copy a VM from another machine
+and manually create a VM XML configuration file, you will need to import it
+into libvirt with a command like:
   virsh define <path to>/my-vm.xml
 This imports the configuration into libvirt (and therefore virt-manager becomes
 aware of it, also).

++++++ xen-4.20.0-testing-src.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/CHANGELOG.md 
new/xen-4.20.0-testing/CHANGELOG.md
--- old/xen-4.20.0-testing/CHANGELOG.md 2025-02-20 18:09:14.000000000 +0100
+++ new/xen-4.20.0-testing/CHANGELOG.md 2025-03-05 14:17:46.000000000 +0100
@@ -4,12 +4,17 @@
 
 The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
 
-## [4.20.0 
UNRELEASED](https://xenbits.xenproject.org/gitweb/?p=xen.git;a=shortlog;h=staging)
 - TBD
+## 
[4.20.0](https://xenbits.xenproject.org/gitweb/?p=xen.git;a=shortlog;h=RELEASE-4.20.0)
 - 2025-03-05
 
 ### Changed
  - Fixed blkif protocol specification for sector sizes different than 512b.
  - The dombuilder in libxenguest no longer un-gzips secondary modules, instead
    leaving this to the guest kernel to do in guest context.
+ - Reduce xenstore library dependencies.
+ - On Arm:
+   - Several FF-A support improvements: add indirect messages support, transmit
+     RXTX buffer to the SPMC, fix version negotication and partition 
information
+     retrieval.
  - On x86:
    - Prefer ACPI reboot over UEFI ResetSystem() run time service call.
    - Prefer CMOS over EFI_GET_TIME as time source.
@@ -17,6 +22,7 @@
      interrupts instead of logical destination mode.
 
 ### Added
+ - Enable CONFIG_UBSAN (Arm64, x86, PPC, RISC-V) for GitLab CI.
  - On Arm:
    - Experimental support for Armv8-R.
    - Support for NXP S32G3 Processors Family and NXP LINFlexD UART driver.
@@ -26,6 +32,9 @@
  - On x86:
    - xl suspend/resume subcommands.
    - `wallclock` command line option to select time source.
+   - Support for Intel EPT Paging-Write Feature.
+   - AMD Zen 5 CPU support, including for new hardware mitigations for the
+     SRSO speculative vulnerability.
 
 ### Removed
  - On x86:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/ChangeLog 
new/xen-4.20.0-testing/ChangeLog
--- old/xen-4.20.0-testing/ChangeLog    2025-02-20 18:09:14.000000000 +0100
+++ new/xen-4.20.0-testing/ChangeLog    2025-03-05 14:17:46.000000000 +0100
@@ -1,7 +1,7 @@
-commit d5b15616b930255ff9a22adcbbe2e4d1231d9ac4
+commit 3ad5d648cda5add395f49fc3704b2552aae734f7
 Author: Andrew Cooper <andrew.coop...@citrix.com>
-Date:   Thu Feb 20 15:47:30 2025 +0000
+Date:   Tue Mar 4 16:17:52 2025 +0000
 
-    Update Xen to 4.20.0-rc5
+    Update to Xen 4.20
     
     Signed-off-by: Andrew Cooper <andrew.coop...@citrix.com>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/Config.mk 
new/xen-4.20.0-testing/Config.mk
--- old/xen-4.20.0-testing/Config.mk    2025-02-20 18:09:14.000000000 +0100
+++ new/xen-4.20.0-testing/Config.mk    2025-03-05 14:17:46.000000000 +0100
@@ -229,10 +229,10 @@
 OVMF_UPSTREAM_REVISION ?= ba91d0292e593df8528b66f99c1b0b14fadc8e16
 
 QEMU_UPSTREAM_URL ?= https://xenbits.xen.org/git-http/qemu-xen.git
-QEMU_UPSTREAM_REVISION ?= 3fdb3cd3a27a22a050c7d27126a24807a7a45745
+QEMU_UPSTREAM_REVISION ?= qemu-xen-4.20.0
 
 MINIOS_UPSTREAM_URL ?= https://xenbits.xen.org/git-http/mini-os.git
-MINIOS_UPSTREAM_REVISION ?= 6d5159e8410be16a47433bac1627e63f8adc7cd9
+MINIOS_UPSTREAM_REVISION ?= xen-RELEASE-4.20.0
 
 SEABIOS_UPSTREAM_URL ?= https://xenbits.xen.org/git-http/seabios.git
 SEABIOS_UPSTREAM_REVISION ?= rel-1.16.3
@@ -241,7 +241,7 @@
 
 
 QEMU_TRADITIONAL_URL ?= 
https://xenbits.xen.org/git-http/qemu-xen-traditional.git
-QEMU_TRADITIONAL_REVISION ?= 3d273dd05e51e5a1ffba3d98c7437ee84e8f8764
+QEMU_TRADITIONAL_REVISION ?= xen-4.20.0
 # Wed Jul 15 10:01:40 2020 +0100
 # qemu-trad: remove Xen path dependencies
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/README 
new/xen-4.20.0-testing/README
--- old/xen-4.20.0-testing/README       2025-02-20 18:09:14.000000000 +0100
+++ new/xen-4.20.0-testing/README       2025-03-05 14:17:46.000000000 +0100
@@ -1,11 +1,11 @@
-#####################################################
+######################################
 __  __            _  _    ____   ___
-\ \/ /___ _ __   | || |  |___ \ / _ \       _ __ ___
- \  // _ \ '_ \  | || |_   __) | | | |_____| '__/ __|
- /  \  __/ | | | |__   _| / __/| |_| |_____| | | (__
-/_/\_\___|_| |_|    |_|(_)_____|\___/      |_|  \___|
+\ \/ /___ _ __   | || |  |___ \ / _ \
+ \  // _ \ '_ \  | || |_   __) | | | |
+ /  \  __/ | | | |__   _| / __/| |_| |
+/_/\_\___|_| |_|    |_|(_)_____|\___/
 
-#####################################################
+######################################
 
 https://www.xen.org/
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/SUPPORT.md 
new/xen-4.20.0-testing/SUPPORT.md
--- old/xen-4.20.0-testing/SUPPORT.md   2025-02-20 18:09:14.000000000 +0100
+++ new/xen-4.20.0-testing/SUPPORT.md   2025-03-05 14:17:46.000000000 +0100
@@ -9,13 +9,13 @@
 
 # Release Support
 
-    Xen-Version: 4.20-rc
-    Initial-Release: n/a
-    Supported-Until: TBD
-    Security-Support-Until: Unreleased - not yet security-supported
+    Xen-Version: 4.20
+    Initial-Release: 2025-03-05
+    Supported-Until: 2026-09-05
+    Security-Support-Until: 2028-03-05
 
 Release Notes
-: <a 
href="https://wiki.xenproject.org/wiki/Xen_Project_X.YY_Release_Notes";>RN</a>
+: <a 
href="https://wiki.xenproject.org/wiki/Xen_Project_4.20_Release_Notes";>RN</a>
 
 # Feature Support
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/xen-4.20.0-testing/automation/eclair_analysis/ECLAIR/tagging.ecl 
new/xen-4.20.0-testing/automation/eclair_analysis/ECLAIR/tagging.ecl
--- old/xen-4.20.0-testing/automation/eclair_analysis/ECLAIR/tagging.ecl        
2025-02-20 18:09:14.000000000 +0100
+++ new/xen-4.20.0-testing/automation/eclair_analysis/ECLAIR/tagging.ecl        
2025-03-05 14:17:46.000000000 +0100
@@ -69,6 +69,7 @@
 MC3A2.R14.4||
 MC3A2.R16.2||
 MC3A2.R16.3||
+MC3A2.R16.6||
 MC3A2.R16.7||
 MC3A2.R17.1||
 MC3A2.R17.3||
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/automation/gitlab-ci/build.yaml 
new/xen-4.20.0-testing/automation/gitlab-ci/build.yaml
--- old/xen-4.20.0-testing/automation/gitlab-ci/build.yaml      2025-02-20 
18:09:14.000000000 +0100
+++ new/xen-4.20.0-testing/automation/gitlab-ci/build.yaml      2025-03-05 
14:17:46.000000000 +0100
@@ -352,6 +352,9 @@
     CONTAINER: debian:12-ppc64le
     KBUILD_DEFCONFIG: ppc64_defconfig
     HYPERVISOR_ONLY: y
+    EXTRA_XEN_CONFIG: |
+      CONFIG_UBSAN=y
+      CONFIG_UBSAN_FATAL=y
 
 debian-12-riscv64-gcc-debug:
   extends: .gcc-riscv64-cross-build-debug
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/docs/misra/safe.json 
new/xen-4.20.0-testing/docs/misra/safe.json
--- old/xen-4.20.0-testing/docs/misra/safe.json 2025-02-20 18:09:14.000000000 
+0100
+++ new/xen-4.20.0-testing/docs/misra/safe.json 2025-03-05 14:17:46.000000000 
+0100
@@ -92,6 +92,22 @@
         },
         {
             "id": "SAF-11-safe",
+            "analyser": {
+                "eclair": "MC3A2.R16.6"
+            },
+            "name": "Rule 16.6: single clause due to kconfig",
+            "text": "A switch statement with a single switch clause because 
other switch clauses are disabled in a given kconfig is safe."
+        },
+        {
+            "id": "SAF-12-safe",
+            "analyser": {
+                "eclair": "MC3A2.R16.6"
+            },
+            "name": "Rule 16.6: single clause due to future expansion",
+            "text": "A switch statement with a single switch clause to 
purposely enable future additions of new cases is safe."
+        },
+        {
+            "id": "SAF-13-safe",
             "analyser": {},
             "name": "Sentinel",
             "text": "Next ID to be used"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/tools/Rules.mk 
new/xen-4.20.0-testing/tools/Rules.mk
--- old/xen-4.20.0-testing/tools/Rules.mk       2025-02-20 18:09:14.000000000 
+0100
+++ new/xen-4.20.0-testing/tools/Rules.mk       2025-03-05 14:17:46.000000000 
+0100
@@ -25,7 +25,7 @@
 XENSTORE_XENSTORED ?= y
 
 # A debug build of tools?
-debug ?= y
+debug ?= n
 debug_symbols ?= $(debug)
 
 XEN_GOCODE_URL    = golang.xenproject.org
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/xen/Kconfig.debug 
new/xen-4.20.0-testing/xen/Kconfig.debug
--- old/xen-4.20.0-testing/xen/Kconfig.debug    2025-02-20 18:09:14.000000000 
+0100
+++ new/xen-4.20.0-testing/xen/Kconfig.debug    2025-03-05 14:17:46.000000000 
+0100
@@ -3,7 +3,7 @@
 
 config DEBUG
        bool "Developer Checks"
-       default y
+       default n
        help
          If you say Y here this will enable developer checks such as asserts
          and extra printks. This option is intended for development purposes
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/xen/Makefile 
new/xen-4.20.0-testing/xen/Makefile
--- old/xen-4.20.0-testing/xen/Makefile 2025-02-20 18:09:14.000000000 +0100
+++ new/xen-4.20.0-testing/xen/Makefile 2025-03-05 14:17:46.000000000 +0100
@@ -6,7 +6,7 @@
 # All other places this is stored (eg. compile.h) should be autogenerated.
 export XEN_VERSION       = 4
 export XEN_SUBVERSION    = 20
-export XEN_EXTRAVERSION ?= .0-rc5$(XEN_VENDORVERSION)
+export XEN_EXTRAVERSION ?= .0$(XEN_VENDORVERSION)
 export XEN_FULLVERSION   = $(XEN_VERSION).$(XEN_SUBVERSION)$(XEN_EXTRAVERSION)
 -include xen-version
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/xen/arch/ppc/Kconfig 
new/xen-4.20.0-testing/xen/arch/ppc/Kconfig
--- old/xen-4.20.0-testing/xen/arch/ppc/Kconfig 2025-02-20 18:09:14.000000000 
+0100
+++ new/xen-4.20.0-testing/xen/arch/ppc/Kconfig 2025-03-05 14:17:46.000000000 
+0100
@@ -2,6 +2,7 @@
        def_bool y
        select FUNCTION_ALIGNMENT_4B
        select HAS_DEVICE_TREE
+       select HAS_UBSAN
        select HAS_VMAP
 
 config PPC64
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/xen/arch/ppc/arch.mk 
new/xen-4.20.0-testing/xen/arch/ppc/arch.mk
--- old/xen-4.20.0-testing/xen/arch/ppc/arch.mk 2025-02-20 18:09:14.000000000 
+0100
+++ new/xen-4.20.0-testing/xen/arch/ppc/arch.mk 2025-03-05 14:17:46.000000000 
+0100
@@ -7,3 +7,9 @@
 CFLAGS += -mstrict-align -mcmodel=medium -mabi=elfv2 -fPIC -mno-altivec 
-mno-vsx -msoft-float
 
 LDFLAGS += -m elf64lppc
+
+ifeq ($(CONFIG_UBSAN),y)
+# Don't enable alignment sanitisation since Power ISA guarantees hardware
+# support for unaligned accesses.
+$(call cc-option-add,CFLAGS_UBSAN,CC,-fno-sanitize=alignment)
+endif
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/xen-4.20.0-testing/xen/arch/ppc/include/asm/processor.h 
new/xen-4.20.0-testing/xen/arch/ppc/include/asm/processor.h
--- old/xen-4.20.0-testing/xen/arch/ppc/include/asm/processor.h 2025-02-20 
18:09:14.000000000 +0100
+++ new/xen-4.20.0-testing/xen/arch/ppc/include/asm/processor.h 2025-03-05 
14:17:46.000000000 +0100
@@ -219,6 +219,8 @@
  */
 #define cpu_relax() asm volatile ( "or %r1, %r1, %r1; or %r2, %r2, %r2" )
 
+#define dump_execution_state() run_in_exception_handler(show_execution_state)
+
 #endif /* __ASSEMBLY__ */
 
 #endif /* _ASM_PPC_PROCESSOR_H */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/xen/arch/ppc/stubs.c 
new/xen-4.20.0-testing/xen/arch/ppc/stubs.c
--- old/xen-4.20.0-testing/xen/arch/ppc/stubs.c 2025-02-20 18:09:14.000000000 
+0100
+++ new/xen-4.20.0-testing/xen/arch/ppc/stubs.c 2025-03-05 14:17:46.000000000 
+0100
@@ -47,7 +47,7 @@
 
 void show_execution_state(const struct cpu_user_regs *regs)
 {
-    BUG_ON("unimplemented");
+    printk("TODO: Implement show_execution_state(regs)\n");
 }
 
 void arch_hypercall_tasklet_result(struct vcpu *v, long res)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/xen/arch/x86/hvm/hvm.c 
new/xen-4.20.0-testing/xen/arch/x86/hvm/hvm.c
--- old/xen-4.20.0-testing/xen/arch/x86/hvm/hvm.c       2025-02-20 
18:09:14.000000000 +0100
+++ new/xen-4.20.0-testing/xen/arch/x86/hvm/hvm.c       2025-03-05 
14:17:46.000000000 +0100
@@ -3797,6 +3797,7 @@
 {
     ASSERT(v == current || !vcpu_runnable(v));
 
+    /* SAF-12-safe */
     switch ( reg )
     {
     default:
@@ -3808,6 +3809,7 @@
 {
     ASSERT(v == current || !vcpu_runnable(v));
 
+    /* SAF-12-safe */
     switch ( reg )
     {
     default:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/xen/arch/x86/traps.c 
new/xen-4.20.0-testing/xen/arch/x86/traps.c
--- old/xen-4.20.0-testing/xen/arch/x86/traps.c 2025-02-20 18:09:14.000000000 
+0100
+++ new/xen-4.20.0-testing/xen/arch/x86/traps.c 2025-03-05 14:17:46.000000000 
+0100
@@ -436,6 +436,7 @@
 
 static unsigned long get_shstk_bottom(unsigned long sp)
 {
+    /* SAF-11-safe */
     switch ( get_stack_page(sp) )
     {
 #ifdef CONFIG_XEN_SHSTK
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/xen-4.20.0-testing/xen/drivers/passthrough/pci.c 
new/xen-4.20.0-testing/xen/drivers/passthrough/pci.c
--- old/xen-4.20.0-testing/xen/drivers/passthrough/pci.c        2025-02-20 
18:09:14.000000000 +0100
+++ new/xen-4.20.0-testing/xen/drivers/passthrough/pci.c        2025-03-05 
14:17:46.000000000 +0100
@@ -354,20 +354,21 @@
     switch ( pdev->type = pdev_type(pseg->nr, bus, devfn) )
     {
         unsigned int cap, sec_bus, sub_bus;
+        unsigned long flags;
 
         case DEV_TYPE_PCIe2PCI_BRIDGE:
         case DEV_TYPE_LEGACY_PCI_BRIDGE:
             sec_bus = pci_conf_read8(pdev->sbdf, PCI_SECONDARY_BUS);
             sub_bus = pci_conf_read8(pdev->sbdf, PCI_SUBORDINATE_BUS);
 
-            spin_lock(&pseg->bus2bridge_lock);
+            spin_lock_irqsave(&pseg->bus2bridge_lock, flags);
             for ( ; sec_bus <= sub_bus; sec_bus++ )
             {
                 pseg->bus2bridge[sec_bus].map = 1;
                 pseg->bus2bridge[sec_bus].bus = bus;
                 pseg->bus2bridge[sec_bus].devfn = devfn;
             }
-            spin_unlock(&pseg->bus2bridge_lock);
+            spin_unlock_irqrestore(&pseg->bus2bridge_lock, flags);
             break;
 
         case DEV_TYPE_PCIe_ENDPOINT:
@@ -437,16 +438,17 @@
     switch ( pdev->type )
     {
         unsigned int sec_bus, sub_bus;
+        unsigned long flags;
 
         case DEV_TYPE_PCIe2PCI_BRIDGE:
         case DEV_TYPE_LEGACY_PCI_BRIDGE:
             sec_bus = pci_conf_read8(pdev->sbdf, PCI_SECONDARY_BUS);
             sub_bus = pci_conf_read8(pdev->sbdf, PCI_SUBORDINATE_BUS);
 
-            spin_lock(&pseg->bus2bridge_lock);
+            spin_lock_irqsave(&pseg->bus2bridge_lock, flags);
             for ( ; sec_bus <= sub_bus; sec_bus++ )
                 pseg->bus2bridge[sec_bus] = pseg->bus2bridge[pdev->bus];
-            spin_unlock(&pseg->bus2bridge_lock);
+            spin_unlock_irqrestore(&pseg->bus2bridge_lock, flags);
             break;
 
         default:
@@ -1053,8 +1055,9 @@
 int find_upstream_bridge(u16 seg, u8 *bus, u8 *devfn, u8 *secbus)
 {
     struct pci_seg *pseg = get_pseg(seg);
-    int ret = 0;
-    int cnt = 0;
+    int ret = 1;
+    unsigned long flags;
+    unsigned int cnt = 0;
 
     if ( *bus == 0 )
         return 0;
@@ -1065,8 +1068,7 @@
     if ( !pseg->bus2bridge[*bus].map )
         return 0;
 
-    ret = 1;
-    spin_lock(&pseg->bus2bridge_lock);
+    spin_lock_irqsave(&pseg->bus2bridge_lock, flags);
     while ( pseg->bus2bridge[*bus].map )
     {
         *secbus = *bus;
@@ -1080,7 +1082,7 @@
     }
 
 out:
-    spin_unlock(&pseg->bus2bridge_lock);
+    spin_unlock_irqrestore(&pseg->bus2bridge_lock, flags);
     return ret;
 }
 

Reply via email to