From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH] eal: check coremask against detected lcores Date: Fri, 18 Apr 2014 00:43:16 +0200 Message-ID: <15724496.jrcSWAV12m@xps13> References: <1397569842-12562-1-git-send-email-david.marchand@6wind.com> <20140415135754.GC3557@hmsreliant.think-freely.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev-VfR2kkLFssw@public.gmane.org To: David Marchand Return-path: In-Reply-To: <20140415135754.GC3557-B26myB8xz7F8NnZeBjwnZQMhkBWG/bsMQH7oEaQurus@public.gmane.org> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces-VfR2kkLFssw@public.gmane.org Sender: "dev" > > lcores that are set in coremask should be checked against lcores detected > > on system. This way, we won't need to check them later. > > > > Besides, if specifying an unavailable lcore, we currently panic in > > eal_thread_loop() because pthread_setaffinity_np fails. > > So this check will return an error with a more explicit message in > > eal_parse_coremask(). > > > > "EAL: pthread_setaffinity_np failed > > > > PANIC in eal_thread_loop(): > > cannot set affinity" > > > > becomes : > > > > "EAL: lcore 4 unavailable > > > > EAL: invalid coremask" > > > > Signed-off-by: David Marchand > > Acked-by: Neil Horman Applied for version 1.6.0r2. Thanks for this nice usability improvement -- Thomas