Received: by 10.223.185.116 with SMTP id b49csp5957207wrg; Wed, 7 Mar 2018 22:37:49 -0800 (PST) X-Google-Smtp-Source: AG47ELs3IB9EVvlICiFQlM2DIelPCVJBb2V+UcHW7b96bLnb6ZC8WmpEorlovG/dtePqlQrqyMSZ X-Received: by 10.99.106.71 with SMTP id f68mr20377079pgc.262.1520491069541; Wed, 07 Mar 2018 22:37:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1520491069; cv=none; d=google.com; s=arc-20160816; b=bDE7U8yndeAXhEZnI3PRJohit8yZcpa2XxX/h7yvv/ACvSurUQ9stXS+PNhFG2Kujs OqYEgK7aG1y64AgyyGBa5EMKvBSoHzBelFYQF/CxwVh/teRZ/YweJvBfYrfX7/OXbiTt Tpzq5YPg7t/8dutvQxLQ3uoqDOi2FxscNlFH+icxBsMBrRplK9cbmO6H+RxEG3QGuCwa AccNyYTiOkquCIPiLbs+1u1S9eaRZyH/cDOeUMEb+CUKSZKv6mU3x2K5CXuU+VYJ05gF DpMcJOQ3QbMlOLq4D1ps6D3ps7L91p8iTlAH1sW0+GqZNhKQEbEKjELJzljNzs8YyCPv GtYw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :spamdiagnosticmetadata:spamdiagnosticoutput:content-language :accept-language:in-reply-to:references:message-id:date:thread-index :thread-topic:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=Y6ELh0P86ejt6XiF64v8XVe4WfWANQd6wm30mPNcRtk=; b=XvonCjrTGyg3daDIG8mp269N9wsLYYyFufI1y1d2bKnPigQ/N0wQ0OvpasjfB1wTk6 Jp6syga6R5+ACX2laHXNEX6I23quVuwU/f0vVCCb95dh1JFNl/dEKOtj7SXOnHRvbGoV 3Cch/0wU6mnPMmgvTQUr9izdqTuf/6fmWlyhZtADDYWKHRxDzl6ISacq3PXDUGq0rhbd a+s6zScc2Do3S9DvQFS4emqTk+1K12w8kMnFUEOxUFJ8O20xJfCZWSUaRP4tgW3yQLAl x9vR+Z4JCwqecEoqXsA9/BEsdSIP2rExR3IOtQzVzBLeBxTkOtNQkrK/rpYG5rOc4gU+ T1OQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@microsoft.com header.s=selector1 header.b=V3WK32Ei; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=microsoft.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h71si11888161pgc.717.2018.03.07.22.37.35; Wed, 07 Mar 2018 22:37:49 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@microsoft.com header.s=selector1 header.b=V3WK32Ei; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=microsoft.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755503AbeCHGgN (ORCPT + 99 others); Thu, 8 Mar 2018 01:36:13 -0500 Received: from mail-bl2nam02on0092.outbound.protection.outlook.com ([104.47.38.92]:59552 "EHLO NAM02-BL2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S965477AbeCHE7x (ORCPT ); Wed, 7 Mar 2018 23:59:53 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=Y6ELh0P86ejt6XiF64v8XVe4WfWANQd6wm30mPNcRtk=; b=V3WK32EirZk/ca1ZHmxGZInreJvx9D7fOlJdWKO0yvKBIw5i4pEr1JCw0ThqSd05/SgzH4YDnrvX7TY7Q40I9kcScAB2ZmL8FjI5IrVlTcu5CKZn98j3v8iZOd8i4LelLjVzS8O2hqHJNgLX1Aw8Ce+Ss3bwF6NEMAp6sYLCjx8= Received: from DM5PR2101MB1032.namprd21.prod.outlook.com (52.132.128.13) by DM5PR2101MB0920.namprd21.prod.outlook.com (52.132.132.165) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.588.3; Thu, 8 Mar 2018 04:59:50 +0000 Received: from DM5PR2101MB1032.namprd21.prod.outlook.com ([fe80::8063:c68a:b210:7446]) by DM5PR2101MB1032.namprd21.prod.outlook.com ([fe80::8063:c68a:b210:7446%2]) with mapi id 15.20.0588.008; Thu, 8 Mar 2018 04:59:50 +0000 From: Sasha Levin To: "linux-kernel@vger.kernel.org" , "stable@vger.kernel.org" CC: Vignesh R , Peter Ujfalusi , Vinod Koul , Sasha Levin Subject: [PATCH AUTOSEL for 4.14 67/67] dmaengine: ti-dma-crossbar: Fix event mapping for TPCC_EVT_MUX_60_63 Thread-Topic: [PATCH AUTOSEL for 4.14 67/67] dmaengine: ti-dma-crossbar: Fix event mapping for TPCC_EVT_MUX_60_63 Thread-Index: AQHTtpoJed321Z9/oUOhO4NQx0kydQ== Date: Thu, 8 Mar 2018 04:58:02 +0000 Message-ID: <20180308045641.7814-67-alexander.levin@microsoft.com> References: <20180308045641.7814-1-alexander.levin@microsoft.com> In-Reply-To: <20180308045641.7814-1-alexander.levin@microsoft.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [52.168.54.252] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;DM5PR2101MB0920;7:0RZ6yb4sSO9bbWQmsQLXV6bvTGY2p92yPdShjtcluq8qvcOcKXpg3JjMgKqTdKlDjOlq5ZVxD/dhJj2vENuhu15ekoHKFGAy3lyPkXdHJ4rWFTY15hVtbSiXGpWodhXUR7blbRLO0kUHcwxNYnkfQrG3ey6r/LCEYuhyUHFvG8afVB1v1Scps4MfcF9vedUfTWDJu4ZnrqEM+kEy9gLm3Olhg7dClLieILyDqQOJWkHBJSb9abKF4HwVsPZGpXOy;20:ACDf7exwpZvI244ISMWl2unJRCmnDxioK4mqkTIFsNvex+pssgNHpNNBoaIxb5kfxmBqGQuAmtybokAeBkRiv3N7FKseKTl/MQ3uHtIdvwZpEc5WU5I1ehls0PwKka1fwsvv5pQa2aRM6sk7u60CvmEBR2eVE/2w/qSghCsnCqk= x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: 9fe57656-0b65-4b89-0545-08d584b16c7c x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(7020095)(4652020)(48565401081)(5600026)(4604075)(3008032)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7193020);SRVR:DM5PR2101MB0920; x-ms-traffictypediagnostic: DM5PR2101MB0920: authentication-results: spf=none (sender IP is ) smtp.mailfrom=Alexander.Levin@microsoft.com; x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(28532068793085)(31051911155226)(89211679590171)(228905959029699); x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(8211001083)(61425038)(6040501)(2401047)(5005006)(8121501046)(3002001)(10201501046)(93006095)(93001095)(3231220)(944501244)(52105095)(6055026)(61426038)(61427038)(6041288)(20161123562045)(20161123564045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(6072148)(201708071742011);SRVR:DM5PR2101MB0920;BCL:0;PCL:0;RULEID:;SRVR:DM5PR2101MB0920; x-forefront-prvs: 060503E79B x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(39860400002)(396003)(39380400002)(346002)(366004)(376002)(189003)(199004)(81156014)(81166006)(5250100002)(8936002)(54906003)(2501003)(305945005)(8676002)(107886003)(110136005)(15760500003)(97736004)(99286004)(6436002)(36756003)(316002)(72206003)(76176011)(14454004)(6486002)(7736002)(478600001)(10290500003)(186003)(22452003)(59450400001)(68736007)(105586002)(2950100002)(106356001)(102836004)(26005)(6506007)(86362001)(3660700001)(5660300001)(2906002)(10090500001)(1076002)(25786009)(2900100001)(53936002)(4326008)(66066001)(6512007)(6666003)(6116002)(3280700002)(3846002)(86612001)(22906009)(217873001);DIR:OUT;SFP:1102;SCL:1;SRVR:DM5PR2101MB0920;H:DM5PR2101MB1032.namprd21.prod.outlook.com;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; received-spf: None (protection.outlook.com: microsoft.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: PLTXKNAUlwDlJeV82wn3vc825hC6TqIsHBWBHN76ZBbMc9qy1HtETgFoY8j8ItnWrT0GLEYR+USDuOFIwc2tRyf4o9rUQ6ybNuAQE0TWgNaQj480HDX8oKAKCLR4YhOK+r+rlSAQff5+mcJ+J6ObFl+GZGFTsazAI9xGumU6QKQ/GiQ0e/6P88tKIngje4iFduihgakMrah0T1Afc33wfN/TIjdXZdZWtUaIzF7tv3JxgQtGd3D0rSmpbtWnLUzRZT3EzAl3N4kAMeKoavI9Mw7oRGn1OQbDI9LqH+A96IifaM6VF5myO2wuDW2mSW/jae+FAV2VfpBl2tQJmlIo1A== spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: microsoft.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9fe57656-0b65-4b89-0545-08d584b16c7c X-MS-Exchange-CrossTenant-originalarrivaltime: 08 Mar 2018 04:58:02.6125 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 72f988bf-86f1-41af-91ab-2d7cd011db47 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR2101MB0920 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Vignesh R [ Upstream commit d087f15786021a9605b20f4c678312510be4cac1 ] Register layout of a typical TPCC_EVT_MUX_M_N register is such that the lowest numbered event is at the lowest byte address and highest numbered event at highest byte address. But TPCC_EVT_MUX_60_63 register layout is different, in that the lowest numbered event is at the highest address and highest numbered event is at the lowest address. Therefore, modify ti_am335x_xbar_write() to handle TPCC_EVT_MUX_60_63 register accordingly. Signed-off-by: Vignesh R Signed-off-by: Peter Ujfalusi Signed-off-by: Vinod Koul Signed-off-by: Sasha Levin --- drivers/dma/ti-dma-crossbar.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/drivers/dma/ti-dma-crossbar.c b/drivers/dma/ti-dma-crossbar.c index 7df910e7c348..9272b173c746 100644 --- a/drivers/dma/ti-dma-crossbar.c +++ b/drivers/dma/ti-dma-crossbar.c @@ -54,7 +54,15 @@ struct ti_am335x_xbar_map { =20 static inline void ti_am335x_xbar_write(void __iomem *iomem, int event, u8= val) { - writeb_relaxed(val, iomem + event); + /* + * TPCC_EVT_MUX_60_63 register layout is different than the + * rest, in the sense, that event 63 is mapped to lowest byte + * and event 60 is mapped to highest, handle it separately. + */ + if (event >=3D 60 && event <=3D 63) + writeb_relaxed(val, iomem + (63 - event % 4)); + else + writeb_relaxed(val, iomem + event); } =20 static void ti_am335x_xbar_free(struct device *dev, void *route_data) --=20 2.14.1