| Message ID | 1288025051-17145-1-git-send-email-manuel.lauss@googlemail.com |
|---|---|
| State | Accepted |
| Delegated to: | Ralf Baechle |
| Headers | show |
On Mon, Oct 25, 2010 at 06:44:11PM +0200, Manuel Lauss wrote: > In commit 7d172bfe ("Alchemy: Add UART PM methods") I introduced > platform PM methods which call a function of the 8250 driver; > this patch works around link failures when the kernel is built > without 8250 support. > > Signed-off-by: Manuel Lauss <manuel.lauss@googlemail.com> > --- > V2: added commit name to patch description as per Sergei's suggestion. Applied, thanks. Though anything like a CONFIG_SERIAL_8250 in board code always strikes me as wrong. What if the driver is built as a module? What if the kernel is built without the driver, then later on the module is built separately and then inserted? Ralf
diff --git a/arch/mips/alchemy/common/platform.c b/arch/mips/alchemy/common/platform.c index 3691630..9e7814d 100644 --- a/arch/mips/alchemy/common/platform.c +++ b/arch/mips/alchemy/common/platform.c @@ -27,6 +27,7 @@ static void alchemy_8250_pm(struct uart_port *port, unsigned int state, unsigned int old_state) { +#ifdef CONFIG_SERIAL_8250 switch (state) { case 0: if ((__raw_readl(port->membase + UART_MOD_CNTRL) & 3) != 3) { @@ -49,6 +50,7 @@ static void alchemy_8250_pm(struct uart_port *port, unsigned int state, serial8250_do_pm(port, state, old_state); break; } +#endif } #define PORT(_base, _irq) \
In commit 7d172bfe ("Alchemy: Add UART PM methods") I introduced platform PM methods which call a function of the 8250 driver; this patch works around link failures when the kernel is built without 8250 support. Signed-off-by: Manuel Lauss <manuel.lauss@googlemail.com> --- V2: added commit name to patch description as per Sergei's suggestion. arch/mips/alchemy/common/platform.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)