From patchwork Wed Nov 17 13:32:02 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adam Ford X-Patchwork-Id: 12692895 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 mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id DC410C433F5 for ; Wed, 17 Nov 2021 13:33:32 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 9C74161B1B for ; Wed, 17 Nov 2021 13:33:32 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 9C74161B1B Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org 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:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=/AbVFcTxRSh8MnAAsGuc9/E4v1iUnIU19j7RFxOayB8=; b=M3K+MPwYSJE7cv 6UKp76PGZQXOdYffVNHnwhf1hzNApbBKlmD0aHd893XecykobA/wfl1EBBWY5AqWTJEC0KWatDrbt 3TEJZwSf+EODRir2d3oKTL0K2o6ciJorPVysRNC89bPvBx+fOGLCdZweP9+X4MSLv82FyOsByNrKe 1t65PqoqxrjGrRiSC4CSWJejRTRi9JaNjRi3RHaLQimAWH8IVuiidJzJbB0/hR/FAUQYDd6D1AeQs 2wzYf1CZJSb+noBKVOuJrmbU/HOsAlC5xOT1z98Vzqk/FbofyTOrk7lEBFfijLqmWo6XSoQVNdmrB 2Afh2gVidxPz52gT0cRQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mnL2s-004rde-LG; Wed, 17 Nov 2021 13:32:14 +0000 Received: from mail-qt1-x82a.google.com ([2607:f8b0:4864:20::82a]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mnL2p-004rcv-K8 for linux-arm-kernel@lists.infradead.org; Wed, 17 Nov 2021 13:32:12 +0000 Received: by mail-qt1-x82a.google.com with SMTP id l8so2579119qtk.6 for ; Wed, 17 Nov 2021 05:32:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=a+vy1Tb9YFr84RmlB3AJ4vwvLVwlNlrB/1q9IGAyrEA=; b=bNKY+gtDtzIiwz4L+cuAGf8u8aVmbbjT7Sb7NbSQLx2yzKqQ5Qsg3Yn58cC6w4S9Lt pnJfoODf5gDYmY+BPpmKBqjMVtBM+XTkoB8quIBe7Y1HKiFRADjAcL9FrULXYqkgkuJU pMJ9AhiJO7TJZrbSbbIQigCZhIB1gvhKvDMn2F3dVwVlcHVAQURQQ0dbInJTNV2vHe+/ wyRYJOHHqUKYzFZZMEXb+DdWYIqf3ao+aBIF21LNQw+eym4SAetlt9IgT3kpqZd2nVrN ZCYLJ00jRXSaAcsrw5Tx+sBeGzYhGSpd+NBPKIRgca8O2hr7ju+0zBz1PXQdZcNVVEYC waPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=a+vy1Tb9YFr84RmlB3AJ4vwvLVwlNlrB/1q9IGAyrEA=; b=KavHtxBZXTajWo8PQPGWpIl0PWxwBZY2XmGEpUFRraxkgIddtmcD6Tlr7C70MvhU28 xpClp+ILjewxiQaF6oGf5HlFsa0tMzZO2hG20/bMXv4MpC7KxjXJX4Ux0tuyX2WEByIV P51rp4ZgrQv/hyWj5CKf8dfL1+cmjr87U8SXvkzPKsh/AxunxAdipQ1XYccFnuktm6IS m2dNC0UArjVcPjOroHnOGRk6gSFgGaGTQn/srIfhwG1JlPHwaItieI4Sa18MfUrEXrP0 P25Oqx/wnGlJIZQyL8wbW7rTmqrwU6LzFDbrXvbIigdkjvG/NdoXgSII/2+mGiPq/zOD HMJQ== X-Gm-Message-State: AOAM5318HFXXGLB5EqxtdG8L4RDa5/VV+GiJ/5nMj9b/VmkvxCEPD6jY k8g0Tr53GvC4Fx+R0xXugnY= X-Google-Smtp-Source: ABdhPJzUmLkAvzGauT7l1Ljxu5j6zNhu+o2GrshVf+Wwb4j6G3O76fuJF/hDci4B4df6Ke44BxeSCA== X-Received: by 2002:ac8:59c5:: with SMTP id f5mr16956841qtf.135.1637155930158; Wed, 17 Nov 2021 05:32:10 -0800 (PST) Received: from aford-OptiPlex-7050.logicpd.com ([174.46.170.158]) by smtp.gmail.com with ESMTPSA id v5sm10411448qtc.60.2021.11.17.05.32.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Nov 2021 05:32:09 -0800 (PST) From: Adam Ford To: linux-clk@vger.kernel.org Cc: aford@beaconembedded.com, cstevens@beaconembedded.com, Adam Ford , Abel Vesa , Michael Turquette , Stephen Boyd , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , Anson Huang , linux-arm-kernel@lists.infradead.org (moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE), linux-kernel@vger.kernel.org (open list) Subject: [PATCH] clk: imx8mn: Fix imx8mn_clko1_sels Date: Wed, 17 Nov 2021 07:32:02 -0600 Message-Id: <20211117133202.775633-1-aford173@gmail.com> X-Mailer: git-send-email 2.32.0 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211117_053211_686787_F2839EF3 X-CRM114-Status: UNSURE ( 9.24 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org When attempting to use sys_pll1_80m as the parent for clko1, the system hangs. This is due to the fact that the source select for sys_pll1_80m was incorrectly pointing to m7_alt_pll_clk, which doesn't yet exist. According to Rev 3 of the TRM, The imx8mn_clko1_sels also incorrectly references an osc_27m which does not exist, nor does an entry for source select bits 010b. Fix both by inserting a dummy clock into the missing space in the table and renaming the incorrectly name clock with dummy. Fixes: 96d6392b54db ("clk: imx: Add support for i.MX8MN clock driver") Signed-off-by: Adam Ford Reviewed-by: Fabio Estevam diff --git a/drivers/clk/imx/clk-imx8mn.c b/drivers/clk/imx/clk-imx8mn.c index c55577604e16..021355a24708 100644 --- a/drivers/clk/imx/clk-imx8mn.c +++ b/drivers/clk/imx/clk-imx8mn.c @@ -277,9 +277,9 @@ static const char * const imx8mn_pdm_sels[] = {"osc_24m", "sys_pll2_100m", "audi static const char * const imx8mn_dram_core_sels[] = {"dram_pll_out", "dram_alt_root", }; -static const char * const imx8mn_clko1_sels[] = {"osc_24m", "sys_pll1_800m", "osc_27m", - "sys_pll1_200m", "audio_pll2_out", "vpu_pll", - "sys_pll1_80m", }; +static const char * const imx8mn_clko1_sels[] = {"osc_24m", "sys_pll1_800m", "dummy", + "sys_pll1_200m", "audio_pll2_out", "sys_pll2_500m", + "dummy", "sys_pll1_80m", }; static const char * const imx8mn_clko2_sels[] = {"osc_24m", "sys_pll2_200m", "sys_pll1_400m", "sys_pll2_166m", "sys_pll3_out", "audio_pll1_out", "video_pll1_out", "osc_32k", };