]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
staging: ks7010: fix line continuations
authorTobin C. Harding <me@tobin.cc>
Mon, 13 Mar 2017 06:38:18 +0000 (17:38 +1100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 13 Mar 2017 22:20:06 +0000 (06:20 +0800)
Checkpatch emits CHECK: Logical continuations should be on the
previous line. Also the same code section causes checkpatch to emit
WARNING: Avoid multiple line dereference.

Move logical line continuations onto the previous line. Move multiple
line dereferences onto single line.

Make these two changes in a single patch to give review a chance
to critique the final layout of the *complex* logical statement.

Signed-off-by: Tobin C. Harding <me@tobin.cc>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/ks7010/ks_hostif.c

index 54ff06d1e799141592289149cba558ccbd3621ba..461482b6e47966e08fc9aa475b64c4683aabea35 100644 (file)
@@ -332,16 +332,13 @@ int hostif_data_indication_wpa(struct ks_wlan_private *priv,
                priv->nstats.rx_errors++;
                return -EINVAL;
        }
-       if (((auth_type == TYPE_PMK1
-                               && priv->wpa.pairwise_suite ==
-                               IW_AUTH_CIPHER_TKIP) || (auth_type == TYPE_GMK1
-                                                       && priv->wpa.
-                                                       group_suite ==
-                                                       IW_AUTH_CIPHER_TKIP)
-                       || (auth_type == TYPE_GMK2
-                               && priv->wpa.group_suite ==
-                               IW_AUTH_CIPHER_TKIP))
-               && priv->wpa.key[auth_type - 1].key_len) {
+       if (((auth_type == TYPE_PMK1 &&
+             priv->wpa.pairwise_suite == IW_AUTH_CIPHER_TKIP) ||
+            (auth_type == TYPE_GMK1 &&
+             priv->wpa.group_suite == IW_AUTH_CIPHER_TKIP) ||
+            (auth_type == TYPE_GMK2 &&
+             priv->wpa.group_suite == IW_AUTH_CIPHER_TKIP)) &&
+           priv->wpa.key[auth_type - 1].key_len) {
                DPRINTK(4, "TKIP: protocol=%04X: size=%u\n",
                        eth_proto, priv->rx_size);
                /* MIC save */