lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1452515429.26146.11.camel@linux.intel.com>
Date:	Mon, 11 Jan 2016 14:30:29 +0200
From:	Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
To:	Anton Wuerfel <anton.wuerfel@....de>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc:	Jiri Slaby <jslaby@...e.com>,
	"James E.J. Bottomley" <jejb@...isc-linux.org>,
	Helge Deller <deller@....de>,
	Peter Hurley <peter@...leysoftware.com>,
	Heikki Krogerus <heikki.krogerus@...ux.intel.com>,
	Qipeng Zha <qipeng.zha@...el.com>,
	Desmond Liu <desmondl@...adcom.com>,
	Wang Long <long.wanglong@...wei.com>,
	Matt Redfearn <matt.redfearn@...tec.com>,
	Paul Burton <paul.burton@...tec.com>,
	Ralf Baechle <ralf@...ux-mips.org>,
	Krzysztof Kozlowski <k.kozlowski@...sung.com>,
	Peter Hung <hpeter@...il.com>,
	Soeren Grunewald <soeren.grunewald@...y.de>,
	Adam Lee <adam.lee@...onical.com>,
	"Maciej S. Szmigiero" <mail@...iej.szmigiero.name>,
	Mans Rullgard <mans@...sr.com>, linux-kernel@...r.kernel.org,
	linux-parisc@...r.kernel.org, linux-kernel@...cs.fau.de,
	phillip.raffeck@....de
Subject: Re: [PATCH v4 05/13] tty: serial: 8250: Remove else after return

On Fri, 2016-01-08 at 18:43 +0100, Anton Wuerfel wrote:
> This patch fixes checkpatch warnings about unnecessary else blocks
> after
> return statements.

> --- a/drivers/tty/serial/8250/8250_pci.c
> +++ b/drivers/tty/serial/8250/8250_pci.c
> @@ -805,10 +805,10 @@ static int pci_netmos_9900_numports(struct
> pci_dev *dev)
>  
>  	pi = (c & 0xff);

And here the parens are redundant.

>  
> -	if (pi == 2) {
> +	if (pi == 2)
>  		return 1;
> -	} else if ((pi == 0) &&
> -			   (dev->device ==
> PCI_DEVICE_ID_NETMOS_9900)) {
> +
> +	if ((pi == 0) && (dev->device == PCI_DEVICE_ID_NETMOS_9900))
> {

-- 
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Intel Finland Oy

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ