From patchwork Tue May 23 17:20:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Rosin X-Patchwork-Id: 13252711 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 825D8C7EE26 for ; Tue, 23 May 2023 17:21:11 +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:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Subject:From:To:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=nv9CQN9xi3w30oMNAfmivljXbs4VMD8Rtr5ZTkult60=; b=k3ja00YKrHUn7z fof3UBntTaNgS5lP8ad5IGFZsHOExwGIhLWqh2qwiJxIkTHw9m5DjL3CYGGEiI/BATEfKwpgtiEtc j32a3PLmwp7ctzyhWBFSLD9rB5rNa5a5tgV4VWRinmVy/vppiGnFtFJHcPOz4lxZBlRLuojGCSo75 MeN56fL0Hd1eRkp2unabUzy35kZlW12qtk0V9kRbbI+dTIXQU7FF1EPKVIKroH1/v2+FuK8oMSLzH MOZ6qiO8HTC9vvGwqK5L1LRqN4n75jm9zkx57jIOM7laGY/UR/0+xAfQ4yN0l16i3mSoip5SAy3pt ccNRwi1/C0jBDe0NeV9Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1q1Vgn-00AwFL-1T; Tue, 23 May 2023 17:20:49 +0000 Received: from mail-am6eur05on20717.outbound.protection.outlook.com ([2a01:111:f400:7e1b::717] helo=EUR05-AM6-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1q1Vgk-00AwDu-0S for linux-arm-kernel@lists.infradead.org; Tue, 23 May 2023 17:20:47 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=n47gtomelcj011q0pxUkpwpCr8adDTDMB4Tfx4ql5IFCGjM6HbWF5M596oig5Iue9mLFajraCLhbvsw5PUHs++/VssXyRvGbrQms2J1LxkuY4osdQ8OnlfUV6n2fjrW+5bI4YFnObH3/ulkCME3oPKUrNSUJJejIPHbByH8oBj4u6LFH0AQHSk6CI7+CItyPrqKoCqXxUbhcyJccQ7lYEM/8qdmPRCm8s/JB7Sm7sRxgfTSAs8XSCJVN5sMdmiAIMrnE/hbGtaTYx5o8+MAjoctNL8uggFHLumVZkQWbnRnr0gtq0wFI1dyfSQxOH52hxstGyegzn8JlBsj10Xo80w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=kB58yjEPuX4C0k3fpbaGhxAt2iJZZExBLlkMV7jNHH0=; b=X1VCwAtVMi8g5b+94rK+FoRQ+OnnlL0Ac9SlGxsEP1vS67UFDH8GaEtqoW+InnOfSQVY91jj6lpt9IuAtpnMPN+cVLgclmz29dVKcUt1tqyU9Qxckiakv1/lfOv3EwpIlb7lyjet8B8J8f5e+gstRvaH6Ef4PGSZtNHKA0iQi8jLhdtbS+bgbrNGPyrzL23nNKJr0PmhZTj4wd0eywFDAZP115Wp29qIuKlgIavezjDm2mJ33dXRN3hcYnH+c85sckHBULAqBTGp021pcqX0MXKrpM63Kw82kHI4QTY0tANBTLkWDB3mg33DmcfHYUwRlWZ1Gkk6GQQtlauURSF3zA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=axentia.se; dmarc=pass action=none header.from=axentia.se; dkim=pass header.d=axentia.se; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=axentia.se; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=kB58yjEPuX4C0k3fpbaGhxAt2iJZZExBLlkMV7jNHH0=; b=B5Mpcj2Lbot2Hs98haHHVWnSb1d6JGEDggTvpx8kAS7k9twt1lYewqBxsuHI8iIu3KSV0/C3D8UkVKcQ6w4U+0QW/R1sYl12ggfvlokG7W5qsJV4pN1g+ug6DqEPxPMaxzEjw8+jTRwUyUanZDupgiJvIHWEHt7CCIjnb3j5EZo= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=axentia.se; Received: from AM0PR02MB4436.eurprd02.prod.outlook.com (2603:10a6:208:ed::15) by PAVPR02MB9205.eurprd02.prod.outlook.com (2603:10a6:102:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6411.28; Tue, 23 May 2023 17:20:40 +0000 Received: from AM0PR02MB4436.eurprd02.prod.outlook.com ([fe80::681f:7dcc:3f6c:3b36]) by AM0PR02MB4436.eurprd02.prod.outlook.com ([fe80::681f:7dcc:3f6c:3b36%5]) with mapi id 15.20.6411.028; Tue, 23 May 2023 17:20:40 +0000 Message-ID: <01e5dae1-d4b0-cf31-516b-423b11b077f1@axentia.se> Date: Tue, 23 May 2023 19:20:37 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.6.0 Content-Language: sv-SE To: LKML From: Peter Rosin Subject: [PATCH v2 1/2] dmaengine: at_hdmac: Repair bitfield macros for peripheral ID handling In-Reply-To: <221d19e2-6b92-7f38-7d8a-a730f54c33ea@axentia.se> References: <221d19e2-6b92-7f38-7d8a-a730f54c33ea@axentia.se> X-ClientProxiedBy: MM0P280CA0071.SWEP280.PROD.OUTLOOK.COM (2603:10a6:190:8::25) To AM0PR02MB4436.eurprd02.prod.outlook.com (2603:10a6:208:ed::15) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AM0PR02MB4436:EE_|PAVPR02MB9205:EE_ X-MS-Office365-Filtering-Correlation-Id: 97d11365-e5eb-47ac-71c6-08db5bb2081e X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: WXY3oiOC6APCUKfbN2Nm7ihJ4e+GGM9RT+N8mqIzs0tT4akpD5PlcO+WNDhncsRckydpbuobixOMDuC3rlD77Oqv6CEcZStPrhG1ZaI2cfsh+aEJ7tbvrPfSHaXwjkhor/f+ceUYpwaWUOIjpg1d9pj9Yu++uHXc5mesyBiWRI5R/sTaXzQ5vLetEA+NTc/yEBNjqzaGXmQ4AbJwOwSMDtDluJgIr0xS4IAlYheuOf1LLnRRKxLOxp1EDfBQhxd3WobTw/OSz0P+5mTcx6AI/6VGVuB1Gxxw6XjK1mPvwfpRXXj6cJ4j1oCQiRwBPQe+dkN9cCckWApOQpFx2S4cuY1pjutCjtCaxYvqKzyEO5Sl9AvrBNwxzafMLCe0co3piAlqbFdhR9dwL/fPf3XU6/5PUpXUTsO0crZPf6GinJlKiiZJaL1bMNeO4PbXdW6x0e0BQJATW3Tk+v+OfHv8hB5QHe1hRz7DAPVKXR7AvP8X8vk3TBEjQEfZJag9ZMXM37wcTsIpPw5F0jpXibme2iw6jgnnAu5PznevV+U6LEax6FnSrfagGqCGNojaeRYgrUQiJdqoVoBdHyrqX4gvTKLW8tnEvMq1Rxqw1MKmeDkw3L5gNldmWl9HTkKvs7VznKLId2Dl+WHCn8oENHH+nw== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AM0PR02MB4436.eurprd02.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(346002)(39840400004)(376002)(396003)(136003)(366004)(451199021)(8936002)(8676002)(5660300002)(186003)(83380400001)(26005)(6506007)(6512007)(86362001)(31696002)(2616005)(38100700002)(41300700001)(6666004)(6486002)(66476007)(66556008)(66946007)(6916009)(4326008)(36756003)(478600001)(316002)(54906003)(2906002)(31686004)(43740500002)(45980500001);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?R9BsyqpWJeTFbi67ojtrbn8Ez87U?= =?utf-8?q?4/tzBJxxh1geWC0c5MBKAXFu0pUn2YnjktVkLo+7N4OBIUhAfRwpqpgNWJ6s6jBtT?= =?utf-8?q?XgzpDHgmlNH9jGuqrkY+OzpypOKXKdDtsdT+bedgRZ+28JQ8MDH+JcqNfMookGZVa?= =?utf-8?q?A/EVXtCUGh3/xwPc/VCe4STaZYC4AWMVOuWvOF20Gl7WX+o/cE4ZXHngXlarhecSE?= =?utf-8?q?2T4+XLoBBWpKNBtCHGLGCm5NRyiiefWxKeHBjtIDwhww9TdQukzX9LUT+XZVJN4c9?= =?utf-8?q?Pii4RhIOfCzDDcvdKlKxehmRAH5McgLj7+2W1gXuhtZGUVxT+0q2ZxKR1ejs9bYpd?= =?utf-8?q?pJ391f5QQ/htRRJojur1V6omCgj85AqUriKhTMDFiqYHWzYivaSxeR9lIc4vHQ+2U?= =?utf-8?q?uoY2r8F980OLbitL4mZdmLMv/xB6OVoRjSPqqaUo7RQgJBSID2/LTqBjS39iB6Rwq?= =?utf-8?q?1AbF75C4ujDDdG2E07fHt1saRq9rS6vjvW+omy8AWOv52bY3DZ9XniB+nbsby6qSE?= =?utf-8?q?jUWGPaQWHO7/iQnJoSShMvtjv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xXIlRyAdHSzVtIr3McYQ3hsZFUYYZiq/pE9M2rrn0?= =?utf-8?q?LNHJkPn2KHF7clW6kJtNLJg9mVy8X0VzORqsTdXnTnYfnQeMRXeB8u0muGyVMdGt+?= =?utf-8?q?hrJucEuezgyX?= X-OriginatorOrg: axentia.se X-MS-Exchange-CrossTenant-Network-Message-Id: 97d11365-e5eb-47ac-71c6-08db5bb2081e X-MS-Exchange-CrossTenant-AuthSource: AM0PR02MB4436.eurprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 May 2023 17:20:40.2906 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4ee68585-03e1-4785-942a-df9c1871a234 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: wgJlz3NgaJNayRtroz7AtbT8cWywv99pdskEbcucHomWvV0p+seXPv99CaWSj4Zk X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAVPR02MB9205 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230523_102046_183579_6B7A4884 X-CRM114-Status: UNSURE ( 9.98 ) X-CRM114-Notice: Please train this message. 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: , Cc: Tudor Ambarus , Ludovic Desroches , "stable@vger.kernel.org" , Vinod Koul , dmaengine@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The MSB part of the peripheral IDs need to go into the ATC_SRC_PER_MSB and ATC_DST_PER_MSB fields. Not the LSB part. This fixes a severe regression for TSE-850 devices (compatible axentia,tse850v3) where output to the audio I2S codec (the main purpose of the device) simply do not work. Fixes: d8840a7edcf0 ("dmaengine: at_hdmac: Use bitfield access macros") Cc: stable@vger.kernel.org Signed-off-by: Peter Rosin Reviewed-by: Tudor Ambarus --- drivers/dma/at_hdmac.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/drivers/dma/at_hdmac.c b/drivers/dma/at_hdmac.c index 8858470246e1..6362013b90df 100644 --- a/drivers/dma/at_hdmac.c +++ b/drivers/dma/at_hdmac.c @@ -153,8 +153,6 @@ #define ATC_AUTO BIT(31) /* Auto multiple buffer tx enable */ /* Bitfields in CFG */ -#define ATC_PER_MSB(h) ((0x30U & (h)) >> 4) /* Extract most significant bits of a handshaking identifier */ - #define ATC_SRC_PER GENMASK(3, 0) /* Channel src rq associated with periph handshaking ifc h */ #define ATC_DST_PER GENMASK(7, 4) /* Channel dst rq associated with periph handshaking ifc h */ #define ATC_SRC_REP BIT(8) /* Source Replay Mod */ @@ -181,10 +179,15 @@ #define ATC_DPIP_HOLE GENMASK(15, 0) #define ATC_DPIP_BOUNDARY GENMASK(25, 16) -#define ATC_SRC_PER_ID(id) (FIELD_PREP(ATC_SRC_PER_MSB, (id)) | \ - FIELD_PREP(ATC_SRC_PER, (id))) -#define ATC_DST_PER_ID(id) (FIELD_PREP(ATC_DST_PER_MSB, (id)) | \ - FIELD_PREP(ATC_DST_PER, (id))) +#define ATC_PER_MSB GENMASK(5, 4) /* Extract MSBs of a handshaking identifier */ +#define ATC_SRC_PER_ID(id) \ + ({ typeof(id) _id = (id); \ + FIELD_PREP(ATC_SRC_PER_MSB, FIELD_GET(ATC_PER_MSB, _id)) | \ + FIELD_PREP(ATC_SRC_PER, _id); }) +#define ATC_DST_PER_ID(id) \ + ({ typeof(id) _id = (id); \ + FIELD_PREP(ATC_DST_PER_MSB, FIELD_GET(ATC_PER_MSB, _id)) | \ + FIELD_PREP(ATC_DST_PER, _id); }) From patchwork Tue May 23 17:20:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Rosin X-Patchwork-Id: 13252712 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 8E4B9C77B75 for ; Tue, 23 May 2023 17:21:18 +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:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Subject:From:To:References :In-Reply-To:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=TxNHl0cemPfWg3CES4Vtv7AQZPwZ5wfprPZ3nFtx0x0=; b=LCNw0s3d0WcclV aK/FrF5tmSWQWZldKOuCJ7G+RmIZb79F8yJ/OKkKYmzbafd/xnbg3WRTIWjuTsgwfRz0fy293Sjt7 l67dr9TQ+nnE8OPMfseCOmysAiGr+ry1LASG5REPqlWBoCWKaA2ub/zPVb+HvGEE3pUPmsar5ytEX vKoc6j5gFFrygmSO6xrz+7aEuPfiLBJ4cICJVMcvat5KAV9Gjfg1hRR9KQFmYKa3onaDUwuCphtob P7pDMRS/VSYpzJzKWcV8i8YXsYq144/T2RLoNI+BzuGnyEDbJnzoazeGv8ZQ5HmHlZn+JRxje2B1F AGulAX0xQ5hJBlPoNLgg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1q1Vgv-00AwI5-11; Tue, 23 May 2023 17:20:57 +0000 Received: from mail-db3eur04on0710.outbound.protection.outlook.com ([2a01:111:f400:fe0c::710] helo=EUR04-DB3-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1q1Vgs-00AwFm-14 for linux-arm-kernel@lists.infradead.org; Tue, 23 May 2023 17:20:55 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=lGibNfBMlyJxFXfQeUGuJQn4xZBv8tP64vHw8/ZgyskFQ2euJPf7831hTMe988aCyTERB8lHisg/3AhKrE8f7no91TZmC/t1sUblihGPRUiLnV4o0cd8r/Mj0H9gY5airzmK9rYqBjpNd1QELUJYztPtTCqfyM6LzH00DK7m/31tQgqA78KwA1HVluS2eIAl8cqQ1D5/eDcGGRXtrHYPKrg+2wVro8p2zt1AFtOyuR0PGi3gu+sHvzJ1ZOKlpagvSWfX5dYWBVR90+G+vrPY1D7sah/f0UDm3y+E/czuY28cfIcQOGKPpZvwJb2kb0SVG9PQ7dH+Mcxro1CWe5vtzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=YCmZY9WSyKFATcL1f3tMKVhPsdg8Fa1x3+yva+emnp0=; b=QJopUsXoE0osc9iGD/8Cn6gLUxtGmUy2CS+isXsvUPLbriBHFuLVW98hOG5C2O765azLlN8jc+oSaZx4Wc3mNPKwfEe6aFc7A4+zplaV7U79V6ZdzegOnRR69t9QLj1ZOiAx+b+d4SixSh1FlvEU0W3IawLa/O5U4Y7LfflIjGXz9IeYBzjpa7DL7wN/EnOYVHtC9RFgRz3snVizq38NGOSamLkcNFmSc684GiV7MMVhiwFT4+3/3ttTg0MKfukSPKr6CKwOqS9bDJP7f7+KI7Bg/cfInl8gpHHjsy2uum8Hok0JBbnTjJcQOkPxZTMB/S3H7NapVWDZAU24/TdRbA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=axentia.se; dmarc=pass action=none header.from=axentia.se; dkim=pass header.d=axentia.se; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=axentia.se; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=YCmZY9WSyKFATcL1f3tMKVhPsdg8Fa1x3+yva+emnp0=; b=DAU/DBB+Lg0rL5buaJx5Q745g+HwQhZcMEpNC3H8oms+oZsfTJACY+aaHeqUCY39+v+fUiQmx94jZJgKuYRa+kuvXS+TKqJfyPIpVqhfQdVqmf0Ib/FHbcnUa5fmukHfnAafdEHd7caHdtuIJlitjEe6QSIezPOAa1NBP00q/I4= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=axentia.se; Received: from AM0PR02MB4436.eurprd02.prod.outlook.com (2603:10a6:208:ed::15) by PAVPR02MB9205.eurprd02.prod.outlook.com (2603:10a6:102:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6411.28; Tue, 23 May 2023 17:20:49 +0000 Received: from AM0PR02MB4436.eurprd02.prod.outlook.com ([fe80::681f:7dcc:3f6c:3b36]) by AM0PR02MB4436.eurprd02.prod.outlook.com ([fe80::681f:7dcc:3f6c:3b36%5]) with mapi id 15.20.6411.028; Tue, 23 May 2023 17:20:49 +0000 Message-ID: Date: Tue, 23 May 2023 19:20:47 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.6.0 Content-Language: sv-SE In-Reply-To: <221d19e2-6b92-7f38-7d8a-a730f54c33ea@axentia.se> References: <221d19e2-6b92-7f38-7d8a-a730f54c33ea@axentia.se> To: LKML From: Peter Rosin Subject: [PATCH v2 2/2] dmaengine: at_hdmac: Extend the Flow Controller bitfield to three bits X-ClientProxiedBy: MM0P280CA0061.SWEP280.PROD.OUTLOOK.COM (2603:10a6:190:8::21) To AM0PR02MB4436.eurprd02.prod.outlook.com (2603:10a6:208:ed::15) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AM0PR02MB4436:EE_|PAVPR02MB9205:EE_ X-MS-Office365-Filtering-Correlation-Id: a58cfb92-e745-420f-6730-08db5bb20dbe X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 6sb4k87muWCu7kOnzl1R4hzNkv1lAZJVj2kFyoIC1zaNzXJBMGm21js+7t2FMeoXG9K6xSj7bks6c5jD+Wy+yjERZkyrzTk4TYfR+d+FoL6P5zffwwH6b5EohBUm3ty2x5V1oT1e2eJmlMfIb7dljZ+Dw2mQnL/Nr/wMNSs00Ah1NTTJ7kT8F1d0tsAsVTuUfq3VYn7P2n9ATais5jpXljwtA76glyR+It2vuFpJSK4khtgHAJ75uoBr1BVfuhavx7j3f82t25p+bQQKkSYgdWW+h0IyDsZpZ01fii/nt+xlSKtTQDI33C1R0YKZV8+5BPQXAIoLM3cNohfZbpA8rguUf6AHs2IUvgWwA8sKojtU0PCGf5F0VzISob7siFcZzEpeUJY7Hp86vctW0SLMBuYNvE2hLNxCiX60snhdvkKS0EWSodDnigy2T9bwVEkx4CyjyUDelknHdTFDCFRNdOxFWGShMo2KIJQb66da32aFpgSR5vh7MDi1kHXDnIlqP2eI55+Ue5W2/AaeTXD4xckjlazNMKTyRlRO8RmiG8SVgVLw3aFNDk8hZeO8FctlEubORsIcm6L1lhBIwjF+2ZnoGJH+na8Yv0vobbOanvkNJpCQho96OrCXdS4bWA6yrKmby/wVFRq9+51vdYmD8g== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AM0PR02MB4436.eurprd02.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(346002)(39840400004)(376002)(396003)(136003)(366004)(451199021)(8936002)(8676002)(5660300002)(186003)(83380400001)(26005)(6506007)(6512007)(86362001)(31696002)(2616005)(38100700002)(41300700001)(6486002)(66476007)(66556008)(66946007)(6916009)(4326008)(36756003)(478600001)(316002)(54906003)(2906002)(31686004)(43740500002)(45980500001);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?LFhlrCjW99NPsDdfYunOPiOLTGhv?= =?utf-8?q?L5FLarEhoJnnpXE0KW9zS9/XQGJvO+q8vhKStsD6Gq7ZE5Li2m191u2+kxNamxuYx?= =?utf-8?q?eFxsHRIwCRBKG+e8m60FUAGc0OZkao2LMaWdsVL0NpP+b1fFizKNUrOIQ+WhcxJmm?= =?utf-8?q?aXlyfMSRvrXzA1PJx3L9L3sPXXecHgdE6pR4hNn49wnipdwPwD57ABwkiEQc/Vk/P?= =?utf-8?q?+MZATZ4ph7PkTfek/bWumIk7gq2QDtKckfxxVQZ/zNja5ELmY/oxONnd58zoNfGac?= =?utf-8?q?FQeOhyEAeVomhC8LmFIIKri4alWKeBZi7MhOiHx/q9QjmpZ9gzJLHB4RA9GtFOqvT?= =?utf-8?q?VxKoXsE7pD29IpEwpgpEQ/GD/L4h/gHBo7lJyjUIM1gC9x3Kht8x6DN5mWIFSAfN4?= =?utf-8?q?hgUgeGKSAUXNHARMiMR4qgtlqsFdJdF1CEFx8Bi/bMEwPUJDY87vtt/CB/nPBz49a?= =?utf-8?q?IwKCHTHxXZROc/DPsh7KMpw9X4thhjPeavjM3rRTOTlB4QCzvVJqrSnszYxzbZ4xd?= =?utf-8?q?+sqi+fDJyHBPBhdJ5DY55HJHYuPtmQXWLzJibsKcdLvlp+aDLzwAfh7wyu2bWueiR?= =?utf-8?q?UT2mn+6jbWrpBdrhjeVNA7vmQHd0x1n5buIVIhgwl+CeIgOvtg46bBfe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=?utf-8?q?99hF/kbPYycp?= X-OriginatorOrg: axentia.se X-MS-Exchange-CrossTenant-Network-Message-Id: a58cfb92-e745-420f-6730-08db5bb20dbe X-MS-Exchange-CrossTenant-AuthSource: AM0PR02MB4436.eurprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 May 2023 17:20:49.7370 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4ee68585-03e1-4785-942a-df9c1871a234 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: J1BA0tFG7My1/71ZEjkzMT4wHFUr9BlRbPt2PZwN68X3CDdISx4h9TVCq6vQMRU+ X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAVPR02MB9205 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230523_102054_370353_39211307 X-CRM114-Status: GOOD ( 10.96 ) 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: , Cc: Tudor Ambarus , Ludovic Desroches , "stable@vger.kernel.org" , Vinod Koul , dmaengine@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Some chips have two bits (e.g SAMA5D3), and some have three (e.g. SAM9G45). A field width of three is compatible as long as valid values are used for the different chips. There is no current use of any value needing three bits, so the fixed bug is relatively benign. Fixes: d8840a7edcf0 ("dmaengine: at_hdmac: Use bitfield access macros") Cc: stable@vger.kernel.org Reviewed-by: Tudor Ambarus Signed-off-by: Peter Rosin --- drivers/dma/at_hdmac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/dma/at_hdmac.c b/drivers/dma/at_hdmac.c index 6362013b90df..ee3a219e3a89 100644 --- a/drivers/dma/at_hdmac.c +++ b/drivers/dma/at_hdmac.c @@ -132,7 +132,7 @@ #define ATC_DST_PIP BIT(12) /* Destination Picture-in-Picture enabled */ #define ATC_SRC_DSCR_DIS BIT(16) /* Src Descriptor fetch disable */ #define ATC_DST_DSCR_DIS BIT(20) /* Dst Descriptor fetch disable */ -#define ATC_FC GENMASK(22, 21) /* Choose Flow Controller */ +#define ATC_FC GENMASK(23, 21) /* Choose Flow Controller */ #define ATC_FC_MEM2MEM 0x0 /* Mem-to-Mem (DMA) */ #define ATC_FC_MEM2PER 0x1 /* Mem-to-Periph (DMA) */ #define ATC_FC_PER2MEM 0x2 /* Periph-to-Mem (DMA) */