From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id A3E0BA046B for ; Fri, 23 Aug 2019 11:44:09 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 93D3E1BF9C; Fri, 23 Aug 2019 11:44:09 +0200 (CEST) Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id 7DF3A1BF9B for ; Fri, 23 Aug 2019 11:44:08 +0200 (CEST) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id CC8E08980FD; Fri, 23 Aug 2019 09:44:07 +0000 (UTC) Received: from rh.redhat.com (ovpn-116-48.ams2.redhat.com [10.36.116.48]) by smtp.corp.redhat.com (Postfix) with ESMTP id 20B2A5F9D3; Fri, 23 Aug 2019 09:44:05 +0000 (UTC) From: Kevin Traynor To: Thomas Monjalon Cc: David Marchand , Stephen Hemminger , dpdk stable Date: Fri, 23 Aug 2019 10:42:54 +0100 Message-Id: <20190823094336.12078-4-ktraynor@redhat.com> In-Reply-To: <20190823094336.12078-1-ktraynor@redhat.com> References: <20190823094336.12078-1-ktraynor@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.6.2 (mx1.redhat.com [10.5.110.67]); Fri, 23 Aug 2019 09:44:08 +0000 (UTC) Subject: [dpdk-stable] patch 'eal/linux: fix return after alarm registration failure' has been queued to LTS release 18.11.3 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 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 Sender: "stable" Hi, FYI, your patch has been queued to LTS release 18.11.3 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 08/28/19. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/kevintraynor/dpdk-stable-queue This queued commit can be viewed at: https://github.com/kevintraynor/dpdk-stable-queue/commit/6f4a16e42610878c498b24af79826bd4580d1a00 Thanks. Kevin Traynor --- >From 6f4a16e42610878c498b24af79826bd4580d1a00 Mon Sep 17 00:00:00 2001 From: Thomas Monjalon Date: Wed, 26 Jun 2019 12:12:00 +0200 Subject: [PATCH] eal/linux: fix return after alarm registration failure [ upstream commit 75683290e5ed7846b3e37d927efca68974fb3f20 ] When adding an alarm, if an error happen when registering the common alarm callback, it is not considered as a major failure. The alarm is then inserted in the list. However it was returning an error code after inserting the alarm. The error code is not set anymore to be consistent with the behaviour. Fixes: af75078fece3 ("first public release") Signed-off-by: Thomas Monjalon Reviewed-by: David Marchand Acked-by: Stephen Hemminger --- lib/librte_eal/linuxapp/eal/eal_alarm.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/librte_eal/linuxapp/eal/eal_alarm.c b/lib/librte_eal/linuxapp/eal/eal_alarm.c index 840ede780..0924c9205 100644 --- a/lib/librte_eal/linuxapp/eal/eal_alarm.c +++ b/lib/librte_eal/linuxapp/eal/eal_alarm.c @@ -138,7 +138,8 @@ rte_eal_alarm_set(uint64_t us, rte_eal_alarm_callback cb_fn, void *cb_arg) rte_spinlock_lock(&alarm_list_lk); if (!handler_registered) { - ret |= rte_intr_callback_register(&intr_handle, - eal_alarm_callback, NULL); - handler_registered = (ret == 0) ? 1 : 0; + /* registration can fail, callback can be registered later */ + if (rte_intr_callback_register(&intr_handle, + eal_alarm_callback, NULL) == 0) + handler_registered = 1; } -- 2.20.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2019-08-22 19:38:20.730451971 +0100 +++ 0004-eal-linux-fix-return-after-alarm-registration-failur.patch 2019-08-22 19:38:20.395027881 +0100 @@ -1 +1 @@ -From 75683290e5ed7846b3e37d927efca68974fb3f20 Mon Sep 17 00:00:00 2001 +From 6f4a16e42610878c498b24af79826bd4580d1a00 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit 75683290e5ed7846b3e37d927efca68974fb3f20 ] + @@ -14 +15,0 @@ -Cc: stable@dpdk.org @@ -20 +21 @@ - lib/librte_eal/linux/eal/eal_alarm.c | 7 ++++--- + lib/librte_eal/linuxapp/eal/eal_alarm.c | 7 ++++--- @@ -23 +24 @@ -diff --git a/lib/librte_eal/linux/eal/eal_alarm.c b/lib/librte_eal/linux/eal/eal_alarm.c +diff --git a/lib/librte_eal/linuxapp/eal/eal_alarm.c b/lib/librte_eal/linuxapp/eal/eal_alarm.c @@ -25,2 +26,2 @@ ---- a/lib/librte_eal/linux/eal/eal_alarm.c -+++ b/lib/librte_eal/linux/eal/eal_alarm.c +--- a/lib/librte_eal/linuxapp/eal/eal_alarm.c ++++ b/lib/librte_eal/linuxapp/eal/eal_alarm.c