diff options
author | Ivan Safonov <insafonov@gmail.com> | 2015-10-27 18:18:10 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-10-29 03:09:08 +0300 |
commit | ad8d8cd3b507fd72a64a61412623450740182828 (patch) | |
tree | 3c1857ebee95654dafca4f087b9d601648f38fe1 /drivers/staging/rtl8188eu/core/rtw_ap.c | |
parent | 20e765310e003651378d8b58bb1e74f8e4b35c08 (diff) | |
download | linux-ad8d8cd3b507fd72a64a61412623450740182828.tar.xz |
staging: rtl8188eu: ternary operator (?:) replaced by min_t kernel macro
min_t macro better conveys the meaning of the code.
Signed-off-by: Ivan Safonov <insafonov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/rtl8188eu/core/rtw_ap.c')
-rw-r--r-- | drivers/staging/rtl8188eu/core/rtw_ap.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/rtl8188eu/core/rtw_ap.c b/drivers/staging/rtl8188eu/core/rtw_ap.c index 5c45f8a8c2cf..3cdb40fea5ee 100644 --- a/drivers/staging/rtl8188eu/core/rtw_ap.c +++ b/drivers/staging/rtl8188eu/core/rtw_ap.c @@ -1795,7 +1795,7 @@ int rtw_ap_inform_ch_switch(struct adapter *padapter, u8 new_ch, u8 ch_offset) plist = plist->next; issue_action_spct_ch_switch(padapter, psta->hwaddr, new_ch, ch_offset); - psta->expire_to = ((pstapriv->expire_to * 2) > 5) ? 5 : (pstapriv->expire_to * 2); + psta->expire_to = min_t(unsigned int, pstapriv->expire_to * 2, 5); } spin_unlock_bh(&pstapriv->asoc_list_lock); |