aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging
diff options
context:
space:
mode:
authorSvenne Krap <svenne@krap.dk>2010-02-14 12:59:42 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2010-03-03 19:42:58 -0500
commit46800b225f8c9dc264e1e9c15b1e104b9e0af5b5 (patch)
treededeae72a9413d243786438aad4c7625db0e4cc8 /drivers/staging
parentbc2955ddf48d2da94019680fa46deae88d39b40e (diff)
Staging: wlan-ng: clean up assignments in if statements
Trivial changes to code-paths. Signed-off-by: Svenne Krap <svenne@krap.dk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging')
-rw-r--r--drivers/staging/wlan-ng/hfa384x_usb.c24
1 files changed, 16 insertions, 8 deletions
diff --git a/drivers/staging/wlan-ng/hfa384x_usb.c b/drivers/staging/wlan-ng/hfa384x_usb.c
index c6a9e17ec79..bd2eba30484 100644
--- a/drivers/staging/wlan-ng/hfa384x_usb.c
+++ b/drivers/staging/wlan-ng/hfa384x_usb.c
@@ -1909,16 +1909,20 @@ int hfa384x_drvr_flashdl_enable(hfa384x_t *hw)
1909 return -EINVAL; 1909 return -EINVAL;
1910 1910
1911 /* Retrieve the buffer loc&size and timeout */ 1911 /* Retrieve the buffer loc&size and timeout */
1912 if ((result = hfa384x_drvr_getconfig(hw, HFA384x_RID_DOWNLOADBUFFER, 1912
1913 &(hw->bufinfo), 1913 result = hfa384x_drvr_getconfig(hw, HFA384x_RID_DOWNLOADBUFFER,
1914 sizeof(hw->bufinfo)))) { 1914 &(hw->bufinfo), sizeof(hw->bufinfo));
1915 if (result) {
1915 return result; 1916 return result;
1916 } 1917 }
1917 hw->bufinfo.page = le16_to_cpu(hw->bufinfo.page); 1918 hw->bufinfo.page = le16_to_cpu(hw->bufinfo.page);
1918 hw->bufinfo.offset = le16_to_cpu(hw->bufinfo.offset); 1919 hw->bufinfo.offset = le16_to_cpu(hw->bufinfo.offset);
1919 hw->bufinfo.len = le16_to_cpu(hw->bufinfo.len); 1920 hw->bufinfo.len = le16_to_cpu(hw->bufinfo.len);
1920 if ((result = hfa384x_drvr_getconfig16(hw, HFA384x_RID_MAXLOADTIME, 1921
1921 &(hw->dltimeout)))) { 1922 result = hfa384x_drvr_getconfig16(hw, HFA384x_RID_MAXLOADTIME,
1923 &(hw->dltimeout));
1924
1925 if (result) {
1922 return result; 1926 return result;
1923 } 1927 }
1924 hw->dltimeout = le16_to_cpu(hw->dltimeout); 1928 hw->dltimeout = le16_to_cpu(hw->dltimeout);
@@ -3073,7 +3077,9 @@ static void hfa384x_usbctlxq_run(hfa384x_t *hw)
3073 3077
3074 /* Now submit the URB and update the CTLX's state 3078 /* Now submit the URB and update the CTLX's state
3075 */ 3079 */
3076 if ((result = SUBMIT_URB(&hw->ctlx_urb, GFP_ATOMIC)) == 0) { 3080
3081 result = SUBMIT_URB(&hw->ctlx_urb, GFP_ATOMIC);
3082 if (result == 0) {
3077 /* This CTLX is now running on the active queue */ 3083 /* This CTLX is now running on the active queue */
3078 head->state = CTLX_REQ_SUBMITTED; 3084 head->state = CTLX_REQ_SUBMITTED;
3079 3085
@@ -3599,7 +3605,8 @@ static void hfa384x_int_rxmonitor(wlandevice_t *wlandev,
3599 skblen - sizeof(p80211_caphdr_t)); 3605 skblen - sizeof(p80211_caphdr_t));
3600 } 3606 }
3601 3607
3602 if ((skb = dev_alloc_skb(skblen)) == NULL) { 3608 skb = dev_alloc_skb(skblen);
3609 if (skb == NULL) {
3603 printk(KERN_ERR 3610 printk(KERN_ERR
3604 "alloc_skb failed trying to allocate %d bytes\n", 3611 "alloc_skb failed trying to allocate %d bytes\n",
3605 skblen); 3612 skblen);
@@ -3870,7 +3877,8 @@ retry:
3870 3877
3871delresp: 3878delresp:
3872 if (delete_resptimer) { 3879 if (delete_resptimer) {
3873 if ((timer_ok = del_timer(&hw->resptimer)) != 0) { 3880 timer_ok = del_timer(&hw->resptimer);
3881 if (timer_ok != 0) {
3874 hw->resp_timer_done = 1; 3882 hw->resp_timer_done = 1;
3875 } 3883 }
3876 } 3884 }