diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/x86/pci/xen.c | 22 | ||||
-rw-r--r-- | arch/x86/xen/time.c | 4 |
2 files changed, 17 insertions, 9 deletions
diff --git a/arch/x86/pci/xen.c b/arch/x86/pci/xen.c index 25cd4a07d09f..2a12f3dbdd02 100644 --- a/arch/x86/pci/xen.c +++ b/arch/x86/pci/xen.c | |||
@@ -226,21 +226,27 @@ static int xen_pcifront_enable_irq(struct pci_dev *dev) | |||
226 | { | 226 | { |
227 | int rc; | 227 | int rc; |
228 | int share = 1; | 228 | int share = 1; |
229 | u8 gsi; | ||
229 | 230 | ||
230 | dev_info(&dev->dev, "Xen PCI enabling IRQ: %d\n", dev->irq); | 231 | rc = pci_read_config_byte(dev, PCI_INTERRUPT_LINE, &gsi); |
231 | 232 | if (rc < 0) { | |
232 | if (dev->irq < 0) | 233 | dev_warn(&dev->dev, "Xen PCI: failed to read interrupt line: %d\n", |
233 | return -EINVAL; | 234 | rc); |
235 | return rc; | ||
236 | } | ||
234 | 237 | ||
235 | if (dev->irq < NR_IRQS_LEGACY) | 238 | if (gsi < NR_IRQS_LEGACY) |
236 | share = 0; | 239 | share = 0; |
237 | 240 | ||
238 | rc = xen_allocate_pirq(dev->irq, share, "pcifront"); | 241 | rc = xen_allocate_pirq(gsi, share, "pcifront"); |
239 | if (rc < 0) { | 242 | if (rc < 0) { |
240 | dev_warn(&dev->dev, "Xen PCI IRQ: %d, failed to register:%d\n", | 243 | dev_warn(&dev->dev, "Xen PCI: failed to register GSI%d: %d\n", |
241 | dev->irq, rc); | 244 | gsi, rc); |
242 | return rc; | 245 | return rc; |
243 | } | 246 | } |
247 | |||
248 | dev->irq = rc; | ||
249 | dev_info(&dev->dev, "Xen PCI mapped GSI%d to IRQ%d\n", gsi, dev->irq); | ||
244 | return 0; | 250 | return 0; |
245 | } | 251 | } |
246 | 252 | ||
diff --git a/arch/x86/xen/time.c b/arch/x86/xen/time.c index 067759e3d6a5..2e2d370a47b1 100644 --- a/arch/x86/xen/time.c +++ b/arch/x86/xen/time.c | |||
@@ -397,7 +397,9 @@ void xen_setup_timer(int cpu) | |||
397 | name = "<timer kasprintf failed>"; | 397 | name = "<timer kasprintf failed>"; |
398 | 398 | ||
399 | irq = bind_virq_to_irqhandler(VIRQ_TIMER, cpu, xen_timer_interrupt, | 399 | irq = bind_virq_to_irqhandler(VIRQ_TIMER, cpu, xen_timer_interrupt, |
400 | IRQF_DISABLED|IRQF_PERCPU|IRQF_NOBALANCING|IRQF_TIMER, | 400 | IRQF_DISABLED|IRQF_PERCPU| |
401 | IRQF_NOBALANCING|IRQF_TIMER| | ||
402 | IRQF_FORCE_RESUME, | ||
401 | name, NULL); | 403 | name, NULL); |
402 | 404 | ||
403 | evt = &per_cpu(xen_clock_events, cpu); | 405 | evt = &per_cpu(xen_clock_events, cpu); |