Re: [RFC PATCH 06/17] net: sched: explicit locking in gso_cpu fallback

2017-11-16 Thread John Fastabend
On 11/15/2017 09:51 AM, Willem de Bruijn wrote: > On Wed, Nov 15, 2017 at 10:11 AM, John Fastabend > wrote: >> On 11/14/2017 04:41 PM, Willem de Bruijn wrote: /* use instead of qdisc->dequeue() for all qdiscs queried with ->peek() */ static inline struct sk_buff *qdisc_dequeue_peeked(s

Re: [RFC PATCH 06/17] net: sched: explicit locking in gso_cpu fallback

2017-11-15 Thread Willem de Bruijn
On Wed, Nov 15, 2017 at 10:11 AM, John Fastabend wrote: > On 11/14/2017 04:41 PM, Willem de Bruijn wrote: >>> /* use instead of qdisc->dequeue() for all qdiscs queried with ->peek() */ >>> static inline struct sk_buff *qdisc_dequeue_peeked(struct Qdisc *sch) >>> { >>> - struct sk_buff *sk

Re: [RFC PATCH 06/17] net: sched: explicit locking in gso_cpu fallback

2017-11-15 Thread John Fastabend
On 11/14/2017 04:41 PM, Willem de Bruijn wrote: >> /* use instead of qdisc->dequeue() for all qdiscs queried with ->peek() */ >> static inline struct sk_buff *qdisc_dequeue_peeked(struct Qdisc *sch) >> { >> - struct sk_buff *skb = sch->gso_skb; >> + struct sk_buff *skb = skb_peek(&sc

Re: [RFC PATCH 06/17] net: sched: explicit locking in gso_cpu fallback

2017-11-14 Thread Willem de Bruijn
>> -static inline int dev_requeue_skb(struct sk_buff *skb, struct Qdisc *q) >> +static inline int __dev_requeue_skb(struct sk_buff *skb, struct Qdisc *q) >> { > > Perhaps dev_requeue_skb_qdisc_locked is more descriptive. Or > adding a lockdep_is_held(..) also documents that the __locked variant >

Re: [RFC PATCH 06/17] net: sched: explicit locking in gso_cpu fallback

2017-11-14 Thread Willem de Bruijn
> /* use instead of qdisc->dequeue() for all qdiscs queried with ->peek() */ > static inline struct sk_buff *qdisc_dequeue_peeked(struct Qdisc *sch) > { > - struct sk_buff *skb = sch->gso_skb; > + struct sk_buff *skb = skb_peek(&sch->gso_skb); > > if (skb) { > -

[RFC PATCH 06/17] net: sched: explicit locking in gso_cpu fallback

2017-11-13 Thread John Fastabend
This work is preparing the qdisc layer to support egress lockless qdiscs. If we are running the egress qdisc lockless in the case we overrun the netdev, for whatever reason, the netdev returns a busy error code and the skb is parked on the gso_skb pointer. With many cores all hitting this case at o

[RFC PATCH 06/17] net: sched: explicit locking in gso_cpu fallback

2017-05-02 Thread John Fastabend
This work is preparing the qdisc layer to support egress lockless qdiscs. If we are running the egress qdisc lockless in the case we overrun the netdev, for whatever reason, the netdev returns a busy error code and the skb is parked on the gso_skb pointer. With many cores all hitting this case at o