- pci_reg_t intr = pci_read_cspace(pci_base, 0x3c);
-
- struct pci_device* device = vzalloc(sizeof(struct pci_device));
- device->class_info = class;
- device->device_info = devinfo;
- device->cspace_base = pci_base;
- device->intr_info = intr;
-
- device_create(&device->dev, pcidev_cat, DEV_IFSYS, NULL);
-
- pci_probe_msi_info(device);
- pci_probe_bar_info(device);
-
- kappendf("%s (dev.%x:%x:%x) \n",
- pos->devdef.name,
- pos->devdef.class.fn_grp,
- pos->devdef.class.device,
- pos->devdef.class.variant);
-
- if (!pos->devdef.init_for) {
- kappendf(KERROR "bad def\n");
- goto fail;
+ if (!pos->devdef.bind) {
+ kprintf(KERROR "pci_loc:%x, (%xh:%xh.%d) unbindable\n",
+ loc,
+ pos->devdef.class.fn_grp,
+ pos->devdef.class.device,
+ pos->devdef.class.variant);
+ goto done;