git://scm.lunaixsky.com
/
lunaix-os.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
feat: support user-spcae pci rescan
[lunaix-os.git]
/
lunaix-os
/
hal
/
ahci
/
ahci.c
diff --git
a/lunaix-os/hal/ahci/ahci.c
b/lunaix-os/hal/ahci/ahci.c
index 8794baba37684d43fd4f460918dd0bf6a2e480ce..61ea95b511dc28a5d658bd9d19d951aae94e153b 100644
(file)
--- a/
lunaix-os/hal/ahci/ahci.c
+++ b/
lunaix-os/hal/ahci/ahci.c
@@
-200,7
+200,7
@@
ahci_driver_init(struct device_def* def, struct device* dev)
ahci_register_device(hbadev);
}
ahci_register_device(hbadev);
}
-
dev->underlay = ahci_drv
;
+
pci_bind_instance(ahci_dev, ahci_drv)
;
return 0;
}
return 0;
}
@@
-444,9
+444,9
@@
achi_register_ops(struct hba_port* port)
static struct pci_device_def ahcidef = {
.dev_class = AHCI_HBA_CLASS,
static struct pci_device_def ahcidef = {
.dev_class = AHCI_HBA_CLASS,
- .ident_mask =
0x0
,
+ .ident_mask =
PCI_MATCH_ANY
,
.devdef = { .class = DEVCLASS(DEVIF_PCI, DEVFN_STORAGE, DEV_SATA),
.name = "Serial ATA Controller",
.devdef = { .class = DEVCLASS(DEVIF_PCI, DEVFN_STORAGE, DEV_SATA),
.name = "Serial ATA Controller",
- .
init_for
= ahci_driver_init }
+ .
bind
= ahci_driver_init }
};
};
-EXPORT_
DEVICE(ahci, &ahcidef.devdef, load_pci_probe
);
\ No newline at end of file
+EXPORT_
PCI_DEVICE(ahci, &ahcidef
);
\ No newline at end of file