From mboxrd@z Thu Jan 1 00:00:00 1970 From: Joe Perches Subject: Re: [net-next 2/7] fm10k: cleanup unnecessary parenthesis in fm10k_iov.c Date: Wed, 31 Jan 2018 03:34:53 -0800 Message-ID: <1517398493.765.55.camel@perches.com> References: <20180124224546.21185-1-jeffrey.t.kirsher@intel.com> <20180124224546.21185-3-jeffrey.t.kirsher@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit Cc: Jacob Keller , netdev@vger.kernel.org, nhorman@redhat.com, sassmann@redhat.com, jogreene@redhat.com To: Jeff Kirsher , davem@davemloft.net Return-path: Received: from smtprelay0181.hostedemail.com ([216.40.44.181]:54738 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752377AbeAaLe6 (ORCPT ); Wed, 31 Jan 2018 06:34:58 -0500 In-Reply-To: <20180124224546.21185-3-jeffrey.t.kirsher@intel.com> Sender: netdev-owner@vger.kernel.org List-ID: On Wed, 2018-01-24 at 14:45 -0800, Jeff Kirsher wrote: > This fixes a few warnings found by checkpatch.pl --strict [] > diff --git a/drivers/net/ethernet/intel/fm10k/fm10k_iov.c b/drivers/net/ethernet/intel/fm10k/fm10k_iov.c [] > @@ -353,7 +353,7 @@ int fm10k_iov_resume(struct pci_dev *pdev) > struct fm10k_vf_info *vf_info = &iov_data->vf_info[i]; > > /* allocate all but the last GLORT to the VFs */ > - if (i == ((~hw->mac.dglort_map) >> FM10K_DGLORTMAP_MASK_SHIFT)) > + if (i == (~hw->mac.dglort_map >> FM10K_DGLORTMAP_MASK_SHIFT)) Strictly, only the if needs parentheses here, but I think it reads better before this change. > @@ -511,7 +511,7 @@ int fm10k_iov_configure(struct pci_dev *pdev, int num_vfs) > return err; > > /* allocate VFs if not already allocated */ > - if (num_vfs && (num_vfs != current_vfs)) { > + if (num_vfs && num_vfs != current_vfs) {