aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/serial/of_serial.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/serial/of_serial.c')
-rw-r--r--drivers/serial/of_serial.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/serial/of_serial.c b/drivers/serial/of_serial.c
index 14f8fa9135be..54483cd3529e 100644
--- a/drivers/serial/of_serial.c
+++ b/drivers/serial/of_serial.c
@@ -122,7 +122,7 @@ static int __devinit of_platform_serial_probe(struct of_device *ofdev,
122 122
123 info->type = port_type; 123 info->type = port_type;
124 info->line = ret; 124 info->line = ret;
125 ofdev->dev.driver_data = info; 125 dev_set_drvdata(&ofdev->dev, info);
126 return 0; 126 return 0;
127out: 127out:
128 kfree(info); 128 kfree(info);
@@ -135,7 +135,7 @@ out:
135 */ 135 */
136static int of_platform_serial_remove(struct of_device *ofdev) 136static int of_platform_serial_remove(struct of_device *ofdev)
137{ 137{
138 struct of_serial_info *info = ofdev->dev.driver_data; 138 struct of_serial_info *info = dev_get_drvdata(&ofdev->dev);
139 switch (info->type) { 139 switch (info->type) {
140#ifdef CONFIG_SERIAL_8250 140#ifdef CONFIG_SERIAL_8250
141 case PORT_8250 ... PORT_MAX_8250: 141 case PORT_8250 ... PORT_MAX_8250: