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 Nov 2019 15:56:09 -0800
From:   Jakub Kicinski <jakub.kicinski@...ronome.com>
To:     <sameehj@...zon.com>
Cc:     <davem@...emloft.net>, <netdev@...r.kernel.org>, <dwmw@...zon.com>,
        <zorik@...zon.com>, <matua@...zon.com>, <saeedb@...zon.com>,
        <msw@...zon.com>, <aliguori@...zon.com>, <nafea@...zon.com>,
        <gtzalik@...zon.com>, <netanel@...zon.com>, <alisaidi@...zon.com>,
        <benh@...zon.com>, <akiyano@...zon.com>
Subject: Re: [PATCH V2 net-next v2 2/3] net: ena: Implement XDP_TX action

On Tue, 19 Nov 2019 15:34:18 +0200, sameehj@...zon.com wrote:
> diff --git a/drivers/net/ethernet/amazon/ena/ena_netdev.c b/drivers/net/ethernet/amazon/ena/ena_netdev.c
> index 35f766d9c..087f132e0 100644
> --- a/drivers/net/ethernet/amazon/ena/ena_netdev.c
> +++ b/drivers/net/ethernet/amazon/ena/ena_netdev.c
> @@ -35,7 +35,6 @@
>  #ifdef CONFIG_RFS_ACCEL
>  #include <linux/cpu_rmap.h>
>  #endif /* CONFIG_RFS_ACCEL */
> -#include <linux/bpf_trace.h>
>  #include <linux/ethtool.h>
>  #include <linux/kernel.h>
>  #include <linux/module.h>
> @@ -47,6 +46,7 @@
>  #include <net/ip.h>
>  
>  #include "ena_netdev.h"
> +#include <linux/bpf_trace.h>
>  #include "ena_pci_id_tbl.h"


Perhaps just add this header include where you want it in the first
patch? :/

> @@ -190,6 +194,17 @@ struct ena_tx_buffer {
>  	/* num of buffers used by this skb */
>  	u32 num_of_bufs;
>  
> +	/* XDP buffer structure which is used for sending packets in
> +	 * the xdp queues
> +	 */
> +	struct xdp_buff *xdp;

Isn't this structure declared on the stack of ena_clean_rx_irq()?
Perhaps you should consider using xdp_frame..

> +	/* The rx page for the rx buffer that was received in rx and
> +	 * re transmitted on xdp tx queues as a result of XDP_TX action.
> +	 * We need to free the page once we finished cleaning the buffer in
> +	 * clean_xdp_irq()
> +	 */
> +	struct page *xdp_rx_page;
> +
>  	/* Indicate if bufs[0] map the linear data of the skb. */
>  	u8 map_linear_data;
>  

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ