OSDN Git Service

aec62xx: Fix kernel oops in driver's probe function
authorAleksandar Radovanovic <biblbroks@sezampro.yu>
Tue, 27 Nov 2007 20:35:53 +0000 (21:35 +0100)
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Tue, 27 Nov 2007 20:35:53 +0000 (21:35 +0100)
commitb48d08177fe635a549aaf63eef508be1de069ebf
tree2d116ba187f198c46b2083b3ef3bca2a3c5ab6d6
parent8266105b15192177ac732ab8a27b315dc9291100
aec62xx: Fix kernel oops in driver's probe function

Add pci_enable_device() to aec62xx probe function
before doing any I/O.

Original probe function tries to read from device's
PCI region 4 before calling ide_setup_pci_device().
Since the device is not enabled at this point,
on machines that have no firmware PCI initialization
(e.g. ASUS WL-700gE router), corresponding PCI BAR
is 0 and the following inb() causes a kernel oops.

Signed-off-by: Aleksandar Radovanovic <biblbroks@sezampro.yu>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
drivers/ide/pci/aec62xx.c