From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH v2 1/1] pci: default to whitelist mode Date: Thu, 30 Mar 2017 21:36:43 +0200 Message-ID: <2981401.fEuT21do2s@xps13> References: <1490701917-17089-1-git-send-email-gaetan.rivet@6wind.com> <20170328124409.GC7450@bidouze.vm.6wind.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Cc: "Van Haaren, Harry" , dev@dpdk.org, "Richardson, Bruce" To: =?ISO-8859-1?Q?Ga=EBtan?= Rivet Return-path: Received: from mail-wr0-f170.google.com (mail-wr0-f170.google.com [209.85.128.170]) by dpdk.org (Postfix) with ESMTP id BF3B837B2 for ; Thu, 30 Mar 2017 21:36:45 +0200 (CEST) Received: by mail-wr0-f170.google.com with SMTP id w43so75020751wrb.0 for ; Thu, 30 Mar 2017 12:36:45 -0700 (PDT) In-Reply-To: List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 2017-03-28 13:02, Van Haaren, Harry: > > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Ga=EBtan Rivet= > > On Tue, Mar 28, 2017 at 01:20:00PM +0100, Bruce Richardson wrote: > > >On Tue, Mar 28, 2017 at 02:01:29PM +0200, Gaetan Rivet wrote: > > >> Expects all devices to be explicitly defined before being probed= . > > >> > > >> The blacklist mode can be prone to errors, coaxing users in capt= uring > > >> devices that could be used for management or otherwise. > > >> The whitelist mode offers users more control and highlight mista= kes by > > >> making them visible on the command line. > > >> > > >> This is more useful to have a clear idea of the state of the sys= tem used, > > >> which is better in the context of standalone / headless applicat= ions. > > >> > > >> Using the -b option will revert to the original behavior. > > >> > > >> Signed-off-by: Gaetan Rivet > > >> --- > > >> v2: justify this default behavior evolution. > > >> --- > > > > > >I don't have major objections to this patch, though it does make i= t > > >mandatory to use port parameters where before it was not. The one > > >suggestion I will make is that, if we take this approach, we shoul= d > > >probably add a --wl-all (whitelist-all) flag to go back to having = all > > >ports automatically bound, if so desired. > > > > >=20 > > Are there use cases where the blacklist mode would be used without > > blacklisting any device? The current -b option is almost enough for= the > > same level of functionality. > >=20 > > If there is an actual need to a full PCI probe, adding this option = is > > certainly possible. I was thinking otherwise of allowing "all" as a= n > > argument to -w, which would have our users using -wall or -w=3Dall,= which > > seems clear enough. >=20 >=20 > If I understand correctly an app that runs without any port parameter= s to EAL would now fail to find any ports? >=20 > That would result in; > - testing frameworks (DTS, fd.io perf lab, customers, etc) would fail= if not specifying ports > - beginners just running ./app/testpmd would need to specify the "mag= ic" -w-all > - confusion about why previously working DPDK apps are now failing du= e to not finding any devices >=20 > I'm not totally opposed, but we should consider carefully what impact= s this change will have across the whole DPDK ecosystem, and if the cha= nge is worth it. If decided that "Yes its worth it", we would need to c= ommunicate this change very clearly. All documentation regarding runnin= g any DPDK app would need to be updated as part of this change. >=20 > Personally I don't see the large benefit this patch brings, but more = of a disturbance in the DPDK; I'm open to be convinced otherwise. I agree it is much more a disturbance to change the default behaviour. Both options -b/-w are already available for people who really care. Anyway, the default behaviour should be an application policy. One day, we will have to make all these command line magics optional, and rely on the application implementation.