lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 11 May 2023 17:21:07 +0300
From:   Dan Carpenter <dan.carpenter@...aro.org>
To:     Yogesh Hegde <yogi.kernel@...il.com>
Cc:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        linux-staging@...ts.linux.dev, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/4] staging: rtl8192e: Rename tmpRegA and TempCCk

On Thu, May 11, 2023 at 07:48:23PM +0530, Yogesh Hegde wrote:
> On Wed, May 10, 2023 at 07:56:29PM +0300, Dan Carpenter wrote:
> > On Wed, May 10, 2023 at 08:39:07PM +0530, Yogesh Hegde wrote:
> > > @@ -680,17 +680,17 @@ static void _rtl92e_dm_tx_power_tracking_cb_thermal(struct net_device *dev)
> > >  		return;
> > >  	}
> > >  
> > > -	tmpRegA = rtl92e_get_rf_reg(dev, RF90_PATH_A, 0x12, 0x078);
> > > -	if (tmpRegA < 3 || tmpRegA > 13)
> > > +	tmp_reg = rtl92e_get_rf_reg(dev, RF90_PATH_A, 0x12, 0x078);
> > > +	if (tmp_reg < 3 || tmp_reg > 13)
> > >  		return;
> > > -	if (tmpRegA >= 12)
> > > -		tmpRegA = 12;
> > > +	if (tmp_reg >= 12)
> > > +		tmp_reg = 12;
> > 
> > Not related to your patch (which is fine) but this if statement can be
> > deleted.
> > 
> > >  	priv->thermal_meter[0] = ThermalMeterVal;
> > >  	priv->thermal_meter[1] = ThermalMeterVal;
> > >  
> > > -	if (priv->thermal_meter[0] >= (u8)tmpRegA) {
> > > +	if (priv->thermal_meter[0] >= (u8)tmp_reg) {
> > 
> > And casting tmp_reg to u8 is nonsense so that casting can be deleted too.
> > 2 separate patches:
> > patch 1: delete unecessary if statement
> > patch 2: delete unecessary casting
> 
> Thank you for taking the time to review my patch and provide your
> feedback. Your suggestions are duly noted, and I appreciate your 
> guidance.
> 
> I will make them into separate patches and submit it. 

You don't have to if you don't want to.  We can apply the patches you
sent as-is.  (No need to resend).  This was just in case anyone felt
motivated to do some more clean up work.

regards,
dan carpenter

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ