Search Linux Wireless

Re: [PATCHv2 6/6] mac80211: mesh power save basics

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

 



On Thu, 2013-01-17 at 17:34 +0100, Marco Porsch wrote:
> On 01/16/2013 11:14 PM, Johannes Berg wrote:
> > On Mon, 2013-01-07 at 16:04 +0100, Marco Porsch wrote:
> >
> >> mode determines when non-peer mesh STA may send Probe Requests and Mesh Peering
> >
> > Please break lines to less than 72 characters, I personally prefer
> > around 60 or so but I'll apply 72 too.
> >
> >> +static inline bool ieee80211_has_qos_mesh_ps(__le16 qc)
> >> +{
> >> +	return (qc & cpu_to_le16(IEEE80211_QOS_CTL_MESH_PS_LEVEL)) != 0;
> >
> > bool means you don't need the !=0 and parentheses.
> 
> Actually, then it pops the following warning:
>    CHECK   net/mac80211/mesh_ps.c
> include/linux/ieee80211.h:584:19: warning: incorrect type in return 
> expression (different base types)
> include/linux/ieee80211.h:584:19:    expected bool
> include/linux/ieee80211.h:584:19:    got restricted __le16
> 
> 
> Other functions in that file have following style:
> static inline int ieee80211_has_pm(__le16 fc)
> {
> 	return (fc & cpu_to_le16(IEEE80211_FCTL_PM)) != 0;
> }
> 
> What do you recommend?

I'm clearly not quick enough for you, sorry. I guess we should keep it
as is then, but I see you removed it entirely later? Anyway ... I just
wasn't aware sparse would then complain, that's a bit stupid but hey.

johannes

--
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 Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux