Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754486AbcL3U1M (ORCPT ); Fri, 30 Dec 2016 15:27:12 -0500 Received: from shards.monkeyblade.net ([184.105.139.130]:46138 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754096AbcL3U1K (ORCPT ); Fri, 30 Dec 2016 15:27:10 -0500 Date: Fri, 30 Dec 2016 15:27:09 -0500 (EST) Message-Id: <20161230.152709.841426532104836350.davem@davemloft.net> To: thomas.preisner+linux@fau.de Cc: dave@thedillows.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-kernel@i4.cs.fau.de, milan.stephan+linux@fau.de, sergei.shtylyov@cogentembedded.com Subject: Re: [PATCH v4 1/2] net: 3com: typhoon: typhoon_init_one: fix incorrect return values From: David Miller In-Reply-To: <1483065474-11512-2-git-send-email-thomas.preisner+linux@fau.de> References: <1482873453.20986.4.camel@dillow-glaptop.roam.corp.google.com> <1483065474-11512-1-git-send-email-thomas.preisner+linux@fau.de> <1483065474-11512-2-git-send-email-thomas.preisner+linux@fau.de> X-Mailer: Mew version 6.7 on Emacs 25.1 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Fri, 30 Dec 2016 11:27:56 -0800 (PST) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 595 Lines: 16 From: Thomas Preisner Date: Fri, 30 Dec 2016 03:37:53 +0100 > In a few cases the err-variable is not set to a negative error code if a > function call in typhoon_init_one() fails and thus 0 is returned > instead. > It may be better to set err to the appropriate negative error > code before returning. > > Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=188841 > > Reported-by: Pan Bian > Signed-off-by: Thomas Preisner > Signed-off-by: Milan Stephan Applied to net-next.