Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp2994117imm; Sun, 1 Jul 2018 09:55:56 -0700 (PDT) X-Google-Smtp-Source: ADUXVKLa3aYSIFR9z3fWvUXD9uJMKe3ZNegbeePdqmbN8xs3yoJxmNn4lyMRIdQ8cbKSeOmnTNhi X-Received: by 2002:a63:24c4:: with SMTP id k187-v6mr18881095pgk.434.1530464155979; Sun, 01 Jul 2018 09:55:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530464155; cv=none; d=google.com; s=arc-20160816; b=FSiTxFkj/WyY2HakobbQ5D4irvQ0a9/dyVpzuHy+XcNLBWEW1+ldk4rJ8qmifbC0FS mxxI2MhrakA3Pf/WGv8nZBwjMGB1KWx0gFzbBdTmyX2E2IYRyRHiu+MgTyogrSTECHaE OqIr9+zrQm8Mcf6kbauAGhncx89J7AjG9BEbeRXwhMklY6eOEWb0fLLOqeyFJN3p6Ds2 +tEIH6E/Lq22sdi3TrDotviztcUbEA/8s5a5VVTcMCZB1gkwQC2kzpd6S6hvmPji9MXm k5WS4zNef2TIB4eyDXCNMP7yYF2JyTixMyKukaSMaDeBDoPnk5+y14vOhqw7GokxGqnP 7x+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=C9K2ZBBhaelcfrdiFFH6OviIlfwlFJg5jW0GffV9BEk=; b=v/11Ssh3720TbjtmUNnYKZLBkW155jtOtUh9fZu7t2gZxhg1AGDO+axiHCia1laD6k uy9/lo5AUZnUzpNmpB6+JP9JkTmWKQrEKgPkIzjdWiIYbXmQKyiwuS8R10nqPEn+IRS5 uWuj+W76snULkzGVx6yYGXeWVZ2vcQnbFMEh9lz2wFCMRSbYCTtdT/CmrRPzz4Iw5M+f NBB0wx9HEYOFJHwvCDicUYtkkc1MOnamQeXW8BdlLIm9r29+A2UI8HzTu4Lf+JKz9Ezn jpjITzKBNLo8Pa4ICCWQ3/oqF6kCV/jVYlpfILnqw/i7wDhp2RgVluGUJrckR5qoF8Ko owrg== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s126-v6si15012998pfc.222.2018.07.01.09.55.41; Sun, 01 Jul 2018 09:55:55 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933976AbeGAQy0 (ORCPT + 99 others); Sun, 1 Jul 2018 12:54:26 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:38208 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932924AbeGAQpX (ORCPT ); Sun, 1 Jul 2018 12:45:23 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 3E8EDA73; Sun, 1 Jul 2018 16:45:22 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Martin Blumenstingl , Kevin Hilman , Jerome Brunet Subject: [PATCH 4.17 147/220] clk: meson: meson8b: mark fclk_div2 gate clocks as CLK_IS_CRITICAL Date: Sun, 1 Jul 2018 18:22:51 +0200 Message-Id: <20180701160914.456473521@linuxfoundation.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180701160908.272447118@linuxfoundation.org> References: <20180701160908.272447118@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.17-stable review patch. If anyone has any objections, please let me know. ------------------ From: Martin Blumenstingl commit 72e1f2302040398dafb64bbb93abdde78c1f2267 upstream. Until commit 05f814402d6174 ("clk: meson: add fdiv clock gates") we relied on the bootloader to enable the fclk_div clock gates. It turns out that our clock tree is incomplete at least on Meson8b (tested with an Odroid-C1, which uses an RGMII PHY) because after the mentioned commit Ethernet is not working anymore (no RX/TX activity can be seen). At the same time Ethernet was still working on Meson8m2 with a RMII PHY. Testing has shown that as soon as "fclk_div2" is disabled Ethernet stops working on Odroid-C1. Unfortunately it's currently not clear what the Ethernet controller IP block uses the fclk_div2 clock for. Mark the clock as CLK_IS_CRITICAL to keep it enabled (as it's already enabled by most bootloaders by default, which is why we didn't notice it before). Fixes: 05f814402d6174 ("clk: meson: add fdiv clock gates") Cc: stable@vger.kernel.org Signed-off-by: Martin Blumenstingl Tested-by: Kevin Hilman Signed-off-by: Jerome Brunet Signed-off-by: Greg Kroah-Hartman --- drivers/clk/meson/meson8b.c | 7 +++++++ 1 file changed, 7 insertions(+) --- a/drivers/clk/meson/meson8b.c +++ b/drivers/clk/meson/meson8b.c @@ -246,6 +246,13 @@ static struct clk_regmap meson8b_fclk_di .ops = &clk_regmap_gate_ops, .parent_names = (const char *[]){ "fclk_div2_div" }, .num_parents = 1, + /* + * FIXME: Ethernet with a RGMII PHYs is not working if + * fclk_div2 is disabled. it is currently unclear why this + * is. keep it enabled until the Ethernet driver knows how + * to manage this clock. + */ + .flags = CLK_IS_CRITICAL, }, };