staging: ks7010: replace uint8_t in favour of u8 in michael_append
authorSergio Paracuellos <sergio.paracuellos@gmail.com>
Wed, 28 Mar 2018 15:24:27 +0000 (17:24 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 29 Mar 2018 09:49:12 +0000 (11:49 +0200)
This commit replaces param which is uint8_t in michael_append
function in favour of preferred one u8. It also removes no more
needed casts when calling this function.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/ks7010/michael_mic.c

index 0b59865..d171cba 100644 (file)
@@ -47,7 +47,7 @@ static inline void michael_block(struct michael_mic_t *mic)
        mic->l += mic->r;
 }
 
-static void michael_append(struct michael_mic_t *mic, uint8_t *src, int bytes)
+static void michael_append(struct michael_mic_t *mic, u8 *src, int bytes)
 {
        int addlen;
 
@@ -125,8 +125,8 @@ void michael_mic_function(struct michael_mic_t *mic, u8 *key,
         * +--+--+--------+--+----+--+--+--+--+--+--+--+--+
         */
        michael_init(mic, key);
-       michael_append(mic, (uint8_t *)data, 12);       /* |DA|SA| */
+       michael_append(mic, data, 12);  /* |DA|SA| */
        michael_append(mic, pad_data, 4);       /* |Priority|0|0|0| */
-       michael_append(mic, (uint8_t *)(data + 12), len - 12);  /* |Data| */
+       michael_append(mic, data + 12, len - 12);       /* |Data| */
        michael_get_mic(mic, result);
 }