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 5196FA0544 for ; Fri, 11 Nov 2022 12:41:36 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 4D5294014F; Fri, 11 Nov 2022 12:41:36 +0100 (CET) Received: from smtp-relay-internal-0.canonical.com (smtp-relay-internal-0.canonical.com [185.125.188.122]) by mails.dpdk.org (Postfix) with ESMTP id 76C1A40141 for ; Fri, 11 Nov 2022 12:41:34 +0100 (CET) Received: from mail-ed1-f70.google.com (mail-ed1-f70.google.com [209.85.208.70]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-internal-0.canonical.com (Postfix) with ESMTPS id AAA57423E2 for ; Fri, 11 Nov 2022 11:41:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1668166893; bh=P18CL9v0KNxC7F7MZievvo5ToeMnC8UqIOLze2I67Y8=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=MOuAoQwPBCF8trNO6nten4Bw0OwAZPwugVbzFKAqdMvjUu9m4zVvtwKh1y9fL7O+e jQuHWq7uJoM/FbOCTVhhB19vb8ns/RpidTonR50YehQDBgu8IE9O0xOJLij0v2pQ+S nJXCppJlgyvo0jtR6CZt3DHgGTAgQCVU4WI7qCiNlQSrDn9UY5qxOOPMid4JSOUvvH +dgVLXqk8QEcLRTQdv4hnHziCy0fRU1IH4OHrGxIxNWhptjtxHDqo3fNWGGMrBRSFd vQ3tnNKjEpnMUNdPZEFsyZC3qa7SWXIpYCw4ZxKfb0uisMILKywH0OCKVICxQChW5l uCY00800tQZVQ== Received: by mail-ed1-f70.google.com with SMTP id y20-20020a056402271400b004630f3a32c3so3454369edd.15 for ; Fri, 11 Nov 2022 03:41:33 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=P18CL9v0KNxC7F7MZievvo5ToeMnC8UqIOLze2I67Y8=; b=lBh+U8Hm7n8CcriaEjiMFLOxuRJ4mLRa9IszYGN2Hmj3IGLLSlbqHYNMK5H3Xi9FkB 4Je65tLlwS3lwBpQ1AiSL4mdHli4J6SrhutJ8qQCHczFzbqaNVwNmtbXlxPPqmHp4kUM oJN+MNrzeBt1BV5Lwzg5ZbZieKKc1HrUNNjLslkCKg+bgFC1GDwr6FLBWmT/ZnPd95Gx l04XCtiu6BXnXoBQutc7TIYOLvhm80f+eYP/Uk5BVFH+9nFOzS3Xundwe6IipbTCCUZL P6OZNsAOC24Z5Sb5d7gxRDONSJ9z1SS08KqpMRRqPPsLDZOIWesR+UBN6Ea7qGC8iGlG qTow== X-Gm-Message-State: ANoB5pnmmh6yXUxMVoGpV8ohm+6Rdtcsgj5U6nf0hrmgMIxz1ijwdNTO unYIPnVEG23oHXO1QO7B64h7XK8zdYOB9qCn/Un5xvLs+SpWTLFVqW1f+Vuh/fMwwCS63wVd52a sLOa5kEl/Yqx/GwesZvp0bYte X-Received: by 2002:a17:907:110d:b0:7a9:6107:572a with SMTP id qu13-20020a170907110d00b007a96107572amr1495043ejb.729.1668166893133; Fri, 11 Nov 2022 03:41:33 -0800 (PST) X-Google-Smtp-Source: AA0mqf7558AborPyUTTWeyltq8A2PqSAnpuLksrhtUMrLH/xqBb3JsBPxUd7rFtg7TCNBEDlASzTcQ== X-Received: by 2002:a17:907:110d:b0:7a9:6107:572a with SMTP id qu13-20020a170907110d00b007a96107572amr1495032ejb.729.1668166892927; Fri, 11 Nov 2022 03:41:32 -0800 (PST) Received: from localhost.localdomain ([2a02:6d40:39af:c100:1891:6c61:50fd:e567]) by smtp.gmail.com with ESMTPSA id vu6-20020a170907a64600b007ae10525550sm790919ejc.47.2022.11.11.03.41.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 03:41:32 -0800 (PST) From: christian.ehrhardt@canonical.com To: Ciara Power Cc: Fan Zhang , Pablo de Lara , dpdk stable Subject: patch 'test/crypto: fix wireless auth digest segment' has been queued to stable release 19.11.14 Date: Fri, 11 Nov 2022 12:39:02 +0100 Message-Id: <20221111113904.1549618-45-christian.ehrhardt@canonical.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221111113904.1549618-1-christian.ehrhardt@canonical.com> References: <20221111113904.1549618-1-christian.ehrhardt@canonical.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 Hi, FYI, your patch has been queued to stable release 19.11.14 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/18/22. 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/cpaelzer/dpdk-stable-queue This queued commit can be viewed at: https://github.com/cpaelzer/dpdk-stable-queue/commit/414eb9ff5a6868a52c70ce5b95a9ee15d32219ec Thanks. Christian Ehrhardt --- >From 414eb9ff5a6868a52c70ce5b95a9ee15d32219ec Mon Sep 17 00:00:00 2001 From: Ciara Power Date: Fri, 7 Oct 2022 13:46:50 +0000 Subject: [PATCH] test/crypto: fix wireless auth digest segment [ upstream commit dc3f6c5347b2b64899694c2f94a6af53c95d2b4d ] The segment size for some tests was too small to hold the auth digest. This caused issues when using op->sym->auth.digest.data for comparisons in AESNI_MB PMD after a subsequent patch enables SGL. For example, if segment size is 2, and digest size is 4, then 4 bytes are read from op->sym->auth.digest.data, which overflows into the memory after the segment, rather than using the second segment that contains the remaining half of the digest. Fixes: 11c5485bb276 ("test/crypto: add scatter-gather tests for IP and OOP") Signed-off-by: Ciara Power Acked-by: Fan Zhang Acked-by: Pablo de Lara --- app/test/test_cryptodev.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/app/test/test_cryptodev.c b/app/test/test_cryptodev.c index 279cf8b07c..e23a68e0b1 100644 --- a/app/test/test_cryptodev.c +++ b/app/test/test_cryptodev.c @@ -3121,6 +3121,16 @@ create_wireless_algo_auth_cipher_operation( remaining_off -= rte_pktmbuf_data_len(sgl_buf); sgl_buf = sgl_buf->next; } + + /* The last segment should be large enough to hold full digest */ + if (sgl_buf->data_len < auth_tag_len) { + rte_pktmbuf_free(sgl_buf->next); + sgl_buf->next = NULL; + TEST_ASSERT_NOT_NULL(rte_pktmbuf_append(sgl_buf, + auth_tag_len - sgl_buf->data_len), + "No room to append auth tag"); + } + sym_op->auth.digest.data = rte_pktmbuf_mtod_offset(sgl_buf, uint8_t *, remaining_off); sym_op->auth.digest.phys_addr = rte_pktmbuf_iova_offset(sgl_buf, -- 2.38.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2022-11-11 12:35:06.347891877 +0100 +++ 0045-test-crypto-fix-wireless-auth-digest-segment.patch 2022-11-11 12:35:04.813192283 +0100 @@ -1 +1 @@ -From dc3f6c5347b2b64899694c2f94a6af53c95d2b4d Mon Sep 17 00:00:00 2001 +From 414eb9ff5a6868a52c70ce5b95a9ee15d32219ec Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit dc3f6c5347b2b64899694c2f94a6af53c95d2b4d ] + @@ -16 +17,0 @@ -Cc: stable@dpdk.org @@ -26 +27 @@ -index c6d47a035e..203b8b61fa 100644 +index 279cf8b07c..e23a68e0b1 100644 @@ -29 +30 @@ -@@ -2990,6 +2990,16 @@ create_wireless_algo_auth_cipher_operation( +@@ -3121,6 +3121,16 @@ create_wireless_algo_auth_cipher_operation(