This is the mail archive of the ecos-patches@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

add CYGPKG_IO_PCI_CONFIGURE_INTLINE


Index: io/pci/current/ChangeLog
===================================================================
RCS file: /cvs/ecos/ecos/packages/io/pci/current/ChangeLog,v
retrieving revision 1.26
diff -u -p -5 -r1.26 ChangeLog
--- io/pci/current/ChangeLog	31 Aug 2004 20:22:14 -0000	1.26
+++ io/pci/current/ChangeLog	12 Oct 2004 13:30:15 -0000
@@ -1,5 +1,11 @@
+2004-10-12  Mark Salter  <msalter@redhat.com>
+
+	* cdl/io_pci.cdl (CYGPKG_IO_PCI_CONFIGURE_INTLINE): New option.
+	* src/pci.c (cyg_pci_translate_interrupt): Don't write INT LINE
+	register unless CYGPKG_IO_PCI_CONFIGURE_INTLINE defined.
+
 2004-08-31  Mark Salter  <msalter@redhat.com>
 
 	* src/pci.c (cyg_pci_translate_interrupt): Write vector number into
 	INT_LINE register.
 	(cyg_pci_get_device_info): Add mechanism for HALs to specify certain
Index: io/pci/current/cdl/io_pci.cdl
===================================================================
RCS file: /cvs/ecos/ecos/packages/io/pci/current/cdl/io_pci.cdl,v
retrieving revision 1.5
diff -u -p -5 -r1.5 io_pci.cdl
--- io/pci/current/cdl/io_pci.cdl	24 Feb 2003 14:24:50 -0000	1.5
+++ io/pci/current/cdl/io_pci.cdl	12 Oct 2004 13:30:15 -0000
@@ -107,7 +107,19 @@ cdl_package CYGPKG_IO_PCI {
             no_define
             calculated { "tests/pci1 tests/pci2" }
             description   "
                 This option specifies the set of tests for the PCI configuration library."
         }
+
+        cdl_option CYGPKG_IO_PCI_CONFIGURE_INTLINE {
+            display "Writeback Interrupt Line register."
+            flavor  bool
+            default_value 0
+            description   "
+                This option causes a PCI device interrupt vector to be
+                written to the Interrupt Line register in config space.
+                This is traditionally done by a BIOS so that device
+                drivers can read the interrupt vector directly from
+                device configuration space."
+        }
     }
 }
Index: io/pci/current/src/pci.c
===================================================================
RCS file: /cvs/ecos/ecos/packages/io/pci/current/src/pci.c,v
retrieving revision 1.21
diff -u -p -5 -r1.21 pci.c
--- io/pci/current/src/pci.c	31 Aug 2004 20:22:15 -0000	1.21
+++ io/pci/current/src/pci.c	12 Oct 2004 13:30:15 -0000
@@ -869,15 +869,17 @@ cyg_pci_translate_interrupt( cyg_pci_dev
 {
     cyg_uint8 bus = CYG_PCI_DEV_GET_BUS(dev_info->devid);
     cyg_uint8 devfn = CYG_PCI_DEV_GET_DEVFN(dev_info->devid);
 
     if (cyg_pcihw_translate_interrupt(bus, devfn, vec)) {
+#ifdef CYGPKG_IO_PCI_CONFIGURE_INTLINE
         // Fill in interrupt line info. This only really works for
         // platforms where assigned PCI irq numbers are less than 255.
         cyg_pcihw_write_config_uint8(bus, devfn,
                                      CYG_PCI_CFG_INT_LINE, 
                                      *vec & 0xff);
+#endif
         return true;
     }
     return false;
 }
 



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]