Received: by 10.213.65.68 with SMTP id h4csp452474imn; Fri, 23 Mar 2018 08:06:42 -0700 (PDT) X-Google-Smtp-Source: AG47ELurxShjBG+5XEBB3k55MeKru4enRS+Ld6od2gjdBCT03VxuGeX3sCeIzkuLX4PttvR2EALu X-Received: by 10.99.42.209 with SMTP id q200mr13367218pgq.379.1521817602923; Fri, 23 Mar 2018 08:06:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521817602; cv=none; d=google.com; s=arc-20160816; b=h2aAfhPDQpbUdzlD9LdDzDw8WqjqUi13vQs11lA51x/kYyf8DD4Y2V+vFlZdthu/AH k9NMTnjrq2dcSC35SNwIorGKYBwkQq69xWgDIUiPnwo+utQ+BR/6xYmMTZ3oacBXvsxY mo5rWApmd+wC73BCHrHtxHHF3fLOxeT57CQuvqX2WSI8FoGT5NgLfz7p+JQgmRRvRkvb chVm3F+UfCXFijTNKKTFf7bJV1JmWeMINYWzygO3xisomN2ARjYhzxH8nAZyUb3G6NHR klRSzx4BGEeDAUmcE3hPLXCrDp5Upr32s56Mvusr+0x8z7bynvfdNJjiv+wvw/Z+5tbk KlVQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=dCYUR5x+e/n7CcDcGhL4zMtWrZYRfaY4v7BQRlHy7wQ=; b=PT07CN/ykSTXZ2IwdVz0W+PzDmBzTcvyvppKQrqR92MEgFFQ2fdJuMjtfmOB0LXRzF cDN6ta1UWQgp6SRiJGq+pe1FACeJME0xfawfdBa84lDwPfqnJYo4n9w9sMGNobAvE34V mdGwKqLZt86yDVAnXhqOzGptZzLcrDeOexj2fIDbPyGluO5OWExQI//QdFcErXsQA4VA VWmOoMeGRhjTJvM9yfUBBtK2/O1HLTeamVklA+ErBSGMugmW05aD3NKsOaL3Gw8URf0g ccYWMV9c5DNGh+o3ifQwUuHB4s6JDnjxy9+OFnl2MQ7CLggm4P8xFLG2rbzg2NPh25P7 I7CA== 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 x4si6299775pgq.11.2018.03.23.08.06.22; Fri, 23 Mar 2018 08:06:42 -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 S1751983AbeCWPEY (ORCPT + 99 others); Fri, 23 Mar 2018 11:04:24 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:35628 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751632AbeCWPEW (ORCPT ); Fri, 23 Mar 2018 11:04:22 -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 1620B12F2; Fri, 23 Mar 2018 15:04:22 +0000 (UTC) Date: Fri, 23 Mar 2018 16:04:20 +0100 From: Greg Kroah-Hartman To: Viresh Kumar Cc: Vincent Guittot , Stephen Boyd , Rajendra Nayak , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, robdclark@gmail.com, s.hauer@pengutronix.de, l.stach@pengutronix.de, shawnguo@kernel.org, fabio.estevam@nxp.com, nm@ti.com, xuwei5@hisilicon.com, robh+dt@kernel.org, olof@lixom.net, georgi.djakov@linaro.org Subject: Re: [PATCH V7 00/13] drivers: Boot Constraint core Message-ID: <20180323150420.GA21152@kroah.com> References: <20180322012606.vuaemu3pvpeojtwr@vireshk-mac-ubuntu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180322012606.vuaemu3pvpeojtwr@vireshk-mac-ubuntu> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Mar 22, 2018 at 09:26:06AM +0800, Viresh Kumar wrote: > On 23-02-18, 15:53, Viresh Kumar wrote: > > Problem statement: > > > > Some devices are powered ON by the bootloader before the bootloader > > handovers control to Linux. It maybe important for some of those devices > > to keep working until the time a Linux device driver probes the device > > and reconfigure its resources. > > > > A typical example of that can be the LCD controller, which is used by > > the bootloaders to show image(s) while the platform is booting into > > Linux. The LCD controller can be using some resources, like clk, > > regulators, etc, that are shared between several devices. These shared > > resources should be configured to satisfy need of all the users. If > > another device's (X) driver gets probed before the LCD controller driver > > in this case, then it may end up disabling or reconfiguring these > > resources to ranges satisfying the current users (only device X) and > > that can make the LCD screen unstable. > > > > Another case can be a debug serial port enabled from the bootloader. > > > > Of course we can have more complex cases where the same resource is > > getting used by two devices while the kernel boots and the order in > > which devices get probed wouldn't matter as the other device will surely > > break then. > > And we have a _real_ use case for this complex scenario as well. > > Georgi (cc'd) is currently working[1] on implementing generic support for the > interconnect bus, which tries to play with the bandwidth of the bus based on how > much are the requirements from different parts of the SoC. The 4th version was > posted recently by him, and things are looking good/positive. > > The bootloader configures the interconnect to provide sufficient bandwidth for > all the devices which are used during boot, few of them are the CPUs, serial and > the LCD controller. As the kernel starts taking control of things, the drivers > being probed start putting their requirements on the interconnect bus. Because > the interconnect doesn't have any representation from the devices which are not > yet initialized by the kernel, the interconnect core incorrectly reduces the > bandwidth of the bus to a level unacceptable to the devices running currently, > like the CPUs and this makes kernel boot awfully slow. This is not an ordering > problem as no matter which device we probe first, we are going to break > something else. > > Georgi already tried using the boot constraint patches to solve this complex > problem, and its a perfect fit. I'm delaying this as I still don't see that "perfect fit" yet. If there are add-on patches that take better advantage of this, great, let's see those, but right now, it feels like you are the only one wanting this. And the increased complexity overall seems not really worth it yet :( greg k-h