diff options
Diffstat (limited to 'drivers/tty/serial/vt8500_serial.c')
-rw-r--r-- | drivers/tty/serial/vt8500_serial.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/tty/serial/vt8500_serial.c b/drivers/tty/serial/vt8500_serial.c index 205d4cf4a063..8fd181436a6b 100644 --- a/drivers/tty/serial/vt8500_serial.c +++ b/drivers/tty/serial/vt8500_serial.c | |||
@@ -554,7 +554,7 @@ static struct uart_driver vt8500_uart_driver = { | |||
554 | .cons = VT8500_CONSOLE, | 554 | .cons = VT8500_CONSOLE, |
555 | }; | 555 | }; |
556 | 556 | ||
557 | static int __devinit vt8500_serial_probe(struct platform_device *pdev) | 557 | static int vt8500_serial_probe(struct platform_device *pdev) |
558 | { | 558 | { |
559 | struct vt8500_port *vt8500_port; | 559 | struct vt8500_port *vt8500_port; |
560 | struct resource *mmres, *irqres; | 560 | struct resource *mmres, *irqres; |
@@ -567,10 +567,6 @@ static int __devinit vt8500_serial_probe(struct platform_device *pdev) | |||
567 | if (!mmres || !irqres) | 567 | if (!mmres || !irqres) |
568 | return -ENODEV; | 568 | return -ENODEV; |
569 | 569 | ||
570 | vt8500_port = kzalloc(sizeof(struct vt8500_port), GFP_KERNEL); | ||
571 | if (!vt8500_port) | ||
572 | return -ENOMEM; | ||
573 | |||
574 | if (np) | 570 | if (np) |
575 | port = of_alias_get_id(np, "serial"); | 571 | port = of_alias_get_id(np, "serial"); |
576 | if (port > VT8500_MAX_PORTS) | 572 | if (port > VT8500_MAX_PORTS) |
@@ -593,6 +589,10 @@ static int __devinit vt8500_serial_probe(struct platform_device *pdev) | |||
593 | return -EBUSY; | 589 | return -EBUSY; |
594 | } | 590 | } |
595 | 591 | ||
592 | vt8500_port = kzalloc(sizeof(struct vt8500_port), GFP_KERNEL); | ||
593 | if (!vt8500_port) | ||
594 | return -ENOMEM; | ||
595 | |||
596 | vt8500_port->uart.type = PORT_VT8500; | 596 | vt8500_port->uart.type = PORT_VT8500; |
597 | vt8500_port->uart.iotype = UPIO_MEM; | 597 | vt8500_port->uart.iotype = UPIO_MEM; |
598 | vt8500_port->uart.mapbase = mmres->start; | 598 | vt8500_port->uart.mapbase = mmres->start; |
@@ -634,7 +634,7 @@ err: | |||
634 | return ret; | 634 | return ret; |
635 | } | 635 | } |
636 | 636 | ||
637 | static int __devexit vt8500_serial_remove(struct platform_device *pdev) | 637 | static int vt8500_serial_remove(struct platform_device *pdev) |
638 | { | 638 | { |
639 | struct vt8500_port *vt8500_port = platform_get_drvdata(pdev); | 639 | struct vt8500_port *vt8500_port = platform_get_drvdata(pdev); |
640 | 640 | ||
@@ -652,7 +652,7 @@ static const struct of_device_id wmt_dt_ids[] = { | |||
652 | 652 | ||
653 | static struct platform_driver vt8500_platform_driver = { | 653 | static struct platform_driver vt8500_platform_driver = { |
654 | .probe = vt8500_serial_probe, | 654 | .probe = vt8500_serial_probe, |
655 | .remove = __devexit_p(vt8500_serial_remove), | 655 | .remove = vt8500_serial_remove, |
656 | .driver = { | 656 | .driver = { |
657 | .name = "vt8500_serial", | 657 | .name = "vt8500_serial", |
658 | .owner = THIS_MODULE, | 658 | .owner = THIS_MODULE, |