On Sun, 12 Nov 2023 22:05:30 -0800 Mina Almasry wrote:
> My issue here is that all these skb helpers call each other so I end
> up having to move a lot of the unrelated skb helpers to this new
> header (maybe that is acceptable but it feels weird).
Splitting pp headers again is not an option, we
On Fri, Nov 10, 2023 at 3:19 PM Jakub Kicinski wrote:
>
> On Sun, 5 Nov 2023 18:44:07 -0800 Mina Almasry wrote:
> > #include
> > #include
> > +#include
> > +#include
>
> > /**
> > * DOC: skb checksums
> > @@ -3402,15 +3404,38 @@ static inline void skb_frag_off_copy(skb_frag_t
> >
On Sun, 5 Nov 2023 18:44:07 -0800 Mina Almasry wrote:
> #include
> #include
> +#include
> +#include
> /**
> * DOC: skb checksums
> @@ -3402,15 +3404,38 @@ static inline void skb_frag_off_copy(skb_frag_t
> *fragto,
> fragto->bv_offset = fragfrom->bv_offset;
> }
>
> +/* Returns
On Thu, Nov 9, 2023 at 1:15 AM Paolo Abeni wrote:
>
> On Sun, 2023-11-05 at 18:44 -0800, Mina Almasry wrote:
> [...]
> > @@ -3421,7 +3446,7 @@ static inline struct page *skb_frag_page(const
> > skb_frag_t *frag)
> > */
> > static inline void __skb_frag_ref(skb_frag_t *frag)
> > {
> > -
On Sun, 2023-11-05 at 18:44 -0800, Mina Almasry wrote:
[...]
> @@ -3421,7 +3446,7 @@ static inline struct page *skb_frag_page(const
> skb_frag_t *frag)
> */
> static inline void __skb_frag_ref(skb_frag_t *frag)
> {
> - get_page(skb_frag_page(frag));
> +
On 2023/11/8 5:19, Mina Almasry wrote:
>>
>>
>
> My personal immediate reaction is that this may just introduce code
> churn without significant benefit. If an unsuspecting caller call
> skb_frag_page() on devmem frag and doesn't correctly handle NULL
> return, it will crash or error out anyway,
On Tue, Nov 7, 2023 at 1:00 AM Yunsheng Lin wrote:
>
> On 2023/11/6 10:44, Mina Almasry wrote:
> > Make skb_frag_page() fail in the case where the frag is not backed
> > by a page, and fix its relevent callers to handle this case.
> >
> > Correctly handle skb_frag refcounting in the
On 2023/11/6 10:44, Mina Almasry wrote:
> Make skb_frag_page() fail in the case where the frag is not backed
> by a page, and fix its relevent callers to handle this case.
>
> Correctly handle skb_frag refcounting in the page_pool_iovs case.
>
> Signed-off-by: Mina Almasry
>
...
> /**
> *
Make skb_frag_page() fail in the case where the frag is not backed
by a page, and fix its relevent callers to handle this case.
Correctly handle skb_frag refcounting in the page_pool_iovs case.
Signed-off-by: Mina Almasry
---
include/linux/skbuff.h | 42