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 075454326E for ; Thu, 2 Nov 2023 10:57:20 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id EEF8040691; Thu, 2 Nov 2023 10:57:19 +0100 (CET) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mails.dpdk.org (Postfix) with ESMTP id A6E2240282 for ; Thu, 2 Nov 2023 10:57:17 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1698919037; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=/OB27NRQQjLMIadXNVeqAEQSOGpX/7eJNZ0p9qO92dw=; b=Ykc4EQGsea9uvk4tEWR8jQ0iRjKkEvIxDkV+pjOXJE2/cencjC1y4QwbWcD/6v2K92DfVE 6yvPnaaejXJ9uvi4Gctz43D0Q5SPndvDSknNdBXHD1G+/2LDv+/W7vDzfQIs9JlpyIC0fh qRn8QY7s+BAE7OTHn6d9sIxHrlIdiU4= Received: from mail-lf1-f72.google.com (mail-lf1-f72.google.com [209.85.167.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-398-jwuFPyM_OoS8SLuOa0uuyg-1; Thu, 02 Nov 2023 05:57:15 -0400 X-MC-Unique: jwuFPyM_OoS8SLuOa0uuyg-1 Received: by mail-lf1-f72.google.com with SMTP id 2adb3069b0e04-507b0270b7fso699861e87.3 for ; Thu, 02 Nov 2023 02:57:15 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698919034; x=1699523834; h=in-reply-to:references:to:from:cc:subject:message-id:date :content-transfer-encoding:mime-version:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=225YBfLkz7h3KsPKelxxxfaQSRbZMDpbPwnZ+DGtQ9Y=; b=N4J8iCQ80BrzxuTRD0jeQm2QEIFlChlnAaMY7vMFa9d9RkYoA7eoubhUAIirCW6ZWr sVjOE4kcQ3WYHh5geR7uBjO+3ogpk8NHF1ArT0PGVibf5U9yX7lFqTTTl1Su/NFWF7lW XfwTCy3dKDAA5LdDltrIIqwRChNR4hXor3UsqN53Q21RCJd6wXgmOk9PFPSEtoQhcpkp 51Dbc4kJFVcaKyBN0X6c3o2QgLFoaKkelgoTPMyGcUWZIE2jtU44TSrb73ndztz7icob aUjeAEfESISPf6s+RafK6i2N2M5J6zn0I7fPIbMykZrSC/eaTlRzbXqECxXgNBkg2rAo 8Jlg== X-Gm-Message-State: AOJu0Yyzp/IqK870S8Hb+Cb6PepRDywzK1j4JrXSDRDngs9w8IiGatyN SXAnjpyD4D1e/I2pgRdubVOqg3eulPJcm78KOogpmwJkSZ202wSsoiFFi4p4QjivVHnoich5N5K lt8H5N0c= X-Received: by 2002:a05:6512:4024:b0:509:4ae3:4656 with SMTP id br36-20020a056512402400b005094ae34656mr1054759lfb.13.1698919034248; Thu, 02 Nov 2023 02:57:14 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEMflrV4Y7n9Q4lSEcqhJ3K3ttp+CIVutkwyajnqZORCOK0LzgAP54mBxzELkjb2m7vjH6pbQ== X-Received: by 2002:a05:6512:4024:b0:509:4ae3:4656 with SMTP id br36-20020a056512402400b005094ae34656mr1054738lfb.13.1698919033887; Thu, 02 Nov 2023 02:57:13 -0700 (PDT) Received: from localhost (2a01cb000f8b9700598da2e1679e8383.ipv6.abo.wanadoo.fr. [2a01:cb00:f8b:9700:598d:a2e1:679e:8383]) by smtp.gmail.com with ESMTPSA id h13-20020a5d4fcd000000b003248a490e3asm1983757wrw.39.2023.11.02.02.57.12 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 02 Nov 2023 02:57:13 -0700 (PDT) Mime-Version: 1.0 Date: Thu, 02 Nov 2023 10:57:12 +0100 Message-Id: Subject: Re: [PATCH] eal: stop iteration after lcore info is processed Cc: , , , From: "Robin Jarry" To: "Ruifeng Wang" , "Kevin Laatz" , =?utf-8?q?Morten_Br=C3=B8rup?= X-Mailer: aerc/0.16.0-55-g2e912b0445cd References: <20231101072053.1319697-1-ruifeng.wang@arm.com> In-Reply-To: <20231101072053.1319697-1-ruifeng.wang@arm.com> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8; format=Flowed X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Ruifeng Wang, Nov 01, 2023 at 08:20: > Telemetry iterates on lcore ID to collect info of a specific lcore. > Since only one lcore is processed at a time, the iteration can stop > when a matching lcore is found. > > Fixes: f2b852d909f9 ("eal: add lcore info in telemetry") > Cc: rjarry@redhat.com > Cc: stable@dpdk.org > > Signed-off-by: Ruifeng Wang > --- > lib/eal/common/eal_common_lcore.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/lib/eal/common/eal_common_lcore.c b/lib/eal/common/eal_commo= n_lcore.c > index ceda714ca5..0d6812ec75 100644 > --- a/lib/eal/common/eal_common_lcore.c > +++ b/lib/eal/common/eal_common_lcore.c > @@ -546,7 +546,8 @@ lcore_telemetry_info_cb(unsigned int lcore_id, void *= arg) > =09=09rte_tel_data_add_dict_uint(info->d, "busy_cycles", usage.busy_cycl= es); > =09} > =20 > -=09return 0; > +=09/* Return non-zero positive value to stop iterating over lcore_id. */ > +=09return 1; > } Hi Ruifeng, Nice catch. Reviewed-by: Robin Jarry