Search Linux Wireless

Re: [PATCH] b43: Upload both beacon templates on initial load

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

 



On Tue, 2008-05-20 at 12:16 +0200, Michael Buesch wrote:
> This updates the beacon template code to upload both templates,
> if we never uploaded one before.
...
> +	bool beacon_templates_virgin; /* Never wrote the templates? */
...
> @@ -4164,12 +4191,15 @@ static int b43_op_start(struct ieee80211
>  	 * and mac80211 reconfiguring it. */
>  	memset(wl->bssid, 0, ETH_ALEN);
>  	memset(wl->mac_addr, 0, ETH_ALEN);
>  	wl->filter_flags = 0;
>  	wl->radiotap_enabled = 0;
>  	b43_qos_clear(wl);
> +	wl->beacon0_uploaded = 0;
> +	wl->beacon1_uploaded = 0;
> +	wl->beacon_templates_virgin = 1;

Just a hint.  You may want to revert the logic, so that you start with
0 and set the variable to 1 as something substantial happens.  You can
introduce more states later if required, or count the upload events.

This way, it would be beacon_templates_loaded or
beacon_templates_touched.

The human brain is better at understanding positive meanings.  "virgin"
means that something did _not_ happen, and it's not like it's very
valuable per se, at least for beacon templates :-)

I worked on code full of things like HAVE_NO_CURSES_H and DISABLE_COLOR,
and it wasn't fun.

-- 
Regards,
Pavel Roskin
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux