From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754017AbZGXTWN (ORCPT ); Fri, 24 Jul 2009 15:22:13 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752834AbZGXTWM (ORCPT ); Fri, 24 Jul 2009 15:22:12 -0400 Received: from qw-out-2122.google.com ([74.125.92.24]:39122 "EHLO qw-out-2122.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751256AbZGXTWL convert rfc822-to-8bit (ORCPT ); Fri, 24 Jul 2009 15:22:11 -0400 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=TLo8KgAdfFhBgOoUuK23k0ooqnRJzINzTy8z/Y0WoyV/M2CLaSnCFDeVpgueinU7Ir pLnuZluZdDS1ijPupqsGdQaHrmSmD9ITsQDp3CVai5edl0Bt70YJNPUhqV00zPVeYksX r2Pn9+KIJZOQIkJef4NOCD1/Ybhc1Zio0AL5E= MIME-Version: 1.0 In-Reply-To: References: <20090724124803.ltfbg57ooyoko0gs@my5.dal.ca> <20090724173422.GA10989@suse.de> Date: Fri, 24 Jul 2009 16:22:10 -0300 Message-ID: Subject: Fwd: [PATCH] Removed useless retval variables in usb-serial.c From: Trevor Pace To: Greg KH Cc: linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Forgot to CC the mailing list as well on this one. Sorry, Trevor Pace ---------- Forwarded message ---------- From: Trevor Pace Date: Fri, Jul 24, 2009 at 2:47 PM Subject: Re: [PATCH] Removed useless retval variables in usb-serial.c To: Greg KH Hey Greg, First off, thanks for the feedback. As you can probably tell I haven't done much kernel patching before. Perhaps "useless" wasn't the term I should have used. Those retval variables seemed to just add more to the code then appears to be necessary.  You are right though the compiler probably optimized them right out of the code so I can't imagine a performance increase as a result of this. I quite like that idea of having the code fall out the bottom and I guess I just never really thought about it that way. Anyway thanks again, Trevor Pace On Fri, Jul 24, 2009 at 2:34 PM, Greg KH wrote: > On Fri, Jul 24, 2009 at 12:48:03PM -0300, Trevor Pace wrote: >> Removed useless return value variables. > > Why are they "useless"? > > They seem useful to me, especially as it causes the code to fall out of > the function at the bottom, and not in the middle, which makes > maintaining the code easier to do over time, right? > > And did this actually cause any generated code to be > faster/smaller/better? > > Oh, and you seem to have messed up a bit of whitespace, please always > run your patches through scripts/checkpatch.pl first. > > thanks, > > greg k-h > -- > 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/ >