From patchwork Fri Mar 29 06:49:18 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrey Smirnov X-Patchwork-Id: 10876457 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 0BA261575 for ; Fri, 29 Mar 2019 06:50:16 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E8AD028E69 for ; Fri, 29 Mar 2019 06:50:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id DCDDC28F8B; Fri, 29 Mar 2019 06:50:15 +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=-5.2 required=2.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED,DKIM_VALID,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED 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 64DDF28F2F for ; Fri, 29 Mar 2019 06:50:15 +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:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ImdF7MkGdOGYOjgZhd93fIXzNwnV9GVcQiAfmFuOH3U=; b=KA73nsMeJgaSnW XvBSK2lOKc2s6MFOe9GlknaiZZZ36MgBmfwOwX37QNSQmIFoP9XxFoYE7ZRT0raH044qK9EBGxi00 PvIASEHPqqygH2NtUS6clJtXbHkUKmu1Hjjb2t//7rBK7wsa8aa/hxmRi5y3wrah7jk+SoH1ap19a pUQ2FjEMpuB/e0X+UZQOmzf9odihW9bBVpLvG218FRDsEaLCvU7UUIuoWLYIsjuE2WcJ1ZVs126Rb IXpkSrO+jxHoafM4vgu6ihTFnATxtqkXqh4fZYakqZL3lVME1DBPasyOZpx/rOygISLQMBZzjsgaO 0amRSGYlOQbVbdFAGJng==; 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 1h9lL4-0004aO-Kj; Fri, 29 Mar 2019 06:50:06 +0000 Received: from mail-pl1-x643.google.com ([2607:f8b0:4864:20::643]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1h9lKd-0003xU-P6 for linux-arm-kernel@lists.infradead.org; Fri, 29 Mar 2019 06:49:41 +0000 Received: by mail-pl1-x643.google.com with SMTP id y6so544826pll.13 for ; Thu, 28 Mar 2019 23:49:39 -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=Ed5a919dY3TxioV9CWgdr4Ii/JOsTqTVDo8QZTkeUjA=; b=KcKE6eZhvOYJHOCyRNr4s2zhCAYrl5ce/sL08Ih58ZtQb4/P6Bd804ndV+TBEAqas4 K7EVk/lOuOTTvDFV+7dQqFeQiUyInitppPvIJOKXJa2HvVG+R8H7XCvZW/KUA5f3f40W rYxT7qVqz/2ndfDF0NacotSNNQk8JkranhiTfgmr98QICOR8K/FmipXXaUyI6dOpT5uB BMRyohFY94UONxszcSm86DkYC5M15HnmjsSwUvLGve5x40RuH9u6bSavV8Pn0rf9kqZw 4vPadMwfe57PKh74ZJn6PWv6tBODJQm53nlg+0JSMqPQxIL1/CzPHouG4lkmYrMQD2bJ W5Vw== 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=Ed5a919dY3TxioV9CWgdr4Ii/JOsTqTVDo8QZTkeUjA=; b=c26GrkD55Q/RIrRcGcqn3tZuXo8miXLy1VDxoMjfkaAw1ATeI0mla43BJV4kd9P2EP mML/YPPe8rm/S/RJCJsFsU0+pOI4FFVZqFPaPDPgV79e/JPyAjaak9kkP1lR9jjm7hDW Rf6OnCifQSTpda7e1b8HxcxaOU6l2LohVAaZrCOBUeq58qN+FNceMbLi5Qa9qDvsc0lV f3fhP+1cHZMigT3G3ypSUELMo+MaSkc7zE2ibr1cTKTqE10Vim0JW2t9ylKpd+5YKRyF 3oLvemxYYB6adaEjlb8bXFm/Jh1OGblnG0d1HAunhWoNNX9yRoS5LP+u/qdQeaH9K7Tp sTEQ== X-Gm-Message-State: APjAAAWbux5XUZ4fPsaceVqtSYFotW35Y3qglWJCX613A7IP4AwzDUUJ E3EqTB5vRmH/PmYhuCyGb3BRbWjt X-Google-Smtp-Source: APXvYqxOo1/psk3OHk8i2powPOqxmXlOQVNlKw+z26Vm4Mk9/xWXvGHAkg5lpLFi3mthdjz1MPB3FQ== X-Received: by 2002:a17:902:5ac9:: with SMTP id g9mr47531462plm.205.1553842179162; Thu, 28 Mar 2019 23:49:39 -0700 (PDT) Received: from squirtle.lan (c-24-22-235-96.hsd1.wa.comcast.net. [24.22.235.96]) by smtp.gmail.com with ESMTPSA id i5sm1602818pfd.16.2019.03.28.23.49.37 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 28 Mar 2019 23:49:38 -0700 (PDT) From: Andrey Smirnov To: Shawn Guo Subject: [PATCH v3 3/9] ARM: dts: imx7d: Specify IMX7D_CLK_IPG as "ipg" clock to SDMA Date: Thu, 28 Mar 2019 23:49:18 -0700 Message-Id: <20190329064924.8728-3-andrew.smirnov@gmail.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190329064924.8728-1-andrew.smirnov@gmail.com> References: <20190329064924.8728-1-andrew.smirnov@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190328_234939_927728_A378B773 X-CRM114-Status: GOOD ( 12.61 ) 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: , Cc: Andrey Smirnov , Angus Ainslie , linux-kernel@vger.kernel.org, Chris Healy , Fabio Estevam , linux-arm-kernel@lists.infradead.org, Lucas Stach 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 Since 25aaa75df1e6 SDMA driver uses clock rates of "ipg" and "ahb" clock to determine if it needs to configure the IP block as operating at 1:1 or 1:2 clock ratio (ACR bit in SDMAARM_CONFIG). Specifying both clocks as IMX7D_CLK_SDMA results in driver incorrectly thinking that ratio is 1:1 which results in broken SDMA funtionality. Fix the code to specify IMX7D_CLK_IPG as "ipg" clock for SDMA, to avoid detecting incorrect clock ratio. Fixes: 25aaa75df1e6 ("dmaengine: imx-sdma: add clock ratio 1:1 check") Signed-off-by: Andrey Smirnov Cc: Angus Ainslie (Purism) Cc: Chris Healy Cc: Lucas Stach Cc: Fabio Estevam Cc: Shawn Guo Cc: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org --- arch/arm/boot/dts/imx7s.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/boot/dts/imx7s.dtsi b/arch/arm/boot/dts/imx7s.dtsi index e67c8dd4bdab..31c610e6c788 100644 --- a/arch/arm/boot/dts/imx7s.dtsi +++ b/arch/arm/boot/dts/imx7s.dtsi @@ -1071,8 +1071,8 @@ compatible = "fsl,imx7d-sdma", "fsl,imx35-sdma"; reg = <0x30bd0000 0x10000>; interrupts = ; - clocks = <&clks IMX7D_SDMA_CORE_CLK>, - <&clks IMX7D_AHB_CHANNEL_ROOT_CLK>; + clocks = <&clks IMX7D_IPG_ROOT_CLK>, + <&clks IMX7D_SDMA_CORE_CLK>; clock-names = "ipg", "ahb"; #dma-cells = <3>; fsl,sdma-ram-script-name = "imx/sdma/sdma-imx7d.bin";