patch-2.4.22 linux-2.4.22/drivers/gsc/dino.c
Next file: linux-2.4.22/drivers/hotplug/Config.in
Previous file: linux-2.4.22/drivers/char/wdt_pci.c
Back to the patch index
Back to the overall index
- Lines: 44
- Date:
2003-08-25 04:44:41.000000000 -0700
- Orig file:
linux-2.4.21/drivers/gsc/dino.c
- Orig date:
2003-06-13 07:51:33.000000000 -0700
diff -urN linux-2.4.21/drivers/gsc/dino.c linux-2.4.22/drivers/gsc/dino.c
@@ -251,7 +251,7 @@
unsigned long flags; \
spin_lock_irqsave(&(DINO_DEV(d)->dinosaur_pen), flags); \
/* tell HW which IO Port address */ \
- gsc_writel((u32) addr & ~3, d->base_addr + DINO_PCI_ADDR); \
+ gsc_writel((u32) addr, d->base_addr + DINO_PCI_ADDR); \
/* generate I/O PORT read cycle */ \
v = gsc_read##type(d->base_addr+DINO_IO_DATA+(addr&mask)); \
spin_unlock_irqrestore(&(DINO_DEV(d)->dinosaur_pen), flags); \
@@ -267,7 +267,7 @@
{ \
unsigned long flags; \
spin_lock_irqsave(&(DINO_DEV(d)->dinosaur_pen), flags); \
- /* tell HW which CFG address */ \
+ /* tell HW which IO port address */ \
gsc_writel((u32) addr, d->base_addr + DINO_PCI_ADDR); \
/* generate cfg write cycle */ \
gsc_write##type(cpu_to_le##size(val), d->base_addr+DINO_IO_DATA+(addr&mask)); \
@@ -467,7 +467,7 @@
* to set up the addresses of the devices on this bus.
*/
#define _8MB 0x00800000UL
-static void __init
+static int __init
dino_card_setup(struct pci_bus *bus, unsigned long base_addr)
{
int i;
@@ -482,7 +482,7 @@
0xffffffffffffffffUL &~ _8MB, _8MB,
NULL, NULL) < 0) {
printk(KERN_WARNING "Dino: Failed to allocate memory region\n");
- return;
+ return -ENODEV;
}
bus->resource[1] = res;
bus->resource[0] = &(dino_dev->hba.io_space);
@@ -495,6 +495,7 @@
gsc_writel(1 << i, base_addr + DINO_IO_ADDR_EN);
pcibios_assign_unassigned_resources(bus);
+ return 0;
}
static void __init
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)