aboutsummaryrefslogtreecommitdiffstats
path: root/0012-synclink_gt.c-move-assignment-out-of-if-block.patch
diff options
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-08-21 16:34:49 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-08-21 16:34:49 +0200
commit4758ee8bc89a86c2110b9e85878538ced8045ef5 (patch)
tree69539cae6631b1981fb23b51e01566f9e84f635d /0012-synclink_gt.c-move-assignment-out-of-if-block.patch
parent02611ede94f297e19bea81ddf41425a24569a545 (diff)
downloadpatches-4758ee8bc89a86c2110b9e85878538ced8045ef5.tar.gz
add new patch and remove ones that were long ago merged
Diffstat (limited to '0012-synclink_gt.c-move-assignment-out-of-if-block.patch')
-rw-r--r--0012-synclink_gt.c-move-assignment-out-of-if-block.patch73
1 files changed, 0 insertions, 73 deletions
diff --git a/0012-synclink_gt.c-move-assignment-out-of-if-block.patch b/0012-synclink_gt.c-move-assignment-out-of-if-block.patch
deleted file mode 100644
index 897470758e14a8..00000000000000
--- a/0012-synclink_gt.c-move-assignment-out-of-if-block.patch
+++ /dev/null
@@ -1,73 +0,0 @@
-From 1989ebb4bdb26b1c90a74fd64c7407222e8e2fee Mon Sep 17 00:00:00 2001
-From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-Date: Wed, 29 Apr 2015 16:22:08 +0200
-Subject: [PATCH 12/36] tty: synclink_gt.c: move assignment out of if () block
-
-We should not be doing assignments within an if () block
-so fix up the code to not do this.
-
-change was created using Coccinelle.
-
-CC: Jiri Slaby <jslaby@suse.cz>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- drivers/tty/synclink_gt.c | 15 ++++++++++-----
- 1 file changed, 10 insertions(+), 5 deletions(-)
-
-diff --git a/drivers/tty/synclink_gt.c b/drivers/tty/synclink_gt.c
-index 0e8c39b6ccd4..0ea8eee00178 100644
---- a/drivers/tty/synclink_gt.c
-+++ b/drivers/tty/synclink_gt.c
-@@ -1539,7 +1539,8 @@ static int hdlcdev_open(struct net_device *dev)
- DBGINFO(("%s hdlcdev_open\n", dev->name));
-
- /* generic HDLC layer open processing */
-- if ((rc = hdlc_open(dev)))
-+ rc = hdlc_open(dev);
-+ if (rc)
- return rc;
-
- /* arbitrate between network and tty opens */
-@@ -1803,7 +1804,8 @@ static int hdlcdev_init(struct slgt_info *info)
-
- /* allocate and initialize network and HDLC layer objects */
-
-- if (!(dev = alloc_hdlcdev(info))) {
-+ dev = alloc_hdlcdev(info);
-+ if (!dev) {
- printk(KERN_ERR "%s hdlc device alloc failure\n", info->device_name);
- return -ENOMEM;
- }
-@@ -1824,7 +1826,8 @@ static int hdlcdev_init(struct slgt_info *info)
- hdlc->xmit = hdlcdev_xmit;
-
- /* register objects with HDLC layer */
-- if ((rc = register_hdlc_device(dev))) {
-+ rc = register_hdlc_device(dev);
-+ if (rc) {
- printk(KERN_WARNING "%s:unable to register hdlc device\n",__FILE__);
- free_netdev(dev);
- return rc;
-@@ -1879,7 +1882,8 @@ static void rx_async(struct slgt_info *info)
-
- stat = 0;
-
-- if ((status = *(p+1) & (BIT1 + BIT0))) {
-+ status = *(p + 1) & (BIT1 + BIT0);
-+ if (status) {
- if (status & BIT1)
- icount->parity++;
- else if (status & BIT0)
-@@ -3755,7 +3759,8 @@ static void slgt_cleanup(void)
- if (serial_driver) {
- for (info=slgt_device_list ; info != NULL ; info=info->next_device)
- tty_unregister_device(serial_driver, info->line);
-- if ((rc = tty_unregister_driver(serial_driver)))
-+ rc = tty_unregister_driver(serial_driver);
-+ if (rc)
- DBGERR(("tty_unregister_driver error=%d\n", rc));
- put_tty_driver(serial_driver);
- }
---
-2.3.7
-