| 110 | } |
| 111 | |
| 112 | static void msi_write_enable(struct rt_pci_device *pdev, rt_bool_t enable) |
| 113 | { |
| 114 | rt_uint16_t msgctl; |
| 115 | |
| 116 | rt_pci_read_config_u16(pdev, pdev->msi_cap + PCIR_MSI_CTRL, &msgctl); |
| 117 | |
| 118 | msgctl &= ~PCIM_MSICTRL_MSI_ENABLE; |
| 119 | |
| 120 | if (enable) |
| 121 | { |
| 122 | msgctl |= PCIM_MSICTRL_MSI_ENABLE; |
| 123 | } |
| 124 | |
| 125 | rt_pci_write_config_u16(pdev, pdev->msi_cap + PCIR_MSI_CTRL, msgctl); |
| 126 | } |
| 127 | |
| 128 | static void msi_affinity_init(struct rt_pci_msi_desc *desc, int msi_index, |
| 129 | rt_bitmap_t *cpumasks) |
no test coverage detected