Commit b6fd2dbb authored by Michal Simek's avatar Michal Simek Committed by Greg Kroah-Hartman

Revert "serial: uartps: Fix error path when alloc failed"

This reverts commit 32cf21ac.

As Johan says, this driver needs a lot more work and these changes are
only going in the wrong direction:
  https://lkml.kernel.org/r/20190523091839.GC568@localhostReported-by: default avatarJohan Hovold <johan@kernel.org>
Signed-off-by: default avatarMichal Simek <michal.simek@xilinx.com>
Cc: stable <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/46cd7f039db847c08baa6508edd7854f7c8ff80f.1585905873.git.michal.simek@xilinx.comSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 8da1a394
......@@ -1542,10 +1542,8 @@ static int cdns_uart_probe(struct platform_device *pdev)
#ifdef CONFIG_SERIAL_XILINX_PS_UART_CONSOLE
cdns_uart_console = devm_kzalloc(&pdev->dev, sizeof(*cdns_uart_console),
GFP_KERNEL);
if (!cdns_uart_console) {
rc = -ENOMEM;
goto err_out_id;
}
if (!cdns_uart_console)
return -ENOMEM;
strncpy(cdns_uart_console->name, CDNS_UART_TTY_NAME,
sizeof(cdns_uart_console->name));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment