; + INIT_WORK(&ptp->pps_work, efx_ptp_pps_worker);
> + ptp->pps_workwq =
> create_singlethread_workqueue("sfc_pps");
> + if (!ptp->pps_workwq) {
> + rc = -ENOMEM;
> + goto fail4;
> + }
> }
> }
> ptp->nic_ts_enabled = false;
For the sfc change:
Acked-by: Edward Cree
On 25/07/18 03:50, Tobin C. Harding wrote:
> In preparation to convert Documentation/network/netdev-FAQ.rst to
> restructured text format we would like to be able to reference 'the
> canonical patch format' section.
>
> Add rest label: 'the_canonical_path_format'.
Here and in the Subject, 'patch' i
ed by conditional
> branches. For instance, if a SCALAR_VALUE is compared > 8, in the 'true'
> branch
Acked-by: Edward Cree
On 26/01/18 01:03, kbuild test robot wrote:
> Fixes: 2935e3c38228 ("sfc: on 8000 series use TX queues for TX timestamps")
> Signed-off-by: Fengguang Wu
Acked-by: Edward Cree
Dave, can you take this directly or do you need it reposted without RFC tags?
I'm not sure what
t;)
Signed-off-by: Fengguang Wu
[ec...@solarflare.com: rewrote commit message]
Signed-off-by: Edward Cree
---
drivers/net/ethernet/sfc/efx.c | 2 +-
drivers/net/ethernet/sfc/ptp.c | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/net/ethernet/sfc/efx.c b/drivers/ne
On 13/01/18 22:03, Karim Eshapa wrote:
> Use pointers to structure as arguments to function instead of coping
> structures and less stack size. Also transfer TNUM(_v, _m) to
> tnum.h file to be used in differnet files for creating anonymous structures
> statically.
>
> Signed-off-by: Karim Eshapa
On 09/03/18 18:58, Alexei Starovoitov wrote:
> It's not waiting for the whole thing, because once bpfilter starts it
> stays running/sleeping because it's stateful.
So, this has been bugging me a bit.
If bpfilter takes a signal and crashes, all that state goes away.
Does that mean your iptables/net
e syz reproducer).
Fixes: cc8b0b92a169 ("bpf: introduce function calls (function boundaries)")
Reported-by: syzbot+4fc427c7af994b094...@syzkaller.appspotmail.com
Signed-off-by: Edward Cree
---
I'm assuming I don't need to get a Signed-off-by from syzkaller to use its
reproducer
Sorry if this has been pointed out before (it's a very long thread), but
in the out-of-line implementation, it appears that static_call_update()
never alters key->func. Am I right in thinking that this should be
fixed by adding 'WRITE_ONCE(key->func, func);' just after the call to
arch_static_
On 07/12/18 16:06, Edward Cree wrote:
> Sorry if this has been pointed out before (it's a very long thread), but
> in the out-of-line implementation, it appears that static_call_update()
> never alters key->func. Am I right in thinking that this should be
> fixed by ad
On 12/12/18 05:59, Nadav Amit wrote:
> Thanks for cc’ing me. (I didn’t know about the other patch-sets.)
Well in my case, that's because I haven't posted any yet. (Will follow up
shortly with what I currently have, though it's not pretty.)
Looking at your patches, it seems you've got a much more
saw was with dynamic calls present).
Edward Cree (2):
static_call: fix out-of-line static call implementation
net: core: rather hacky PoC implementation of dynamic calls
include/linux/static_call.h | 6 +-
net/core/dev.c | 222 +++-
2 fi
Actually call __static_call_update() from static_call_update(), and fix the
former so it can actually compile. Also make it update key.func.
Signed-off-by: Edward Cree
---
include/linux/static_call.h | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/include/linux
t it right; this is sad.
It's also full of printk()s right now to display what it's doing for
debugging purposes; obviously those wouldn't be quite the same in a
finished version.
Signed-off-by: Edward Cree
---
net/core/dev.c | 222
On 12/12/18 18:14, Nadav Amit wrote:
> Second, (2i) is not very intuitive for me. Using the out-of-line static
> calls seems to me as less performant than the inline (potentially, I didn’t
> check).
>
> Anyhow, the use of out-of-line static calls seems to me as
> counter-intuitive. I think (didn’t
On 12/12/18 19:04, Jakub Kicinski wrote:
> On Tue, 11 Dec 2018 20:56:06 +0900, Alice Ferrazzi wrote:
>> Signed-off-by: Alice Ferrazzi
>> ---
>> tools/testing/selftests/bpf/test_offload.py | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/tools/testing/selftests/bpf/test_
On 12/12/18 21:15, Nadav Amit wrote:
>> On Dec 12, 2018, at 10:33 AM, Edward Cree wrote:
>>
>> AIUI the outline version uses a tail-call (i.e. jmpq *target) rather than an
>> additional call and ret. So I wouldn't expect it to be too expensive.
>> More to the
On 12/06/15 19:51, Jarod Wilson wrote:
> Without this change, modprobe -r sfc hits the BUG_ON() in
> efx_pci_remove_main(). Best as I can tell, this was just an oversight,
> efx->state gets set to STATE_UNINIT in the error path of
> efx_register_netdev() just after unregister_netdevice(), and the s
On 22/05/18 16:36, Colin King wrote:
> From: Colin Ian King
>
> Rename VXGE_HW_ERR_PRIVILAGED_OPEARATION to VXGE_HW_ERR_PRIVILAGED_OPERATION
> to fix spelling mistake.
>
> Signed-off-by: Colin Ian King
"Privilaged" doesn't look right either, maybe fix both at once?
-> VXGE_HW_PRIVILEGED_OPERATIO
On 30/04/18 02:31, Wenwen Wang wrote:
> In ethtool_get_rxnfc(), the object "info" is firstly copied from
> user-space. If the FLOW_RSS flag is set in the member field flow_type of
> "info" (and cmd is ETHTOOL_GRXFH), info needs to be copied again from
> user-space because FLOW_RSS is newer and has
On 05/02/2021 12:47, Bhaskar Chowdhury wrote:
>
>
> s/fuck/mess/
> s/fucking/s/
>
> Signed-off-by: Bhaskar Chowdhury
Right or wrong, these are not "spelling fixes".
Please do not misrepresent your patch in your Subject: line.
(Also, subsystem prefix should probably just be "net: sunhme:".)
On 10/08/2020 16:51, Guenter Roeck wrote:
> On Thu, Aug 06, 2020 at 07:17:43PM +0100, Edward Cree wrote:
>> Maybe I should add a
>>
>> static inline u32 mod_u64(u64 dividend, u32 divisor)
>> {
>> return do_div(dividend, divisor);
>> }
> Your
On 06/08/2020 00:48, kernel test robot wrote:
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
> master
> head: d15fe4ec043588beee823781602ddb51d0bc84c8
> commit: adcfc3482813fa2c34e5902005853f79c2aa [13398/13940] sfc_ef100:
> read Design Parameters at probe tim
Without wishing to weigh in on whether this caching is a good idea...
Wouldn't it be simpler, rather than having two separate "alloc" and "flush"
caches, to have a single larger cache, such that whenever it becomes full
we bulk flush the top half, and when it's empty we bulk alloc the bottom
hal
On 28/02/2021 17:05, Alexey Dobriyan wrote:
> From 251ca5673886b5bb0a42004944290b9d2b267a4a Mon Sep 17 00:00:00 2001
> From: Alexey Dobriyan
> Date: Fri, 19 Feb 2021 13:37:24 +0300
> Subject: [PATCH 10/11] pragma once: delete few backslashes
>
> Some macros contain one backslash too many and end
On 27/11/2020 19:37, t...@redhat.com wrote:
> From: Tom Rix
>
> The macro use will already have a semicolon.
>
> Signed-off-by: Tom Rix
> ---
> net/core/flow_offload.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/net/core/flow_offload.c b/net/core/flow_offload.c
>
On 25/11/2020 00:32, Miguel Ojeda wrote:
> I have said *authoring* lines of *this* kind takes a minute per line.
> Specifically: lines fixing the fallthrough warning mechanically and
> repeatedly where the compiler tells you to, and doing so full-time for
> a month.
> It is useful since it makes i
On 24/11/2020 21:25, Kees Cook wrote:
> I still think this isn't right -- it's a case statement that runs off
> the end without an explicit flow control determination.
Proves too much — for instance
case foo:
case bar:
thing;
break;
doesn't require a fallthrough; after cas
other channels, max 32)
>
> Which in turn triggers EINVAL on XDP processing:
>
> sfc :86:00.0 ext0: XDP TX failed (-22)
>
> Signed-off-by: Ivan Babrou
Acked-by: Edward Cree
comes from the driver's channel structures having been designed a
decade ago when 32 cpus ought to be enough for anybody... AFAIR the
hardware is capable of giving us something like 1024 evqs if we ask
for them, it just might not have that many msi-x vectors for us.)
Anyway, the patch looks correct, so
Acked-by: Edward Cree
-ed
On 16/12/2020 08:45, Jesper Dangaard Brouer wrote:
> So, what I hear is that this fix is just pampering over the real issue.
Yes, it is, but it's better than nothing in the meantime while we work
out the complete fix.
> I suggest that you/we detect the situation, and have a code path that
> will
Sorry if this has been suggested before, but if so I couldn't find it.
Short version: could a sysfs dir reference a list of default attributes
rather than having to instantiate them all?
Long version:
If I'm understanding correctly, when creating a sysfs dir for a kobject, we
call populate_dir()
On 16/02/16 23:55, Greg Kroah-Hartman wrote:
On Tue, Feb 16, 2016 at 11:46:49PM +, Edward Cree wrote:
Sorry if this has been suggested before, but if so I couldn't find it.
Short version: could a sysfs dir reference a list of default attributes
rather than having to instantiate the
On 17/02/16 00:47, Greg Kroah-Hartman wrote:
How many sysfs entries are you creating for that 20kb? And how did you
measure it? If you don't access the files, the backing store is not
allocated, saving you a lot of memory.
Thinking about this some more, could we not do the same thing with the
On 21/05/15 00:33, Cong Wang wrote:
> On Wed, May 20, 2015 at 2:10 PM, Alex Gartrell wrote:
>> Hey everyone,
>>
>> tl;dr; pure python generic netlink library with simple clients for ipvs and
>> taskstats here: https://github.com/facebook/gnlpy
> libnl should have python support for generic netlink
>> This breaks older compilers that can't initialize anon structures.
>
> How old ? Even gcc 3.1 says you can use unnamed struct/union fields and
> 3.2 is the minimum version required to compile the kernel as mentioned
> in the README.
>
> We could simply just name the structure, but I doubt this
On 20/02/15 01:00, Hiroshi Shimamoto wrote:
> From: Hiroshi Shimamoto
>
> Add netlink directives and ndo entry to allow VF multicast promiscuous mode.
>
> The administrator wants to allow dedicatedly multicast promiscuous per VF.
If I'm properly understanding, this seems to be an ixgbe-specific op
On 20/02/15 21:05, Skidmore, Donald C wrote:
> If a vender specific interface is objectionable maybe a simpler and more
> generic interface would be for the PF to be able to set a given VF into
> "trusted" mode... I admit exactly what 'trusted' meant would vary from vender
> to vender, but it wo
On 25/04/16 17:42, Bert Kenward wrote:
> Add myself and Edward Cree as maintainers.
> Remove Shradha Shah, who is on extended leave.
>
> Cc: David S. Miller
> Cc: Edward Cree
> Cc: Shradha Shah
> Signed-off-by: Bert Kenward
Acked-by: Edward Cree
> ---
> MAINTAINER
On 10/10/2019 15:42, Alexander Lobakin wrote:
> Commit 323ebb61e32b ("net: use listified RX for handling GRO_NORMAL
> skbs") have introduced a sysctl variable gro_normal_batch for defining
> a limit for listified Rx of GRO_NORMAL skbs. The initial value of 8 is
> purely arbitrary and has been chose
On 10/10/2019 15:42, Alexander Lobakin wrote:
> Commit 323ebb61e32b4 ("net: use listified RX for handling GRO_NORMAL
> skbs") made use of listified skb processing for the users of
> napi_gro_frags().
> The same technique can be used in a way more common napi_gro_receive()
> to speed up non-merged (
in a way more common napi_gro_receive()
>>> to speed up non-merged (GRO_NORMAL) skbs for a wide range of drivers,
>>> including gro_cells and mac80211 users.
>>>
>>> Signed-off-by: Alexander Lobakin
Acked-by: Edward Cree
but I think this needs review from the socionext folks as well.
On 05/02/19 08:50, Nadav Amit wrote:
>> In cases where RCU cannot be used (e.g. because some callees need to RCU
>> synchronise), it might be possible to add a variant that uses
>> synchronize_rcu_tasks() when updating, but this series does not attempt this.
> I wonder why.
Mainly because I have ye
atic calls, since the inline
implementation lead to crashes; I have not yet determined whether they were
the fault of my patch or of the static calls series.
Edward Cree (4):
static_call: add indirect call promotion (dynamic_call) infrastructure
net: core: use a dynamic_call for pt_prev->
defaults to off (and depends
on a static_call implementation being available).
Signed-off-by: Edward Cree
---
include/linux/dynamic_call.h | 300 +++
init/Kconfig | 11 ++
kernel/Makefile | 1 +
kernel/dynamic_call
Typically a small number of callees, such as ip[v6]_rcv or packet_rcv,
will cover most packets.
Signed-off-by: Edward Cree
---
net/core/dev.c | 12 +---
1 file changed, 9 insertions(+), 3 deletions(-)
diff --git a/net/core/dev.c b/net/core/dev.c
index 8e276e0192a1..7b38a33689d8 100644
There are currently only two possible callees, ip_list_rcv and
ipv6_list_rcv. Even when more are added, most packets will typically
follow one of a small number of callees on any given system.
Signed-off-by: Edward Cree
---
net/core/dev.c | 6 +-
1 file changed, 5 insertions(+), 1
Typically there will be a small number of callees, such as ip_local_deliver
or ip_forward, which will cover most packets.
Signed-off-by: Edward Cree
---
include/net/dst.h | 5 -
net/core/dst.c| 2 ++
2 files changed, 6 insertions(+), 1 deletion(-)
diff --git a/include/net/dst.h b
On 29/04/2019 12:18, Nicholas Mc Guire wrote:
> On Mon, Apr 29, 2019 at 12:00:06PM +0100, Edward Cree wrote:
>> Again, a __force cast doesn't seem necessary here. It looks like the
>> code is just using the wrong types; if all of src, dst and uncongested
>> were __le6
ject & description are incomplete, you're also changing i2c_new_device()
to i2c_new_client_device().
Other than that,
Acked-by: Edward Cree
> Solarflare folks, please review/test.
>
> Thank you.
Falcon isn't likely to get tested by us, I think we only have about three
o
On 24/07/2019 12:26, Chuhong Yuan wrote:
> Instead of using to_pci_dev + pci_get_drvdata,
> use dev_get_drvdata to make code simpler.
>
> Signed-off-by: Chuhong Yuan
Acked-by: Edward Cree
> ---
> drivers/net/ethernet/sfc/ef10.c | 4 ++--
> drivers/net/ethernet/sfc/efx.c
On 09/01/19 22:59, Josh Poimboeuf wrote:
> Static calls are a replacement for global function pointers. They use
> code patching to allow direct calls to be used instead of indirect
> calls. They give the flexibility of function pointers, but with
> improved performance. This is especially impor
The new Code of Conduct makes me feel threatened and uncomfortable.
No, really. As a person with (diagnosed) Asperger's, I'm a member of,
objectively, a marginalised minority. Effectively (i.e. this is a massive
oversimplification), I was born without the hard-wired circuitry for
social
int
On 19/09/18 15:18, Jonathan Corbet wrote:
> I'd like to address just this part, speaking only for myself.
> The LF is not in the position of arbitrating anything here. The body
> charged with that is the LF Technical Advisory Board, which is a
> different thing.
Thank you for clarifying that.
Jo
On 20/09/18 02:16, Olof Johansson wrote:
> I would be very surprised if any of my peers on the TAB ever had those
> intentions, and I know I would not have them myself.
In case my references to individualsmade it unclear: I have no reason to
suspect _any_ of the present TAB members would; everythi
On 20/09/18 10:27, unconditionedwitn...@redchan.it wrote:
> Contributors can, at any time, rescind the license grant regarding their
> property via written notice to those whom they are rescinding the grant
> from (regarding their property (code)).
I know others have already said it, but:
This is
On 03/05/18 05:36, Alexei Starovoitov wrote:
> bpfilter.ko consists of bpfilter_kern.c (normal kernel module code)
> and user mode helper code that is embedded into bpfilter.ko
>
> The steps to build bpfilter.ko are the following:
> - main.c is compiled by HOSTCC into the bpfilter_umh elf executabl
D#1398883 ("Out-of-bounds-read")
>
> Fixes: 9b41080125176841e ("sfc: insert catch-all filters for encapsulated
> traffic")
> Signed-off-by: Colin Ian King
Good catch.
Acked-by: Edward Cree
> ---
> drivers/net/ethernet/sfc/ef10.c | 2 +-
> 1 file changed,
On 01/06/16 15:39, Kangjie Lu wrote:
> The field autoneg of pauseparam is not initialized in some
> implementations of get_pauseparam(), but the whole object is
> copied to userland.
>
> Signed-off-by: Kangjie Lu
> ---
> net/core/ethtool.c | 5 -
> 1 file changed, 4 insertions(+), 1 deletion(
itre
> Reviewed-by: Josh Triplett
> Acked-by: Richard Cochran
For the sfc change:
Acked-by: Edward Cree
And I accept that "suggests" isn't needed and the current "imply" semantics
are probably fine. If not we can always change it or resurrect "suggests".
On 20/10/16 18:04, Nicolas Pitre wrote:
> On Thu, 20 Oct 2016, Edward Cree wrote:
>> Also, I don't think having any FOO=y should preclude BAZ=m. Suppose both
>> FOO and FOO2 imply BAZ, FOO=y and FOO2=m.
> Some people didn't like the fact that you could turn a driver
On 20/10/16 19:29, Nicolas Pitre wrote:
> On Thu, 20 Oct 2016, Edward Cree wrote:
>> But the desire is a property of the user, not of the driver. If you're
>> willing to add CONFIG_FOO_BAZ to every combination of (driver, subsystem)
>> then "imply" becomes u
On 21/02/17 14:29, David Laight wrote:
>> The entire file should use the proper "__uX" kernel types
>> rather than the uint* ones.
> The uint* ones are part of the C standard :-)
>
> David
>
... which is exactly why we can't use them.
http://yarchive.net/comp/linux/kernel_headers.html#17
Vi
On 10/02/17 16:14, Colin Ian King wrote:
> Hi there,
>
>
> not sure if this is a bug, or intentional, but CoverityScan picked up a
> mismatch in arguments when calling efx_ef10_handle_rx_event_error() with
> commit "sfc: process RX event inner checksum flags"
It's a bug, thanks for the catch (and
On 02/08/16 12:40, Baole Ni wrote:
> I find that the developers often just specified the numeric value
> when calling a macro which is defined with a parameter for access permission.
> As we know, these numeric value for access permission have had the
> corresponding macro,
> and that using macro
about it).
I've gone with that as it's simple and it doesn't seem likely to matter -
name collisions should be found promptly either way - but if it's a
problem I could change it.
Signed-off-by: Edward Cree
---
fs/kernfs/dir.c | 100 +-
On 24/06/2020 22:06, Jason A. Donenfeld wrote:
> Hi Alexander,
>
> This patch introduced a behavior change around GRO_DROP:
>
> napi_skb_finish used to sometimes return GRO_DROP:
>
>> -static gro_result_t napi_skb_finish(gro_result_t ret, struct sk_buff *skb)
>> +static gro_result_t napi_skb_finish
> On Mon, Sep 28 2020 at 21:05, Edward Cree wrote:
>> Only compile-tested so far, because I'm waiting for my kernel to
>> finish rebuilding with CONFIG_DEBUG_ATOMIC_SLEEP
I've now tested and confirmed that the might_sleep warning goes
away with this patch.
Thomas, do
() check and the code concerned
doesn't seemto have changed a great deal since.
Anyway, this fix looks correct, and you can have my
Acked-by: Edward Cree
but I thinkit might be cleaner to avoid having to have this unused
can_sleep argument on all the NICs that don't need it, by instead
thods, which are happy with being
called from atomic contexts.
Fixes: f00bf2305cab ("sfc: don't update stats on VF when called in atomic
context")
Reported-by: Sebastian Andrzej Siewior
Signed-off-by: Edward Cree
---
Only compile-tested so far, because I'm waiting for my ker
On 28/05/2020 20:49, David Miller wrote:
> From: Arnd Bergmann
> Date: Wed, 27 May 2020 15:41:06 +0200
>
>> 'nic_data' is no longer used outside of the #ifdef block
>> in efx_ef10_set_mac_address:
>>
>> drivers/net/ethernet/sfc/ef10.c:3231:28: error: unused variable 'nic_data'
>> [-Werror,-Wunuse
checking table before dereferencing it when checking for a null
> table->must_restore_filters.
>
> Addresses-Coverity: ("Dereference before null check")
> Fixes: e4fe938cff04 ("sfc: move 'must restore' flags out of ef10-specific
> nic_data")
> Signed-off-by: Colin Ian King
Acked-by: Edward Cree
On 02/08/2020 16:39, Jia-Ju Bai wrote:
> To fix this problem, "req->op" is assigned to a local variable, and then
> the driver accesses this variable instead of "req->op".
>
> Signed-off-by: Jia-Ju Bai
Not sure how necessary this is (or even if anyone's still usingSiena
SR-IOV, since it needed a
ropped by the core stack, but it seems to have no impact on related
> drivers' functionality.
> gro_normal_batch is left untouched as it's very individual for every
> single system configuration and might be tuned in manual order to
> achieve an optimal performance.
>
>
On 13/08/2020 15:39, Christophe Leroy wrote:
> ppc6xx_defconfig fails building sfc.ko module, complaining
> about the lack of _umoddi3 symbol.
>
> This is due to the following test
>
> if (EFX_MIN_DMAQ_SIZE % reader->value) {
>
> Because reader->value is u64.
Already fixed in net.git
On 26/10/2020 23:47, Sasha Levin wrote:
> From: Edward Cree
>
> [ Upstream commit 1c0544d24927e4fad04f858216b8ea767a3bd123 ]
>
> Instead of using efx_tx_queue_partner(), which relies on the assumption
> that tx_queues_per_channel is 2, efx_tx_send_pending() iterates
On 26/07/2020 11:58, Julia Lawall wrote:
> list_for_each_safe is able to handle an empty list.
> The only effect of avoiding the loop is not initializing the
> index variable.
> Drop list_empty tests in cases where these variables are not
> used.
Sure, why not.
Acked-by: Edward Cree
On 23/07/2020 20:08, David Miller wrote:
> From: Luo bin
> Date: Thu, 23 Jul 2020 22:40:37 +0800
>
>> +static int hinic_fw_reporter_dump(struct devlink_health_reporter *reporter,
>> + struct devlink_fmsg *fmsg, void *priv_ctx,
>> + struct n
On 09/06/2020 17:58, Joe Perches wrote:
> On Tue, 2020-06-09 at 13:16 +0200, Greg Kroah-Hartman wrote:
>> What is wrong with the existing control of dynamic
>> debug messages that you want to add another type of arbitrary grouping
>> to it?
> There is no existing grouping mechanism.
>
> Many drive
On 09/06/2020 18:56, Joe Perches wrote:
> These are _not_ netif_ control flags. Some are though.
> For instance:
>
> $ git grep "MODULE_PARM.*\bdebug\b" drivers/net | head -10
> [...]
>
> These are all level/class output controls.
TIL, thanks! I should have looked deeperrather than assuming
they
Disclaimer: *definitely* not speaking for my employer.
On 09/06/2020 18:19, Stephen Hemminger wrote:
> How many times have you or Linus argued about variable naming.
> Yes, words do matter and convey a lot of implied connotation and meaning.
Connotation, unlike denotation, is widely variable. I w
ng/selftests/bpf/test_verifier
and tools/testing/selftests/bpf/test_align pass.
v3: added a few more tests; removed RFC tags.
v2: fixed nfp build, made test_align pass again and extended it with a few
new tests (though still need to add more).
Edward Cree (12):
selftests/bpf: add test for
Currently fails due to bug in verifier bounds handling.
Signed-off-by: Edward Cree
---
tools/testing/selftests/bpf/test_verifier.c | 26 ++
1 file changed, 26 insertions(+)
diff --git a/tools/testing/selftests/bpf/test_verifier.c
b/tools/testing/selftests/bpf
e to conclude something about the result (e.g. pointer & 0x40 is either
0 or 0x40).
Signed-off-by: Edward Cree
---
include/linux/bpf.h | 34 +-
include/linux/bpf_verifier.h | 40 +-
include/linux/tnum.h | 79 ++
kernel/bpf/Makefile |2 +-
kernel/bp
Signed-off-by: Edward Cree
---
drivers/net/ethernet/netronome/nfp/bpf/verifier.c | 24 +--
kernel/bpf/tnum.c | 1 +
2 files changed, 15 insertions(+), 10 deletions(-)
diff --git a/drivers/net/ethernet/netronome/nfp/bpf/verifier.c
b/drivers
ly not necessary, it makes the code more
straightforward and symmetrical between signed and unsigned bounds.
Signed-off-by: Edward Cree
---
include/linux/bpf_verifier.h | 22 +-
include/linux/tnum.h | 2 +
kernel/bpf/tnum.c| 16 +
kernel/bpf/verifier.c
Some of the verifier's error messages have changed, and some constructs
that previously couldn't be verified are now accepted.
Signed-off-by: Edward Cree
---
tools/testing/selftests/bpf/test_verifier.c | 226 ++--
1 file changed, 116 insertions(+), 110
Signed-off-by: Edward Cree
---
kernel/bpf/verifier.c | 46 +++---
1 file changed, 27 insertions(+), 19 deletions(-)
diff --git a/kernel/bpf/verifier.c b/kernel/bpf/verifier.c
index d45c1d1..3e1df75 100644
--- a/kernel/bpf/verifier.c
+++ b/kernel/bpf
New test adds 14 to the unknown value before adding to the packet pointer,
meaning there's no 'fixed offset' field and instead we add into the
var_off, yielding a '4n+2' value.
Signed-off-by: Edward Cree
---
tools/testing/selftests/bpf/test_align.c | 67 ++
.)
Signed-off-by: Edward Cree
---
tools/testing/selftests/bpf/test_align.c | 225 ++-
1 file changed, 132 insertions(+), 93 deletions(-)
diff --git a/tools/testing/selftests/bpf/test_align.c
b/tools/testing/selftests/bpf/test_align.c
index bccebd9..031bba8 100644
"direct packet access: test2" was potentially reading four bytes from
pkt + 0x, which could take it past the verifier's limit, causing
the program to be rejected.
Increase the shifts by one so that R2 is now mask 0x7fff instead of
mask 0x.
Signed-off-by: Edward Cree
---
Signed-off-by: Edward Cree
---
tools/testing/selftests/bpf/test_align.c | 104 +++
1 file changed, 104 insertions(+)
diff --git a/tools/testing/selftests/bpf/test_align.c
b/tools/testing/selftests/bpf/test_align.c
index dfd96c6..6bc2ceb 100644
--- a/tools/testing
Tests non-add/sub operations (AND, LSH) on pointers decaying them to
unknown scalars.
Also tests that a pkt_ptr add which could potentially overflow is rejected
(find_good_pkt_pointers ignores it and doesn't give us any reg->range).
Signed-off-by: Edward Cree
---
tools/testing/selft
Variable ctx accesses and stack accesses aren't allowed, because we can't
determine what type of value will be read.
Signed-off-by: Edward Cree
---
tools/testing/selftests/bpf/test_verifier.c | 41 +
1 file changed, 41 insertions(+)
diff --git a/too
On 28/06/17 14:50, Daniel Borkmann wrote:
> Hi Edward,
>
> Did you also have a chance in the meantime to look at reducing complexity
> along with your unification? I did run the cilium test suite with your
> latest set from here and current # worst case processed insns that
> verifier has to go thr
On 28/06/17 16:15, Daniel Borkmann wrote:
> On 06/27/2017 02:56 PM, Edward Cree wrote:
>> Tracks value alignment by means of tracking known & unknown bits.
>> Tightens some min/max value checks and fixes a couple of bugs therein.
>
> You mean the one in relation to pat
On 28/06/17 18:09, Daniel Borkmann wrote:
> Could you elaborate on this one? If I understand it correctly, then
> the scalar += pointer case would mean the following: given I have one
> of the allowed pointer types in adjust_ptr_min_max_vals() then the
> prior scalar type inherits the ptr type/id.
On 07/07/17 18:45, Nadav Amit wrote:
> For me changes such as:
>
>> if (dst_reg->min_value != BPF_REGISTER_MIN_RANGE)
>> -dst_reg->min_value -= min_val;
>> +dst_reg->min_value -= max_val;
>
> are purely cryptic. What happened here? Was there a bu
On 28/06/17 22:37, Alexei Starovoitov wrote:
> Increasing the limit is must have, since pruning suffered so much.
> Going from 53k to 76k is pretty substantial.
> What is the % increase for tests in selftests/ ?
When I tried to measure the test_verifier tests, they changed hardly at
all, only a co
is loosely based on a patch by Josef Bacik
.
Build-tested only. Applies on top of patches 1-3.
Signed-off-by: Edward Cree
---
include/linux/bpf_verifier.h | 5 +-
kernel/bpf/verifier.c| 179 ++-
2 files changed, 111 insertions(+), 73 deletion
1 - 100 of 166 matches
Mail list logo