From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id 077527D0F; Mon, 31 Jul 2017 18:48:32 +0200 (CEST) Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga105.jf.intel.com with ESMTP; 31 Jul 2017 09:48:31 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.41,304,1498546800"; d="scan'208";a="113963013" Received: from fyigit-mobl1.ger.corp.intel.com (HELO [10.237.220.48]) ([10.237.220.48]) by orsmga004.jf.intel.com with ESMTP; 31 Jul 2017 09:48:30 -0700 To: Matan Azrad , Adrien Mazarguil Cc: dev@dpdk.org, stable@dpdk.org References: <20170726093401.GU19852@6wind.com> <1501151244-2917-1-git-send-email-matan@mellanox.com> From: Ferruh Yigit Message-ID: Date: Mon, 31 Jul 2017 17:48:29 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <1501151244-2917-1-git-send-email-matan@mellanox.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH v2] net/mlx4: fix flow creation before start X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 31 Jul 2017 16:48:34 -0000 On 7/27/2017 11:27 AM, Matan Azrad wrote: > The corrupted code causes segmentation fault when user creates > flow with drop action before device starting. > > For example, failsafe PMD recreates all the flows before calling > dev_start in plug-in sequence and mlx4 allocated its flow drop > queue in dev_start. > Hence, when failsafe created flow with drop action after plug-in > event, mlx4 tried to dereference flow drop queue which was uninitialized. > > The fix added check to the drop qp accesibale and conditioned the > ibv_create_flow calling on device starting. > > Fixes: 642fe56a1ba5 ("net/mlx4: use a single drop queue for all drop flows") > Fixes: 46d5736a7049 ("net/mlx4: support basic flow items and actions") > Cc: stable@dpdk.org > > Signed-off-by: Matan Azrad > Acked-by: Adrien Mazarguil Applied to dpdk-next-net/master, thanks.