Skip to content

Commit 2e01911

Browse files
Michal Simekgregkh
authored andcommitted
Revert "serial: uartps: Fix uartps_major handling"
This reverts commit 5e9bd2d. 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/310999ab5342f788a7bc1b0e68294d4f052cad07.1585905873.git.michal.simek@xilinx.com Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 8f3d9f3 commit 2e01911

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

drivers/tty/serial/xilinx_uartps.c

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1564,6 +1564,7 @@ static int cdns_uart_probe(struct platform_device *pdev)
15641564
goto err_out_id;
15651565
}
15661566

1567+
uartps_major = cdns_uart_uart_driver->tty_driver->major;
15671568
cdns_uart_data->cdns_uart_driver = cdns_uart_uart_driver;
15681569

15691570
/*
@@ -1694,7 +1695,6 @@ static int cdns_uart_probe(struct platform_device *pdev)
16941695
console_port = NULL;
16951696
#endif
16961697

1697-
uartps_major = cdns_uart_uart_driver->tty_driver->major;
16981698
cdns_uart_data->cts_override = of_property_read_bool(pdev->dev.of_node,
16991699
"cts-override");
17001700
return 0;
@@ -1756,12 +1756,6 @@ static int cdns_uart_remove(struct platform_device *pdev)
17561756
console_port = NULL;
17571757
#endif
17581758

1759-
/* If this is last instance major number should be initialized */
1760-
mutex_lock(&bitmap_lock);
1761-
if (bitmap_empty(bitmap, MAX_UART_INSTANCES))
1762-
uartps_major = 0;
1763-
mutex_unlock(&bitmap_lock);
1764-
17651759
uart_unregister_driver(cdns_uart_data->cdns_uart_driver);
17661760
return rc;
17671761
}

0 commit comments

Comments
 (0)