From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 93D89CD1284 for ; Thu, 4 Apr 2024 06:48:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:CC:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=bdD8+hDL2f5rmwqqDhXc1vEEC2Qf0BDL0a5VyJ4t58Y=; b=CGMXWekJ62AjXt Vmbo/LP7IOUDfbdA77SU0RJ3rgHFWh0n2RciHaqV1NLRiMFnwWI8COJA965532zfk71s+G4fYeWCw H8whzkybn8MVdeIeXBoJ8OgbUlfmd/FcktoJktgkQNJ19yuc+w2cpB0Oz6vrHjOHOd7VWJJTGMIJJ CdkXL4b1jRbRNMp9naIh7+jk/4n2DeqG/A0zuq47CaWDbVCjOKQnfBTMx70HZUDoZLi5Ejt6apHmo ZRLyzBpurqH001b4y3CyOeW7Y8rIvAad9SPkpgLDG/y93HuAUsyXrQ4hFV92Otwj/33fJTtNuPYhk EXv1XBGN7uozRmlx96Sg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rsGtc-00000001Vaw-2mcE; Thu, 04 Apr 2024 06:48:24 +0000 Received: from esa.microchip.iphmx.com ([68.232.154.123]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rsGta-00000001Va7-1wfu for linux-arm-kernel@lists.infradead.org; Thu, 04 Apr 2024 06:48:23 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1712213302; x=1743749302; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=LGK2yHu2NA1tw1OVzxXDi8K+v7+Kt4wEU5L7h21w5BU=; b=uPnVAVqwht3m7eL2aplK0uiMtGKzksL7j5AfhIjsVnTPbPcPJrSkVbNw jVfk5IjMESJq0LAJxIGz1Q+dvTLp7ogA6QUKMAUIRrRpcwYHjN2McUrRw sh+CSDprjaB70GrkUdq14xAiY4qZGwIjPJoqpZIcuW/6nsIBacnvTFQ9E S/L5VogwG67YgD0ueuHecNXuB3rYMpfrAkQageYskYUpjhnH9fpLil6XH mnraClVw/CErPAy0px+j20EOlxN7iNo7e14KY+4N0ItREB0YAUBa9Quqs 2owcoC8mYhpIx2n9D4MWkg1R1rXXYm1XsTuboHB6y2Jz07tVNMMV/2Db5 g==; X-CSE-ConnectionGUID: GsiGwEYZQ9CUJDJZMZRgQg== X-CSE-MsgGUID: CFzFroZ/TOuqjz/ebU1XeA== X-IronPort-AV: E=Sophos;i="6.07,178,1708412400"; d="scan'208";a="19959521" X-Amp-Result: SKIPPED(no attachment in message) Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa2.microchip.iphmx.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 03 Apr 2024 23:48:22 -0700 Received: from chn-vm-ex04.mchp-main.com (10.10.85.152) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Wed, 3 Apr 2024 23:47:51 -0700 Received: from localhost (10.10.85.11) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server id 15.1.2507.35 via Frontend Transport; Wed, 3 Apr 2024 23:47:51 -0700 Date: Thu, 4 Apr 2024 08:47:50 +0200 From: Horatiu Vultur To: Daniel Machon CC: Lars Povlsen , Steen Hegelund , , "David S. Miller" , Eric Dumazet , "Jakub Kicinski" , Paolo Abeni , , , Subject: Re: [PATCH net-next 3/3] net: sparx5: add support for tc flower redirect action Message-ID: <20240404064750.psxhftdmvf5pannf@DEN-DL-M31836.microchip.com> References: <20240403-mirror-redirect-actions-v1-0-c8e7c8132c89@microchip.com> <20240403-mirror-redirect-actions-v1-3-c8e7c8132c89@microchip.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20240403-mirror-redirect-actions-v1-3-c8e7c8132c89@microchip.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240403_234822_566571_D16AD660 X-CRM114-Status: GOOD ( 12.49 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The 04/03/2024 20:41, Daniel Machon wrote: Hi Daniel, > +static int sparx5_tc_action_redirect(struct vcap_admin *admin, > + struct vcap_rule *vrule, > + struct flow_cls_offload *fco, > + struct flow_action_entry *act) > +{ > + struct vcap_u72_action ports = {0}; > + int err; The same comments from previous patch applies also here. > + > + if (admin->vtype != VCAP_TYPE_IS0 && admin->vtype != VCAP_TYPE_IS2) { > + NL_SET_ERR_MSG_MOD(fco->common.extack, > + "Redirect action not supported in this VCAP"); > + return -EOPNOTSUPP; > + } > + > + err = vcap_rule_add_action_u32(vrule, VCAP_AF_MASK_MODE, > + SPX5_PMM_REPLACE_ALL); > + if (err) > + return err; > + > + sparx5_tc_flower_set_port_mask(&ports, act->dev); > + > + err = vcap_rule_add_action_u72(vrule, VCAP_AF_PORT_MASK, &ports); > + if (err) > + return err; > + And here. > + return 0; > +} > -- > 2.34.1 > -- /Horatiu _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel