From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 301C03D0AE; Tue, 19 Dec 2023 22:57:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=infradead.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="xhkXf21S" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: Content-Type:In-Reply-To:From:References:Cc:To:Subject:MIME-Version:Date: Message-ID:Sender:Reply-To:Content-ID:Content-Description; bh=M7vYwyFBTmXa7mBCYsTu/n+QlJGbIPVud40PFjUfiyM=; b=xhkXf21S7LYXVoeF3VpoobRnb1 Dv/PMqOfwlfkkNy03gDBHnf/IIFG77n6wGj0BTrf8LNTtz8SO9dBU+okjGyKQEGNouOKTwGupcAdH QEdbpM11JGfsOi69JGBQ5sHDaj4XjsPX+ZCJzy34OlxUIf397A4FHIEW6w5tMQLxXbcbbULfCsVK+ 36/PLyjx85RGIXKof1LCC8rO0Euokn+xoMjE8j/Nv8q/kPMxpP4lFvJuYTCQxYygpuoByjK4zKKSf SQ9SG+/Kh97kOTdsb4dsMpazvluGNzPLaTYf4UKtDg7XKTrO0MOoFZwSy/gzY0uFAQt5HQg9IICMu 2m7ELvOQ==; Received: from [50.53.46.231] (helo=[192.168.254.15]) by bombadil.infradead.org with esmtpsa (Exim 4.96 #2 (Red Hat Linux)) id 1rFj1v-00Fdwd-1k; Tue, 19 Dec 2023 22:57:39 +0000 Message-ID: <41abf11c-dbd4-48b1-8ca3-746b62256da8@infradead.org> Date: Tue, 19 Dec 2023 14:57:38 -0800 Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH net-next] xsk: make struct xsk_cb_desc available outside CONFIG_XDP_SOCKETS Content-Language: en-US To: Vladimir Oltean , netdev@vger.kernel.org Cc: bpf@vger.kernel.org, linux-kernel@vger.kernel.org, Tony Nguyen , =?UTF-8?B?QmrDtnJuIFTDtnBlbA==?= , Magnus Karlsson , Maciej Fijalkowski , Jonathan Lemon , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Alexei Starovoitov , Daniel Borkmann , Jesper Dangaard Brouer , John Fastabend , Larysa Zaremba References: <20231219110205.1289506-1-vladimir.oltean@nxp.com> From: Randy Dunlap In-Reply-To: <20231219110205.1289506-1-vladimir.oltean@nxp.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit 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 Acked-by: Randy Dunlap Tested-by: Randy Dunlap # 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