PATCH for rtems - pci.h

Ralf Rösch ralf.roesch at cantastic.de
Thu Apr 13 14:48:37 UTC 2006


My mips-rtems tool chain produces linker errors when pci_x_y_z functions
are declared "extern",
defining them "static" solves the problem. See patch below.

Regards
Ralf


Index: cpukit/include/rtems/pci.h
===================================================================
RCS file: /usr1/CVS/rtems/cpukit/include/rtems/pci.h,v
retrieving revision 1.7
diff -u -r1.7 pci.h
--- cpukit/include/rtems/pci.h    4 May 2005 19:42:12 -0000    1.7
+++ cpukit/include/rtems/pci.h    13 Apr 2006 14:02:57 -0000
@@ -1130,7 +1130,7 @@

extern pci_config BSP_pci_configuration;

-extern inline int
+static inline int
pci_read_config_byte(
   unsigned char bus,
   unsigned char slot,
@@ -1142,7 +1142,7 @@
             bus, slot, function, where, val);
}

-extern inline int
+static inline int
pci_read_config_word(
   unsigned char bus,
   unsigned char slot,
@@ -1154,7 +1154,7 @@
              bus, slot, function, where, val);
}

-extern inline int
+static inline int
pci_read_config_dword(
   unsigned char bus,
   unsigned char slot,
@@ -1165,7 +1165,7 @@
   return BSP_pci_configuration.pci_functions->read_config_dword(bus,
slot, function, where, val);
}

-extern inline int
+static inline int
pci_write_config_byte(
   unsigned char bus,
   unsigned char slot,
@@ -1177,7 +1177,7 @@
              bus, slot, function, where, val);
}

-extern inline int
+static inline int
pci_write_config_word(
   unsigned char bus,
   unsigned char slot,
@@ -1189,7 +1189,7 @@
               bus, slot, function, where, val);
}

-extern inline int
+static inline int
pci_write_config_dword(
   unsigned char bus,
   unsigned char slot,






More information about the users mailing list