On Tue, Jan 11, 2011 at 2:54 AM, Levi, Shahar <shahar_levi@xxxxxx> wrote: >>> diff --git a/drivers/net/wireless/wl12xx/acx.c b/drivers/net/wireless/wl12xx/acx.c >>> index 54fd68d..f33ab50 100644 >>> --- a/drivers/net/wireless/wl12xx/acx.c >>> +++ b/drivers/net/wireless/wl12xx/acx.c >>> @@ -1359,6 +1359,42 @@ out: >>> return ret; >>> } >>> >>> +/* setup BA session receiver setting in the FW. */ >>> +int wl1271_acx_set_ba_receiver_session(struct wl1271 *wl, u8 tid_index, >>> + u16 *ssn, u8 policy) >> >> You don't modify ssn here, so why pass it as a pointer? Use u16 directly >> here instead. >> >> Actually it's even worse. As stated in mac80211.h, ssn can be NULL >> here, so you would be accessing a NULL pointer in that case. >> >> I see that you check "policy", which indicates whether ssn is valid or >> not, but why not make it cleaner by checking if ssn is NULL and setting >> it to zero before passing instead? > good chtch. it was left from previous implantation. will be fix. There is two options from you suggestion: a) move ssn directly and then check policy if it is valid b) keep ssn as pointer and check it to validate it is valid. I will use a option. Thanks, Shahar -- 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