Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp410675rdh; Thu, 23 Nov 2023 07:14:49 -0800 (PST) X-Google-Smtp-Source: AGHT+IGdmjEIKN+e1XqbNKoeCA3P13sxObA68IAW6Yl41+y9i6ouNBcV2SqJJXM5qGVO1EU8Sx3I X-Received: by 2002:a17:90b:4c87:b0:27c:f845:3e3f with SMTP id my7-20020a17090b4c8700b0027cf8453e3fmr6118825pjb.1.1700752488826; Thu, 23 Nov 2023 07:14:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700752488; cv=none; d=google.com; s=arc-20160816; b=x4Q08bBu05cWjsgwc3kLwsP/YQDm7ShTZUMaNnPwMTPm2E+w1Vzrmd0FLZSZ7slYGn Z8sEkYX9ilndsV1MmQsKRopzvTEkCpi5pcfCN7Jl8cZa853eLvmA8W2MP0lkjCyRJHeW C5kFm2JrgZRXD7ELB3I9E5Q+PSQLenyrfWYj1213JagWVEujDyXaY5qhLqcGmiSKu9/u WUTi6qLm3Esdye1WS7oIDNcbnut9oGp4wfiHZRNbA+5v1QMiHSzYEpauSI1hBZrTevZC O2/8WLtGiVZmOi8BbbC020I+ZX+6mFk5eRKRkJ31pnyzkSkRwDczdq2VHm3e33cpETxx S4rw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=tjyPqzCzon3lA2/wGIkgy85tEm0FY1v7eXqgEj2Jgbw=; fh=trAT+d34q+ZQIK27/rYiKbPFt8w8AkD+WFX1mUfL76I=; b=F4SBa1a2LSssp/Qs7bxQVkuqgpveWZzvTMeRQMuJIGGSxmnMckaTgy/iwJTRCWUAJd 8YoiVK45ju8CHDrnXpRZhiK5+/GWLCwOJqqKNdV0MeIU9LV+ZNXLbgx5u5mqDVSA6sPY TdRNH1D1qWK3Y98hnCXJ60OS0r/btsp9fFRooUmQVitITRDzzzl5Lp5bZIRXqWUi/6X2 VhOlFUjA/9Y+eGYnBAjG6F2DhJeleeeRB/n7edgmhCLJQpLqJsOe2e4jbdnoeLI06gu9 Jnr6FdBpmAEaWXwf+i2EZQRcoxT57QGjYjA//t7mQ0lWtwr7mW4z4oLW6UXOCq3DDJg6 TPow== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="WiA/xWos"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 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 lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id j22-20020a17090a7e9600b002747da1ef66si1408748pjl.53.2023.11.23.07.14.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Nov 2023 07:14:48 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="WiA/xWos"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id F0E5780278CB; Thu, 23 Nov 2023 07:14:45 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346027AbjKWPOb (ORCPT + 99 others); Thu, 23 Nov 2023 10:14:31 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42144 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229602AbjKWPOX (ORCPT ); Thu, 23 Nov 2023 10:14:23 -0500 Received: from mail-wm1-x332.google.com (mail-wm1-x332.google.com [IPv6:2a00:1450:4864:20::332]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5798BD53 for ; Thu, 23 Nov 2023 07:14:26 -0800 (PST) Received: by mail-wm1-x332.google.com with SMTP id 5b1f17b1804b1-40b34563987so5755775e9.1 for ; Thu, 23 Nov 2023 07:14:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1700752465; x=1701357265; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=tjyPqzCzon3lA2/wGIkgy85tEm0FY1v7eXqgEj2Jgbw=; b=WiA/xWosHCbpnM5PANQs4pRib25WvssyrHNjC/PZ5UYAixdrxh0ty+x849nZEKesyK bVUCUuosxZeY1uscujwmZosMBgFtHnCTHPK7ixeWAR1vjrbRVt/Jqlw9GE4iNVJ0zkWM iW9DdRzs8JmI80u8DdxwTkITqu6cC7AuLWvycEt21+33wh7bo/7WoS9ntxvSOvjUFSsX kWgJOa7OV/n+alDI5kkJZfG0nxZ7G+gfd1sluvmJmXC6miQtbalmxW00jCE1Htk7Ovyk jER4t0Y9L/L3og9z0Qw9E6DXFPkWDim3emXaxP9cH7qC69Em5qOKIr7TZA7UIWZtMnOW Fs9w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700752465; x=1701357265; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=tjyPqzCzon3lA2/wGIkgy85tEm0FY1v7eXqgEj2Jgbw=; b=I0eEpUy/ohHo1/k4+RA0QOug9IBurGn4SMBo0vFKKzUNbQdGbDmkdrY31vbE3SM84L Rv/Vnk+I9pkg0KwMHHFPc0UfVjPt2PZ04BgNE8TTsjr7bsL5FpfUxeihuFE3TT3tXJi1 XImCtwlUpscLcIAOpb1mVSBdas3gC72q6ONPMxKwh+bcgD53cAd1Yj2NVsfkvNlV621F CI9I6/itJuV2Xx32Feb3V9uErmpNFaxmmiHkY2eaevnLotTTczrcNqjg2lLGv+P3OlSb Mxwsup8f7yfadQ2mRt4XOYLdJ4lGQpFW9DtNu5QnzcE25ExHBiPMwnsfXEJotHe9XPwB xSbg== X-Gm-Message-State: AOJu0YxL6CnPf2eLGTW006zXQHR4Bn9V7LQea5a6DyNtaR2ZsLOQ/PJs +Ev8ybsKcM/KlUCMeIQvH5WzmQ== X-Received: by 2002:a05:600c:32af:b0:408:36bb:5b0c with SMTP id t47-20020a05600c32af00b0040836bb5b0cmr2567488wmp.7.1700752464653; Thu, 23 Nov 2023 07:14:24 -0800 (PST) Received: from localhost ([102.36.222.112]) by smtp.gmail.com with ESMTPSA id d8-20020adfef88000000b003258934a4bcsm1953036wro.42.2023.11.23.07.14.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Nov 2023 07:14:23 -0800 (PST) Date: Thu, 23 Nov 2023 18:14:18 +0300 From: Dan Carpenter To: Laura Nao Cc: broonie@kernel.org, groeck@chromium.org, kernel@collabora.com, kernelci@lists.linux.dev, lenb@kernel.org, linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, rafael@kernel.org, robh+dt@kernel.org, shuah@kernel.org Subject: Re: [RFC PATCH 0/2] Add a test to verify device probing on ACPI platforms Message-ID: <431009f0-56e7-46e8-a3a0-a8070554b727@suswa.mountain> References: <4f1283d4-1c50-4aba-ba54-b9ea975bf61d@moroto.mountain> <20231123120942.33222-1-laura.nao@collabora.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231123120942.33222-1-laura.nao@collabora.com> X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Thu, 23 Nov 2023 07:14:46 -0800 (PST) On Thu, Nov 23, 2023 at 01:09:42PM +0100, Laura Nao wrote: > > Your talk was interesting at Linux Plumbers. > > > > https://www.youtube.com/watch?v=oE73eVSyFXQ [time +2:35] > > > > This is probably a stupid question, but why not just add something to > > call_driver_probe() which creates a sysfs directory tree with all the > > driver information? > > > > Thanks for the feedback! > > Improving the device driver model to publish driver and devices info > was indeed another option we considered. We could have a debugfs entry > storing this kind of information, similar to what devices_deferred > does and in a standardized format. This would provide an interface > that is easier to query at runtime for getting a list of devices that > were probed correctly. > This would cover devices with a driver that's built into the kernel or > as a module; in view of catching also those cases where a device is > not probed because the relevant config is not enabled, I think we'd > still need another way of building a list of devices present on the > platform to be used as reference. Yeah. So we'd still need patch #1 as-is and but patch #2 would probably be simpler if we had this information in sysfs. Or a different solution would be to do what someone said in the LPC talk and just save the output of the previous boot and complain if there was a regression where something didn't probe. > > The solution proposed in this RFC follows the same approach used for > dt based platforms for simplicity. But if adding a new sysfs entry > storing devices and driver info proves to be a viable option for > upstream, we can surely explore it and improve the probe test to > leverage that. You're saying "simplicity" but I think you mean easiest from a political point of view. It's not the most simple format at all. It's like massive detective work to find the information and then you'll have to redo it for DT and for USB. Are there other kinds of devices which can be probed? I feel like you're not valuing your stuff at the right level. This shouldn't be in debugfs. It should be a first class citizen in sysfs. The exact format for this information is slightly tricky and people will probably debate that. But I think most people will agree that it's super useful. regards, dan carpenter