diff options
author | Huang Shijie <b32955@freescale.com> | 2012-09-11 15:30:30 +0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-09-11 12:21:33 -0700 |
commit | 23666a74c9f552bc9cfef20ded1b8b29bedb80c6 (patch) | |
tree | 928253889b5fa1e00a59ad72e2d2ca1ad0bc2d9f /drivers/tty/serial/mxs-auart.c | |
parent | cdd86b277dc82220aa630414896505517a02a201 (diff) |
serial: mxs-auart: put the device in the error path
The mxs_auart_probe() gets the device by the get_device().
So we should put the device in the error path to balance the
device's reference counter.
Signed-off-by: Huang Shijie <b32955@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/serial/mxs-auart.c')
-rw-r--r-- | drivers/tty/serial/mxs-auart.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/tty/serial/mxs-auart.c b/drivers/tty/serial/mxs-auart.c index 68984136bfb..6db3baa39a9 100644 --- a/drivers/tty/serial/mxs-auart.c +++ b/drivers/tty/serial/mxs-auart.c @@ -781,6 +781,7 @@ out_free_irq: auart_port[pdev->id] = NULL; free_irq(s->irq, s); out_free_clk: + put_device(s->dev); clk_put(s->clk); out_free: kfree(s); |