From: Matthew Wilcox
> Sent: 23 July 2019 04:09
> Improved compatibility with bvec
> 
> Signed-off-by: Matthew Wilcox (Oracle) <wi...@infradead.org>
> ---
>  include/linux/skbuff.h | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h
> index 8076e2ba8349..e849e411d1f3 100644
> --- a/include/linux/skbuff.h
> +++ b/include/linux/skbuff.h
> @@ -312,7 +312,7 @@ typedef struct skb_frag_struct skb_frag_t;
> 
>  struct skb_frag_struct {
>       struct page *bv_page;
> -     __u32 size;
> +     unsigned int bv_len;
>       __u32 page_offset;
>  };

This is 'just plain stupid'.
The 'bv_' prefix of the members of 'struct bvec' is there so that 'grep'
(etc) can be used to find the uses of the members.

In a 'struct skb_frag_struct' a sensible prefix might be 'sf_'.

OTOH it might be sensible to use (or embed) a 'struct bvec'
instead of 'skb_frag_struct'.

        David

-
Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, 
UK
Registration No: 1397386 (Wales)

Reply via email to