From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id EEA3841EA5; Thu, 16 Mar 2023 01:07:07 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B2B6340EF1; Thu, 16 Mar 2023 01:07:07 +0100 (CET) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mails.dpdk.org (Postfix) with ESMTP id 4ED7740DF6 for ; Thu, 16 Mar 2023 01:07:06 +0100 (CET) Received: by linux.microsoft.com (Postfix, from userid 1086) id A33ED20C7DF7; Wed, 15 Mar 2023 17:07:05 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com A33ED20C7DF7 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1678925225; bh=fwlED4pkyE2zEvG1s9/7zANzFEfYScNRji78omjtT1Q=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Jae8tn2wRArgnTOtZwinhSetMFxi+cFia5/b3qnm6kGzi9aCsJXhE7SgND3ASLBAw /mf7DHz6YGerm2M6IIUmeTxgLL8H4dwHZHDtedy33sls4NzhZplXFtgpKZjDg91ZiK kzSmqK+6S/1/U3nkhGKVL41UCqND12KUL8CDL5zs= From: Tyler Retzlaff To: dev@dpdk.org Cc: thomas@monjalon.net, david.marchand@redhat.com, stephen@networkplumber.org, Tyler Retzlaff Subject: [PATCH v5 0/2] fix race in rte_thread_create failure path Date: Wed, 15 Mar 2023 17:07:02 -0700 Message-Id: <1678925224-2706-1-git-send-email-roretzla@linux.microsoft.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1677782682-27200-1-git-send-email-roretzla@linux.microsoft.com> References: <1677782682-27200-1-git-send-email-roretzla@linux.microsoft.com> X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org v5: * refactor patch to use pthread_cond_t to wait for thread start wrapper to complete work. * rename some variables to group those that are part of the wrapper synchronization. * use stack instead of heap allocation for thread start context. v4: * style fixes reported by CI v3: * don't free wrapper context from new thread now that wrapper completion is complete before returning from creating thread. v2: * new approach over v1 of the patch to avoid using pthread np API that is not available on Alpine Linux. * to conform to rte_thread_create parameter const qualification include an additional patch to const qualify rte_thread_set_affinity cpusetp parameter. Tyler Retzlaff (2): eal: make cpusetp to rte thread set affinity const eal: fix failure path race setting new thread affinity lib/eal/common/eal_common_thread.c | 6 ++-- lib/eal/include/rte_thread.h | 2 +- lib/eal/unix/rte_thread.c | 70 +++++++++++++++++++++++--------------- 3 files changed, 47 insertions(+), 31 deletions(-) -- 1.8.3.1