staging: wilc1000: fix line over 80 chars in remove_network_from_shadow()
authorAjay Singh <ajay.kathat@microchip.com>
Wed, 2 May 2018 07:13:31 +0000 (12:43 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 3 May 2018 20:56:34 +0000 (13:56 -0700)
Added changes to avoid line over 80 character issue in
remove_network_from_shadow().

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/wilc1000/wilc_wfi_cfgoperations.c

index af9bbadab9e58231a912877bc6be03858d16a3f0..c93c55d2e2a3c3c53e1f13b97dc4fa229a611e3e 100644 (file)
@@ -253,18 +253,18 @@ static void remove_network_from_shadow(struct timer_list *unused)
        int i, j;
 
        for (i = 0; i < last_scanned_cnt; i++) {
-               if (time_after(now, last_scanned_shadow[i].time_scan +
-                              (unsigned long)(SCAN_RESULT_EXPIRE))) {
-                       kfree(last_scanned_shadow[i].ies);
-                       last_scanned_shadow[i].ies = NULL;
+               if (!time_after(now, last_scanned_shadow[i].time_scan +
+                               (unsigned long)(SCAN_RESULT_EXPIRE)))
+                       continue;
+               kfree(last_scanned_shadow[i].ies);
+               last_scanned_shadow[i].ies = NULL;
 
-                       kfree(last_scanned_shadow[i].join_params);
+               kfree(last_scanned_shadow[i].join_params);
 
-                       for (j = i; (j < last_scanned_cnt - 1); j++)
-                               last_scanned_shadow[j] = last_scanned_shadow[j + 1];
+               for (j = i; (j < last_scanned_cnt - 1); j++)
+                       last_scanned_shadow[j] = last_scanned_shadow[j + 1];
 
-                       last_scanned_cnt--;
-               }
+               last_scanned_cnt--;
        }
 
        if (last_scanned_cnt != 0)