From patchwork Tue Jul 24 14:21:28 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Roy Pledge X-Patchwork-Id: 10542235 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id A823014BC for ; Tue, 24 Jul 2018 14:22:32 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9650E28B97 for ; Tue, 24 Jul 2018 14:22:32 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8A8D228BC5; Tue, 24 Jul 2018 14:22:32 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id EB53128BA1 for ; Tue, 24 Jul 2018 14:22:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:Reply-To:List-Subscribe:List-Help: List-Post:List-Archive:List-Unsubscribe:List-Id:MIME-Version:References: In-Reply-To:Message-Id:Date:Subject:To:From:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=HVgEQUreWUJMZSZ8A5BkVOK76UO3OiezwL1XF+Pb3aI=; b=Y3ACm6+TZpWHhq MKYD+5c52NPx0XejDcXv66LAWxk5qmCYZ1zIbhERqisfzBqgEHHfG8UR85wnLO0NC/PTcuX7KwuDZ jjdNVQnHOTVOi2g3JZfGqZSscy/O+df9tmpdsLX2gZPYzKtboHWWSbYXtsw3Rr+Zb28W65bN6SNSx o0xJ/a0BmeWTajzzk3/aHPSDneMOKJcuG10sa1GeXr3uEir2d+BRfFSKF5S5si+oO22qum++xnkLZ tSW9lKn+ShTOlMxVMzye5EPJVcZANO9IlJDn0hpDJ/Lf/Bvg0gtDmpOlNJLIL9La8z+pG89XN1Q64 L4w33WmnUdu+evgxc/XA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1fhyCq-00009a-1I; Tue, 24 Jul 2018 14:22:28 +0000 Received: from mail-he1eur01on0043.outbound.protection.outlook.com ([104.47.0.43] helo=EUR01-HE1-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1fhyCW-0008GG-PO for linux-arm-kernel@lists.infradead.org; Tue, 24 Jul 2018 14:22:10 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=lDZKIHyR2034iUyRWQVawtltx+astMShveJjBdzqC+Y=; b=cTGRPTfRQ6mSo/2gkmsLl3TD9kTr+7/ueifkB8U/6RrRJLhnltpHagvBAVZ161XNiYKsZ3MSY4NWJrvQwSuIp4Jo9zX3lRPLr2peQHk1eGnI5tJmdYa1EEKwzpcxyaI84XuDmKb0eKAJYWCn1Iduzy2XGCr3P20Uz5scCcWpmao= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=roy.pledge@nxp.com; Received: from rhuath.am.freescale.net (64.157.242.222) by DB7PR04MB4490.eurprd04.prod.outlook.com (2603:10a6:5:35::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.973.21; Tue, 24 Jul 2018 14:21:52 +0000 From: Roy Pledge To: devel@driverdev.osuosl.org, linux-arm-kernel@lists.infradead.org, gregkh@linuxfoundation.org, leoyang.li@nxp.com Subject: [PATCH v3 1/4] staging: fsl-dpaa2/eth: move generic FD defines to DPIO Date: Tue, 24 Jul 2018 09:21:28 -0500 Message-Id: <20180724142131.28970-2-roy.pledge@nxp.com> X-Mailer: git-send-email 2.8.3 In-Reply-To: <20180724142131.28970-1-roy.pledge@nxp.com> References: <20180724142131.28970-1-roy.pledge@nxp.com> MIME-Version: 1.0 X-Originating-IP: [64.157.242.222] X-ClientProxiedBy: SN6PR0102CA0006.prod.exchangelabs.com (2603:10b6:805:1::19) To DB7PR04MB4490.eurprd04.prod.outlook.com (2603:10a6:5:35::16) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 923dfc80-95bd-4e4f-58d1-08d5f170ce90 X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989117)(5600073)(711020)(4618075)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(2017052603328)(7153060)(7193020); SRVR:DB7PR04MB4490; X-Microsoft-Exchange-Diagnostics: 1; DB7PR04MB4490; 3:YnRX93i5/6Mr5fRZgJi3IWR8GKTP54QER+kI0YsiS0NUGpTFZ+tpe7ZdxIcP57H4Wur6JMDC9b+J8euyDF8X2eSIKdVs05oMnRr6ScnmKTOuUADnAM2FWECOxG4tirVspiAo4wE8Zjn28Ua+q6EpeexvTzfg5DNrFV/chXmlVz0ixK+Z9o6dPsKAFnfwC4weOFIEr4OqzwTqW1m0jFYZdNY5wRrjx2zr7mJyRnQWnLh4W0wZfsZ2mdmabt5YmUnE; 25:l7BtaZ6cfrPbFzkJQTJDf5mXUCXNjY1LWOTwfg0a27+nOAhvI0rRzWroyN/ANdEFmS1I9DTwjgMZUmsS7H+aJ/pCpSl9bJ9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:Cy9KWHeuvAmqyKFTCxG9HVcn2h5MMNvD0jYEd8C0znFnqG7EgAneMuv7SEtXbRmZcUuU46AIYSq0NBoqvUBirDHGE5S9zPcZXYvbC40FNjGm1caBhJprHBzdlHe9Uzs2qMT4ogYQcmwwp1D3oh2KM27RTye7/ugkAF55X3x4+c+JL1xjLFqB/3s2GwrGELp4dR/SICzDgR9rwXyXytEtAL5lwK+/z9rB3zrmAqXZ2AH/I2QTT7AOd0qYQzdIo6hYpiu8/ggbCe5jKlqKjXVoMKZQatwRybO5J5ksP/cuCJXGUxotllX33ByImGHMYqYp X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(10201501046)(93006095)(93001095)(3231311)(944501410)(52105095)(3002001)(6055026)(149027)(150027)(6041310)(20161123564045)(20161123562045)(20161123560045)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(6072148)(201708071742011)(7699016); SRVR:DB7PR04MB4490; BCL:0; PCL:0; RULEID:; SRVR:DB7PR04MB4490; X-Forefront-PRVS: 0743E8D0A6 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(136003)(376002)(346002)(396003)(39860400002)(366004)(199004)(189003)(1076002)(2616005)(105586002)(44832011)(66066001)(446003)(11346002)(486006)(2906002)(3450700001)(47776003)(2870700001)(478600001)(6486002)(36756003)(53936002)(106356001)(956004)(575784001)(86362001)(6512007)(476003)(386003)(81156014)(5660300001)(6506007)(16526019)(68736007)(6636002)(97736004)(8936002)(6666003)(305945005)(23676004)(76176011)(52116002)(186003)(50226002)(26005)(81166006)(7736002)(316002)(14444005)(3846002)(6116002)(25786009)(4326008)(43066004)(8676002)(50466002)(41533002); DIR:OUT; SFP:1101; SCL:1; SRVR:DB7PR04MB4490; H:rhuath.am.freescale.net; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; Received-SPF: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?utf-8?q?1=3BDB7PR04MB4490=3B23=3A40un7By?= =?utf-8?q?aNuvnI0efi5GupjsP1sD1cEseVJn3nD1AMCyEz24DxOsOYEtLHDjnGlTcoKFjRpfD?= =?utf-8?q?6vTVzKLg4q7RYhblw1UhzLf5gUaLKj0zmwN3aXQV50XQl9EQ6DicYOlGt5p2F+5Kg?= =?utf-8?q?KQhQbWyyDrwMQhGV1kcezPRpbo5uVluVg7X/khNK8ZeMZPhp3+OdjAyKk6n1IIB7n?= =?utf-8?q?HYvthewTwxJ/rl3dk/1QDkGa0fov1NQFUdTLir7Efq/rp7BPmovy5/rDDryCDKLcN?= =?utf-8?q?cuM3JrkFQT1zkWZSCHmChxlEGNQN+eFD+CtFn17ZLxZ/nXg9B85Xb14sicxjTiSjC?= =?utf-8?q?bSdEwXUgsGZaekUeD0jocPou9N0q3CME5c0lqOLJHOetDt+fqZ3OhysZQ//EKcs7a?= =?utf-8?q?PIFeGadOABssP7wrRbbqadBWGMteRNKd93RNzSFzmJ4+rdzFtbpQTU1TbZYjTas3e?= =?utf-8?q?7v8hP87XJXT8IAsuLr3sbtCbO3n8z2qw217pTTZra3nFHoRv26DIVmbFdR6uXCthP?= =?utf-8?q?nar5y8VLiHyyE7nIrC75M0aOMTLC5aROu7Pcjbh2or6JtvPy9TQaBGGXmKNMIJBBA?= =?utf-8?q?mw1/5m9t60Yzgf1+k9gSAw9y6cVGX4WCfo1pM8Qf1eynAWBnIjTPVMD9bnPY+NqkX?= =?utf-8?q?MJ7ohacGpg2+TB201wJugbx+PB1h0/hcnBdrM0YFmBzMtxgvtIZqUTv6qyiLtq4Ba?= =?utf-8?q?brVBSBkKXqKFnYoATAQxjCTyMDGPzQFfAfAzNf6gRtCByME2jk+vm/flMWh+CYbIb?= =?utf-8?q?30Us564ib7v7/ypr+9h8QAvR15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D3OsZRNV+EU7/fU6X+t8nUXQb8jmDImfQ3ehOVD2PUQaquHSm45BTPP/fib51xlU42zpHVziy3uxlmxmd1xiHtKwQ+aWtVaBiGXqnGsye7CqWFztYR7kMI6bWHADSyclxseDRX0dMK7WqyoZ3psJfAuzmT6Z0Vj855OFuNc89rftdnTipmKfBxigU3FU04LJqUSa1swj9iUrne319/hxpfvV8YrNR53S9WycfTIXB1+YZeWFKbDKjsd2c9Y/uiXKObzOuNdtUZyyAtztrM4BVKA+8VWoamQCqNQ5hGvo0YeIEhEU4S4RHlzwrPlLZ418/hBAbUaUSE7Ri8GgdA1dMd19JcLjYutPDypAQ0pJkOmyjRI3HnB6PmQRapwXNLrCQwFniRQ8Hu4VADDVTBvLFEJSSg==; 5:8U0QQxkkE4tLi5BQiqWnKrkIJctYQpi5Mu2UdC50rSlLEWqnGKxP77INfYwJ1CA7MCzvMC7Y5F7C/WwMhXX5BfUjXZ/aFDThRVHZ8pLEpqDivkO/iAUcpy5/d6qH2O4n/wF4dNN9hI0kXaUh/fHFSXUEBn4eJdFR/N9wGDgnwwM=; 7:arVdy/dOoYaLkEJndrGUy5ErsHiL7DPpmk1HjzqTd1vNZ9cAP6SoqvUCRPjDmtcEG2gCccv1kBVlory4fuqS+XdL7DZYQ9E2ixXRSPZKYQSvqVcX/RLPoSZb/zzusS5rkm7I0XggKpgQS7Xvo6mdwhrCvhsJsEt6yxe4eh4vQIJ40gcIWkU4eOykHVATAjZz8KBlC525EpxuUFNZ25IcPq6pz0k5Q8OCS+VWdCoa+AIWo/yxCBCINErj5kDnIcrW SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2018 14:21:52.9078 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 923dfc80-95bd-4e4f-58d1-08d5f170ce90 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB7PR04MB4490 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180724_072208_838350_8D508B49 X-CRM114-Status: GOOD ( 11.41 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: roy.pledge@nxp.com Cc: horia.geanta@nxp.com, arnd@arndb.de, catalin.marinas@arm.com, ruxandra.radulescu@nxp.com, linux-kernel@vger.kernel.org, robin.murphy@arm.com, laurentiu.tudor@nxp.com Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP From: Horia Geantă Previous commits: commit 6e2387e8f19e ("staging: fsl-dpaa2/eth: Add Freescale DPAA2 Ethernet driver") commit 39163c0ce0f4 ("staging: fsl-dpaa2/eth: Errors checking update") have added bits that are not specific to the WRIOP accelerator. Move these where they belong (in DPIO) such that other accelerators can make use of them. Signed-off-by: Horia Geantă Acked-by: Ioana Radulescu --- drivers/staging/fsl-dpaa2/ethernet/dpaa2-eth.c | 4 ++-- drivers/staging/fsl-dpaa2/ethernet/dpaa2-eth.h | 18 +++++------------- drivers/staging/fsl-mc/include/dpaa2-fd.h | 12 ++++++++++++ 3 files changed, 19 insertions(+), 15 deletions(-) diff --git a/drivers/staging/fsl-dpaa2/ethernet/dpaa2-eth.c b/drivers/staging/fsl-dpaa2/ethernet/dpaa2-eth.c index 3963717..d5f0ac5 100644 --- a/drivers/staging/fsl-dpaa2/ethernet/dpaa2-eth.c +++ b/drivers/staging/fsl-dpaa2/ethernet/dpaa2-eth.c @@ -455,7 +455,7 @@ static int build_sg_fd(struct dpaa2_eth_priv *priv, dpaa2_fd_set_format(fd, dpaa2_fd_sg); dpaa2_fd_set_addr(fd, addr); dpaa2_fd_set_len(fd, skb->len); - dpaa2_fd_set_ctrl(fd, DPAA2_FD_CTRL_PTA | DPAA2_FD_CTRL_PTV1); + dpaa2_fd_set_ctrl(fd, FD_CTRL_PTA | FD_CTRL_PTV1); if (priv->tx_tstamp && skb_shinfo(skb)->tx_flags & SKBTX_HW_TSTAMP) enable_tx_tstamp(fd, sgt_buf); @@ -508,7 +508,7 @@ static int build_single_fd(struct dpaa2_eth_priv *priv, dpaa2_fd_set_offset(fd, (u16)(skb->data - buffer_start)); dpaa2_fd_set_len(fd, skb->len); dpaa2_fd_set_format(fd, dpaa2_fd_single); - dpaa2_fd_set_ctrl(fd, DPAA2_FD_CTRL_PTA | DPAA2_FD_CTRL_PTV1); + dpaa2_fd_set_ctrl(fd, FD_CTRL_PTA | FD_CTRL_PTV1); if (priv->tx_tstamp && skb_shinfo(skb)->tx_flags & SKBTX_HW_TSTAMP) enable_tx_tstamp(fd, buffer_start); diff --git a/drivers/staging/fsl-dpaa2/ethernet/dpaa2-eth.h b/drivers/staging/fsl-dpaa2/ethernet/dpaa2-eth.h index 905a4e6..9269cb0 100644 --- a/drivers/staging/fsl-dpaa2/ethernet/dpaa2-eth.h +++ b/drivers/staging/fsl-dpaa2/ethernet/dpaa2-eth.h @@ -124,21 +124,13 @@ struct dpaa2_eth_swa { #define DPAA2_FD_FRC_FAICFDV 0x0400 /* Error bits in FD CTRL */ -#define DPAA2_FD_CTRL_UFD 0x00000004 -#define DPAA2_FD_CTRL_SBE 0x00000008 -#define DPAA2_FD_CTRL_FSE 0x00000020 -#define DPAA2_FD_CTRL_FAERR 0x00000040 - -#define DPAA2_FD_RX_ERR_MASK (DPAA2_FD_CTRL_SBE | \ - DPAA2_FD_CTRL_FAERR) -#define DPAA2_FD_TX_ERR_MASK (DPAA2_FD_CTRL_UFD | \ - DPAA2_FD_CTRL_SBE | \ - DPAA2_FD_CTRL_FSE | \ - DPAA2_FD_CTRL_FAERR) +#define DPAA2_FD_RX_ERR_MASK (FD_CTRL_SBE | FD_CTRL_FAERR) +#define DPAA2_FD_TX_ERR_MASK (FD_CTRL_UFD | \ + FD_CTRL_SBE | \ + FD_CTRL_FSE | \ + FD_CTRL_FAERR) /* Annotation bits in FD CTRL */ -#define DPAA2_FD_CTRL_PTA 0x00800000 -#define DPAA2_FD_CTRL_PTV1 0x00400000 #define DPAA2_FD_CTRL_ASAL 0x00020000 /* ASAL = 128B */ /* Frame annotation status */ diff --git a/drivers/staging/fsl-mc/include/dpaa2-fd.h b/drivers/staging/fsl-mc/include/dpaa2-fd.h index b55b89b..2576aba 100644 --- a/drivers/staging/fsl-mc/include/dpaa2-fd.h +++ b/drivers/staging/fsl-mc/include/dpaa2-fd.h @@ -67,6 +67,18 @@ struct dpaa2_fd { #define SG_FINAL_FLAG_MASK 0x1 #define SG_FINAL_FLAG_SHIFT 15 +/* Error bits in FD CTRL */ +#define FD_CTRL_ERR_MASK 0x000000FF +#define FD_CTRL_UFD 0x00000004 +#define FD_CTRL_SBE 0x00000008 +#define FD_CTRL_FLC 0x00000010 +#define FD_CTRL_FSE 0x00000020 +#define FD_CTRL_FAERR 0x00000040 + +/* Annotation bits in FD CTRL */ +#define FD_CTRL_PTA 0x00800000 +#define FD_CTRL_PTV1 0x00400000 + enum dpaa2_fd_format { dpaa2_fd_single = 0, dpaa2_fd_list,