<feed xmlns='http://www.w3.org/2005/Atom'>
<title>pm24.git/samples/bpf, branch v4.18</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<id>https://git.kobert.dev/pm24.git/atom?h=v4.18</id>
<link rel='self' href='https://git.kobert.dev/pm24.git/atom?h=v4.18'/>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/'/>
<updated>2018-08-09T19:50:44Z</updated>
<entry>
<title>samples/bpf: xdp_redirect_cpu adjustment to reproduce teardown race easier</title>
<updated>2018-08-09T19:50:44Z</updated>
<author>
<name>Jesper Dangaard Brouer</name>
<email>brouer@redhat.com</email>
</author>
<published>2018-08-08T21:00:39Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=37d7ff25957e05860e068a986209fee128db574a'/>
<id>urn:sha1:37d7ff25957e05860e068a986209fee128db574a</id>
<content type='text'>
The teardown race in cpumap is really hard to reproduce.  These changes
makes it easier to reproduce, for QA.

The --stress-mode now have a case of a very small queue size of 8, that helps
to trigger teardown flush to encounter a full queue, which results in calling
xdp_return_frame API, in a non-NAPI protect context.

Also increase MAX_CPUS, as my QA department have larger machines than me.

Tested-by: Jean-Tsung Hsiao &lt;jhsiao@redhat.com&gt;
Signed-off-by: Jesper Dangaard Brouer &lt;brouer@redhat.com&gt;
Signed-off-by: Daniel Borkmann &lt;daniel@iogearbox.net&gt;
</content>
</entry>
<entry>
<title>samples/bpf: Fix tc and ip paths in xdp2skb_meta.sh</title>
<updated>2018-07-10T07:19:01Z</updated>
<author>
<name>Taeung Song</name>
<email>treeze.taeung@gmail.com</email>
</author>
<published>2018-07-09T17:51:21Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=b9626f45abccd044f8048269c67720f0719f2d4e'/>
<id>urn:sha1:b9626f45abccd044f8048269c67720f0719f2d4e</id>
<content type='text'>
The below path error can occur:

  # ./xdp2skb_meta.sh --dev eth0 --list
  ./xdp2skb_meta.sh: line 61: /usr/sbin/tc: No such file or directory

So just use command names instead of absolute paths of tc and ip.
In addition, it allow callers to redefine $TC and $IP paths

Fixes: 36e04a2d78d9 ("samples/bpf: xdp2skb_meta shows transferring info from XDP to SKB")
Reviewed-by: Jesper Dangaard Brouer &lt;brouer@redhat.com&gt;
Signed-off-by: Taeung Song &lt;treeze.taeung@gmail.com&gt;
Acked-by: Jesper Dangaard Brouer &lt;brouer@redhat.com&gt;
Signed-off-by: Daniel Borkmann &lt;daniel@iogearbox.net&gt;
</content>
</entry>
<entry>
<title>samples/bpf: add .gitignore file</title>
<updated>2018-07-05T07:58:53Z</updated>
<author>
<name>Taeung Song</name>
<email>treeze.taeung@gmail.com</email>
</author>
<published>2018-07-04T13:36:39Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=c48424d993fafd1e04b228fbd46176f828233d82'/>
<id>urn:sha1:c48424d993fafd1e04b228fbd46176f828233d82</id>
<content type='text'>
For untracked executables of samples/bpf, add this.

  Untracked files:
    (use "git add &lt;file&gt;..." to include in what will be committed)

  	samples/bpf/cpustat
  	samples/bpf/fds_example
  	samples/bpf/lathist
  	samples/bpf/load_sock_ops
	...

Signed-off-by: Taeung Song &lt;treeze.taeung@gmail.com&gt;
Acked-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Daniel Borkmann &lt;daniel@iogearbox.net&gt;
</content>
</entry>
<entry>
<title>samples/bpf: Check the error of write() and read()</title>
<updated>2018-07-05T07:58:52Z</updated>
<author>
<name>Taeung Song</name>
<email>treeze.taeung@gmail.com</email>
</author>
<published>2018-07-04T13:36:38Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=02a2f000a3629274bfad60bfc4de9edec49e63e7'/>
<id>urn:sha1:02a2f000a3629274bfad60bfc4de9edec49e63e7</id>
<content type='text'>
test_task_rename() and test_urandom_read()
can be failed during write() and read(),
So check the result of them.

Reviewed-by: David Laight &lt;David.Laight@ACULAB.COM&gt;
Signed-off-by: Taeung Song &lt;treeze.taeung@gmail.com&gt;
Acked-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Daniel Borkmann &lt;daniel@iogearbox.net&gt;
</content>
</entry>
<entry>
<title>samples/bpf: Check the result of system()</title>
<updated>2018-07-05T07:58:52Z</updated>
<author>
<name>Taeung Song</name>
<email>treeze.taeung@gmail.com</email>
</author>
<published>2018-07-04T13:36:37Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=492b7e894587c151be681f86d4d1d086375f7b45'/>
<id>urn:sha1:492b7e894587c151be681f86d4d1d086375f7b45</id>
<content type='text'>
To avoid the below build warning message,
use new generate_load() checking the return value.

  ignoring return value of ‘system’, declared with attribute warn_unused_result

And it also refactors the duplicate code of both
test_perf_event_all_cpu() and test_perf_event_task()

Cc: Teng Qin &lt;qinteng@fb.com&gt;
Signed-off-by: Taeung Song &lt;treeze.taeung@gmail.com&gt;
Acked-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Daniel Borkmann &lt;daniel@iogearbox.net&gt;
</content>
</entry>
<entry>
<title>samples/bpf: add missing &lt;linux/if_vlan.h&gt;</title>
<updated>2018-07-05T07:58:52Z</updated>
<author>
<name>Taeung Song</name>
<email>treeze.taeung@gmail.com</email>
</author>
<published>2018-07-04T13:36:36Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=4d5d33a085335ef469c9a87792bcaaaa8e64d8c4'/>
<id>urn:sha1:4d5d33a085335ef469c9a87792bcaaaa8e64d8c4</id>
<content type='text'>
This fixes build error regarding redefinition:

    CLANG-bpf  samples/bpf/parse_varlen.o
  samples/bpf/parse_varlen.c:111:8: error: redefinition of 'vlan_hdr'
  struct vlan_hdr {
         ^
  ./include/linux/if_vlan.h:38:8: note: previous definition is here

So remove duplicate 'struct vlan_hdr' in sample code and include if_vlan.h

Signed-off-by: Taeung Song &lt;treeze.taeung@gmail.com&gt;
Acked-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Daniel Borkmann &lt;daniel@iogearbox.net&gt;
</content>
</entry>
<entry>
<title>samples/bpf: deal with EBUSY return code from sendmsg in xdpsock sample</title>
<updated>2018-07-03T01:37:12Z</updated>
<author>
<name>Magnus Karlsson</name>
<email>magnus.karlsson@intel.com</email>
</author>
<published>2018-06-29T07:48:19Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=c03079c9d93d593d44524883b6b6127b21978e22'/>
<id>urn:sha1:c03079c9d93d593d44524883b6b6127b21978e22</id>
<content type='text'>
Sendmsg in the SKB path of AF_XDP can now return EBUSY when a packet
was discarded and completed by the driver. Just ignore this message
in the sample application.

Fixes: b4b8faa1ded7 ("samples/bpf: sample application and documentation for AF_XDP sockets")
Signed-off-by: Magnus Karlsson &lt;magnus.karlsson@intel.com&gt;
Reported-by: Pavel Odintsov &lt;pavel@fastnetmon.com&gt;
Signed-off-by: Alexei Starovoitov &lt;ast@kernel.org&gt;
</content>
</entry>
<entry>
<title>bpf: Change bpf_fib_lookup to return lookup status</title>
<updated>2018-06-28T22:02:02Z</updated>
<author>
<name>David Ahern</name>
<email>dsahern@gmail.com</email>
</author>
<published>2018-06-26T23:21:18Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=4c79579b44b1876444f4d04de31c1a37098a0350'/>
<id>urn:sha1:4c79579b44b1876444f4d04de31c1a37098a0350</id>
<content type='text'>
For ACLs implemented using either FIB rules or FIB entries, the BPF
program needs the FIB lookup status to be able to drop the packet.
Since the bpf_fib_lookup API has not reached a released kernel yet,
change the return code to contain an encoding of the FIB lookup
result and return the nexthop device index in the params struct.

In addition, inform the BPF program of any post FIB lookup reason as
to why the packet needs to go up the stack.

The fib result for unicast routes must have an egress device, so remove
the check that it is non-NULL.

Signed-off-by: David Ahern &lt;dsahern@gmail.com&gt;
Signed-off-by: Daniel Borkmann &lt;daniel@iogearbox.net&gt;
</content>
</entry>
<entry>
<title>samples/bpf: xdpsock: use skb Tx path for XDP_SKB</title>
<updated>2018-06-05T13:48:57Z</updated>
<author>
<name>Björn Töpel</name>
<email>bjorn.topel@intel.com</email>
</author>
<published>2018-06-04T12:06:01Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=9f5232cc7f040f443f81069f553d31b27ab7eb79'/>
<id>urn:sha1:9f5232cc7f040f443f81069f553d31b27ab7eb79</id>
<content type='text'>
Make sure that XDP_SKB also uses the skb Tx path.

Signed-off-by: Björn Töpel &lt;bjorn.topel@intel.com&gt;
Signed-off-by: Daniel Borkmann &lt;daniel@iogearbox.net&gt;
</content>
</entry>
<entry>
<title>samples/bpf: minor *_nb_free performance fix</title>
<updated>2018-06-04T15:21:02Z</updated>
<author>
<name>Magnus Karlsson</name>
<email>magnus.karlsson@intel.com</email>
</author>
<published>2018-06-04T11:57:15Z</published>
<link rel='alternate' type='text/html' href='https://git.kobert.dev/pm24.git/commit/?id=a65ea68b8dd92fea86d2b8ca7e43caeaa5ddcdff'/>
<id>urn:sha1:a65ea68b8dd92fea86d2b8ca7e43caeaa5ddcdff</id>
<content type='text'>
Signed-off-by: Magnus Karlsson &lt;magnus.karlsson@intel.com&gt;
Signed-off-by: Daniel Borkmann &lt;daniel@iogearbox.net&gt;
</content>
</entry>
</feed>
