Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp4327243ybg; Mon, 8 Jun 2020 05:13:35 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy/qCERGRH39U+IAc0KZXaXfqPc3aX13wq/neSwi2wwMJAwHnubNguzXGqJaVvQZT84afnP X-Received: by 2002:a17:906:a387:: with SMTP id k7mr21716319ejz.408.1591618414871; Mon, 08 Jun 2020 05:13:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591618414; cv=none; d=google.com; s=arc-20160816; b=LS0jq3aJwuwwCfoXH3MvDZGnhl3ClAF/hiU/WEsP/azj6nE7OgLJRC7IF23V7e3cim 2sjUMBBH+RlbT+5F4GpjL8g+J13qNPbfOZEtf96gM4wGFbMQHE010yRgju/PrXqmnw/W I+zj/PgOCGk0a6Wd1tpRVX/eieIarJaXDFesgYlpHL6jKrQrv5Zt00mgnQjbH4/X4Z2x Ov5C8RPaXyzeH3nRemRuf8ntB/EeOGY52GIA2po/qUJmcL6r+wrLXjUbwXZIGUe9pTWd 4xVqJe4yyZBaAT8JJYx4DxBeYvQKAvPl29yJ0T/iZv1XHchGtoFJ6IWR/gLXOO99tvkS oMzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=ltyhMEkISX5kr7cpVF0JSUjRPfEgCrElNZMuYmRJ7Fs=; b=c1jMhiGY8jcCHO5vbPn/KgjxUz/QqKuzUqgMXlnmblK6tidKKnBp2TyXecLBROqpYs v/OcKLDoeSAuDaH5EFrQQcl6OU+YBOzmuJEnBvECkoZQYsXBlkP7X/lIWvDx5w0b4OsQ Jet7WR1y6XOnY+LhDa4gZqdGhZPqiYWTvt9D+see0TnB4SBoAm90MfKTKrOgTqZ7pXIf SrKkr2I0gvwQd8DRa8bzSlZkHCZy/GfwFx/BjLZW5Ad6jvgJzURZfuoDaW+3keWzoZ8N nrx4vj8m1EdybLC6uc80ws871eH+1ytBRUj51Tu6OISb6ve+4Zszj6LIzF/ihv3gFDRa kjHg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=g21KG36U; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x17si8967908ejs.175.2020.06.08.05.13.11; Mon, 08 Jun 2020 05:13:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=g21KG36U; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729668AbgFHMLV (ORCPT + 99 others); Mon, 8 Jun 2020 08:11:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49156 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729310AbgFHMLU (ORCPT ); Mon, 8 Jun 2020 08:11:20 -0400 Received: from mail-pg1-x544.google.com (mail-pg1-x544.google.com [IPv6:2607:f8b0:4864:20::544]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A5EFDC08C5C2; Mon, 8 Jun 2020 05:11:19 -0700 (PDT) Received: by mail-pg1-x544.google.com with SMTP id t7so8682091pgt.3; Mon, 08 Jun 2020 05:11:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=ltyhMEkISX5kr7cpVF0JSUjRPfEgCrElNZMuYmRJ7Fs=; b=g21KG36UQZBZgT0ff9ZNcPra0WKx8ZP3mpu6p2d0+L2Auc6tKCoucLeRxERzyK2kIw g3uIktUQ7uP0kXuGVWz1NBNYvV3a4bEWVmbqE3E6/NiKyFVQ4xWE/FQEGsol/4Ia0ord XiFwyNap2P6+nzC0MdfIXZPILjtIpbrermT9vZh5xCvr+NfyS1EsMHC21RUFgcw0pQNr 9xfzihQYHMDi8xDrt5Q4Jpb2QOAqcqAB8Esh3Y/IvoPS44GGi8197IpU/1FFaHpgn2Yi 4EXyr4Af+Sx/JDoXmgxQE6NIjAhVXYg9JDrwKTAe+/Tm4ua9H0kRqKgcxBqS4Lpr35rV 0BrA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=ltyhMEkISX5kr7cpVF0JSUjRPfEgCrElNZMuYmRJ7Fs=; b=CQpomzP+NxMmG5ZuGigJcaEOCf7VKX/uuPweGNF3nY0Anzcu8np38d6Rfkd8+4/ftN C28yyRM15vo0F/NExDFoTSrbTUKqKuDhLNp2FhcrGa2IcvZuDi4Ym6irnAAqCEZ9XC3v uh8DWkIXBNXgfa+EorIKrYspbHoMlsWR8sN8s5at7+EBatNBmCwMKNpCFRgC4Gd0y9eU GljahWc0Lj4j8R+gqAseWjwrFn4Z4FJbRnwuG3mhaIJ/wvz80SalgxKZzOvGt+BNBUQP 9riFkaE2Nvr6Z7Bl10yosGrveE09LddlZebI7aU3rm//RVtBdQ9pyYpys6Kn2BkLE0vC xKVA== X-Gm-Message-State: AOAM530UtFj9yJs5POYcfd19UXxp+A+OnY1GRv+vnC+e9PVr4cmzAUOS 28Eyb6lLdTleXEpFSCqvYNeWPhOJJQGbBPzMfp0= X-Received: by 2002:a63:305:: with SMTP id 5mr19335432pgd.74.1591618279199; Mon, 08 Jun 2020 05:11:19 -0700 (PDT) MIME-Version: 1.0 References: <20200324175719.62496-1-andriy.shevchenko@linux.intel.com> <20200325032901.29551-1-saravanak@google.com> <20200325125120.GX1922688@smile.fi.intel.com> <295d25de-f01e-26de-02d6-1ac0c149d828@arm.com> <20200326163110.GD1922688@smile.fi.intel.com> <20200608091712.GA28093@pengutronix.de> <20200608115917.f5dhazixnxunl5o5@pengutronix.de> In-Reply-To: <20200608115917.f5dhazixnxunl5o5@pengutronix.de> From: Andy Shevchenko Date: Mon, 8 Jun 2020 15:11:07 +0300 Message-ID: Subject: Re: [PATCH v3] driver core: Break infinite loop when deferred probe can't be satisfied To: Marco Felsch Cc: Andy Shevchenko , Grant Likely , Saravana Kannan , Andrzej Hajda , artem.bityutskiy@linux.intel.com, Felipe Balbi , Mark Brown , Ferry Toth , Greg Kroah-Hartman , Linux Kernel Mailing List , Linux PM , Peter Ujfalusi , "Rafael J. Wysocki" , kernel-team@android.com, nd , Sascha Hauer 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 On Mon, Jun 8, 2020 at 2:59 PM Marco Felsch wrote: > On 20-06-08 14:13, Andy Shevchenko wrote: > > On Mon, Jun 8, 2020 at 12:20 PM Marco Felsch wrote: > > > On 20-03-26 18:31, Andy Shevchenko wrote: > > > sorry for picking this up again but I stumbled above the same issue > > > within the driver imx/drm driver which is using the component framework. > > > I end up in a infinity boot loop if I enabled the HDMI (which is the > > > DesignWare bridge device) and the LVDS support and the LVDS bind return > > > with EPROBE_DEFER. There are no words within the component framework docs > > > which says that this is forbidden. Of course we can work-around the > > > driver-core framework but IMHO this shouldn't be the way to go. I do not > > > say that we should revert the commit introducing the regression but we > > > should address this not only by extending the docs since the most > > > drm-drivers are using the component framework and can end up in the same > > > situation. > > > > > > > > It can be solved by refactoring the driver probe routine. If a resource is > > > > > required to be present, then check that it is available early; before > > > > > registering child devices. > > > > > > > > We fix one and leave others. > > > > > > E.g. the imx-drm and the sunxi driver... > > > > Just out of curiosity, does my patch fix an issue for you? > > I didn't applied your patch yet. I can test it if you want. If you can, thanks! > > > > > The proposed solution to modify driver core is fragile and susceptible to > > > > > side effects from other probe paths. I don't think it is the right approach. -- With Best Regards, Andy Shevchenko