Message ID | Z9PwOQeBSYlgZlHq@gondor.apana.org.au (mailing list archive) |
---|---|
State | New |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | net: mctp: Remove unnecessary cast in mctp_cb | expand |
Hi Herbert, > The void * cast in mctp_cb is unnecessary as it's already been done > at the start of the function. Thanks for the change, all looks good to me, and now we're consistent with __mctp_cb() above. Acked-by: Jeremy Kerr <jk@codeconstruct.com.au> Cheers, Jeremy
diff --git a/include/net/mctp.h b/include/net/mctp.h index 1ecbff7116f6..07d458990113 100644 --- a/include/net/mctp.h +++ b/include/net/mctp.h @@ -212,7 +212,7 @@ static inline struct mctp_skb_cb *mctp_cb(struct sk_buff *skb) BUILD_BUG_ON(sizeof(struct mctp_skb_cb) > sizeof(skb->cb)); WARN_ON(cb->magic != 0x4d435450); - return (void *)(skb->cb); + return cb; } /* If CONFIG_MCTP_FLOWS, we may add one of these as a SKB extension,
The void * cast in mctp_cb is unnecessary as it's already been done at the start of the function. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>