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: <20171214074612.2afda1d0@redhat.com>
Date:   Thu, 14 Dec 2017 07:46:12 +0100
From:   Jesper Dangaard Brouer <brouer@...hat.com>
To:     Saeed Mahameed <saeedm@...lanox.com>
Cc:     Tariq Toukan <tariqt@...lanox.com>,
        Daniel Borkmann <borkmann@...earbox.net>,
        Alexei Starovoitov <alexei.starovoitov@...il.com>,
        netdev@...r.kernel.org, dsahern@...il.com,
        Matan Barak <matanb@...lanox.com>, gospo@...adcom.com,
        bjorn.topel@...el.com, michael.chan@...adcom.com, brouer@...hat.com
Subject: Re: [bpf-next V1-RFC PATCH 02/14] xdp/mlx5: setup xdp_rxq_info and
 extend with qtype


On Wed, 13 Dec 2017 15:03:33 -0800 Saeed Mahameed <saeedm@...lanox.com> wrote:

> >>> @@ -707,6 +714,8 @@ static void mlx5e_free_rq(struct mlx5e_rq *rq)
> >>>    	if (rq->xdp_prog)
> >>>    		bpf_prog_put(rq->xdp_prog);
> >>>    
> >>> +	xdp_rxq_info_unreg(&rq->xdp_rxq);
> >>> +
> >>>    	switch (rq->wq_type) {
> >>>    	case MLX5_WQ_TYPE_LINKED_LIST_STRIDING_RQ:
> >>>    		mlx5e_rq_free_mpwqe_info(rq);
> >>> @@ -2768,6 +2777,11 @@ static int mlx5e_alloc_drop_rq(struct
> >>> mlx5_core_dev *mdev, if (err)
> >>>    		return err;
> >>>    
> >>> +	/* XDP RX-queue info for "Drop-RQ", packets never reach
> >>> XDP */
> >>> +	xdp_rxq_info_init(&rq->xdp_rxq);
> >>> +	xdp_rxq_info_type(&rq->xdp_rxq, RXQ_TYPE_SINK);
> >>> +	xdp_rxq_info_reg(&rq->xdp_rxq);
> >>> +  
> 
> I don't see why you need this, This RQ is not even assigned to any 
> netdev_rxq! it is a pure HW object that drops traffic in HW when netdev 
> is down, it even has no buffers or napi handling, just ignore it's 
> existence for the sake of mlx5 xdp_rxq_info reg/unreg stuff and remove 
> RXQ_TYPE_SINK, bottom line it is not a real RQ and for sure XDP has 
> nothing to do with it.

I need it here, because the take-down/free code-path is the same for
these two types of RQ's.

-- 
Best regards,
  Jesper Dangaard Brouer
  MSc.CS, Principal Kernel Engineer at Red Hat
  LinkedIn: http://www.linkedin.com/in/brouer

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ