From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932437AbbLBJYr (ORCPT ); Wed, 2 Dec 2015 04:24:47 -0500 Received: from aserp1040.oracle.com ([141.146.126.69]:49485 "EHLO aserp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932405AbbLBJYm (ORCPT ); Wed, 2 Dec 2015 04:24:42 -0500 Date: Wed, 2 Dec 2015 12:23:50 +0300 From: Dan Carpenter To: James Simmons Cc: Greg Kroah-Hartman , devel@driverdev.osuosl.org, Oleg Drokin , Andreas Dilger , Amir Shehata , Linux Kernel Mailing List , lustre-devel@lists.lustre.org Subject: Re: [PATCH 11/40] staging: lustre: DLC Feature dynamic net config Message-ID: <20151202092349.GK18797@mwanda> References: <1448062576-23757-1-git-send-email-jsimmons@infradead.org> <1448062576-23757-12-git-send-email-jsimmons@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1448062576-23757-12-git-send-email-jsimmons@infradead.org> User-Agent: Mutt/1.5.21 (2010-09-15) X-Source-IP: userv0022.oracle.com [156.151.31.74] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 20, 2015 at 06:35:47PM -0500, James Simmons wrote: > + > + return 0; > > failed4: > - lnet_ping_target_fini(); > - failed3: > the_lnet.ln_refcount = 0; > + lnet_ping_md_unlink(pinfo, &md_handle); > + lnet_ping_info_free(pinfo); > + failed3: > lnet_acceptor_stop(); > + rc = LNetEQFree(the_lnet.ln_ping_target_eq); > + LASSERT(rc == 0); ^^^^^^^^^^^^^^^^ > failed2: > lnet_destroy_routes(); > lnet_shutdown_lndnis(); > @@ -1263,8 +1609,12 @@ LNetNIInit(lnet_pid_t requested_pid) > lnet_unprepare(); > failed0: > LASSERT(rc < 0); ^^^^^^^^^^^^^^^ These asserts contradict each other. But mostly please remove all the GW-BASIC style numbered labeled names from this patch. You wouldn't name your variables "int var1, var2, var3" so for label names you should give them meaningful names as well. Don't name them after the goto location, name them after the label location to say the first thing that the label does. err_fini: err_acceptor_stop: err_destroy_routes: err_empty_list: regards, dan carpenter