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 ACCE5A04C3 for ; Fri, 22 Nov 2019 15:42:37 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 9F3CD2BA2; Fri, 22 Nov 2019 15:42:37 +0100 (CET) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) by dpdk.org (Postfix) with ESMTP id B43832BC7 for ; Fri, 22 Nov 2019 15:42:35 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1574433755; 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=HS14FRvmsHfQHpckEu17MeBr/7kTJdOmW8tUI5lVdh4=; b=eN2QWZFsuSjRFOJ0R/hl6GvzgRw30foByuh6wpVVabpkVQCJyYr5Ea18PQb0R93ox7rObc caentEPXFN6UEBjrnllHdYsvVTnlTl2FSkij448zCnhW7QG7F8l9GQVI4byO05TEo438PR X/G5HeG46s/e+UIazIg79EewjWd35t0= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-25-pCEdWsvLO3WBQWI11ZRAXQ-1; Fri, 22 Nov 2019 09:42:33 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id BFA411005502 for ; Fri, 22 Nov 2019 14:42:32 +0000 (UTC) Received: from rh.redhat.com (unknown [10.36.118.60]) by smtp.corp.redhat.com (Postfix) with ESMTP id 139EE8516; Fri, 22 Nov 2019 14:42:28 +0000 (UTC) From: Kevin Traynor To: Aaron Conole Cc: David Marchand , dpdk stable Date: Fri, 22 Nov 2019 14:41:11 +0000 Message-Id: <20191122144131.21231-25-ktraynor@redhat.com> In-Reply-To: <20191122144131.21231-1-ktraynor@redhat.com> References: <20191122144131.21231-1-ktraynor@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-MC-Unique: pCEdWsvLO3WBQWI11ZRAXQ-1 X-Mimecast-Spam-Score: 0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Subject: [dpdk-stable] patch 'test/interrupt: account for race with callback' has been queued to LTS release 18.11.6 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.6 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 11/29/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 rebasi= ng (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/a9a4cf75229f132db7= 280e8441d6293a39de43d7 Thanks. Kevin. --- >From a9a4cf75229f132db7280e8441d6293a39de43d7 Mon Sep 17 00:00:00 2001 From: Aaron Conole Date: Thu, 8 Aug 2019 13:38:35 -0400 Subject: [PATCH] test/interrupt: account for race with callback [ upstream commit 73afc9df00d8ba4ff58d4a7a86691ca10520d462 ] Because the eal interrupt framework can race when invoking the callback and a separate unregister call, the test needs to accommodate the chance that the two collide. Do this by checking the return value of unregister against the race-condition flag (EAGAIN). Fixes: f1a6c22424ce ("app/test: update interrupts test") Signed-off-by: Aaron Conole Reviewed-by: David Marchand --- test/test/test_interrupts.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/test/test/test_interrupts.c b/test/test/test_interrupts.c index 4e82e9a22..32ef0a208 100644 --- a/test/test/test_interrupts.c +++ b/test/test/test_interrupts.c @@ -371,7 +371,11 @@ test_interrupt_full_path_check(enum test_interrupt_han= dle_type intr_type) =20 =09rte_delay_ms(TEST_INTERRUPT_CHECK_INTERVAL); -=09if (rte_intr_callback_unregister(&test_intr_handle, -=09=09=09test_interrupt_callback, &test_intr_handle) < 0) -=09=09return -1; +=09while ((count =3D +=09=09rte_intr_callback_unregister(&test_intr_handle, +=09=09=09=09=09 test_interrupt_callback, +=09=09=09=09=09 &test_intr_handle)) < 0) { +=09=09if (count !=3D -EAGAIN) +=09=09=09return -1; +=09} =20 =09if (flag =3D=3D 0) { --=20 2.21.0 --- Diff of the applied patch vs upstream commit (please double-check if non-= empty: --- --- -=092019-11-22 14:36:56.565927899 +0000 +++ 0025-test-interrupt-account-for-race-with-callback.patch=092019-11-22 1= 4:36:55.193149372 +0000 @@ -1 +1 @@ -From 73afc9df00d8ba4ff58d4a7a86691ca10520d462 Mon Sep 17 00:00:00 2001 +From a9a4cf75229f132db7280e8441d6293a39de43d7 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit 73afc9df00d8ba4ff58d4a7a86691ca10520d462 ] + @@ -12 +13,0 @@ -Cc: stable@dpdk.org @@ -17 +18 @@ - app/test/test_interrupts.c | 10 +++++++--- + test/test/test_interrupts.c | 10 +++++++--- @@ -20,4 +21,4 @@ -diff --git a/app/test/test_interrupts.c b/app/test/test_interrupts.c -index d8c2d8124..233b14a70 100644 ---- a/app/test/test_interrupts.c -+++ b/app/test/test_interrupts.c +diff --git a/test/test/test_interrupts.c b/test/test/test_interrupts.c +index 4e82e9a22..32ef0a208 100644 +--- a/test/test/test_interrupts.c ++++ b/test/test/test_interrupts.c