From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <thomas@monjalon.net> Received: from out3-smtp.messagingengine.com (out3-smtp.messagingengine.com [66.111.4.27]) by dpdk.org (Postfix) with ESMTP id 7F29091 for <dev@dpdk.org>; Wed, 31 Oct 2018 16:06:16 +0100 (CET) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id C7C4D21FF4; Wed, 31 Oct 2018 11:06:15 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Wed, 31 Oct 2018 11:06:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=mesmtp; bh=y/1BpuYvTgDaQXtNZsJA50jXUeW8ZsKpPrKYvzPgkxY=; b=TuAVR2PO3IKf LK5UOuyuW2kVJHH5ko4eh5UpireoKACig2NxS2+/4vLGNlPBmih9c1htYPtVLfV7 XSWYctuCaYHAhop0SFviyKM22XftMYSJ9keUwgdPr+v9FHlwfW52+mopxJJrM44q 75YR3qaoBRmrhO7Y56NNrXndytK657E= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=y/1BpuYvTgDaQXtNZsJA50jXUeW8ZsKpPrKYvzPgk xY=; b=f8CmfY+ScXybOb3L6RynWs8tA+6cXicRyrlusJlSQ2HnzMIu6YNrJOT+a YQN1Rzibq1XBVzxZANlrPIODDMfgewSHyGCN9vBJuRH73HOFPMA/86giFEJNWcq5 +oiaw1NY3MdALkDdCCRsppSO2c78NCv5b2ut6bKvqnSrCuS//ivib3cmUrFX/0rG Sz8rKd/bq9lgxWWMVnREc9NRFD3Y/gFyghtHJq5AQSTM6LeZBexC5ym1Nl1PjrQX jSefFtVagbQsXK5/U2iGRfNxxx5+xS3CsTy/kCN6x/v2T6MCOjRQbQUWYwSroykg U/irKjb3EqO7f8ZxTK+SY837a8wqQ== X-ME-Sender: <xms:58TZW4vrzrNDSHy5sioEWKmyyiRPu-SxIFqkZeWpBLN2qsKoxGW5ZQ> X-ME-Proxy: <xmx:58TZWyWBiBH69ITlYCmobs861bi6y-ndrR37DkFstcQivJf84tlFUw> <xmx:58TZWzQi0a0coeHEwocOeBICB0RCGKtwPvuDbQtpBewSYQXlWiJL1g> <xmx:58TZW-QqJ8IWxigds3N9AGrQIBfun4ArPafHBo-ujQ7KSawONOCuKg> <xmx:58TZW9FHGVD1tlB6svFlclSR1sJAsGaPF8xjlJaS3hxyta_rAzryyw> <xmx:58TZW6mkcrIhgCtyWQyXI8wEC2h6_bxXz0q6pzBCB4ox7FM8MkzEfQ> <xmx:58TZW3Eqwu2P4uNKu3dyM4PEfizPHoDQgyvxzcf1VXLjlhFe8-9rrg> Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 27921102A0; Wed, 31 Oct 2018 11:06:14 -0400 (EDT) From: Thomas Monjalon <thomas@monjalon.net> To: Radu Nicolau <radu.nicolau@intel.com> Cc: dev@dpdk.org, declan.doherty@intel.com, chas3@att.com, ferruh.yigit@intel.com, arybchenko@solarflare.com Date: Wed, 31 Oct 2018 16:06:19 +0100 Message-ID: <2490703.Y8HZJr6zFH@xps> In-Reply-To: <1540994346-17532-1-git-send-email-radu.nicolau@intel.com> References: <1540994346-17532-1-git-send-email-radu.nicolau@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH] net/bonding: fix segfault when creating bonded device X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions <dev.dpdk.org> List-Unsubscribe: <https://mails.dpdk.org/options/dev>, <mailto:dev-request@dpdk.org?subject=unsubscribe> List-Archive: <http://mails.dpdk.org/archives/dev/> List-Post: <mailto:dev@dpdk.org> List-Help: <mailto:dev-request@dpdk.org?subject=help> List-Subscribe: <https://mails.dpdk.org/listinfo/dev>, <mailto:dev-request@dpdk.org?subject=subscribe> X-List-Received-Date: Wed, 31 Oct 2018 15:06:16 -0000 31/10/2018 14:59, Radu Nicolau: > After the patch below the call to rte_eth_bond_8023ad_agg_selection_set > from probe() segfaults; there is no need to call the function, just set > the mode directly. > > Fixes: 391797f04208 ("drivers/bus: move driver assignment to end of probing") It would not segfault if you call rte_eth_dev_probing_finish() at the real end of the probing function. Then the port will be considered not valid in rte_eth_bond_8023ad_agg_selection_set(). It does not solve your problem but it is more correct. So I suggest to revert this patch (which was a wrong fix): http://git.dpdk.org/dpdk/commit/?id=1620175 Then the issue is to allow configuring a port before the end of probing. This patch is workarounding the public API which checks port validity. I think it is a good approach.