From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f49.google.com (mail-wm0-f49.google.com [74.125.82.49]) by dpdk.org (Postfix) with ESMTP id 6C8428E6C for ; Tue, 3 Nov 2015 12:21:13 +0100 (CET) Received: by wmff134 with SMTP id f134so81382986wmf.1 for ; Tue, 03 Nov 2015 03:21:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind_com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:organization:user-agent :in-reply-to:references:mime-version:content-transfer-encoding :content-type; bh=RPNVdg+MRg9FN+zHhWZDeLXfNaUxkiMH95KNxTrO0xI=; b=L1Fw++9rDIa4MQz/JS4WIUpV4Dhe9VRP9jQWXyMsOImjrC1W+0jTQ+oCIs18SSjpmO w7JLlfHzillI4CmIrnRTG1SeRACrerSkgA0YS906Os9j3/eEHDXQxdl6gj4+1cKsoxQS YBwyeXnSHtfo1mHGLYG2RDA6bx7m/zkTmZSgQp/RP9qgI1MPaAEawsSR5nxb6tfPsdom nEuf6TzWzLlSXt9s3YKi2zN0YOHkmBuuFKd1SD72L9/On94cc1KVTBNSKkLwuLfhXDzm XWYZo/mizXRMJcheT/mFf/67oyFltv+b7PL3DCNjGgJVX4LfJ7FNPvwrY58pEqMySqoh OoZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:organization :user-agent:in-reply-to:references:mime-version :content-transfer-encoding:content-type; bh=RPNVdg+MRg9FN+zHhWZDeLXfNaUxkiMH95KNxTrO0xI=; b=cdLhrt3ykG6R7AYSJz/arXUGMU4MDuWiL26iUPjAcLqQdmJAuLzIPfNvD6IheG0ywX cJzunM0PmSYuFhc+WQQYS0dD+wznqACzTuNuUeb6NyMgB5OGkcnlgpTt1l/pJS3IY17Y Grd8hx6gCiCS1jqPR5XDQi9a5vEYG9qBngW+UZc3bhOqY4jJz+4bwSVslbMcRpqmZC+A xnBR7/mwtpLOSMwiH2RpX/nOQFpYQ+1wgbzbcajCCmQrQ/jSlUebNTGNl7f0nuWNAIXs BVdn+rl5EJdJXOTGMh/T8CAROmhujSDPYDUNE54sNqwkFfsqH0wIGeGrNm7iHo1LU3vu XKpg== X-Gm-Message-State: ALoCoQkhzjT0QMjtkdbHz8T9dV0jhAru8zZs7lkoHOUggDVTtB41eemAj8wuds6XrjC3y8GWW6Gi X-Received: by 10.28.213.212 with SMTP id m203mr18328067wmg.33.1446549673282; Tue, 03 Nov 2015 03:21:13 -0800 (PST) Received: from xps13.localnet (guy78-3-82-239-227-177.fbx.proxad.net. [82.239.227.177]) by smtp.gmail.com with ESMTPSA id l81sm22839982wmb.2.2015.11.03.03.21.12 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 03 Nov 2015 03:21:12 -0800 (PST) From: Thomas Monjalon To: David Marchand Date: Tue, 03 Nov 2015 12:20:02 +0100 Message-ID: <33652013.vVXR4tZhrp@xps13> Organization: 6WIND User-Agent: KMail/4.14.10 (Linux/4.1.6-1-ARCH; KDE/4.14.11; x86_64; ; ) In-Reply-To: References: <1446108903-14412-1-git-send-email-david.marchand@6wind.com> <1835472.4si0y6iqvT@xps13> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Cc: dev@dpdk.org Subject: Re: [dpdk-dev] [PATCH 3/3] ethdev: prevent segfaults in rte_eth_dev_is_detachable X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Nov 2015 11:21:13 -0000 2015-11-03 12:19, David Marchand: > On Tue, Nov 3, 2015 at 12:10 PM, Thomas Monjalon > wrote: > > > 2015-10-29 09:55, David Marchand: > > > From: Maxime Leroy > > > > > > Some drivers like virtual ones don't specify any driver pointer in the > > > structure rte_eth_dev. > > > > > > To prevent segfault, we should check if this pointer is NULL before > > > dereferencing it. > > > > > > Signed-off-by: Maxime Leroy > > > Signed-off-by: David Marchand > > > > It is not clear what the problem is. > > And the driver fields should probably be removed or changed as it too > > tigthly > > related to the PCI driver. > > > > It does look odd to me as well, quickly went through head, and did not see > a case where this could happen. > Maxime is not available at the moment, so I think I will just drop this > patch. > > How about this patchset rebased on head with just the first two patches ? Perfect, thanks