lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <94A40403-ADBB-4126-8E9E-FC067E12A214@8x8.com>
Date: Wed, 12 Mar 2025 13:48:56 -0400
From: Jonathan Lennox <jonathan.lennox@....com>
To: Jonathan Lennox <jonathan.lennox42@...il.com>
Cc: Jakub Kicinski <kuba@...nel.org>,
 Paolo Abeni <pabeni@...hat.com>,
 David Ahern <dsahern@...nel.org>,
 netdev@...r.kernel.org,
 Stephen Hemminger <stephen@...workplumber.org>,
 Cong Wang <xiyou.wangcong@...il.com>,
 Jiri Pirko <jiri@...nulli.us>,
 Pedro Tammela <pctammela@...atatu.com>
Subject: Re: [PATCH net-next v3] tc-tests: Update tc police action tests for
 tc buffer size rounding fixes.

And with this I’ve resent it not as a MIME attachment, sorry about that.

> On Mar 12, 2025, at 1:48 PM, Jonathan Lennox <jonathan.lennox42@...il.com> wrote:
> 
> Before tc's recent change to fix rounding errors, several tests which
> specified a burst size of "1m" would translate back to being 1048574
> bytes (2b less than 1Mb).  sprint_size prints this as "1024Kb".
> 
> With the tc fix, the burst size is instead correctly reported as
> 1048576 bytes (precisely 1Mb), which sprint_size prints as "1Mb".
> 
> This updates the expected output in the tests' matchPattern values
> to accept either the old or the new output.
> 
> Signed-off-by: Jonathan Lennox <jonathan.lennox@....com>
> ---
> .../selftests/tc-testing/tc-tests/actions/police.json  | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/tools/testing/selftests/tc-testing/tc-tests/actions/police.json b/tools/testing/selftests/tc-testing/tc-tests/actions/police.json
> index dd8109768f8f..5596f4df0e9f 100644
> --- a/tools/testing/selftests/tc-testing/tc-tests/actions/police.json
> +++ b/tools/testing/selftests/tc-testing/tc-tests/actions/police.json
> @@ -689,7 +689,7 @@
>         "cmdUnderTest": "$TC actions add action police rate 7mbit burst 1m continue index 1",
>         "expExitCode": "0",
>         "verifyCmd": "$TC actions get action police index 1",
> -        "matchPattern": "action order [0-9]*:  police 0x1 rate 7Mbit burst 1024Kb mtu 2Kb action continue",
> +        "matchPattern": "action order [0-9]*:  police 0x1 rate 7Mbit burst (1024Kb|1Mb) mtu 2Kb action continue",
>         "matchCount": "1",
>         "teardown": [
>             "$TC actions flush action police"
> @@ -716,7 +716,7 @@
>         "cmdUnderTest": "$TC actions add action police rate 7mbit burst 1m drop index 1",
>         "expExitCode": "0",
>         "verifyCmd": "$TC actions ls action police",
> -        "matchPattern": "action order [0-9]*:  police 0x1 rate 7Mbit burst 1024Kb mtu 2Kb action drop",
> +        "matchPattern": "action order [0-9]*:  police 0x1 rate 7Mbit burst (1024Kb|1Mb) mtu 2Kb action drop",
>         "matchCount": "1",
>         "teardown": [
>             "$TC actions flush action police"
> @@ -743,7 +743,7 @@
>         "cmdUnderTest": "$TC actions add action police rate 7mbit burst 1m ok index 1",
>         "expExitCode": "0",
>         "verifyCmd": "$TC actions ls action police",
> -        "matchPattern": "action order [0-9]*:  police 0x1 rate 7Mbit burst 1024Kb mtu 2Kb action pass",
> +        "matchPattern": "action order [0-9]*:  police 0x1 rate 7Mbit burst (1024Kb|1Mb) mtu 2Kb action pass",
>         "matchCount": "1",
>         "teardown": [
>             "$TC actions flush action police"
> @@ -770,7 +770,7 @@
>         "cmdUnderTest": "$TC actions add action police rate 7mbit burst 1m reclassify index 1",
>         "expExitCode": "0",
>         "verifyCmd": "$TC actions get action police index 1",
> -        "matchPattern": "action order [0-9]*:  police 0x1 rate 7Mbit burst 1024Kb mtu 2Kb action reclassify",
> +        "matchPattern": "action order [0-9]*:  police 0x1 rate 7Mbit burst (1024Kb|1Mb) mtu 2Kb action reclassify",
>         "matchCount": "1",
>         "teardown": [
>             "$TC actions flush action police"
> @@ -797,7 +797,7 @@
>         "cmdUnderTest": "$TC actions add action police rate 7mbit burst 1m pipe index 1",
>         "expExitCode": "0",
>         "verifyCmd": "$TC actions ls action police",
> -        "matchPattern": "action order [0-9]*:  police 0x1 rate 7Mbit burst 1024Kb mtu 2Kb action pipe",
> +        "matchPattern": "action order [0-9]*:  police 0x1 rate 7Mbit burst (1024Kb|1Mb) mtu 2Kb action pipe",
>         "matchCount": "1",
>         "teardown": [
>             "$TC actions flush action police"
> -- 
> 2.34.1
> 


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ