github.com/jspc/eggos@v0.5.1-0.20221028160421-556c75c878a5/drivers/pci/driver.go (about)

     1  package pci
     2  
     3  var drivers = map[string]Driver{}
     4  
     5  type Driver interface {
     6  	Name() string
     7  	Init(dev *Device) error
     8  	Idents() []Identity
     9  	Intr()
    10  }
    11  
    12  func Register(driver Driver) {
    13  	drivers[driver.Name()] = driver
    14  }