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]
Date: Tue, 19 Dec 2023 14:57:38 -0800
From: Randy Dunlap <rdunlap@...radead.org>
To: Vladimir Oltean <vladimir.oltean@....com>, netdev@...r.kernel.org
Cc: bpf@...r.kernel.org, linux-kernel@...r.kernel.org,
 Tony Nguyen <anthony.l.nguyen@...el.com>, Björn Töpel
 <bjorn@...nel.org>, Magnus Karlsson <magnus.karlsson@...el.com>,
 Maciej Fijalkowski <maciej.fijalkowski@...el.com>,
 Jonathan Lemon <jonathan.lemon@...il.com>,
 "David S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>,
 Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
 Alexei Starovoitov <ast@...nel.org>, Daniel Borkmann <daniel@...earbox.net>,
 Jesper Dangaard Brouer <hawk@...nel.org>,
 John Fastabend <john.fastabend@...il.com>,
 Larysa Zaremba <larysa.zaremba@...el.com>
Subject: Re: [PATCH net-next] xsk: make struct xsk_cb_desc available outside
 CONFIG_XDP_SOCKETS



On 12/19/23 03:02, Vladimir Oltean wrote:
> The ice driver fails to build when CONFIG_XDP_SOCKETS is disabled.
> 
> drivers/net/ethernet/intel/ice/ice_base.c:533:21: error:
> variable has incomplete type 'struct xsk_cb_desc'
>         struct xsk_cb_desc desc = {};
>                            ^
> include/net/xsk_buff_pool.h:15:8: note:
> forward declaration of 'struct xsk_cb_desc'
> struct xsk_cb_desc;
>        ^
> 
> Fixes: d68d707dcbbf ("ice: Support XDP hints in AF_XDP ZC mode")
> Closes: https://lore.kernel.org/netdev/8b76dad3-8847-475b-aa17-613c9c978f7a@infradead.org/
> Signed-off-by: Vladimir Oltean <vladimir.oltean@....com>


Acked-by: Randy Dunlap <rdunlap@...radead.org>
Tested-by: Randy Dunlap <rdunlap@...radead.org> # build-tested

Thanks.

> ---
> Posting to net-next since this tree is broken at this stage, not only
> bpf-next.
> 
>  include/net/xdp_sock_drv.h | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/include/net/xdp_sock_drv.h b/include/net/xdp_sock_drv.h
> index b62bb8525a5f..526c1e7f505e 100644
> --- a/include/net/xdp_sock_drv.h
> +++ b/include/net/xdp_sock_drv.h
> @@ -12,14 +12,14 @@
>  #define XDP_UMEM_MIN_CHUNK_SHIFT 11
>  #define XDP_UMEM_MIN_CHUNK_SIZE (1 << XDP_UMEM_MIN_CHUNK_SHIFT)
>  
> -#ifdef CONFIG_XDP_SOCKETS
> -
>  struct xsk_cb_desc {
>  	void *src;
>  	u8 off;
>  	u8 bytes;
>  };
>  
> +#ifdef CONFIG_XDP_SOCKETS
> +
>  void xsk_tx_completed(struct xsk_buff_pool *pool, u32 nb_entries);
>  bool xsk_tx_peek_desc(struct xsk_buff_pool *pool, struct xdp_desc *desc);
>  u32 xsk_tx_peek_release_desc_batch(struct xsk_buff_pool *pool, u32 max);

-- 
#Randy
https://people.kernel.org/tglx/notes-about-netiquette
https://subspace.kernel.org/etiquette.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ