From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Warren Date: Wed, 21 Oct 2015 14:16:40 -0600 Subject: [U-Boot] [PATCH 2/8] dm: pci: Avoid a driver model build error with CONFIG_CMD_PCI_ENUM In-Reply-To: <1445104205-4079-3-git-send-email-sjg@chromium.org> References: <1445104205-4079-1-git-send-email-sjg@chromium.org> <1445104205-4079-3-git-send-email-sjg@chromium.org> Message-ID: <5627F2A8.7080703@wwwdotorg.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 10/17/2015 11:49 AM, Simon Glass wrote: > This is not supported with driver model, so print a message instead of > generating a build error. Rescanning PCI is not yet implemented. > diff --git a/common/cmd_pci.c b/common/cmd_pci.c > @@ -457,7 +457,11 @@ static int do_pci(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) > return pci_cfg_display(bdf, addr, size, value); > #ifdef CONFIG_CMD_PCI_ENUM > case 'e': > +# ifdef CONFIG_DM_PCI > + printf("This command is not yet supported with driver model\n"); > +# else > pci_init(); > +# endif That feature is enabled on most/all Tegra boards with PCI support. Hopefully nobody will miss it; I guess I haven't used it so I don't object to this change. However, wouldn't it be better to remove CONFIG_CMD_PCI_ENUM from the config header rather than leaving the command enabled yet non-functional? Or are you planning on implementing this path in the near future?