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 4B84645BB3; Wed, 23 Oct 2024 17:42:42 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 1DCE340613; Wed, 23 Oct 2024 17:42:42 +0200 (CEST) Received: from mail-pl1-f174.google.com (mail-pl1-f174.google.com [209.85.214.174]) by mails.dpdk.org (Postfix) with ESMTP id B74F5402DF for ; Wed, 23 Oct 2024 17:42:40 +0200 (CEST) Received: by mail-pl1-f174.google.com with SMTP id d9443c01a7336-20c8b557f91so69690725ad.2 for ; Wed, 23 Oct 2024 08:42:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1729698160; x=1730302960; 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=Z0fRInZ1UrZEpTkPX1Rv3AJsUzItRfHN4bVthYrRpPw=; b=IJhdFbXKYEMH2kEfaehGXBIxXyJCRgv7VzLycjhRJZFgQv1xXVUj5Nq2IT8ROwBMdo wwlCeK1HpRtA+CKd8wdr8ff4YT64YyK/D2t1YB5JcMAqK3c4N4Spish60YHJGb13xhY6 T6PyhMcUi3FUwhrVRuzPiVfC28XrhT4io6z7Am85b4rpS1ODrmhNCjzjy0qQQ3cfflkW DboVqtr24snVGzEnztAGeiOSaNBA26uR2kkaNJ2jHNe/Au2M1aZUbDwAn5/bjg+ZorUc piqWvovCwmgtUN+4lpj7EciQOMGogSHh6ZWEGkrqWEqLo+f+FzBct1P9INIZ6N3SGGH1 6P7A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729698160; x=1730302960; 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=Z0fRInZ1UrZEpTkPX1Rv3AJsUzItRfHN4bVthYrRpPw=; b=u9eVZHVgHpIYRJR0MgTuSiLL4sX5WjO6MfOme32U5INvYehdNJtGW/2MusmX/8gtbu kAnXui01bEbJUZgCO65Kn7ycBu+4a1che5pNo5leloRBb3lV9B4Um0rFK3dkSkbLHoj6 j/ovYkC89GvyNXrFnHT0J+CV78o52m2JY0MA+/Rera+K6rHVvbm8dinJP2Oqvc8QO1ub 8JCv93gqCSycGTTVONNfEWNPdMr5UzFqIi2GnMBVAZ1kQlIuCkAlkU9cOIixH5gYM6HY 2nYbAXCn5Eom3HOTCw4ta6cnH4gvgdpjHhAMulznzmvzGxof55X9WaPI7pIs2a7X6acg F9BA== X-Gm-Message-State: AOJu0YxsFP7FyM+tOQgrx2nTZJmYO1IF4IRdgFvDfe165VZWqASK2vCK c6Ynz0c0ZWjT1JQweLYfvfaqK1yu4s7fwIbvaKqNO4XnJ/jEuWYi4rDnPuAi6X0= X-Google-Smtp-Source: AGHT+IHH7yTm+TyhHGZgSIhe1XK+WMuA9STBWG3m3+agakyL2YaOMr0fLQXLeLoRFvQU/w/xrNxuxg== X-Received: by 2002:a17:902:cec3:b0:20c:5a64:9bc6 with SMTP id d9443c01a7336-20fab2db84fmr29021695ad.50.1729698159742; Wed, 23 Oct 2024 08:42:39 -0700 (PDT) Received: from hermes.local (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-20e7ef0ad78sm58997355ad.84.2024.10.23.08.42.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 23 Oct 2024 08:42:39 -0700 (PDT) Date: Wed, 23 Oct 2024 08:42:37 -0700 From: Stephen Hemminger To: Dengdui Huang Cc: , , , , , , , , Subject: Re: [PATCH v4 00/42] replace strerror Message-ID: <20241023084237.4da0ae1b@hermes.local> In-Reply-To: <20241023082852.2780488-1-huangdengdui@huawei.com> References: <20231114082539.1858594-44-huangdengdui@huawei.com> <20241023082852.2780488-1-huangdengdui@huawei.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 Wed, 23 Oct 2024 16:28:10 +0800 Dengdui Huang wrote: > The function strerror() is insecure in a multi-thread environment. > It is better to use rte_strerror() instead of strerror(). > In this patchset, only the libs and drivers are modified. > > chang log: > v3->v4 fix ci error > v2->v3 drop patch "telemetry: replace strerror" due to compile fail > v1-v2 fix ci error Even rte_strerror is not completely safe. It depends on the calling thread being a registered lcore. It would be better to use a coccinelle script to do direct replacement with strerror_r(). Also, rte_strerror is not signal safe.