Commit c2f5fde1 authored by Anton Wuerfel's avatar Anton Wuerfel Committed by Greg Kroah-Hartman

tty: serial: 8250: Remove else after return

This patch fixes checkpatch warnings about unnecessary else blocks after
return statements.
Signed-off-by: default avatarAnton Würfel <anton.wuerfel@fau.de>
Signed-off-by: default avatarPhillip Raffeck <phillip.raffeck@fau.de>
Reviewed-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: linux-kernel@i4.cs.fau.de
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 740dc2de
...@@ -805,10 +805,10 @@ static int pci_netmos_9900_numports(struct pci_dev *dev) ...@@ -805,10 +805,10 @@ static int pci_netmos_9900_numports(struct pci_dev *dev)
pi = (c & 0xff); pi = (c & 0xff);
if (pi == 2) { if (pi == 2)
return 1; return 1;
} else if ((pi == 0) &&
(dev->device == PCI_DEVICE_ID_NETMOS_9900)) { if ((pi == 0) && (dev->device == PCI_DEVICE_ID_NETMOS_9900)) {
/* two possibilities: 0x30ps encodes number of parallel and /* two possibilities: 0x30ps encodes number of parallel and
* serial ports, or 0x1000 indicates *something*. This is not * serial ports, or 0x1000 indicates *something*. This is not
* immediately obvious, since the 2s1p+4s configuration seems * immediately obvious, since the 2s1p+4s configuration seems
...@@ -816,12 +816,12 @@ static int pci_netmos_9900_numports(struct pci_dev *dev) ...@@ -816,12 +816,12 @@ static int pci_netmos_9900_numports(struct pci_dev *dev)
* advertising the same function 3 as the 4s+2s1p config. * advertising the same function 3 as the 4s+2s1p config.
*/ */
sub_serports = dev->subsystem_device & 0xf; sub_serports = dev->subsystem_device & 0xf;
if (sub_serports > 0) { if (sub_serports > 0)
return sub_serports; return sub_serports;
} else {
dev_err(&dev->dev, "NetMos/Mostech serial driver ignoring port on ambiguous config.\n"); dev_err(&dev->dev,
return 0; "NetMos/Mostech serial driver ignoring port on ambiguous config.\n");
} return 0;
} }
moan_device("unknown NetMos/Mostech program interface", dev); moan_device("unknown NetMos/Mostech program interface", dev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment