Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3969192pxv; Mon, 19 Jul 2021 13:11:43 -0700 (PDT) X-Google-Smtp-Source: ABdhPJztKVC9LBinLl+MwljxwID35ZgYnCJIzkI6B6AjjAkmBdW8r+XEFcU1+S3vDme4K4aUxYYr X-Received: by 2002:a17:906:9b1:: with SMTP id q17mr8962623eje.546.1626725503017; Mon, 19 Jul 2021 13:11:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626725503; cv=none; d=google.com; s=arc-20160816; b=xFDdm8QIp9SAowOVFStEAG0H2MqTBMpbkxCuQgecp+lXHZ3J1ma7CKoL6S3xsb1qYe GPYmlMexTzf99oCujm1JF4gPN8v000c3F0QecWmVj6nyK2JWAi/RkI73oy6ToQo29/ZW PSWd08p810XuhSKSBY3uQeKbKuVW4jmagqGR2tjUDgkDwzcWY0owDJ8oc/Qayd9PL57M zooY83imGnkz27/O9XykieAoqyHHoZPZVwFt0S91rGwfpbzqJwSl8UKz5oNYHYj0Jn3x ZXXgClGE/IQRq0lQyulJ3kXtdmaqxDlGEqEDQ/9y49PBlicEJFtpWCsWaO9WE0jJ7GvJ izZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=+jdLZvJN21CTu/nU9p3zM/7iZ/xDd3v4ptR1eHb187U=; b=qDT19yBIIcad4N5rDJpZroSlMoiPJlD72gNJv8DHVA9rgN61tRYoBD3MwKKV86TWh7 MwXpXPvriVaJ5Ck4SJSVwyA/HxhB2qnhXg5yaDGsMgjKbZggTuYD5j/NgoIA8lLYBRKl OM6mqVbpZzpsj8vIBm8zBmh59mg3GNvIWE4DQ9SFzXwRo7zn0GTJsNYxTB7chQb0zM7M 1XMYPQJnM4nHtdadGLPWqVQkvVwBUmPsfdKKke0q9w883wMKtK9j6VtkEuA/qj5IBS9X YfDbTpIFzTKO4KfEDyAiAlYingz4rh5uzGRo8Tm3t2NyGY8kWBTSWo7QS1/s7mpBewmT GNBw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=GAA2TFcq; 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=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h14si21765165ejk.417.2021.07.19.13.11.19; Mon, 19 Jul 2021 13:11:43 -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=@linaro.org header.s=google header.b=GAA2TFcq; 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=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1384960AbhGSSls (ORCPT + 99 others); Mon, 19 Jul 2021 14:41:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33062 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1384088AbhGSSTm (ORCPT ); Mon, 19 Jul 2021 14:19:42 -0400 Received: from mail-lf1-x133.google.com (mail-lf1-x133.google.com [IPv6:2a00:1450:4864:20::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 44EEEC061762 for ; Mon, 19 Jul 2021 11:49:15 -0700 (PDT) Received: by mail-lf1-x133.google.com with SMTP id v6so31963385lfp.6 for ; Mon, 19 Jul 2021 12:00:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=+jdLZvJN21CTu/nU9p3zM/7iZ/xDd3v4ptR1eHb187U=; b=GAA2TFcqcWKOiNo7WTflTgsUtZoVN+Sr0pFrALy8uy/woqt17QIoJqfYp3Tuf8NwtD jMiXlHSGBKJkq9CnBheHrhObo675Jc2Ua5Rd03WylMJj4URR+qAs5aEfbtR8twNDiUCq nxPCeUDKG8iUp9iK9SKc40K8Mljh6vKLRfOR0sz1fFweRa3X30nbCQJcwNA4f7pXWhs3 B4R4+85bflBh80tdunaKPpbFV7h39mGQfhA94+U/bsyVicM5BZgtkOUpbNc1KIRbqTvS sF6tcpFTV1R0Pu4eIYZdf5XHr88AeJWG3VEIbp0uj1SDhe3DRa2rxXZPJfECGCM2yVaL rQkA== 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=+jdLZvJN21CTu/nU9p3zM/7iZ/xDd3v4ptR1eHb187U=; b=sz5o7s6ySG5wobZkGZhzpkQ1u6YOgPtFWteR+I6p2NsX/mJSvN3LUkjxM+uDECwq5D fykSrAIA7Pj4CI2DvBdqqbKh/8q5ONw4JW7+hWjnFYbsz75YKYitMeHcz7w9e0IBIrT3 kxIdWNvCH963Dc7rzGqUBTH1YRVSyiCLS0kbVgDUNaWngGs4exjpUJK+ufJAETarsXrn H+Nwvb/+yySon1AmjrNj8igmWEtTaJKYv7m32frfSnDZ0pKIIYJd/9ueL8kCGKwDnb2C JfP6jy2Jzg5LR0vN4kFoTcHSWHsec01DFVyjksEy5/3Qun7bXETpkcHsYu2vvVBEzAaZ P5Sw== X-Gm-Message-State: AOAM532PT0lubZQdccM56XI8AtlarW2TPIaGyQ8/dshB4Fh+ZRYqFWTY BU1+T2wd7upiuMBwL1nzSdLJ/wPCdD3XZQapZkdlhQ== X-Received: by 2002:a19:7408:: with SMTP id v8mr19183878lfe.508.1626721216181; Mon, 19 Jul 2021 12:00:16 -0700 (PDT) MIME-Version: 1.0 References: <20210707045320.529186-1-john.stultz@linaro.org> In-Reply-To: From: John Stultz Date: Mon, 19 Jul 2021 12:00:05 -0700 Message-ID: Subject: Re: [PATCH] firmware: QCOM_SCM: Allow qcom_scm driver to be loadable as a permenent module To: Bjorn Andersson Cc: lkml , Catalin Marinas , Will Deacon , Andy Gross , Joerg Roedel , Thomas Gleixner , Marc Zyngier , Linus Walleij , Vinod Koul , Kalle Valo , Maulik Shah , Saravana Kannan , Todd Kjos , Greg Kroah-Hartman , linux-arm-msm , "list@263.net:IOMMU DRIVERS , Joerg Roedel ," , "open list:GPIO SUBSYSTEM" Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jul 16, 2021 at 10:01 PM Bjorn Andersson wrote: > On Tue 06 Jul 23:53 CDT 2021, John Stultz wrote: > > Allow the qcom_scm driver to be loadable as a permenent module. > > > > This still uses the "depends on QCOM_SCM || !QCOM_SCM" bit to > > ensure that drivers that call into the qcom_scm driver are > > also built as modules. While not ideal in some cases its the > > only safe way I can find to avoid build errors without having > > those drivers select QCOM_SCM and have to force it on (as > > QCOM_SCM=n can be valid for those drivers). > > > > Reviving this now that Saravana's fw_devlink defaults to on, > > which should avoid loading troubles seen before. > > > > Are you (in this last paragraph) saying that all those who have been > burnt by fw_devlink during the last months and therefor run with it > disabled will have a less fun experience once this is merged? > I guess potentially. So way back when this was originally submitted, some folks had trouble booting if it was set as a module due to it loading due to the deferred_probe_timeout expiring. My attempts to change the default timeout value to be larger ran into trouble, but Saravana's fw_devlink does manage to resolve things properly for this case. But if folks are having issues w/ fw_devlink, and have it disabled, and set QCOM_SCM=m they could still trip over the issue with the timeout firing before it is loaded (especially if they are loading modules from late mounted storage rather than ramdisk). > (I'm picking this up, but I don't fancy the idea that some people are > turning the boot process into a lottery) Me neither, and I definitely think the deferred_probe_timeout logic is way too fragile, which is why I'm eager for fw_devlink as it's a much less racy approach to handling module loading dependencies. So if you want to hold on this, while any remaining fw_devlink issues get sorted, that's fine. But I'd also not cast too much ire at fw_devlink, as the global probe timeout approach for handling optional links isn't great, and we need a better solution. thanks -john