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: <20231020180631.0f7eaebb@kernel.org>
Date: Fri, 20 Oct 2023 18:06:31 -0700
From: Jakub Kicinski <kuba@...nel.org>
To: Stanislav Fomichev <sdf@...gle.com>
Cc: bpf@...r.kernel.org, ast@...nel.org, daniel@...earbox.net,
 andrii@...nel.org, martin.lau@...ux.dev, song@...nel.org, yhs@...com,
 john.fastabend@...il.com, kpsingh@...nel.org, haoluo@...gle.com,
 jolsa@...nel.org, toke@...nel.org, willemb@...gle.com, dsahern@...nel.org,
 magnus.karlsson@...el.com, bjorn@...nel.org, maciej.fijalkowski@...el.com,
 hawk@...nel.org, yoong.siang.song@...el.com, netdev@...r.kernel.org,
 xdp-hints@...-project.net
Subject: Re: [PATCH bpf-next v4 03/11] tools: ynl: Print xsk-features from
 the sample

On Thu, 19 Oct 2023 10:49:36 -0700 Stanislav Fomichev wrote:
> Regenerate the userspace specs and print xsk-features bitmask.

I'm afraid you regenerated in previous patch already :]
Perhaps we should add an easy-to-use flag to ynl-regen to skip tools/ ?

> diff --git a/tools/net/ynl/samples/netdev.c b/tools/net/ynl/samples/netdev.c
> index b828225daad0..da7c2848f773 100644
> --- a/tools/net/ynl/samples/netdev.c
> +++ b/tools/net/ynl/samples/netdev.c
> @@ -44,6 +44,12 @@ static void netdev_print_device(struct netdev_dev_get_rsp *d, unsigned int op)
>  			printf(" %s", netdev_xdp_rx_metadata_str(1 << i));
>  	}
>  
> +	printf(" xsk-features (%llx):", d->xsk_features);
> +	for (int i = 0; d->xsk_features > 1U << i; i++) {

Shouldn't this be >= ?

> +		if (d->xsk_features & (1U << i))
> +			printf(" %s", netdev_xsk_flags_str(1 << i));
> +	}

Powered by blists - more mailing lists