• M
    ACPI / resources: call acpi_get_override_irq() only for legacy IRQ resources · 204ebc0a
    Mika Westerberg 提交于
    acpi_get_override_irq() was added because there was a problem with
    buggy BIOSes passing wrong IRQ() resource for the RTC IRQ.  The
    commit that added the workaround was 61fd47e0 (ACPI: fix two
    IRQ8 issues in IOAPIC mode).
    
    With ACPI 5 enumerated devices there are typically one or more
    extended IRQ resources per device (and these IRQs can be shared).
    However, the acpi_get_override_irq() workaround forces all IRQs in
    range 0 - 15 (the legacy ISA IRQs) to be edge triggered, active high
    as can be seen from the dmesg below:
    
    	ACPI: IRQ 6 override to edge, high
    	ACPI: IRQ 7 override to edge, high
    	ACPI: IRQ 7 override to edge, high
    	ACPI: IRQ 13 override to edge, high
    
    Also /proc/interrupts for the I2C controllers (INT33C2 and INT33C3) shows
    the same thing:
    
    	7:          4          0          0          0   IO-APIC-edge INT33C2:00, INT33C3:00
    
    The _CSR method for INT33C2 (and INT33C3) device returns following
    resource:
    
    	Interrupt (ResourceConsumer, Level, ActiveLow, Shared,,, )
    	{
    		0x00000007,
    	}
    
    which states that this is supposed to be level triggered, active low,
    shared IRQ instead.
    
    Fix this by making sure that acpi_get_override_irq() gets only called
    when we are dealing with legacy IRQ() or IRQNoFlags() descriptors.
    
    While we are there, correct pr_warning() to print the right triggering
    value.
    
    This change turns out to be necessary to make DMA work correctly on
    systems based on the Intel Lynxpoint PCH (Platform Controller Hub).
    
    [rjw: Changelog]
    Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com>
    Cc: 3.9+ <stable@vger.kernel.org>
    Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
    204ebc0a
resource.c 14.9 KB