]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
serial: 8250_dw: Use ifdef with ACPI
authorHeikki Krogerus <heikki.krogerus@linux.intel.com>
Wed, 16 Jan 2013 12:08:15 +0000 (14:08 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 16 Jan 2013 15:36:10 +0000 (07:36 -0800)
There are no stubs for ACPI functions so the driver needs to
have this ifdef or it will not compile without ACPI.

Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/8250/8250_dw.c

index ceacf5e36f2efe4110bb97c408f0e3ac9273d044..bfdaf8b2680bd2d157a1bdf3d86ada71865718f0 100644 (file)
@@ -145,6 +145,7 @@ static int dw8250_probe_of(struct uart_port *p)
        return 0;
 }
 
+#ifdef CONFIG_ACPI
 static bool dw8250_acpi_dma_filter(struct dma_chan *chan, void *parm)
 {
        return chan->chan_id == *(int *)parm;
@@ -231,6 +232,12 @@ static int dw8250_probe_acpi(struct uart_port *p)
 
        return 0;
 }
+#else
+static inline int dw8250_probe_acpi(struct uart_port *p)
+{
+       return -ENODEV;
+}
+#endif /* CONFIG_ACPI */
 
 static void dw8250_setup_port(struct uart_8250_port *up)
 {