aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/acpi/pci_irq.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/acpi/pci_irq.c')
-rw-r--r--drivers/acpi/pci_irq.c48
1 files changed, 24 insertions, 24 deletions
diff --git a/drivers/acpi/pci_irq.c b/drivers/acpi/pci_irq.c
index e567c03b238e..65aee79b3971 100644
--- a/drivers/acpi/pci_irq.c
+++ b/drivers/acpi/pci_irq.c
@@ -258,7 +258,7 @@ typedef int (*irq_lookup_func) (struct acpi_prt_entry *, int *, int *, char **);
258 258
259static int 259static int
260acpi_pci_allocate_irq(struct acpi_prt_entry *entry, 260acpi_pci_allocate_irq(struct acpi_prt_entry *entry,
261 int *edge_level, int *active_high_low, char **link) 261 int *triggering, int *polarity, char **link)
262{ 262{
263 int irq; 263 int irq;
264 264
@@ -266,8 +266,8 @@ acpi_pci_allocate_irq(struct acpi_prt_entry *entry,
266 266
267 if (entry->link.handle) { 267 if (entry->link.handle) {
268 irq = acpi_pci_link_allocate_irq(entry->link.handle, 268 irq = acpi_pci_link_allocate_irq(entry->link.handle,
269 entry->link.index, edge_level, 269 entry->link.index, triggering,
270 active_high_low, link); 270 polarity, link);
271 if (irq < 0) { 271 if (irq < 0) {
272 ACPI_DEBUG_PRINT((ACPI_DB_WARN, 272 ACPI_DEBUG_PRINT((ACPI_DB_WARN,
273 "Invalid IRQ link routing entry\n")); 273 "Invalid IRQ link routing entry\n"));
@@ -275,8 +275,8 @@ acpi_pci_allocate_irq(struct acpi_prt_entry *entry,
275 } 275 }
276 } else { 276 } else {
277 irq = entry->link.index; 277 irq = entry->link.index;
278 *edge_level = ACPI_LEVEL_SENSITIVE; 278 *triggering = ACPI_LEVEL_SENSITIVE;
279 *active_high_low = ACPI_ACTIVE_LOW; 279 *polarity = ACPI_ACTIVE_LOW;
280 } 280 }
281 281
282 ACPI_DEBUG_PRINT((ACPI_DB_INFO, "Found IRQ %d\n", irq)); 282 ACPI_DEBUG_PRINT((ACPI_DB_INFO, "Found IRQ %d\n", irq));
@@ -285,7 +285,7 @@ acpi_pci_allocate_irq(struct acpi_prt_entry *entry,
285 285
286static int 286static int
287acpi_pci_free_irq(struct acpi_prt_entry *entry, 287acpi_pci_free_irq(struct acpi_prt_entry *entry,
288 int *edge_level, int *active_high_low, char **link) 288 int *triggering, int *polarity, char **link)
289{ 289{
290 int irq; 290 int irq;
291 291
@@ -307,8 +307,8 @@ static int
307acpi_pci_irq_lookup(struct pci_bus *bus, 307acpi_pci_irq_lookup(struct pci_bus *bus,
308 int device, 308 int device,
309 int pin, 309 int pin,
310 int *edge_level, 310 int *triggering,
311 int *active_high_low, char **link, irq_lookup_func func) 311 int *polarity, char **link, irq_lookup_func func)
312{ 312{
313 struct acpi_prt_entry *entry = NULL; 313 struct acpi_prt_entry *entry = NULL;
314 int segment = pci_domain_nr(bus); 314 int segment = pci_domain_nr(bus);
@@ -327,7 +327,7 @@ acpi_pci_irq_lookup(struct pci_bus *bus,
327 return_VALUE(-1); 327 return_VALUE(-1);
328 } 328 }
329 329
330 ret = func(entry, edge_level, active_high_low, link); 330 ret = func(entry, triggering, polarity, link);
331 return_VALUE(ret); 331 return_VALUE(ret);
332} 332}
333 333
@@ -339,8 +339,8 @@ acpi_pci_irq_lookup(struct pci_bus *bus,
339static int 339static int
340acpi_pci_irq_derive(struct pci_dev *dev, 340acpi_pci_irq_derive(struct pci_dev *dev,
341 int pin, 341 int pin,
342 int *edge_level, 342 int *triggering,
343 int *active_high_low, char **link, irq_lookup_func func) 343 int *polarity, char **link, irq_lookup_func func)
344{ 344{
345 struct pci_dev *bridge = dev; 345 struct pci_dev *bridge = dev;
346 int irq = -1; 346 int irq = -1;
@@ -374,7 +374,7 @@ acpi_pci_irq_derive(struct pci_dev *dev,
374 } 374 }
375 375
376 irq = acpi_pci_irq_lookup(bridge->bus, PCI_SLOT(bridge->devfn), 376 irq = acpi_pci_irq_lookup(bridge->bus, PCI_SLOT(bridge->devfn),
377 pin, edge_level, active_high_low, 377 pin, triggering, polarity,
378 link, func); 378 link, func);
379 } 379 }
380 380
@@ -401,8 +401,8 @@ int acpi_pci_irq_enable(struct pci_dev *dev)
401{ 401{
402 int irq = 0; 402 int irq = 0;
403 u8 pin = 0; 403 u8 pin = 0;
404 int edge_level = ACPI_LEVEL_SENSITIVE; 404 int triggering = ACPI_LEVEL_SENSITIVE;
405 int active_high_low = ACPI_ACTIVE_LOW; 405 int polarity = ACPI_ACTIVE_LOW;
406 char *link = NULL; 406 char *link = NULL;
407 int rc; 407 int rc;
408 408
@@ -431,7 +431,7 @@ int acpi_pci_irq_enable(struct pci_dev *dev)
431 * values override any BIOS-assigned IRQs set during boot. 431 * values override any BIOS-assigned IRQs set during boot.
432 */ 432 */
433 irq = acpi_pci_irq_lookup(dev->bus, PCI_SLOT(dev->devfn), pin, 433 irq = acpi_pci_irq_lookup(dev->bus, PCI_SLOT(dev->devfn), pin,
434 &edge_level, &active_high_low, &link, 434 &triggering, &polarity, &link,
435 acpi_pci_allocate_irq); 435 acpi_pci_allocate_irq);
436 436
437 /* 437 /*
@@ -439,8 +439,8 @@ int acpi_pci_irq_enable(struct pci_dev *dev)
439 * device's parent bridge. 439 * device's parent bridge.
440 */ 440 */
441 if (irq < 0) 441 if (irq < 0)
442 irq = acpi_pci_irq_derive(dev, pin, &edge_level, 442 irq = acpi_pci_irq_derive(dev, pin, &triggering,
443 &active_high_low, &link, 443 &polarity, &link,
444 acpi_pci_allocate_irq); 444 acpi_pci_allocate_irq);
445 445
446 /* 446 /*
@@ -462,7 +462,7 @@ int acpi_pci_irq_enable(struct pci_dev *dev)
462 } 462 }
463 } 463 }
464 464
465 rc = acpi_register_gsi(irq, edge_level, active_high_low); 465 rc = acpi_register_gsi(irq, triggering, polarity);
466 if (rc < 0) { 466 if (rc < 0) {
467 printk(KERN_WARNING PREFIX "PCI Interrupt %s[%c]: failed " 467 printk(KERN_WARNING PREFIX "PCI Interrupt %s[%c]: failed "
468 "to register GSI\n", pci_name(dev), ('A' + pin)); 468 "to register GSI\n", pci_name(dev), ('A' + pin));
@@ -477,8 +477,8 @@ int acpi_pci_irq_enable(struct pci_dev *dev)
477 printk("Link [%s] -> ", link); 477 printk("Link [%s] -> ", link);
478 478
479 printk("GSI %u (%s, %s) -> IRQ %d\n", irq, 479 printk("GSI %u (%s, %s) -> IRQ %d\n", irq,
480 (edge_level == ACPI_LEVEL_SENSITIVE) ? "level" : "edge", 480 (triggering == ACPI_LEVEL_SENSITIVE) ? "level" : "edge",
481 (active_high_low == ACPI_ACTIVE_LOW) ? "low" : "high", dev->irq); 481 (polarity == ACPI_ACTIVE_LOW) ? "low" : "high", dev->irq);
482 482
483 return_VALUE(0); 483 return_VALUE(0);
484} 484}
@@ -494,8 +494,8 @@ void acpi_pci_irq_disable(struct pci_dev *dev)
494{ 494{
495 int gsi = 0; 495 int gsi = 0;
496 u8 pin = 0; 496 u8 pin = 0;
497 int edge_level = ACPI_LEVEL_SENSITIVE; 497 int triggering = ACPI_LEVEL_SENSITIVE;
498 int active_high_low = ACPI_ACTIVE_LOW; 498 int polarity = ACPI_ACTIVE_LOW;
499 499
500 ACPI_FUNCTION_TRACE("acpi_pci_irq_disable"); 500 ACPI_FUNCTION_TRACE("acpi_pci_irq_disable");
501 501
@@ -511,7 +511,7 @@ void acpi_pci_irq_disable(struct pci_dev *dev)
511 * First we check the PCI IRQ routing table (PRT) for an IRQ. 511 * First we check the PCI IRQ routing table (PRT) for an IRQ.
512 */ 512 */
513 gsi = acpi_pci_irq_lookup(dev->bus, PCI_SLOT(dev->devfn), pin, 513 gsi = acpi_pci_irq_lookup(dev->bus, PCI_SLOT(dev->devfn), pin,
514 &edge_level, &active_high_low, NULL, 514 &triggering, &polarity, NULL,
515 acpi_pci_free_irq); 515 acpi_pci_free_irq);
516 /* 516 /*
517 * If no PRT entry was found, we'll try to derive an IRQ from the 517 * If no PRT entry was found, we'll try to derive an IRQ from the
@@ -519,7 +519,7 @@ void acpi_pci_irq_disable(struct pci_dev *dev)
519 */ 519 */
520 if (gsi < 0) 520 if (gsi < 0)
521 gsi = acpi_pci_irq_derive(dev, pin, 521 gsi = acpi_pci_irq_derive(dev, pin,
522 &edge_level, &active_high_low, NULL, 522 &triggering, &polarity, NULL,
523 acpi_pci_free_irq); 523 acpi_pci_free_irq);
524 if (gsi < 0) 524 if (gsi < 0)
525 return_VOID; 525 return_VOID;