Skip to content

Commit 9479f0f

Browse files
committed
Merge tag 'stable/for-linus-3.4-rc1-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen
Pull xen fixes from Konrad Rzeszutek Wilk: "Two fixes for regressions: * one is a workaround that will be removed in v3.5 with proper fix in the tip/x86 tree, * the other is to fix drivers to load on PV (a previous patch made them only load in PVonHVM mode). The rest are just minor fixes in the various drivers and some cleanup in the core code." * tag 'stable/for-linus-3.4-rc1-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen: xen/pcifront: avoid pci_frontend_enable_msix() falsely returning success xen/pciback: fix XEN_PCI_OP_enable_msix result xen/smp: Remove unnecessary call to smp_processor_id() xen/x86: Workaround 'x86/ioapic: Add register level checks to detect bogus io-apic entries' xen: only check xen_platform_pci_unplug if hvm
2 parents 1ddca05 + f09d843 commit 9479f0f

File tree

6 files changed

+8
-5
lines changed

6 files changed

+8
-5
lines changed

arch/x86/xen/mmu.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1859,6 +1859,7 @@ pgd_t * __init xen_setup_kernel_pagetable(pgd_t *pgd,
18591859
#endif /* CONFIG_X86_64 */
18601860

18611861
static unsigned char dummy_mapping[PAGE_SIZE] __page_aligned_bss;
1862+
static unsigned char fake_ioapic_mapping[PAGE_SIZE] __page_aligned_bss;
18621863

18631864
static void xen_set_fixmap(unsigned idx, phys_addr_t phys, pgprot_t prot)
18641865
{
@@ -1899,7 +1900,7 @@ static void xen_set_fixmap(unsigned idx, phys_addr_t phys, pgprot_t prot)
18991900
* We just don't map the IO APIC - all access is via
19001901
* hypercalls. Keep the address in the pte for reference.
19011902
*/
1902-
pte = pfn_pte(PFN_DOWN(__pa(dummy_mapping)), PAGE_KERNEL);
1903+
pte = pfn_pte(PFN_DOWN(__pa(fake_ioapic_mapping)), PAGE_KERNEL);
19031904
break;
19041905
#endif
19051906

@@ -2064,6 +2065,7 @@ void __init xen_init_mmu_ops(void)
20642065
pv_mmu_ops = xen_mmu_ops;
20652066

20662067
memset(dummy_mapping, 0xff, PAGE_SIZE);
2068+
memset(fake_ioapic_mapping, 0xfd, PAGE_SIZE);
20672069
}
20682070

20692071
/* Protected by xen_reservation_lock. */

arch/x86/xen/smp.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ static irqreturn_t xen_reschedule_interrupt(int irq, void *dev_id)
5959

6060
static void __cpuinit cpu_bringup(void)
6161
{
62-
int cpu = smp_processor_id();
62+
int cpu;
6363

6464
cpu_init();
6565
touch_softlockup_watchdog();

drivers/block/xen-blkfront.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1475,7 +1475,7 @@ static int __init xlblk_init(void)
14751475
if (!xen_domain())
14761476
return -ENODEV;
14771477

1478-
if (!xen_platform_pci_unplug)
1478+
if (xen_hvm_domain() && !xen_platform_pci_unplug)
14791479
return -ENODEV;
14801480

14811481
if (register_blkdev(XENVBD_MAJOR, DEV_NAME)) {

drivers/net/xen-netfront.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1965,7 +1965,7 @@ static int __init netif_init(void)
19651965
if (xen_initial_domain())
19661966
return 0;
19671967

1968-
if (!xen_platform_pci_unplug)
1968+
if (xen_hvm_domain() && !xen_platform_pci_unplug)
19691969
return -ENODEV;
19701970

19711971
printk(KERN_INFO "Initialising Xen virtual ethernet driver.\n");

drivers/pci/xen-pcifront.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -290,6 +290,7 @@ static int pci_frontend_enable_msix(struct pci_dev *dev,
290290
} else {
291291
printk(KERN_DEBUG "enable msix get value %x\n",
292292
op.value);
293+
err = op.value;
293294
}
294295
} else {
295296
dev_err(&dev->dev, "enable msix get err %x\n", err);

drivers/xen/xen-pciback/pciback_ops.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ int xen_pcibk_enable_msix(struct xen_pcibk_device *pdev,
234234
if (dev_data)
235235
dev_data->ack_intr = 0;
236236

237-
return result;
237+
return result > 0 ? 0 : result;
238238
}
239239

240240
static

0 commit comments

Comments
 (0)