Since the newbus changes, I have had kernel compile failures, due to
the fact that I don't have any old style PCI drivers configured
on my system.  By #ifdef'ing out the code that wraperises the
old driver code.

Diffs are as follows (this requires defining "NOOLDPCIDRIVERS").

Obviously, this code should eventually all disappear, but is there
a more elegant way of doing things at the moment?  Are these
changes worth committing?


*** pci.c.orig  Mon Apr 19 08:21:08 1999
--- pci.c       Wed Apr 21 23:41:33 1999
***************
*** 846,851 ****
--- 846,852 ----
  
  #include "pci_if.h"
  
+ #if !defined(NOOLDPCIDRIVERS)
  /*
   * A simple driver to wrap the old pci driver mechanism for back-compat.
   */
***************
*** 921,928 ****
--- 922,932 ----
        { 0, 0 }
  };
  
+ #endif
+ 
  static devclass_t     pci_devclass;
  
+ #if !defined(NOOLDPCIDRIVERS)
  /*
   * Create a new style driver around each old pci driver.
   */
***************
*** 946,951 ****
--- 950,956 ----
                devclass_add_driver(pci_devclass, driver);
        }
  }
+ #endif
  
  /*
   * New style pci driver.  Parent device is either a pci-host-bridge or a
***************
*** 1330,1336 ****
--- 1335,1343 ----
  {
        switch (what) {
        case MOD_LOAD:
+ #if !defined(NOOLDPCIDRIVERS)
                pci_wrap_old_drivers();
+ #endif
                break;
  
        case MOD_UNLOAD:



*** userconfig.c.orig   Wed Apr 21 23:45:28 1999
--- userconfig.c        Wed Apr 21 23:41:22 1999
***************
*** 570,575 ****
--- 570,576 ----
                insdev(&scratch,ap[i].id_enabled?active:inactive);
        }
  #if NPCI > 0
+ #if !defined(NOOLDPCIDRIVERS)
      for (i = 0; i < pcidevice_set.ls_length; i++)
      {
        if (pcidevice_set.ls_items[i])
***************
*** 595,600 ****
--- 596,602 ----
            }
        }
      }
+ #endif
  #endif        /* NPCI > 0 */
  }
  
-- 
Geoff Rehmet, The Internet Solution - Infrastructure 
tel: +27-11-283-5462, fax: +27-11-283-5401 mobile: +27-83-292-5800
email: geo...@is.co.za 
URL: http://www.is.co.za 


To Unsubscribe: send mail to majord...@freebsd.org
with "unsubscribe freebsd-current" in the body of the message

Reply via email to