diff options
author | Felix Fietkau <nbd@openwrt.org> | 2014-11-23 13:54:28 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2014-11-23 13:54:28 +0000 |
commit | 25cb8318cd686a91c626c668b2ceaf85e8234d7a (patch) | |
tree | 26ab9a56b83751eb643ef6dfd1fa83f1da4d5fcd /target/linux/ar71xx/patches-3.10/103-tty-ar933x_uart-convert-to-use-devm_-functions.patch | |
parent | 01794562126c90aa6bb99dd95be7f09f59a47fc2 (diff) | |
download | upstream-25cb8318cd686a91c626c668b2ceaf85e8234d7a.tar.gz upstream-25cb8318cd686a91c626c668b2ceaf85e8234d7a.tar.bz2 upstream-25cb8318cd686a91c626c668b2ceaf85e8234d7a.zip |
ar71xx: remove linux 3.10 support
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 43344
Diffstat (limited to 'target/linux/ar71xx/patches-3.10/103-tty-ar933x_uart-convert-to-use-devm_-functions.patch')
-rw-r--r-- | target/linux/ar71xx/patches-3.10/103-tty-ar933x_uart-convert-to-use-devm_-functions.patch | 72 |
1 files changed, 0 insertions, 72 deletions
diff --git a/target/linux/ar71xx/patches-3.10/103-tty-ar933x_uart-convert-to-use-devm_-functions.patch b/target/linux/ar71xx/patches-3.10/103-tty-ar933x_uart-convert-to-use-devm_-functions.patch deleted file mode 100644 index fab6f23416..0000000000 --- a/target/linux/ar71xx/patches-3.10/103-tty-ar933x_uart-convert-to-use-devm_-functions.patch +++ /dev/null @@ -1,72 +0,0 @@ -From f157945cd134e2cfa47ed9bb1f599632d112d94e Mon Sep 17 00:00:00 2001 -From: Gabor Juhos <juhosg@openwrt.org> -Date: Mon, 29 Jul 2013 19:39:20 +0200 -Subject: [PATCH] tty: ar933x_uart: convert to use devm_* functions - -Use devm_* functions in order to simplify cleanup -paths. - -Signed-off-by: Gabor Juhos <juhosg@openwrt.org> ---- - drivers/tty/serial/ar933x_uart.c | 26 ++++++++------------------ - 1 file changed, 8 insertions(+), 18 deletions(-) - ---- a/drivers/tty/serial/ar933x_uart.c -+++ b/drivers/tty/serial/ar933x_uart.c -@@ -652,19 +652,18 @@ static int ar933x_uart_probe(struct plat - return -EINVAL; - } - -- up = kzalloc(sizeof(struct ar933x_uart_port), GFP_KERNEL); -+ up = devm_kzalloc(&pdev->dev, sizeof(struct ar933x_uart_port), -+ GFP_KERNEL); - if (!up) - return -ENOMEM; - - port = &up->port; -- port->mapbase = mem_res->start; - -- port->membase = ioremap(mem_res->start, AR933X_UART_REGS_SIZE); -- if (!port->membase) { -- ret = -ENOMEM; -- goto err_free_up; -- } -+ port->membase = devm_ioremap_resource(&pdev->dev, mem_res); -+ if (IS_ERR(port->membase)) -+ return PTR_ERR(port->membase); - -+ port->mapbase = mem_res->start; - port->line = id; - port->irq = irq_res->start; - port->dev = &pdev->dev; -@@ -686,16 +685,10 @@ static int ar933x_uart_probe(struct plat - - ret = uart_add_one_port(&ar933x_uart_driver, &up->port); - if (ret) -- goto err_unmap; -+ return ret; - - platform_set_drvdata(pdev, up); - return 0; -- --err_unmap: -- iounmap(up->port.membase); --err_free_up: -- kfree(up); -- return ret; - } - - static int ar933x_uart_remove(struct platform_device *pdev) -@@ -705,11 +698,8 @@ static int ar933x_uart_remove(struct pla - up = platform_get_drvdata(pdev); - platform_set_drvdata(pdev, NULL); - -- if (up) { -+ if (up) - uart_remove_one_port(&ar933x_uart_driver, &up->port); -- iounmap(up->port.membase); -- kfree(up); -- } - - return 0; - } |