From: Ley Foon Tan Date: Tue, 16 Dec 2014 07:28:34 +0000 (+0800) Subject: serial: altera-uart: fix NULL device in log message X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=b820cd7643d5fdf05d6f5d32507d330609113248;p=linux-beck.git serial: altera-uart: fix NULL device in log message Add device pointer to port->dev. Before: "(NULL device *): ttyAL0 at MMIO 0x2020 (irq = 6, base_baud = 3125000) is a Altera UART" After: "altera_uart 2020.serial: ttyAL0 at MMIO 0x2020 (irq = 6, base_baud = 3125000) is a Altera UART" Signed-off-by: Ley Foon Tan Acked-by: Tobias Klauser Acked-by: Pavel Machek Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/tty/serial/altera_uart.c b/drivers/tty/serial/altera_uart.c index eb15a50623cb..b2859fe07e14 100644 --- a/drivers/tty/serial/altera_uart.c +++ b/drivers/tty/serial/altera_uart.c @@ -589,6 +589,7 @@ static int altera_uart_probe(struct platform_device *pdev) port->iotype = SERIAL_IO_MEM; port->ops = &altera_uart_ops; port->flags = UPF_BOOT_AUTOCONF; + port->dev = &pdev->dev; platform_set_drvdata(pdev, port);