Search Linux Wireless

Re: [PATCH 08/10] cfg80211: make regulatory_request use wiphy_idx instead of wiphy

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

 



On Mon, 2009-02-16 at 02:11 -0800, Luis R. Rodriguez wrote:

> >> * Driver hints which never have the wiphy NULL
> >> * __regulatory_hint: called from 11d hints, and from the workqueue
> >> that processes the pending requests (which can come from userspace or
> >> from drivers right now).
> >
> > Ok, but in the first case you can't have NULL, and in the second you
> > could just inline it. It's not an operation that requires an inline here
> > for it.
> 
> Sure, its just called twice

Yeah but the first call is entirely pointless since wiphy cannot be NULL
there. I don't want to encourage random error-checking accessors where
writing wiphy->wiphy_idx is perfectly fine.

>  and I think it makes the code more
> readable to use a routine, what if I just move it to core.c or reg.c.

If you really think it makes the code that much more readable then
please just use it once in the case where a NULL argument can happen
(the workqueue), and move it to that code.

johannes

Attachment: signature.asc
Description: This is a digitally signed message part


[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