Subject: Re: [PATCH net 4/4] net: wwan: iosm: fix incorrect skb length

From: Jakub Kicinski <[email-masked]>
Date: Tue, 22 Nov 2022 20:46:44 -0800

On Tue, 22 Nov 2022 23:17:46 +0530 [email-masked] wrote:
> From: M Chetan Kumar <[email-masked]>
> 
> skb passed to network layer contains incorrect length.
> 
> In mux aggregation protocol, the datagram block received
> from device contains block signature, packet & datagram
> header. The right skb len to be calculated by subracting
> datagram pad len from datagram length.
> 
> Whereas in mux lite protocol, the skb contains single
> datagram so skb len is calculated by subtracting the
> packet offset from datagram header.

Sparse says:

drivers/net/wwan/iosm/iosm_ipc_mux_codec.c:478:38: warning: restricted __le16 degrades to integer
drivers/net/wwan/iosm/iosm_ipc_mux_codec.c:571:52: warning: restricted __le16 degrades to integer