Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756326Ab2JDJbY (ORCPT ); Thu, 4 Oct 2012 05:31:24 -0400 Received: from metis.ext.pengutronix.de ([92.198.50.35]:53633 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755802Ab2JDJbV (ORCPT ); Thu, 4 Oct 2012 05:31:21 -0400 Message-ID: <506D575F.4040402@pengutronix.de> Date: Thu, 04 Oct 2012 11:31:11 +0200 From: Marc Kleine-Budde Organization: Pengutronix e.K. User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20120907 Thunderbird/15.0.1 MIME-Version: 1.0 To: Peter Senna Tschudin CC: wg@grandegger.com, kernel-janitors@vger.kernel.org, davem@davemloft.net, jj@chaosbits.net, linux-can@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 3/20] drivers/net/can/sja1000/peak_pci.c: fix error return code References: <1349281090-10013-4-git-send-email-peter.senna@gmail.com> In-Reply-To: <1349281090-10013-4-git-send-email-peter.senna@gmail.com> X-Enigmail-Version: 1.4.4 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig5BEFDC20CFC64095788A0E8A" X-SA-Exim-Connect-IP: 2001:6f8:1178:4:5054:ff:fe8d:eefb X-SA-Exim-Mail-From: mkl@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1898 Lines: 63 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig5BEFDC20CFC64095788A0E8A Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 10/03/2012 06:17 PM, Peter Senna Tschudin wrote: > From: Peter Senna Tschudin >=20 > Convert a nonnegative error return code to a negative one, as returned > elsewhere in the function. >=20 > A simplified version of the semantic match that finds this problem is a= s > follows: (http://coccinelle.lip6.fr/) >=20 > // > ( > if@p1 (\(ret < 0\|ret !=3D 0\)) > { ... return ret; } > | > ret@p1 =3D 0 > ) > ... when !=3D ret =3D e1 > when !=3D &ret > *if(...) > { > ... when !=3D ret =3D e2 > when forall > return ret; > } > // >=20 > Signed-off-by: Peter Senna Tschudin Applied to can. Tnx, Marc --=20 Pengutronix e.K. | Marc Kleine-Budde | Industrial Linux Solutions | Phone: +49-231-2826-924 | Vertretung West/Dortmund | Fax: +49-5121-206917-5555 | Amtsgericht Hildesheim, HRA 2686 | http://www.pengutronix.de | --------------enig5BEFDC20CFC64095788A0E8A Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://www.enigmail.net/ iEYEARECAAYFAlBtV18ACgkQjTAFq1RaXHPUhACfZftbepPARo5phiUlDFxBOlhZ KCYAn3uW8Qr0gOg2wGr2nDG+Nf2mkV4/ =9Fva -----END PGP SIGNATURE----- --------------enig5BEFDC20CFC64095788A0E8A-- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/