Skip to content

Commit b6fd2db

Browse files
Michal Simekgregkh
authored andcommitted
Revert "serial: uartps: Fix error path when alloc failed"
This reverts commit 32cf21a. 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@localhost Reported-by: Johan Hovold <[email protected]> Signed-off-by: Michal Simek <[email protected]> Cc: stable <[email protected]> Link: https://lore.kernel.org/r/46cd7f039db847c08baa6508edd7854f7c8ff80f.1585905873.git.michal.simek@xilinx.com Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 8da1a39 commit b6fd2db

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

drivers/tty/serial/xilinx_uartps.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1542,10 +1542,8 @@ static int cdns_uart_probe(struct platform_device *pdev)
15421542
#ifdef CONFIG_SERIAL_XILINX_PS_UART_CONSOLE
15431543
cdns_uart_console = devm_kzalloc(&pdev->dev, sizeof(*cdns_uart_console),
15441544
GFP_KERNEL);
1545-
if (!cdns_uart_console) {
1546-
rc = -ENOMEM;
1547-
goto err_out_id;
1548-
}
1545+
if (!cdns_uart_console)
1546+
return -ENOMEM;
15491547

15501548
strncpy(cdns_uart_console->name, CDNS_UART_TTY_NAME,
15511549
sizeof(cdns_uart_console->name));

0 commit comments

Comments
 (0)