Search Linux Wireless

RE: [PATCH 1/5] wifi: rtl8xxxu: Add central frequency offset tracking

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> -----Original Message-----
> From: Bitterblue Smith <rtl8821cerfe2@xxxxxxxxx>
> Sent: Saturday, October 22, 2022 2:32 AM
> To: Ping-Ke Shih <pkshih@xxxxxxxxxxx>; linux-wireless@xxxxxxxxxxxxxxx
> Cc: Jes Sorensen <Jes.Sorensen@xxxxxxxxx>
> Subject: Re: [PATCH 1/5] wifi: rtl8xxxu: Add central frequency offset tracking
> 
> On 21/10/2022 08:47, Ping-Ke Shih wrote:
> >
> >
> >> -----Original Message-----
> >> From: Bitterblue Smith <rtl8821cerfe2@xxxxxxxxx>
> >> Sent: Monday, October 17, 2022 1:27 AM
> [...]
> >> +			if (priv->cfo_tracking.packet_count == 0xffffffff)
> >> +				priv->cfo_tracking.packet_count = 0;
> >> +			else
> >> +				priv->cfo_tracking.packet_count++;
> >
> > 'packet_count' is u32, so 0xffffffff + 1 will become 0. Then, just
> >
> >    priv->cfo_tracking.packet_count++;
> >
> 
> I thought so, but I'm not *that* familiar with the C standard,
> so I left it how I found it in one of the Realtek drivers.

'packet_count' is used as a sequence number to indicate number of received
packets is changed, and then it can re-calculate CFO. So, don't worry to
do packet_count++, not just left code from Realtek vendor driver. This is
one reason that we need to rewrite the driver for Linux upstream.

Ping-Ke





[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux