Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp388930pxt; Thu, 5 Aug 2021 02:09:10 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxuN4SnLYnXfjmZiG2yB/UwfNpxVE4R4FJMIFj3sHiMOR/0dKmzMcLuI3T/NEC8h1EjqUgr X-Received: by 2002:a17:906:7191:: with SMTP id h17mr3882783ejk.330.1628154550579; Thu, 05 Aug 2021 02:09:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628154550; cv=none; d=google.com; s=arc-20160816; b=aHXM+2Qbriqox7x5mQlg9E00iWov6F+AO09cXzJgSESlS2yXQIgKUQ+LM/4vxeLkBE MpgRvr56gQ3+tQogZbdEsCfaELS5EUPdz5fUA6BWYaoC6rNlWTjBWfh2lDkPIrfKwWnI u6E+7fpMQ0iP8UE1oS4ZbofMhEi2rHgg8mUGqa4p5tjGQt7VyRHTwLux5cBx9D5sWiPy EOOwU/Tpd/mhCx8nv13pGnjIhpAo1TPv7MvCCNdD6+74KeQ7JSpXb1RQnvODjo7bwoBn LCqC0xIZujNPZPibgcNhHfJtKJr0SlWt2shpVE99A8wZoB3iVrBpJ+3dNLSbqRI7lQzm KgLA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=l79yvUcRgsQQ1Fch0XXZwpKuDTQPWsiGia3k2eieT5E=; b=SYhXRoRTmaVnGk2lRaWpD76ExP3L+ZPtGSUd7Q8fQNvtckF3sEzE7HHFtGkhWV17my leMjemAQHk80MaDVUC2HZhwV9pZtx4RqIh0vneubc9SZguC35I9hpV/4uZj1365+dVrp TJspY9f8K+8WGz0Yes04yIkzktEGlLWVxF43W9r6D8Sixnk6VxDUBDgkRGzXKRkkkUQZ y9XnsBGmEPqpqVqLvzC+rM57XSBD3uvq/Q4fM04VQOVh1JDxs/snH5kcdyNOjIRUtG2P TPoxv4hXXz2gId2QQuZq/yowtIKvMUDmjt/j+/SEm4f5qfzjoh8y/O6BHukl7ghDGWnk yqIg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="PEelsw/2"; 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id um11si4978320ejb.419.2021.08.05.02.08.47; Thu, 05 Aug 2021 02:09:10 -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=@kernel.org header.s=k20201202 header.b="PEelsw/2"; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239531AbhHEI30 (ORCPT + 99 others); Thu, 5 Aug 2021 04:29:26 -0400 Received: from mail.kernel.org ([198.145.29.99]:44516 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234796AbhHEI3W (ORCPT ); Thu, 5 Aug 2021 04:29:22 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 19371610A0; Thu, 5 Aug 2021 08:29:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1628152149; bh=Xg0egegKAE3+y3A+acHFXR93G2BYuupBkGB74QQ+zRM=; h=From:To:Cc:Subject:Date:From; b=PEelsw/28D9DPhzFZY0q0agg1OYvad8oXCvZq6IB7mEQpkvcvv5itECn+flypwzB9 /KdSav5U0A/+3pML0562aJmFIQ9/M+LBoLvENhDj4j9FJRabckE/+HMKPOCT6TLDeK /hF5r6LjhGUbMdtg8AS6YmjjOqPFVI9HA4sCrfYsAS2JWTILoSFMvKrVPT08JYLJqz m7+L1st2mQDMK6iEwMlrO9YUhx1u/WsDH1akvkQzIPybkujnyZ2zHnXG23K1ULRv/y 9jCqtI3r8d0/gsv2052xuQeMe4JypG7jN5xIeRga6mH116VkbITCu1NZVY4sIUiLJa 5DNu9f3pgPyWQ== Received: by mail.kernel.org with local (Exim 4.94.2) (envelope-from ) id 1mBYkP-001DuS-Qf; Thu, 05 Aug 2021 10:29:01 +0200 From: Mauro Carvalho Chehab To: Rob Herring Cc: linuxarm@huawei.com, mauro.chehab@huawei.com, Mauro Carvalho Chehab , linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org Subject: [PATCH 0/3] Fix handling of multi-level OF nodes Date: Thu, 5 Aug 2021 10:28:57 +0200 Message-Id: X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: Mauro Carvalho Chehab Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Rob, This series address the issues related to not add all of_node data at sysfs. Patch 1 is the real fix. Patch 2 just changes the order of init, in order to allow printing what's happening when registering a device; Patch 3 is just debug. With patch 1 applied, the sysfs nodes seem to match the PCI configuration: $ find /sys/devices/platform/soc/f4000000.pcie/ -name of_node /sys/devices/platform/soc/f4000000.pcie/of_node /sys/devices/platform/soc/f4000000.pcie/pci0000:00/0000:00:00.0/of_node /sys/devices/platform/soc/f4000000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/0000:02:07.0/of_node /sys/devices/platform/soc/f4000000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/0000:02:07.0/pci_bus/0000:06/of_node /sys/devices/platform/soc/f4000000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/pci_bus/0000:02/of_node /sys/devices/platform/soc/f4000000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/0000:02:05.0/of_node /sys/devices/platform/soc/f4000000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/0000:02:05.0/pci_bus/0000:05/of_node /sys/devices/platform/soc/f4000000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/0000:02:01.0/of_node /sys/devices/platform/soc/f4000000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/0000:02:01.0/pci_bus/0000:03/of_node /sys/devices/platform/soc/f4000000.pcie/pci0000:00/0000:00:00.0/pci_bus/0000:01/of_node /sys/devices/platform/soc/f4000000.pcie/pci0000:00/pci_bus/0000:00/of_node Mauro Carvalho Chehab (3): PCI: of: Fix handling of multi-level PCI devices PCI: of: Setup PCI before setting the OF node PCI: of: Add some debug printks to track problems with of_node setup drivers/pci/of.c | 9 +++++++++ drivers/pci/probe.c | 5 ++--- 2 files changed, 11 insertions(+), 3 deletions(-) -- 2.31.1