Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2859211imu; Fri, 18 Jan 2019 00:10:09 -0800 (PST) X-Google-Smtp-Source: ALg8bN5g25owMCqEv15sF8Nj7YWbKk4EdfukxAto/GcetRV2pfI9G+AFg5P50XtHkfg4JdwYyLVa X-Received: by 2002:a63:4b25:: with SMTP id y37mr17087662pga.181.1547799009882; Fri, 18 Jan 2019 00:10:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1547799009; cv=none; d=google.com; s=arc-20160816; b=o4ioOERuhigrpKeGJ/lF6hcVaSNsDKZTHY0PWoCXER9TvzLjk8Sa5v5qZ6Zh9CTTNl uIO0uvd+Pqzo2i7r4jGSbp/Bjd+69xH+LpFFW4fNoUd2mPK80Yo6/EQm2STrDFBN0iai n1vYcQQki5I51M58rlUgTex2NlH5aEr5HbCB+V4oXxJyMe+yYGjnOlSF00HJ41YOk6CE IZzURJj0aANrqzV8KRyG8tYt/wSN0jGTe7KXg8VtfFR0mJy2OWC7W+W5foBLrLGYJUvB cPUBYr0Ao+ELqvbgaA2/4xwB98Zfe/BHEwkhoZdwi23wYPBS9i1WdlFCSjUcC8mIwJFe aywQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=fbYzqlhTa6lS452rFzjA7xlNTtvcC9WmdtzhQHS36HU=; b=B8C7IgZPzxu6z09wOfid4MNVYoAoolMZy6pWhKfEzheASfCnqkOWNOfpBKzX+qEb9J ZhpYnEqmb/pjHGhx9ZwvLjnIJv3+n6fcnxKLR7R4A5rvx7kawZlbpm0owaPOCAtda6+b V2sqAUvP+X8Alo796+AlEmS97J5oLzfIT4dHIHyS7kDMCTDb6gaxlbBfQV9YIHYm/QXP ddkcqfhNwu/mI8VNQYlOrkqajbzKBL/4m8iIX1QPMEKBdpbsExpNzvukIhh1LxJIgBAD VMH/beOfvs14msjEqGntV1etcwrEj52c2m1sNKnLZw5eyeCFx2pIJs/BOOyDmAoH3JxA LGSw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=oPOUqKMM; 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=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v10si4260659plg.82.2019.01.18.00.09.50; Fri, 18 Jan 2019 00:10:09 -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=@kernel.org header.s=default header.b=oPOUqKMM; 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=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727245AbfARIHu (ORCPT + 99 others); Fri, 18 Jan 2019 03:07:50 -0500 Received: from mail.kernel.org ([198.145.29.99]:37924 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727148AbfARIHt (ORCPT ); Fri, 18 Jan 2019 03:07:49 -0500 Received: from bbrezillon (91-160-177-164.subs.proxad.net [91.160.177.164]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 1737E20855; Fri, 18 Jan 2019 08:07:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1547798868; bh=iycJr6kMP0y8uo8Se6qfTNrgbB+LhAyuaI7z/89S51o=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=oPOUqKMMPfNCqnbLw20NA61qi0SdMPmFMJH6DehB8UnC8dZxattVHb88ATKxDtHoU TLibIkiyd1fI3uBF7gSTsk5fZifycuAfgcGqEJFUi5PxKB7r1FfoGREs/oWP1edSdz S7yYSZ+lJh1Qd9LmSkggyrVT7qajrULBoptzlCkQ= Date: Fri, 18 Jan 2019 09:07:36 +0100 From: Boris Brezillon To: Paul Cercueil Cc: David Woodhouse , Brian Norris , Marek Vasut , Richard Weinberger , Rob Herring , Mark Rutland , Ralf Baechle , Paul Burton , James Hogan , Miquel Raynal , Harvey Hunt , linux-mtd@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org Subject: Re: [PATCH 1/8] MIPS: DTS: CI20: Set BCH clock to 200 MHz Message-ID: <20190118090736.6f1283bd@bbrezillon> In-Reply-To: <20190118010634.27399-1-paul@crapouillou.net> References: <20190118010634.27399-1-paul@crapouillou.net> X-Mailer: Claws Mail 3.16.0 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Paul, On Thu, 17 Jan 2019 22:06:27 -0300 Paul Cercueil wrote: > This is currently done inside the jz4780-bch driver, but it really > should be done here instead. > I disagree with that statement. If it's a per-SoC constraint then you can select the appropriate rate based on the compatible in the driver. If the clock rate depends on the NAND chip it probably means it's used to generate the RE/WE pulse and should depend on the NAND timings passed to ->setup_data_interface(). In either case, this should not be specified in the DT. Regards, Boris > Signed-off-by: Paul Cercueil > --- > arch/mips/boot/dts/ingenic/ci20.dts | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/arch/mips/boot/dts/ingenic/ci20.dts b/arch/mips/boot/dts/ingenic/ci20.dts > index 50cff3cbcc6d..aa892ec54d0a 100644 > --- a/arch/mips/boot/dts/ingenic/ci20.dts > +++ b/arch/mips/boot/dts/ingenic/ci20.dts > @@ -111,6 +111,9 @@ > pinctrl-names = "default"; > pinctrl-0 = <&pins_nemc>; > > + assigned-clocks = <&cgu JZ4780_CLK_BCH>; > + assigned-clock-rates = <200000000>; > + > nand@1 { > reg = <1>; >