tu to some completely different value most of the time. This patch
fixes the issue by logging in with the previously used mtu value and
printing an error message saying that the given mtu is unsupported.
Signed-off-by: John Allen
---
diff --git a/drivers/net/ethernet/ibm/ibmvnic.c
b/driver
it will be symmetrically freed during release resources.
Signed-off-by: John Allen
---
diff --git a/drivers/net/ethernet/ibm/ibmvnic.c
b/drivers/net/ethernet/ibm/ibmvnic.c
index bb56460..f0dbb76 100644
--- a/drivers/net/ethernet/ibm/ibmvnic.c
+++ b/drivers/net/ethernet/ibm/ibmvnic.c
@@ -867,7
the original code doesn't make sense,
> we should propagate the errno from notifiers.
>
> Cc: John Fastabend
> Signed-off-by: Cong Wang
> ---
[...]
> static ssize_t tx_queue_len_store(struct device *dev,
> struct device_attribute *a
the original code doesn't make sense,
> we should propagate the errno from notifiers.
>
> Cc: John Fastabend
> Signed-off-by: Cong Wang
> ---
Acked-by: John Fastabend
e skb array
> when we change dev->tx_queue_len.
>
> To avoid handling race conditions with TX BH, we need to
> deactivate all TX queues before change the value and bring them
> back after we are done, this also makes implementation easier.
>
> Cc: John Fastabend
> S
d to revert this,
commit 752fbcc33405d6f8249465e4b2c4e420091bb825
Author: Cong Wang
Date: Tue Sep 19 13:15:42 2017 -0700
net_sched: no need to free qdisc in RCU callback
gen estimator has been rewritten in commit 1c0d32fde5bd
("net_sched: gen_estimator: complete rewrite of rate estimators"),
the caller no longer needs to wait for a grace period. So this
patch gets rid of it.
Cc: Jamal Hadi Salim
Cc: Eric Dumazet
Signed-off-by: Cong Wang
Acked-by: Eric Dumazet
Signed-off-by: David S. Miller
Thanks,
John
to RCU callback. Otherwise we risk the datapath
adding skbs during removal.
Fixes: c5ad119fb6c09 ("net: sched: pfifo_fast use skb_array")
Signed-off-by: John Fastabend
---
include/net/sch_generic.h |1 +
net/sched/sch_generic.c | 50 -
2 fil
;kfree_rcu
>
> I assumed that since q is processed in rcu reader, it is also freed after
> a grace period, but now looking at the code I don't see it happening
> like that.
>
> So I think that change to miniq made the existing race window
> a bit wider and easier to hit.
>
> I believe that calling kfree_rcu by call_rcu should resolve this.
>
Hi,
Just sent a patch to complete qdisc_destroy from rcu callback. This
is needed to resolve a race with the lockless qdisc patches.
But I guess it should fix the miniq issue as well?
Thanks,
John
g with the qdisc itself in:
>> qdisc_destroy->qdisc_free
>>
>> Before miniq, tp was checked in the rcu reader path. In case it was not
>> null, q was processed. In slow patch, tp is freed after rcu grace period:
>> tcf_proto_destroy->kfree_rcu
>>
>> I assumed that sin
On 12/20/2017 12:17 PM, Jakub Kicinski wrote:
> On Wed, 20 Dec 2017 10:04:17 -0800, John Fastabend wrote:
>> On 12/19/2017 10:34 PM, Jakub Kicinski wrote:
>>> On Tue, 19 Dec 2017 22:22:27 -0800, Jakub Kicinski wrote:
>>>>>> I get this:
>>>&
On 12/20/2017 02:41 PM, Cong Wang wrote:
> On Wed, Dec 20, 2017 at 12:09 PM, John Fastabend
> wrote:
>> RCU grace period is needed for lockless qdiscs added in the commit
>> c5ad119fb6c09 ("net: sched: pfifo_fast use skb_array").
>>
>> It is needed now
On 12/20/2017 03:23 PM, Cong Wang wrote:
> On Wed, Dec 20, 2017 at 3:05 PM, John Fastabend
> wrote:
>> On 12/20/2017 02:41 PM, Cong Wang wrote:
>>> On Wed, Dec 20, 2017 at 12:09 PM, John Fastabend
>>> wrote:
>>>> RCU grace period is need
On 12/20/2017 01:59 PM, Jakub Kicinski wrote:
> On Wed, 20 Dec 2017 12:09:19 -0800, John Fastabend wrote:
>> RCU grace period is needed for lockless qdiscs added in the commit
>> c5ad119fb6c09 ("net: sched: pfifo_fast use skb_array").
>>
>> It is needed now tha
stats_cpu_backlog_dec(qdisc, skb);
>>631 qdisc_bstats_cpu_update(qdisc, skb);
>>632 qdisc_qstats_cpu_qlen_dec(qdisc);
>>633 }
>>634
>>635 return skb;
>>636 }
>
> Yeah, this one is c
Fixes: c5ad119fb6c0 ("net: sched: pfifo_fast use skb_array")
> Reported-by: Jakub Kicinski
> Cc: John Fastabend
> Signed-off-by: Cong Wang
> ---
> net/sched/sch_generic.c | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/net/sched/sch_generic.c b/net/s
n't help. And it is only a
local_bh_disable.
> Fixes: 7bbde83b1860 ("net: sched: drop qdisc_reset from dev_graft_qdisc")
> Reported-by: Jakub Kicinski
> Cc: John Fastabend
> Signed-off-by: Cong Wang
> ---
> net/sched/sch_generic.c | 5 -
> 1 file chang
On 12/22/2017 12:31 PM, Cong Wang wrote:
> On Thu, Dec 21, 2017 at 7:06 PM, John Fastabend
> wrote:
>> On 12/21/2017 04:03 PM, Cong Wang wrote:
>>> __skb_array_empty() is only safe if array is never resized.
>>> pfifo_fast_dequeue() is called in TX BH context and w
On 12/24/2017 07:49 PM, Wei Yongjun wrote:
> When dev_requeue_skb() is called with bluked skb list, only the
> first skb of the list will be requeued to qdisc layer, and leak
> the others without free them.
>
> TCP is broken due to skb leak since no free skb will be considered
> as still in the ho
On 12/27/2017 10:29 AM, Cong Wang wrote:
> On Sat, Dec 23, 2017 at 10:57 PM, John Fastabend
> wrote:
>> On 12/22/2017 12:31 PM, Cong Wang wrote:
>>> I understand why you had it, but it is just not safe. You don't want
>>> to achieve performance gain by crash
e normal case checks would suffer some so best to just
allocate an extra pointer.
Reported-by: Jakub Kicinski
Fixes: c5ad119fb6c09 ("net: sched: pfifo_fast use skb_array")
Signed-off-by: John Fastabend
---
include/linux/ptr_ring.h |7 ++-
1 file changed, 6 insertions(+), 1 delet
On 01/02/2018 09:17 AM, Michael S. Tsirkin wrote:
> On Tue, Jan 02, 2018 at 07:01:33PM +0200, Michael S. Tsirkin wrote:
>> On Tue, Jan 02, 2018 at 11:52:19AM -0500, David Miller wrote:
>>> From: John Fastabend
>>> Date: Wed, 27 Dec 2017 19:50:25 -0800
>>&g
On 01/02/2018 10:49 AM, David Miller wrote:
> From: Wei Yongjun
> Date: Wed, 27 Dec 2017 17:05:52 +0800
>
>> When dev_requeue_skb() is called with bluked skb list, only the
> ^^
>
> "bulked"
>
>> first skb of the list will be requeued to qdisc layer,
On 01/02/2018 03:12 PM, Michael S. Tsirkin wrote:
> On Tue, Jan 02, 2018 at 01:27:23PM -0800, John Fastabend wrote:
>> On 01/02/2018 09:17 AM, Michael S. Tsirkin wrote:
>>> On Tue, Jan 02, 2018 at 07:01:33PM +0200, Michael S. Tsirkin wrote:
>>>> On Tue, Jan 02, 2
obvious in my opinion.
Signed-off-by: John Fastabend
---
kernel/bpf/sockmap.c |7 +++
1 file changed, 7 insertions(+)
diff --git a/kernel/bpf/sockmap.c b/kernel/bpf/sockmap.c
index 5ee2e41..dfbbde2 100644
--- a/kernel/bpf/sockmap.c
+++ b/kernel/bpf/sockmap.c
@@ -591,6 +591,13 @@ static
On 01/03/2018 07:50 AM, Michael S. Tsirkin wrote:
> On Tue, Jan 02, 2018 at 04:25:03PM -0800, John Fastabend wrote:
>>>
>>> More generally, what makes this usage safe?
>>> Is there a way to formalize it at the API level?
>>>
>>
>> Right I think
On 01/02/2018 08:41 PM, Cong Wang wrote:
> Hi, John
>
> While reviewing your ptr_ring fix again today, it looks like your
> "lockless" qdisc patchset breaks dev->tx_queue_len behavior.
>
> Before your patchset, dev->tx_queue_len is merely an integer to read,
&g
The sockmap infrastructure is only aware of TCP sockets at the
moment. In the future we plan to add UDP. In both cases CONFIG_NET
should be built-in.
So lets only build sockmap if CONFIG_INET is enabled.
Signed-off-by: John Fastabend
---
include/linux/bpf.h |2 +-
include/linux
This was added for some work that was eventually factored out but the
helper call was missed. Remove it now and add it back later if needed.
Signed-off-by: John Fastabend
---
kernel/bpf/sockmap.c |8
1 file changed, 8 deletions(-)
diff --git a/kernel/bpf/sockmap.c b/kernel/bpf
On 01/03/2018 03:41 PM, Cong Wang wrote:
> On Wed, Jan 3, 2018 at 10:09 AM, John Fastabend
> wrote:
>> On 01/02/2018 08:41 PM, Cong Wang wrote:
>>> Hi, John
>>>
>>> While reviewing your ptr_ring fix again today, it looks like your
>>> "lockl
obvious in my opinion.
Signed-off-by: John Fastabend
---
kernel/bpf/sockmap.c | 11 +--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/kernel/bpf/sockmap.c b/kernel/bpf/sockmap.c
index 5ee2e41..1712d31 100644
--- a/kernel/bpf/sockmap.c
+++ b/kernel/bpf/sockmap.c
@@ -591,8
>
> Cc: intel-wired-...@lists.osuosl.org
> Cc: Jeff Kirsher
> Cc: Alexander Duyck
> Signed-off-by: Jesper Dangaard Brouer
> ---
Looked a bit for reset paths that might be missed but didn't
find any. LGTM.
Acked-by: John Fastabend
t; Cc: intel-wired-...@lists.osuosl.org
> Cc: Björn Töpel
> Cc: Jeff Kirsher
> Cc: Paul Menzel
> Signed-off-by: Jesper Dangaard Brouer
> Reviewed-by: Paul Menzel
> ---
Same here. LGTM.
Acked-by: John Fastabend
igned-off-by: Jesper Dangaard Brouer
> Acked-by: Alexei Starovoitov
> ---
LGTM
Acked-by: John Fastabend
On 01/03/2018 02:25 AM, Jesper Dangaard Brouer wrote:
> This patch only introduce the core data structures and API functions.
> All XDP enabled drivers must use the API before this info can used.
>
> There is a need for XDP to know more about the RX-queue a given XDP
> frames have arrived on. For
f-by: Alexei Starovoitov
> ---
LGTM, I'll drop it on my test systems and start running with it.
Although I don't have any Variant 1 code to test, but seems that
is being covered by others.
Thanks!
Acked-by: John Fastabend
future.
Signed-off-by: John Fastabend
---
samples/sockmap/sockmap_user.c | 142 +---
1 file changed, 103 insertions(+), 39 deletions(-)
diff --git a/samples/sockmap/sockmap_user.c b/samples/sockmap/sockmap_user.c
index 7cc9d22..5cbe7a5 100644
--- a/samples/sockmap
seful, the reporting could be better, etc. But,
IMO lets push this now rather than sit on it for weeks until I get
time to do the above improvements.
---
John Fastabend (7):
bpf: refactor sockmap sample program update for arg parsing
bpf: add sendmsg option for testing BPF programs
supported, but more can be added as
needed.
The new help argument gives the following,
Usage: ./sockmap --cgroup
options:
--help -h
--cgroup -c
--rate -r
--verbose -v
--iov_count-i
--length -l
--test -t
Signed-off-by: John Fastabend
get many GBps of data which helps exercise the
sockmap code.
Signed-off-by: John Fastabend
---
samples/sockmap/sockmap_user. |0
samples/sockmap/sockmap_user.c | 55
2 files changed, 39 insertions(+), 16 deletions(-)
create mode 100644 samples
-by: John Fastabend
---
samples/sockmap/sockmap_user.c |2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/samples/sockmap/sockmap_user.c b/samples/sockmap/sockmap_user.c
index bae85f8..0d8950f 100644
--- a/samples/sockmap/sockmap_user.c
+++ b/samples/sockmap/sockmap_user.c
Add a base test that does not use BPF hooks to test baseline case.
Signed-off-by: John Fastabend
---
samples/sockmap/sockmap_user.c | 26 +-
1 file changed, 21 insertions(+), 5 deletions(-)
diff --git a/samples/sockmap/sockmap_user.c b/samples/sockmap/sockmap_user.c
Report bytes/sec sent as well as total bytes. Useful to get rough
idea how different configurations and usage patterns perform with
sockmap.
Signed-off-by: John Fastabend
---
samples/sockmap/sockmap_user.c | 37 -
1 file changed, 32 insertions(+), 5
Avoid extra step of setting limit from cmdline and do it directly in
the program.
Signed-off-by: John Fastabend
---
samples/sockmap/sockmap_user.c |7 +++
1 file changed, 7 insertions(+)
diff --git a/samples/sockmap/sockmap_user.c b/samples/sockmap/sockmap_user.c
index 0d8950f..2afbefd
CKs along with fixes to 2/7 iov free
also pointed out by Martin.
Thanks Daniel and Martin for the reviews!
---
John Fastabend (7):
bpf: refactor sockmap sample program update for arg parsing
bpf: add sendmsg option for testing BPF programs
bpf: sockmap sample, use fork() fo
future.
Signed-off-by: John Fastabend
Acked-by: Martin KaFai Lau
---
samples/sockmap/sockmap_user.c | 165
1 file changed, 114 insertions(+), 51 deletions(-)
diff --git a/samples/sockmap/sockmap_user.c b/samples/sockmap/sockmap_user.c
index 7cc9d22..ffd1d12
get many GBps of data which helps exercise the
sockmap code.
Signed-off-by: John Fastabend
Acked-by: Martin KaFai Lau
---
samples/sockmap/sockmap_user.c | 55
1 file changed, 39 insertions(+), 16 deletions(-)
diff --git a/samples/sockmap/sockmap_user.c
supported, but more can be added as
needed.
The new help argument gives the following,
Usage: ./sockmap --cgroup
options:
--help -h
--cgroup -c
--rate -r
--verbose -v
--iov_count-i
--length -l
--test -t
Signed-off-by: John Fastabend
Report bytes/sec sent as well as total bytes. Useful to get rough
idea how different configurations and usage patterns perform with
sockmap.
Signed-off-by: John Fastabend
Acked-by: Martin KaFai Lau
---
samples/sockmap/sockmap_user.c | 47
1 file
Add a base test that does not use BPF hooks to test baseline case.
Signed-off-by: John Fastabend
Acked-by: Martin KaFai Lau
---
samples/sockmap/sockmap_user.c | 26 +-
1 file changed, 21 insertions(+), 5 deletions(-)
diff --git a/samples/sockmap/sockmap_user.c b
Avoid extra step of setting limit from cmdline and do it directly in
the program.
Signed-off-by: John Fastabend
Acked-by: Martin KaFai Lau
---
samples/sockmap/sockmap_user.c |7 +++
1 file changed, 7 insertions(+)
diff --git a/samples/sockmap/sockmap_user.c b/samples/sockmap
-by: John Fastabend
Acked-by: Martin KaFai Lau
---
samples/sockmap/sockmap_user.c |2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/samples/sockmap/sockmap_user.c b/samples/sockmap/sockmap_user.c
index f9d3785..fe943c9 100644
--- a/samples/sockmap/sockmap_user.c
+++ b/samples
rgeted to -bpf-next and without fixes tag?
>
> No need. It's fine.
>
Also I'm looking over sockmap code now for the bug, should have
something shortly.
Agree this is a nice cleanup of the test code though. On the other
hand I should add some explicit tests for this case (deleting map
with elements) as well though.
.John
other patch set can
cleanup the bigger issue of rollback.
Thanks,
.John
other patch set can
cleanup the bigger issue of rollback.
Thanks,
.John
On 01/23/2018 10:16 AM, Daniel Borkmann wrote:
> On 01/23/2018 06:18 AM, John Fastabend wrote:
>> On 01/22/2018 09:01 PM, Alexei Starovoitov wrote:
>>> On Tue, Jan 23, 2018 at 01:55:30PM +0900, Prashant Bhole wrote:
>>>> On 1/23/2018 1:38 PM, Alexei Starovoitov wrote:
e skb array
> when we change dev->tx_queue_len.
>
> To avoid handling race conditions with TX BH, we need to
> deactivate all TX queues before change the value and bring them
> back after we are done, this also makes implementation easier.
>
> Cc: John Fastabend
> S
-
> 1 file changed, 16 insertions(+), 9 deletions(-)
>
Thanks for fixing this up.
Acked-by: John Fastabend
ssed to kmalloc().
>
> kmalloc then returns ZERO_SIZE_PTR with a subsequent crash.
>
> Reported-by: syzbot+87678bcf753b44c39...@syzkaller.appspotmail.com
> Cc: John Fastabend
> Signed-off-by: Michael S. Tsirkin
> ---
Dang, I missed this case. Thanks.
Acked-by: John Fastabe
sample or preferably a selftest for this case
as well (assuming I didn't miss one).
@Dave Watson can you take a quick look to verify the changes are
good on TLS ULP side.
---
John Fastabend (3):
net: add a UID to use for ULP socket assignment
bpf: sockmap, add sock close() hook
() handler. This fixes the above case.
Fixes: 174a79ff9515 ("bpf: sockmap with sk redirect support")
Reported-by: Prashant Bhole
Signed-off-by: John Fastabend
---
include/net/tcp.h|2 +
kernel/bpf/sockmap.c | 145 +++---
2 files c
("bpf: sockmap with sk redirect support")
Signed-off-by: John Fastabend
---
kernel/bpf/sockmap.c | 19 ++-
1 file changed, 14 insertions(+), 5 deletions(-)
diff --git a/kernel/bpf/sockmap.c b/kernel/bpf/sockmap.c
index b85a79c..a8cd1b7 100644
--- a/kernel/bpf/sockmap.c
+
error code back and should check
that rather than rely on logs.
Signed-off-by: John Fastabend
---
include/net/tcp.h |6 ++
net/ipv4/tcp_ulp.c | 53 +++-
net/tls/tls_main.c |2 ++
3 files changed, 56 insertions(+), 5 deletions(-)
diff --
On 01/25/2018 04:26 PM, John Fastabend wrote:
> A set of fixes for sockmap to resolve map/prog not being cleaned
> up when maps are not cleaned up from the program side.
>
Well that first sentence is a bit confusing now that I read it again.
Here is a better version,
"
A se
On 01/26/2018 07:52 AM, Dave Watson wrote:
> On 01/25/18 04:27 PM, John Fastabend wrote:
>> I did not however retest TLS with the small change to ULP layer.
>> Mostly because I don't have a TLS setup. I plan/hope to get around
>> to writing either a sample or preferabl
The following series implements...
---
John Fastabend (3):
net: add a UID to use for ULP socket assignment
bpf: sockmap, add sock close() hook to remove socks
bpf: sockmap, fix leaking maps with attached but not detached progs
include/net/tcp.h|8 ++
kernel/bpf
On 01/26/2018 09:43 AM, John Fastabend wrote:
> The following series implements...
>
> ---
>
Sorry random noise on my side fat-fingered some keys.
Please just ignore it. :/
avoid
any reader confusion.
---
John Fastabend (3):
net: add a UID to use for ULP socket assignment
bpf: sockmap, add sock close() hook to remove socks
bpf: sockmap, fix leaking maps with attached but not detached progs
include/net/tcp.h|8 ++
kernel/bpf/sockmap.c |
error code back and should check
that rather than rely on logs.
Signed-off-by: John Fastabend
---
include/net/tcp.h |6 +
net/ipv4/tcp_ulp.c | 57 +++-
net/tls/tls_main.c |2 ++
3 files changed, 60 insertions(+), 5 deletions(-)
diff --
("bpf: sockmap with sk redirect support")
Signed-off-by: John Fastabend
---
kernel/bpf/sockmap.c | 19 ++-
1 file changed, 14 insertions(+), 5 deletions(-)
diff --git a/kernel/bpf/sockmap.c b/kernel/bpf/sockmap.c
index 4e7ba37..a30449d 100644
--- a/kernel/bpf/sockmap.c
+
() handler. This fixes the above case.
Fixes: 174a79ff9515 ("bpf: sockmap with sk redirect support")
Reported-by: Prashant Bhole
Signed-off-by: John Fastabend
---
include/net/tcp.h|2 +
kernel/bpf/sockmap.c | 146 +++---
2 files c
On 01/26/2018 10:14 AM, John Fastabend wrote:
> The selftests test_maps program was leaving dangling BPF sockmap
> programs around because not all psock elements were removed from
> the map. The elements in turn hold a reference on the BPF program
> they are attached to causing BPF
net-next) so lets do the complete fix
rather than this series IMO.
.John
> ---
> v3: use skb_array_resize_multiple()
> v2: handle error case for ->change_tx_queue_len()
>
> Cong Wang (3):
> net: introduce helper dev_change_tx_queue_len()
> net_sched: plug in qdisc
On 01/28/2018 09:57 PM, Cong Wang wrote:
> On Sun, Jan 28, 2018 at 9:35 PM, John Fastabend
> wrote:
>> On 01/25/2018 06:26 PM, Cong Wang wrote:
>>> This pathcset restores the pfifo_fast qdisc behavior of dropping
>>> packets based on latest dev->tx_queue_len
error code back and should check
that rather than rely on logs.
Signed-off-by: John Fastabend
---
include/net/tcp.h |6 +
net/ipv4/tcp_ulp.c | 57 +++-
net/tls/tls_main.c |2 ++
3 files changed, 60 insertions(+), 5 deletions(-)
diff --
that we should do a module put
in case future users use this with another ULP other than sockmap.
And module_put is a nop when owner = NULL (sockmap case) so no
harm here and code is more robust.
Patch 2/3 Be explicit and set user_visible to false just to avoid
any reader confusion.
---
John Fast
("bpf: sockmap with sk redirect support")
Signed-off-by: John Fastabend
---
kernel/bpf/sockmap.c | 19 ++-
1 file changed, 14 insertions(+), 5 deletions(-)
diff --git a/kernel/bpf/sockmap.c b/kernel/bpf/sockmap.c
index 6c6c274..c8b25f1 100644
--- a/kernel/bpf/sockmap.c
+
() handler. This fixes the above case.
Fixes: 174a79ff9515 ("bpf: sockmap with sk redirect support")
Reported-by: Prashant Bhole
Signed-off-by: John Fastabend
---
include/net/tcp.h|2 +
kernel/bpf/sockmap.c | 156 +-
2 files c
For testing I ran both sample/sockmap and selftests bpf/test_maps.c.
Dave Watson ran TLS test suite on v1 version of the patches without
the put_module error path change.
v4 fix missing rcu_unlock()
v3 wrap psock reference in RCU
v2 changes rebased onto bpf-next with small update adding module_put
---
error code back and should check
that rather than rely on logs.
Signed-off-by: John Fastabend
---
include/net/tcp.h |6 +
net/ipv4/tcp_ulp.c | 59
net/tls/tls_main.c |2 ++
3 files changed, 62 insertions(+), 5 deletions(-)
diff --
() handler. This fixes the above case.
Fixes: 174a79ff9515 ("bpf: sockmap with sk redirect support")
Reported-by: Prashant Bhole
Signed-off-by: John Fastabend
---
include/net/tcp.h|2 +
kernel/bpf/sockmap.c | 168 ++
2 files ch
("bpf: sockmap with sk redirect support")
Signed-off-by: John Fastabend
---
kernel/bpf/sockmap.c | 19 ++-
1 file changed, 14 insertions(+), 5 deletions(-)
diff --git a/kernel/bpf/sockmap.c b/kernel/bpf/sockmap.c
index bd4a6d9..48c3341 100644
--- a/kernel/bpf/sockmap.c
+
we
are, continues normal polling operation.
Signed-off-by: John Allen
---
diff --git a/drivers/net/ethernet/ibm/ibmvnic.c
b/drivers/net/ethernet/ibm/ibmvnic.c
index 8c3058d5d191..2a26b2ece7fe 100644
--- a/drivers/net/ethernet/ibm/ibmvnic.c
+++ b/drivers/net/ethernet/ibm/ibmvnic.c
@@ -1831,7
On 02/12/2018 02:22 AM, Edward Cree wrote:
> On 10/02/18 03:18, Alexei Starovoitov wrote:
>> On Thu, Feb 08, 2018 at 07:31:55PM +, Edward Cree wrote:
>>> By storing subprog boundaries as a subprogno mark on each insn, rather than
>>> a start (and implicit end) for each subprog, we collect a nu
;t even know that such an option exists.
James> I may be an atypical developer but I'd rather have a root canal
James> than browse through menuconfig options. The way to get people
James> to learn about new debugging options is to blog about it (or
James> write an lwn.net article) which google will find the next time
James> I ask it how I debug XXX. Google (probably as a service to
James> humanity) rarely turns up Kconfig options in response to a
James> query.
I agree with James here. Looking at the SLAB vs SLUB Kconfig entries
tells me *nothing* about why I should pick one or the other, as an
example.
John
may want to use the 5-tuple
of the socket as the lookup key.
To support this add hash support.
Signed-off-by: John Fastabend
---
tools/bpf/bpftool/map.c|1 +
tools/include/uapi/linux/bpf.h |6 +-
2 files changed, 6 insertions(+), 1 deletion(-)
diff --git a/include/linux/bpf.h
. This avoids storing the key in the metadata
which will be useful when keys can be longer than 4 bytes. We
rename the sk pointers to sk_redir at this point as well to
avoid any confusion between the current sk pointer and the
redirect pointer sk_redir.
Signed-off-by: John Fastabend
This runs existing SOCKMAP tests with SOCKHASH map type. To do this
we push programs into include file and build two BPF programs. One
for SOCKHASH and one for SOCKMAP.
We then run the entire test suite with each type.
Signed-off-by: John Fastabend
---
tools/testing/selftests/bpf/Makefile
type which reuses almost
all the sockmap code except it needed a few special add/remove
handlers.
To test this we duplicate all the sockmap testing except swap out
the sockmap with a sockhash.
---
John Fastabend (3):
bpf: sockmap, refactor sockmap routines to work with hashmap
bpf
On 04/27/2018 03:54 PM, Alexei Starovoitov wrote:
> On Fri, Apr 27, 2018 at 10:51 PM, John Fastabend
> wrote:
>> In the original sockmap implementation we got away with using an
>> array similar to devmap. However, unlike devmap where an ifindex
>> has a nice 1:1 funct
type which reuses almost
all the sockmap code except it needed a few special add/remove
handlers.
To test this we duplicate all the sockmap testing except swap out
the sockmap with a sockhash.
---
John Fastabend (3):
bpf: sockmap, refactor sockmap routines to work with hashmap
bpf
This runs existing SOCKMAP tests with SOCKHASH map type. To do this
we push programs into include file and build two BPF programs. One
for SOCKHASH and one for SOCKMAP.
We then run the entire test suite with each type.
Signed-off-by: John Fastabend
---
tools/testing/selftests/bpf/Makefile
. This avoids storing the key in the metadata
which will be useful when keys can be longer than 4 bytes. We
rename the sk pointers to sk_redir at this point as well to
avoid any confusion between the current sk pointer and the
redirect pointer sk_redir.
Signed-off-by: John Fastabend
something else tricky.
To test this we duplicate all the sockmap testing except swap out
the sockmap with a sockhash.
v2: fix file stats and add v2 tag
---
John Fastabend (3):
bpf: sockmap, refactor sockmap routines to work with hashmap
bpf: sockmap, add hash map support
bpf: selftest
may want to use the 5-tuple
of the socket as the lookup key.
To support this add hash support.
Signed-off-by: John Fastabend
---
include/linux/bpf.h|8 +
include/linux/bpf_types.h |1
include/uapi/linux/bpf.h |6
kernel/bpf/core.c |1
kernel
provide only diffs +/- on that.
John Fastabend (4):
bpf: sockmap, refactor sockmap routines to work with hashmap
bpf: sockmap, add hash map support
bpf: bpftool, support for sockhash
bpf: selftest additions for SOCKHASH
include/linux/bpf.h| 8 +
include/linux
. This avoids storing the key in the metadata
which will be useful when keys can be longer than 4 bytes. We
rename the sk pointers to sk_redir at this point as well to
avoid any confusion between the current sk pointer and the
redirect pointer sk_redir.
Signed-off-by: John Fastabend
may want to use the 5-tuple
of the socket as the lookup key.
To support this add hash support.
Signed-off-by: John Fastabend
---
include/linux/bpf.h | 8 +
include/linux/bpf_types.h | 1 +
include/uapi/linux/bpf.h | 6 +-
kernel/bpf/core.c | 1 +
kernel/bpf/sockmap.c
This runs existing SOCKMAP tests with SOCKHASH map type. To do this
we push programs into include file and build two BPF programs. One
for SOCKHASH and one for SOCKMAP.
We then run the entire test suite with each type.
Signed-off-by: John Fastabend
---
tools/include/uapi/linux/bpf.h
This adds the SOCKHASH map type to bpftools so that we get correct
pretty printing.
Signed-off-by: John Fastabend
---
tools/bpf/bpftool/map.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/bpf/bpftool/map.c b/tools/bpf/bpftool/map.c
index a6cdb64..4420b1a 100644
--- a/tools/bpf
On 04/27/2018 05:10 PM, Alexei Starovoitov wrote:
> On Fri, Apr 27, 2018 at 04:24:43PM -0700, John Fastabend wrote:
>> This runs existing SOCKMAP tests with SOCKHASH map type. To do this
>> we push programs into include file and build two BPF programs. One
>> for SOCKHAS
901 - 1000 of 2189 matches
Mail list logo