Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp1439568rwb; Fri, 19 Aug 2022 03:53:29 -0700 (PDT) X-Google-Smtp-Source: AA6agR6RgEy0DAcLInpW0mJDhE7iQBcilfEAJcz04FVESnDnJdK1gpV5PJ9EMXvV5dLAtpyr0B75 X-Received: by 2002:a17:907:2d8c:b0:730:f00f:7ab0 with SMTP id gt12-20020a1709072d8c00b00730f00f7ab0mr4334135ejc.611.1660906409224; Fri, 19 Aug 2022 03:53:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660906409; cv=none; d=google.com; s=arc-20160816; b=w7Jz79OgQ0Za53avwoZxpFbigSqrD7t3KVTvSrI7MJ5dIaTZwbA0l2vUXFo2qRTYVl sTKDj2y+pRSsZO4cLM0HPkv9QfXRMQHJCbVKm2Vc4BxEGsxZfYqd34LwWyNMrIp7hjv0 Qqh0LzRC8486rXlkEFC+/f6R3eXyFC7w9EpxefHWtxPd8CXXbBahJ6yEcf64LV+qTvbb w5kzlZamP9+Vlu2PnmyeFt9f2sM0IK78HH2V0KxvdEVKVOTooruI/mcyNCrKF1QBqfn6 3+Py8BcFkOCwf8lC2fVnlST74ksGKFNMyMACG7bL7NeB/QDBRy/A+VmZFcsXiwqWRRUn F12Q== 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=f2ymQP7RmyhXPwARC3XVO6qBIZTzz5uQg4wHNvMjs4k=; b=KWEuIXqk2ncMOdQTaxUQs+iK7K5K/vqU9Cy7IzwLBdaNR3wcf4rJsULtJZHk2gSpy2 bMX14aOpf7BMHV2gH+tLLZPBspCXPbZvusEwfoEMQ9Z9hAUMSN5SireEPuhZ/4xhHAeJ ouWvPZa+UHaJHXpEWvkhBJg52MsL1V7SMCKCpBivIjAozrbwk7mPM08ZAfqHGdxJMFV1 cVA3dJlG8C92/Kb1gEBmQuqj2/YOrmgS5sc96tRyYFVAo7vDtIu34xQ6V+u+Ywa/of6+ 4H+uF7CP85fMYpsQDqlVLyi3qQXIXYL0K/YIg1HTK0YkHoW0ON323mEUvImE09LKZ2jQ +eZg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=mCPV9jMI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id o3-20020a056402438300b0044605636faesi3542469edc.102.2022.08.19.03.53.03; Fri, 19 Aug 2022 03:53:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=mCPV9jMI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 S1346735AbiHSKmj (ORCPT + 99 others); Fri, 19 Aug 2022 06:42:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36298 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1348047AbiHSKme (ORCPT ); Fri, 19 Aug 2022 06:42:34 -0400 Received: from mail-qk1-x733.google.com (mail-qk1-x733.google.com [IPv6:2607:f8b0:4864:20::733]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A28CDF4CA0; Fri, 19 Aug 2022 03:42:33 -0700 (PDT) Received: by mail-qk1-x733.google.com with SMTP id i7so2955085qka.13; Fri, 19 Aug 2022 03:42:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc; bh=f2ymQP7RmyhXPwARC3XVO6qBIZTzz5uQg4wHNvMjs4k=; b=mCPV9jMIz0oEOjkgWgvplWqWmlNVEzR7uz2r+pEAWeJebgT5MlOkKaYqLlHrZqOp/j DS66dyi7cQXSSGVTIZI+OkYU/TO5792CsscgKhvoNQotG9iQsj74xQZHbxxvIjlsh324 suGLCjyMSgI7tJGzT2qcyk875xTTh2jUH/cDV/FKtvVES1qzNorrJ2ilrb72mNnyhHCs XlCGcB/E2y5Vk1hieATHIc0jW5jyZ+MmmckyahgUPanINAQB7GfwgataySfYaV06gnyW swMrPb6rO52QIgVPAVwlU+PzEDw1+uyNmuH3VOFysKrhqsjdEwd1jw+IDWM+Zr86qZ0H iRRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc; bh=f2ymQP7RmyhXPwARC3XVO6qBIZTzz5uQg4wHNvMjs4k=; b=iFxA+t2UONJUCFQZUxmb6LJZSftkBc/IHijHl++EouU88Ccs61rU9z/hW2zG5q33rA 6PJekYsxW4TerAlaBOKn0762UMT90td7NkKZ9H8H/mQ8kcOCO3zH2mYpCVon5OeQjcFI ns2ra9CWwkdGwG1yi4Ll2/P7RITuiFOiUOwVVn4SC3v3wL2McSoRdYB7e9XWSiZz7kCf gUV6ms3KmyysqrBvKDlJBWa+esIWpXjx0FXAri5H6H+UKWuZVVX1usmbm5bITmYtl4rm WMq5r1u7Ga5VXpCOrWVba0G720mpJxIM7q4gzxCC7ijiDH4zs6V+DZ0I+fgIWqUWZOSa 03ZQ== X-Gm-Message-State: ACgBeo2VCB/LJfVbP/HBfa75Vf4XHEu8dZq/9lSJ9ieIQscTp0yKb9T1 sm7LJXR1ZvNC+7gPIYVc0rmYm8VyTnofUjtRavM= X-Received: by 2002:a05:620a:254d:b0:6ab:84b8:25eb with SMTP id s13-20020a05620a254d00b006ab84b825ebmr4710971qko.383.1660905752738; Fri, 19 Aug 2022 03:42:32 -0700 (PDT) MIME-Version: 1.0 References: <1660649244-146842-1-git-send-email-john.garry@huawei.com> <1660649244-146842-2-git-send-email-john.garry@huawei.com> <366fd6dd-a37b-c7ec-fdf3-48f8a8024834@huawei.com> <1a5eb773-d339-512f-7c5d-7ef72edfdc2a@huawei.com> In-Reply-To: <1a5eb773-d339-512f-7c5d-7ef72edfdc2a@huawei.com> From: Andy Shevchenko Date: Fri, 19 Aug 2022 13:41:56 +0300 Message-ID: Subject: Re: [PATCH PoC 1/3] ACPI / PNP: Don't add enumeration_by_parent devices To: John Garry Cc: Len Brown , "Rafael J. Wysocki" , ACPI Devel Maling List , Linux Kernel Mailing List , Linuxarm Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Aug 19, 2022 at 1:20 PM John Garry wrote: > On 19/08/2022 10:59, Andy Shevchenko wrote: > >>>> The hisi_lpc driver also creates a platform device serial device for uart, > >>>> which is the actual uart which we want to use - see > >>>> hisi_lpc_acpi_add_child(). That function does not check > >>>> physical_node_count value, but acpi_create_platform_device() does check it. > >>>> So if we were to move hisi_lpc_acpi_add_child() across to use > >>>> acpi_create_platform_device(), then the change in this patch is required to > >>>> not create the PNP binding (so that physical_node_count is not set from > >>>> PNP probe). > >>> Hmm... The flag, as I interpret it, is equal to "the device in > >>> question is a peripheral device to the non-discoverable bus, such as > >>> SPI, I2C or UART". I.o.w. I do not see how PNP suits here. So, from my > >>> point of view it seems like an abuse of the flag. Not sure the current > >>> state of affairs in ACPI glue layer regarding this, though. > >> Sorry, but I'm not following you here. Which flag are you talking about? > > "enumerated by parent". > > ok, right. So I thought that PNP0501 was a standard cid to describe > 16550-compat UART which may be on an LPC bus. And a LPC bus is > non-discoverable, like SPI or I2C, which also use "enumerated by parent". While in most cases the above-mentioned UART is sitting behind LPC and what you described is all true, there is no requirement to have PNP0501 to be tightened to LPC bus, so it can be any 8250-compatible UART. > Indeed, using PNP0501 for hisi lpc UART cid would be without problem, > apart from the fact that we can't do all the PIO translation (so need > "enumerated by parent"). Yeah, what can use this flag is the UART peer that connects to the UART host, but it's a bit grey, because UART is p2p and not controller-peripheral type of connections. -- With Best Regards, Andy Shevchenko