Skip to content

Commit

Permalink
leds-ss4200: Check pci_enable_device return
Browse files Browse the repository at this point in the history
pci_enable_result is defined using the __must_check macro but
leds-ss4200 is not checking the return value.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Dave Hansen <dave@sr71.net>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
  • Loading branch information
Dave Hansen authored and Richard Purdie committed Dec 16, 2009
1 parent 7f131cf commit 09a46db
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions drivers/leds/leds-ss4200.c
Original file line number Diff line number Diff line change
Expand Up @@ -344,10 +344,14 @@ static struct pci_dev *nas_gpio_pci_dev;
static int __devinit ich7_lpc_probe(struct pci_dev *dev,
const struct pci_device_id *id)
{
int status = 0;
int status;
u32 gc = 0;

pci_enable_device(dev);
status = pci_enable_device(dev);
if (status) {
dev_err(&dev->dev, "pci_enable_device failed\n");
return;
}

nas_gpio_pci_dev = dev;
status = pci_read_config_dword(dev, PMBASE, &g_pm_io_base);
Expand Down

0 comments on commit 09a46db

Please sign in to comment.