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 4C8C0A0C4F for ; Mon, 12 Jul 2021 15:13:07 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 46DE24119C; Mon, 12 Jul 2021 15:13:07 +0200 (CEST) Received: from mail-wm1-f53.google.com (mail-wm1-f53.google.com [209.85.128.53]) by mails.dpdk.org (Postfix) with ESMTP id A4ACF40685 for ; Mon, 12 Jul 2021 15:13:06 +0200 (CEST) Received: by mail-wm1-f53.google.com with SMTP id n4so975168wms.1 for ; Mon, 12 Jul 2021 06:13:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=6pQxx6SoBorI5iLK81RPvkL/FQ5Aq+SzcmTeZaaxEZ8=; b=lo6ZhUPZ4/exJrjJZ3CHCvHdreXWr5SAS9faSbHuxj7pUpbFc8P4SJZsP80//I63UW 7Q8MorvvErJyenl9UBlVfLC2T/mRvfxXrNQ1yaiiDtqbtdx0Mk+5RXnnjzmCnc+cH2VZ ClPAE8I1qQu9IeG7VB0vh5/ZF5rLj7lzICLorJiI52292v0Yx/zAMuFtfZ3na2oUYDXl pWeXEjuRkyUi+iWHw0pb3typbdD4rwK3IcPMxkfkKAKSyLTE4DuM6nO1RATJgYjZawgd 3xwGL9HLqG3Avwy/uCEgp9EiYlDRtLGhTp6wuDStrx7T6eXO9MHsUwaUEsfdtdOkfZe0 qmFg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=6pQxx6SoBorI5iLK81RPvkL/FQ5Aq+SzcmTeZaaxEZ8=; b=TX8nHqkhx+1y0bLX5sfYaB9ab2PBK972UNlLRVQdn/y5OYT1iFWGHJPMnDrO2lzPtF 2IvfGuLM7LChNfBtNTEtl9Upwj79dYkxa+Q5w7O/pFq6+ozo1JGSRN8KZUUHZ5uvf7se VgJALSL8Wnr/4BPPYIt/1chYxGrDkRrOZmRjPsUw+s4lIlmaufuC2so/7ytmj/GyZ3KO JwSV7YWU5yhdi3Zjro9dWwuIlIwymoQdWYs/03gVb+JKdPti6cDdf5LkC82p5T5V5YBP d+P0ypvEpFHhuQrr6bkZMcLyUCwO0G3Zg8SQZu4zXdIVTNiI8PatZ9BlG7ANr8FZDj6j HNRA== X-Gm-Message-State: AOAM530hyxxvFG8JizHv0zAMQFC9yr41IEvejrx+M1jTFvfv0CliiiPw ccDMdX4JSCLTwy97sMwwNsMBSuA1tY6ZW4ea X-Google-Smtp-Source: ABdhPJxZ7SoHb9+HxxmvmJr34A2I89VKmpqTnBiQtp66F3YmjnAqH4VUclPRlD1G2eWpeVKFIXh07w== X-Received: by 2002:a05:600c:1546:: with SMTP id f6mr55143859wmg.164.1626095586428; Mon, 12 Jul 2021 06:13:06 -0700 (PDT) Received: from localhost ([137.220.125.106]) by smtp.gmail.com with ESMTPSA id j6sm6527878wrm.97.2021.07.12.06.13.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Jul 2021 06:13:05 -0700 (PDT) From: luca.boccassi@gmail.com To: Ivan Malov Cc: Andrew Rybchenko , Andy Moreton , dpdk stable Date: Mon, 12 Jul 2021 14:04:52 +0100 Message-Id: <20210712130551.2462159-57-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210712130551.2462159-1-luca.boccassi@gmail.com> References: <20210712130551.2462159-1-luca.boccassi@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] patch 'net/sfc: check ID overflow in action port ID' has been queued to stable release 20.11.3 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 Sender: "stable" Hi, FYI, your patch has been queued to stable release 20.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 07/14/21. 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/bluca/dpdk-stable This queued commit can be viewed at: https://github.com/bluca/dpdk-stable/commit/810cbe8ff07bdfebc74287bbbaa0cb6c1e7b2f20 Thanks. Luca Boccassi --- >From 810cbe8ff07bdfebc74287bbbaa0cb6c1e7b2f20 Mon Sep 17 00:00:00 2001 From: Ivan Malov Date: Thu, 27 May 2021 17:27:22 +0300 Subject: [PATCH] net/sfc: check ID overflow in action port ID [ upstream commit fb3c4efb65be520082a34c0afb85d492ff093c82 ] The container in the action configuration is U32, but the ID is U16, and overflow check is missing. Fixes: 1fb65e4dae8a ("net/sfc: support flow action port ID in transfer rules") Signed-off-by: Ivan Malov Reviewed-by: Andrew Rybchenko Reviewed-by: Andy Moreton --- drivers/net/sfc/sfc_mae.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/sfc/sfc_mae.c b/drivers/net/sfc/sfc_mae.c index 2f02fcdd19..abeee38a2f 100644 --- a/drivers/net/sfc/sfc_mae.c +++ b/drivers/net/sfc/sfc_mae.c @@ -2000,6 +2000,9 @@ sfc_mae_rule_parse_action_port_id(struct sfc_adapter *sa, uint16_t port_id; int rc; + if (conf->id > UINT16_MAX) + return EOVERFLOW; + port_id = (conf->original != 0) ? sas->port_id : conf->id; rc = sfc_mae_switch_port_by_ethdev(mae->switch_domain_id, -- 2.30.2 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2021-07-12 13:41:39.613393781 +0100 +++ 0057-net-sfc-check-ID-overflow-in-action-port-ID.patch 2021-07-12 13:41:36.454121861 +0100 @@ -1 +1 @@ -From fb3c4efb65be520082a34c0afb85d492ff093c82 Mon Sep 17 00:00:00 2001 +From 810cbe8ff07bdfebc74287bbbaa0cb6c1e7b2f20 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit fb3c4efb65be520082a34c0afb85d492ff093c82 ] + @@ -10 +11,0 @@ -Cc: stable@dpdk.org @@ -20 +21 @@ -index 33bff275cf..2ea2d63c5c 100644 +index 2f02fcdd19..abeee38a2f 100644 @@ -23 +24 @@ -@@ -2653,6 +2653,9 @@ sfc_mae_rule_parse_action_port_id(struct sfc_adapter *sa, +@@ -2000,6 +2000,9 @@ sfc_mae_rule_parse_action_port_id(struct sfc_adapter *sa,