Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751750AbbKHUQY (ORCPT ); Sun, 8 Nov 2015 15:16:24 -0500 Received: from mail-yk0-f174.google.com ([209.85.160.174]:35569 "EHLO mail-yk0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750912AbbKHUQW (ORCPT ); Sun, 8 Nov 2015 15:16:22 -0500 MIME-Version: 1.0 In-Reply-To: <20151108065145.GA1183@alpha.sfu-kras.ru> References: <20151108065145.GA1183@alpha.sfu-kras.ru> Date: Sun, 8 Nov 2015 22:16:21 +0200 Message-ID: Subject: Re: [PATCH 10/12] staging: rtl8188eu: reg_macid variable removed in hw_var_set_macaddr From: Andy Shevchenko To: Ivan Safonov Cc: devel@driverdev.osuosl.org, Greg Kroah-Hartman , Vaishali Thakkar , Jakub Sitnicki , Anish Bhatt , Joe Perches , Nicholas Mc Guire , Alexey Khoroshilov , =?UTF-8?Q?R=C3=A9my_Oudompheng?= , Sudip Mukherjee , Shraddha Barke , "linux-kernel@vger.kernel.org" Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1829 Lines: 54 On Sun, Nov 8, 2015 at 8:51 AM, Ivan Safonov wrote: > The reg_macid variable used only once. Also idx renamed to i and Adapter to adapter. > > Signed-off-by: Ivan Safonov > --- > drivers/staging/rtl8188eu/hal/usb_halinit.c | 11 ++++------- > 1 file changed, 4 insertions(+), 7 deletions(-) > > diff --git a/drivers/staging/rtl8188eu/hal/usb_halinit.c b/drivers/staging/rtl8188eu/hal/usb_halinit.c > index 5789e1e..e1d6632 100644 > --- a/drivers/staging/rtl8188eu/hal/usb_halinit.c > +++ b/drivers/staging/rtl8188eu/hal/usb_halinit.c > @@ -1253,15 +1253,12 @@ static void hw_var_set_opmode(struct adapter *Adapter, u8 variable, u8 *val) > } > } > > -static void hw_var_set_macaddr(struct adapter *Adapter, u8 variable, u8 *val) > +static void hw_var_set_macaddr(struct adapter *adapter, u8 variable, u8 *val) > { > - u8 idx = 0; > - u32 reg_macid; > - > - reg_macid = REG_MACID; > + int i; > > - for (idx = 0; idx < 6; idx++) > - usb_write8(Adapter, (reg_macid+idx), val[idx]); > + for (i = 0; i < 6; i++) ETH_ALEN? > + usb_write8(adapter, REG_MACID + i, val[i]); > } > > static void hw_var_set_bssid(struct adapter *Adapter, u8 variable, u8 *val) > -- > 2.4.10 > > -- > 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/ -- With Best Regards, Andy Shevchenko -- 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/