From ee8abf783dd36f65440fd782ad16f9768631d998 Mon Sep 17 00:00:00 2001 From: Yinghai Lu Date: Wed, 17 Nov 2010 12:10:40 -0800 Subject: PCI: Skip id checking if no id is passed Will get warning when pci stub driver is built-in kenel like: pci-stub: invalid id string "" So stop early if no id is passed. Signed-off-by: Yinghai Lu Signed-off-by: Jesse Barnes --- drivers/pci/pci-stub.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'drivers/pci/pci-stub.c') diff --git a/drivers/pci/pci-stub.c b/drivers/pci/pci-stub.c index f7b68ca6cc98..4c0336b31caf 100644 --- a/drivers/pci/pci-stub.c +++ b/drivers/pci/pci-stub.c @@ -47,6 +47,10 @@ static int __init pci_stub_init(void) if (rc) return rc; + /* no ids passed actually */ + if (ids[0] == '\0') + return 0; + /* add ids specified in the module parameter */ p = ids; while ((id = strsep(&p, ","))) { -- cgit v1.2.3-59-g8ed1b