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 435FB43EF7; Wed, 24 Apr 2024 17:50:26 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id BD13F4359C; Wed, 24 Apr 2024 17:50:25 +0200 (CEST) Received: from mail-pl1-f177.google.com (mail-pl1-f177.google.com [209.85.214.177]) by mails.dpdk.org (Postfix) with ESMTP id 8B0F0402D1 for ; Wed, 24 Apr 2024 17:50:24 +0200 (CEST) Received: by mail-pl1-f177.google.com with SMTP id d9443c01a7336-1e65b29f703so55257905ad.3 for ; Wed, 24 Apr 2024 08:50:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1713973823; x=1714578623; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=PqjtUD2BK+Erz0SpNH0Bu6RR5HZs8hZE+Lfx+65Bw2I=; b=IB8vaoM8/CIvMo4H4LomyFMuQDE5LB8gxyerACR4f47m86GPrRmwx53e33llIyQE1A /i9uohd8oqfL2B0ReKVRUm88lL1zGQ5aTy1IhLUSt5/E4gUbju6e4grBvXIyjWKfaKqR 6/XLqMbc6bOpwaDxaeBw0/WmIYuK9tWCwyfyyHXx77/jlToSKtOPmNoC1ycTADqmiiQL /xHrZ5O5DiVSIQ+/rlvz0CbnHotZvZun8dXdZPWe5TB5OlBqoxQugEkeWUkvV3ovT75h GWRio3sanH12ud04qanEebgzWXOvj9Y36tkmAS5mTGwNRnIOVaUEqfPFlRk3ZDwmms3F HkZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1713973823; x=1714578623; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=PqjtUD2BK+Erz0SpNH0Bu6RR5HZs8hZE+Lfx+65Bw2I=; b=xQ21AaqX65pko+5duLZeaD/gEsniY7poQs+wF5wfJDQ2HeDMo0cil5JDkQ767isGpb ElsxDUgTn0jo/ARsOp5FlWzZJFqLuVSGqYdEKws2PyMfgFoslZB+ryvF4NcC2VTqUub3 IWkq/RFhZI5NGt3IZBZQb7wWY+FkttdliVBXPvBAwFqwqXE/g1g1lW5Q9wm5TScEjCEN n8u9+jewg3WGBqdn9VK4USNKCedvYbjALTmG8UvO6WM7fhoUSzJQDeYg17usAdBdGhb2 gBI8+XZMp6Yc+9j7qVZsleDl4b9OdJFYJfUnxuO6c87ASC91H12rQ8mZTg+3+HXi8oe/ WaPw== X-Gm-Message-State: AOJu0YxWYdf0cR4KTJkTWP9tfjbpEKj9hXIOnMIIbhqzXIbD6cChuLm4 CvyKGKuVelANWR7f8D/B9hzWegPiRTRaDJYyWFEh6RFfmqwMvJMJe7uxbV8s7fvtumVul8eUPO+ R X-Google-Smtp-Source: AGHT+IHQk7piTi0PircP0Vp1zuHFe4u5ZI9Hicktae3SAjjvA+blBPU2EkSSoRRNAn1NBc+vqpbwpA== X-Received: by 2002:a17:902:ce8f:b0:1e4:ccf6:209f with SMTP id f15-20020a170902ce8f00b001e4ccf6209fmr3425192plg.28.1713973823567; Wed, 24 Apr 2024 08:50:23 -0700 (PDT) Received: from hermes.local (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id a13-20020a170902b58d00b001e0942da6c7sm12012458pls.284.2024.04.24.08.50.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 24 Apr 2024 08:50:23 -0700 (PDT) Date: Wed, 24 Apr 2024 08:50:21 -0700 From: Stephen Hemminger To: Jianyue Wu Cc: dev@dpdk.org Subject: Re: [PATCH] eal/linux: enhanced error handling for affinity Message-ID: <20240424085021.11f2ff96@hermes.local> In-Reply-To: <20240423030243.59895-1-wujianyue000@163.com> References: <20240423030243.59895-1-wujianyue000@163.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit 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 On Tue, 23 Apr 2024 11:02:43 +0800 Jianyue Wu wrote: > Improve the robustness of setting thread affinity in DPDK > by adding detailed error logging. Is this an error you saw in your application or something inside DPDK? > Changes: > 1. Check the return value of pthread_setaffinity_np() and log an error > if the call fails. Not sure this is necessary. The rte_thread functions are intended to be os independent wrapper for threads. Does it need to be this chatty. > 2. Include the current thread name, the intended CPU set, and a detailed > error message in the log. This introduces a more code and ends up being Linux/BSD specific only for the case where application did something wrong.