Received: by 2002:a05:7412:b101:b0:e2:908c:2ebd with SMTP id az1csp3058135rdb; Wed, 15 Nov 2023 21:08:07 -0800 (PST) X-Google-Smtp-Source: AGHT+IEudaMu/k+7Be/BaATxm1GJfDadj9X5sBJnK/qWVjJ1c1XgOJ3N+Ufg8vqTubL4pBhDkw+a X-Received: by 2002:a05:6e02:1a09:b0:359:c239:3f57 with SMTP id s9-20020a056e021a0900b00359c2393f57mr18727857ild.16.1700111287273; Wed, 15 Nov 2023 21:08:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700111287; cv=none; d=google.com; s=arc-20160816; b=js35zpDS+dcyjiUaJ7BEC4b/NIr14O6zHE6vc+DWvKsPe6yrMxrrzzGOFFMdCYC9ik CnlrbCVTVYqZ2olT7WbRuaW7ldxRFHSwem1oVroIen1FukCv0vQh0A+9gKuRvWpj1vQq gJDeenS0d8KoTdzueDBQbut0UPccTzALxi8EI7KyiJkZjUAQPIQDdGh3SlHnEiPT08ZQ ZW7AowenmL4fXjUAsYRVMceCdfMlkVzl0qn221xJX2yKRJjmPDKF3UvNcVunfnnOJBtw XBG9XbMnz6HZkrUd/C6vPgSDwtaK9jgkP692o92JhE7kJ2o7SXioPDf+sc1uDERCcKvM h4lg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=n47o3OCFeDC4YRz6dczMMUhasbGb5AVuJwwpKHI7eFo=; fh=yN7IoLHLtt6vKXKGyU691VmARqiWKaxRxHxZ2WPM8q8=; b=ta9+DhNRgIh5UqzNyxaQz7fvWBYU4FK2FHO6aq2NoVMFjVtyLTrlX9MC1pALDPl8SR RIVYmK/SQwtMUaPTjM2zeSRDBZiV9S12XTY5EOqMBDuJVJm+mgDayzywrlroDIw5uoQp O+N/IiJ9kojl7weAzhsM7uOzRQzllanzffKBiUkqfX/rQLm7LnKwlukCk/2TLNfedIuZ NP5vHEKyJgufk8XB/6UuBAX4kHPhnkkRV9MW6RHph71prB5tpPN3X6ieWtQa59dcUNWs 1jSPoPc3hmYUGf2vJUOd7QaRh6anpV4Wzr8Qrykk8qopMyNqCerSteg0B02bwIj7iF5V pi9g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=kMy9X+Zv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [2620:137:e000::3:3]) by mx.google.com with ESMTPS id bn20-20020a056a02031400b005bd27920754si12804480pgb.204.2023.11.15.21.08.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 15 Nov 2023 21:08:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) client-ip=2620:137:e000::3:3; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=kMy9X+Zv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 5F0138028927; Wed, 15 Nov 2023 21:08:04 -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 S230024AbjKPFHs (ORCPT + 99 others); Thu, 16 Nov 2023 00:07:48 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47782 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229446AbjKPFHr (ORCPT ); Thu, 16 Nov 2023 00:07:47 -0500 Received: from mail-lf1-x12c.google.com (mail-lf1-x12c.google.com [IPv6:2a00:1450:4864:20::12c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BB18719E for ; Wed, 15 Nov 2023 21:07:43 -0800 (PST) Received: by mail-lf1-x12c.google.com with SMTP id 2adb3069b0e04-507bd644a96so536694e87.3 for ; Wed, 15 Nov 2023 21:07:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1700111262; x=1700716062; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=n47o3OCFeDC4YRz6dczMMUhasbGb5AVuJwwpKHI7eFo=; b=kMy9X+ZvZZcOmSWLeFHvAHNtNge8oJD4OdCGchhk/D79Ye4EhoblebUNO5c+S3dXIQ di50xAIrda8ld6gu7NWvTpo1V4/u261eu9DsWH7w7TBDe0RD+7Ip3ezP31g0kDfJZ5uy rgUc95XjztBClPsRiO0/U+e0Ep7N+ozu5DH5E= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700111262; x=1700716062; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=n47o3OCFeDC4YRz6dczMMUhasbGb5AVuJwwpKHI7eFo=; b=l3GF9i4qtClOO4zsebT4tDysmvNNoijjbD7r3YZsiJhosgccwqPM82/CekI3qRwpQ0 GourLIjynOaIaAQFo1MTnmEWhnTfyFKO7SotkWBeOlkMDZ0VFWexCG9iB0bElhMKAQ3p loy5uBHiC0Kg3+Cac4etW5BvZ7T2lHMXtzLZjhMTnEsM9AAgCAY5ppWuU0SguzkqqUTi 7nprNHDlX1mgKNHBFz4T10Kh2xwyPACei9wRxnp1vqjwGKSiwDf2NMZdrTDXFItxJM0m DPAVwSMZCXghzyKOSsDRm0GJ8rKDAOBmIcFxZsAzo4geiDg5D4I8vbFE9DwVrlHDbkgm nAjA== X-Gm-Message-State: AOJu0Ywuozt4HcMw+xhQurFXwAImN5guyKYMyJgGlgdj9NWzDdkcOfDK XbwqAszlJ1jxH/B3MaSwhaFe7SNahTS4RhPr+bXfFA== X-Received: by 2002:a19:7616:0:b0:509:4980:7bf0 with SMTP id c22-20020a197616000000b0050949807bf0mr9759057lff.38.1700111261841; Wed, 15 Nov 2023 21:07:41 -0800 (PST) MIME-Version: 1.0 References: <20231109100606.1245545-1-wenst@chromium.org> <859ac058-c50a-4eb8-99b6-3011ef4e7529@collabora.com> In-Reply-To: From: Chen-Yu Tsai Date: Thu, 16 Nov 2023 13:07:30 +0800 Message-ID: Subject: Re: [RFC PATCH v2 0/7] of: Introduce hardware prober driver To: Rob Herring Cc: Doug Anderson , AngeloGioacchino Del Regno , Frank Rowand , Krzysztof Kozlowski , Conor Dooley , Matthias Brugger , Hsin-Yi Wang , Dmitry Torokhov , andriy.shevchenko@linux.intel.com, Jiri Kosina , linus.walleij@linaro.org, broonie@kernel.org, gregkh@linuxfoundation.org, hdegoede@redhat.com, james.clark@arm.com, james@equiv.tech, keescook@chromium.org, petr.tesarik.ext@huawei.com, rafael@kernel.org, tglx@linutronix.de, Jeff LaBundy , linux-input@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org, Johan Hovold Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.0 required=5.0 tests=DKIMWL_WL_HIGH,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]); Wed, 15 Nov 2023 21:08:04 -0800 (PST) On Thu, Nov 16, 2023 at 5:35=E2=80=AFAM Rob Herring wr= ote: > > On Wed, Nov 15, 2023 at 2:45=E2=80=AFPM Doug Anderson wrote: > > > > Hi, > > > > On Wed, Nov 15, 2023 at 2:28=E2=80=AFPM Rob Herring wrote: > > > > > > > So if we're searching the whole device tree for "failed-needs-probe= " > > > > then we need to figure out which devices are related to each other.= If > > > > a given board has second sources for MIPI panels, touchscreens, and > > > > trackpads then we need to know which of the "failed-needs-probe" > > > > devices are trackpads, which are touchscreens, and which are MIPI > > > > panels. Do you have any suggestions for how we should do that? Mayb= e > > > > it was in some other thread that I missed? I guess we could have a > > > > board-specific table mapping (compatible + node name + reg) to a > > > > class, but that feels awkward. > > > > > > Node name is supposed to correspond to device class, so why not use > > > that (no path or unit-address.) and nothing else (well, besides > > > "status")? > > > > One problem is that I could imagine having two second source trackpads > > that both have the same i2c address. That would give them the same > > name, right? I guess you could maybe come up with some sort of suffix > > rule? Like > > > > trackpad-1@10 { > > compatible =3D "elan,blah"; > > ret =3D <0x10>; > > status =3D "failed-needs-probe"; > > ... > > } > > trackpad-2@10 { > > compatible =3D "goodix,gt7375p"; > > ret =3D <0x10>; > > status =3D "failed-needs-probe"; > > ... > > } > > > > Then I guess the class would be "trackpad"? > > That issue is somewhat orthogonal because it is not following the spec. > > I'm not sure mixing the 2 styles of node names is a good idea. While > not used too much, matching by node name does ignore the unit-address, > but I'm not sure we could ignore a '-N'. of_node_name_prefix() solves that. I assume that's the intended use case? > I think our options are either add something to the unit-address or > use i2c-mux binding. Adding to the unit-address is not unprecedented. > I did that for some of the register bit level bindings where you have > a node for different bits at the same address. The downside is > unit-address is bus specific, so we'd have to add that for multiple > buses. For the i2c-mux, it's perhaps a bit complex and I'm not sure > what if anything you'd have to do to manage the mux that's not really > there. > > Rob