Commit ea6cd250 authored by Paul Gortmaker's avatar Paul Gortmaker Committed by Thomas Gleixner

x86: Rename eisa_set_level_irq to elcr_set_level_irq

This routine has been around for over a decade, but with EISA
being dead and abandoned for about twice that long, the name can
be kind of confusing.  The function is going at the PIC Edge/Level
Configuration Registers (ELCR), so rename it as such and mentally
decouple it from the long since dead EISA bus.
Signed-off-by: default avatarPaul Gortmaker <paul.gortmaker@windriver.com>
Reviewed-by: default avatarMaciej W. Rozycki <macro@linux-mips.org>
Acked-by: default avatarPavel Machek <pavel@ucw.cz>
Cc: Rafael J. Wysocki <rjw@rjwysocki.net>
Cc: Len Brown <len.brown@intel.com>
Cc: Bjorn Helgaas <bhelgaas@google.com>
Cc: x86@kernel.org
Link: http://lkml.kernel.org/r/1431217657-934-1-git-send-email-paul.gortmaker@windriver.comSigned-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
parent 7cb68598
...@@ -157,8 +157,7 @@ static inline void unlock_vector_lock(void) {} ...@@ -157,8 +157,7 @@ static inline void unlock_vector_lock(void) {}
extern atomic_t irq_err_count; extern atomic_t irq_err_count;
extern atomic_t irq_mis_count; extern atomic_t irq_mis_count;
/* EISA */ extern void elcr_set_level_irq(unsigned int irq);
extern void eisa_set_level_irq(unsigned int irq);
/* SMP */ /* SMP */
extern __visible void smp_apic_timer_interrupt(struct pt_regs *); extern __visible void smp_apic_timer_interrupt(struct pt_regs *);
......
...@@ -608,7 +608,7 @@ static int acpi_register_gsi_pic(struct device *dev, u32 gsi, ...@@ -608,7 +608,7 @@ static int acpi_register_gsi_pic(struct device *dev, u32 gsi,
* Make sure all (legacy) PCI IRQs are set as level-triggered. * Make sure all (legacy) PCI IRQs are set as level-triggered.
*/ */
if (trigger == ACPI_LEVEL_SENSITIVE) if (trigger == ACPI_LEVEL_SENSITIVE)
eisa_set_level_irq(gsi); elcr_set_level_irq(gsi);
#endif #endif
return gsi; return gsi;
......
...@@ -146,19 +146,20 @@ static void __init pirq_peer_trick(void) ...@@ -146,19 +146,20 @@ static void __init pirq_peer_trick(void)
/* /*
* Code for querying and setting of IRQ routes on various interrupt routers. * Code for querying and setting of IRQ routes on various interrupt routers.
* PIC Edge/Level Control Registers (ELCR) 0x4d0 & 0x4d1.
*/ */
void eisa_set_level_irq(unsigned int irq) void elcr_set_level_irq(unsigned int irq)
{ {
unsigned char mask = 1 << (irq & 7); unsigned char mask = 1 << (irq & 7);
unsigned int port = 0x4d0 + (irq >> 3); unsigned int port = 0x4d0 + (irq >> 3);
unsigned char val; unsigned char val;
static u16 eisa_irq_mask; static u16 elcr_irq_mask;
if (irq >= 16 || (1 << irq) & eisa_irq_mask) if (irq >= 16 || (1 << irq) & elcr_irq_mask)
return; return;
eisa_irq_mask |= (1 << irq); elcr_irq_mask |= (1 << irq);
printk(KERN_DEBUG "PCI: setting IRQ %u as level-triggered\n", irq); printk(KERN_DEBUG "PCI: setting IRQ %u as level-triggered\n", irq);
val = inb(port); val = inb(port);
if (!(val & mask)) { if (!(val & mask)) {
...@@ -965,11 +966,11 @@ static int pcibios_lookup_irq(struct pci_dev *dev, int assign) ...@@ -965,11 +966,11 @@ static int pcibios_lookup_irq(struct pci_dev *dev, int assign)
} else if (r->get && (irq = r->get(pirq_router_dev, dev, pirq)) && \ } else if (r->get && (irq = r->get(pirq_router_dev, dev, pirq)) && \
((!(pci_probe & PCI_USE_PIRQ_MASK)) || ((1 << irq) & mask))) { ((!(pci_probe & PCI_USE_PIRQ_MASK)) || ((1 << irq) & mask))) {
msg = "found"; msg = "found";
eisa_set_level_irq(irq); elcr_set_level_irq(irq);
} else if (newirq && r->set && } else if (newirq && r->set &&
(dev->class >> 8) != PCI_CLASS_DISPLAY_VGA) { (dev->class >> 8) != PCI_CLASS_DISPLAY_VGA) {
if (r->set(pirq_router_dev, dev, pirq, newirq)) { if (r->set(pirq_router_dev, dev, pirq, newirq)) {
eisa_set_level_irq(newirq); elcr_set_level_irq(newirq);
msg = "assigned"; msg = "assigned";
irq = newirq; irq = newirq;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment