Message ID | 1503482375-19983-2-git-send-email-arvind.yadav.cs@gmail.com (mailing list archive) |
---|---|
State | Accepted |
Commit | 28b75415ad19fef232d8daab4d5de17d753f0b36 |
Delegated to: | Kalle Valo |
Headers | show |
Arvind Yadav <arvind.yadav.cs@gmail.com> wrote: > rate_control_ops are not supposed to change at runtime. All functions > working with rate_control_ops provided by <net/mac80211.h> work with > const rate_control_ops. So mark the non-const structs as const. > > Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com> 2 patches applied to wireless-drivers-next.git, thanks. 28b75415ad19 wireless: ipw2200: Replace PCI pool old API 9ea792a48cdd net: rsi: mac80211: constify ieee80211_ops
diff --git a/drivers/net/wireless/realtek/rtlwifi/rc.c b/drivers/net/wireless/realtek/rtlwifi/rc.c index 951d257..02811ed 100644 --- a/drivers/net/wireless/realtek/rtlwifi/rc.c +++ b/drivers/net/wireless/realtek/rtlwifi/rc.c @@ -283,7 +283,7 @@ static void rtl_rate_free_sta(void *rtlpriv, kfree(rate_priv); } -static struct rate_control_ops rtl_rate_ops = { +static const struct rate_control_ops rtl_rate_ops = { .name = "rtl_rc", .alloc = rtl_rate_alloc, .free = rtl_rate_free,
rate_control_ops are not supposed to change at runtime. All functions working with rate_control_ops provided by <net/mac80211.h> work with const rate_control_ops. So mark the non-const structs as const. Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com> --- drivers/net/wireless/realtek/rtlwifi/rc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)