Merge branch 'for-6.9/amd-sfh' into for-linus
[sfrench/cifs-2.6.git] / drivers / tty / serial / sccnxp.c
index 2be2c10980253fefc9215a4c42e8523b362537a9..f24217a560d7a21a8d9c1048717129494a90bf38 100644 (file)
@@ -1021,7 +1021,7 @@ err_out:
        return ret;
 }
 
-static int sccnxp_remove(struct platform_device *pdev)
+static void sccnxp_remove(struct platform_device *pdev)
 {
        int i;
        struct sccnxp_port *s = platform_get_drvdata(pdev);
@@ -1036,10 +1036,11 @@ static int sccnxp_remove(struct platform_device *pdev)
 
        uart_unregister_driver(&s->uart);
 
-       if (!IS_ERR(s->regulator))
-               return regulator_disable(s->regulator);
-
-       return 0;
+       if (!IS_ERR(s->regulator)) {
+               int ret = regulator_disable(s->regulator);
+               if (ret)
+                       dev_err(&pdev->dev, "Failed to disable regulator\n");
+       }
 }
 
 static struct platform_driver sccnxp_uart_driver = {
@@ -1047,7 +1048,7 @@ static struct platform_driver sccnxp_uart_driver = {
                .name   = SCCNXP_NAME,
        },
        .probe          = sccnxp_probe,
-       .remove         = sccnxp_remove,
+       .remove_new     = sccnxp_remove,
        .id_table       = sccnxp_id_table,
 };
 module_platform_driver(sccnxp_uart_driver);