From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Wed, 6 Aug 2014 23:28:27 +0300 From: Dan Carpenter Subject: Re: [PATCH 3/5] staging: dgnc: Fix that open brace { should be on the previous line Message-ID: <20140806202827.GF4856@mwanda> References: <1407351686-7217-1-git-send-email-bergo.torino@gmail.com> <1407351686-7217-2-git-send-email-bergo.torino@gmail.com> <1407351686-7217-3-git-send-email-bergo.torino@gmail.com> <1407351686-7217-4-git-send-email-bergo.torino@gmail.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1407351686-7217-4-git-send-email-bergo.torino@gmail.com> List-Id: Linux Driver Project Developer List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: driverdev-devel-bounces@linuxdriverproject.org Sender: driverdev-devel-bounces@linuxdriverproject.org To: Konrad Zapalowicz Cc: devel@driverdev.osuosl.org, lidza.louina@gmail.com, driverdev-devel@linuxdriverproject.org, gregkh@linuxfoundation.org On Wed, Aug 06, 2014 at 09:01:24PM +0200, Konrad Zapalowicz wrote: > @@ -1935,8 +1935,8 @@ static void neo_vpd(struct dgnc_board *brd) > > if (((brd->vpd[0x08] != 0x82) /* long resource name tag */ > && (brd->vpd[0x10] != 0x82)) /* long resource name tag (PCI-66 files)*/ > - || (brd->vpd[0x7F] != 0x78)) /* small resource end tag */ > - { > + || (brd->vpd[0x7F] != 0x78)) { /* small resource end tag */ > + This condition should really be written like this: if ((brd->vpd[0x08] != 0x82 && /* long resource name tag */ brd->vpd[0x10] != 0x82) || /* (PCI-66 files) */ brd->vpd[0x7F] != 0x78) { /* small resource end tag */ Except that the magical numbers should be defines and then we could remove the comments. This stuff could be changed in a later patch, no worries. TODO-list: 2014-08-06: dgnc: Too many magic numbers regards, dan carpenter > memset(brd->vpd, '\0', NEO_VPD_IMAGESIZE); > } else { > /* Search for the serial number */ _______________________________________________ devel mailing list devel@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel