summaryrefslogtreecommitdiff
path: root/drivers/tty/serial/sunsu.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/tty/serial/sunsu.c')
-rw-r--r--drivers/tty/serial/sunsu.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/tty/serial/sunsu.c b/drivers/tty/serial/sunsu.c
index 0d8465728473..699cc1b5f6aa 100644
--- a/drivers/tty/serial/sunsu.c
+++ b/drivers/tty/serial/sunsu.c
@@ -1454,7 +1454,7 @@ static int su_probe(struct platform_device *op)
kfree(up);
return err;
}
- dev_set_drvdata(&op->dev, up);
+ platform_set_drvdata(op, up);
nr_inst++;
@@ -1483,7 +1483,7 @@ static int su_probe(struct platform_device *op)
if (err)
goto out_unmap;
- dev_set_drvdata(&op->dev, up);
+ platform_set_drvdata(op, up);
nr_inst++;
@@ -1496,7 +1496,7 @@ out_unmap:
static int su_remove(struct platform_device *op)
{
- struct uart_sunsu_port *up = dev_get_drvdata(&op->dev);
+ struct uart_sunsu_port *up = platform_get_drvdata(op);
bool kbdms = false;
if (up->su_type == SU_PORT_MS ||
@@ -1516,8 +1516,6 @@ static int su_remove(struct platform_device *op)
if (kbdms)
kfree(up);
- dev_set_drvdata(&op->dev, NULL);
-
return 0;
}