XHCI Use named bits in PIC command register config
All checks were successful
Build ISO image / build-and-deploy (push) Successful in 1m36s
Build documentation / build-and-deploy (push) Successful in 42s

This commit is contained in:
2026-04-30 19:10:10 +02:00
parent 616ba40a14
commit 05d03716cb

View File

@@ -36,7 +36,10 @@ bool pci_xhci_init(struct proc* proc, struct reschedule_ctx* rctx, struct pci_in
uint16_t pci_cmd = pci_read16(pci_info.bus, pci_info.slot, pci_info.func, PCI_COMMAND); uint16_t pci_cmd = pci_read16(pci_info.bus, pci_info.slot, pci_info.func, PCI_COMMAND);
uint16_t new_cmd = (pci_cmd | (1 << 1) | (1 << 2)) & ~(1 << 10); uint16_t new_cmd = pci_cmd;
new_cmd |= (1 << PCI_CMD_MEMSPACE);
new_cmd |= (1 << PCI_CMD_BUSMASTER);
new_cmd &= (1 << PCI_CMD_INTRDISABLE);
if (pci_cmd != new_cmd) { if (pci_cmd != new_cmd) {
pci_write16(pci_info.bus, pci_info.slot, pci_info.func, PCI_COMMAND, new_cmd); pci_write16(pci_info.bus, pci_info.slot, pci_info.func, PCI_COMMAND, new_cmd);