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 407B7A0A02; Wed, 5 May 2021 18:16:04 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2B0854112F; Wed, 5 May 2021 18:16:04 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mails.dpdk.org (Postfix) with ESMTP id 5C17541117 for ; Wed, 5 May 2021 18:16:02 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1620231361; 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: in-reply-to:in-reply-to:references:references; bh=0AfYC8jUnpvYO+W+Na9D42rkyZWGYVE6MwPKlvWBQbk=; b=Mk7U4pbEUt2HFcnI8j7d78lXu0+NarBWJlxMh9NtA0q6lvSwNmNdG0lfFw+pi6TLSZ9VMj FcgKTr1h50RP98Bx2jV+/lZLP45zcl4CzY+k4vNPFSoqVViMfbxj5MPr1QEZjPyN+8I8jr OhCxdlU/cm3ALlpEbBqc/zBY+yc2HSg= Received: from mail-ua1-f70.google.com (mail-ua1-f70.google.com [209.85.222.70]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-501-ArQaZOugPSCNJKXYEOgXRA-1; Wed, 05 May 2021 12:15:59 -0400 X-MC-Unique: ArQaZOugPSCNJKXYEOgXRA-1 Received: by mail-ua1-f70.google.com with SMTP id g12-20020ab04e0c0000b02901f93b0bde1eso185064uah.16 for ; Wed, 05 May 2021 09:15:59 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=0AfYC8jUnpvYO+W+Na9D42rkyZWGYVE6MwPKlvWBQbk=; b=tbDQ32GC/6iypWY2EVNzA+9cs9lLAjZNWQ4ZggVbjO2sCTxCGCX0gO2VI+pAwAspxy t7wOJi+y8U8WyfG7iFgUeV93d39lwFOzlTNnx5AlqCm6gq0FunQIUbhjhn0lDG3rsmMS wnLqyCxYrYc7RV2wgkg/tYB9NifgKwODQspQAtXUIzlOq+ZYJnI2vQKyLsYT6JipW7hY AKR14mwqLjQGhhxZyFOXkkORKEc6VxlVnddluelmd2PPx39B7mL4xDBFtzOxpuPJIPQI hvLwpusaW6NJK2vtI21jevjY6JW1TspcmGD3Ee0tYzy0vh0yWjVSOYY6snqXR4S3Vrii d7Ew== X-Gm-Message-State: AOAM531FC4A+iJ3EMXbgTMymXdKsaYMQzVSSQRXQ9rg5sD4NVkPHr/Gj UuWPqbfJJ2od6cHylbDJye0w2kqiRc+KPAJPz14A2ntweZ4OX4UreTUpagB4GyW1OzjDVAozXAe QprKlbaUuIC4KKRSfD9I= X-Received: by 2002:a67:6b41:: with SMTP id g62mr8479886vsc.5.1620231358925; Wed, 05 May 2021 09:15:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyPoesX51VLC/yO+b3drGRO77IXFYWWD9MumzF6HtstkzHT0/wcC7DbHg4S9qJMhOMH5LLqTEzleCTxBG/aThA= X-Received: by 2002:a67:6b41:: with SMTP id g62mr8479864vsc.5.1620231358776; Wed, 05 May 2021 09:15:58 -0700 (PDT) MIME-Version: 1.0 References: <20210505152248.253496-1-ciara.power@intel.com> In-Reply-To: From: David Marchand Date: Wed, 5 May 2021 18:15:47 +0200 Message-ID: To: Bruce Richardson Cc: Ciara Power , dev , dpdk stable Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=dmarchan@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="UTF-8" Subject: Re: [dpdk-dev] [PATCH] telemetry: fix accessing callbacks list using lock 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 Sender: "dev" On Wed, May 5, 2021 at 5:36 PM Bruce Richardson wrote: > > On Wed, May 05, 2021 at 03:22:48PM +0000, Ciara Power wrote: > > The list_commands() function accessed the callbacks list, > > but did not take the lock. This may have caused inconsistencies if > > callbacks were being registered at the same time. > > This is now fixed to lock before iterating the list, > > and unlock afterwards. > > > > Fixes: f38748736eb2 ("telemetry: add default callback commands") > > Cc: stable@dpdk.org > > > > Reported-by: David Marchand > > Signed-off-by: Ciara Power > Acked-by: Bruce Richardson Applied, thanks. -- David Marchand