|
17 | 17 | offloadCfg = pCfg.offload; |
18 | 18 | reverseSyncCfg = pCfg.reverseSync; |
19 | 19 | primeEnabled = syncCfg.enable || reverseSyncCfg.enable || offloadCfg.enable; |
20 | | - busIDType = lib.types.strMatching "([[:print:]]+[:@][0-9]{1,3}:[0-9]{1,2}:[0-9])?"; |
| 20 | + busIDType = lib.types.strMatching "([[:print:]]+:[0-9]{1,3}(@[0-9]{1,10})?:[0-9]{1,2}:[0-9])?"; |
21 | 21 | ibtSupport = useOpenModules || (nvidia_x11.ibtSupport or false); |
22 | 22 | settingsFormat = pkgs.formats.keyValue { }; |
23 | 23 | in |
|
120 | 120 | prime.nvidiaBusId = lib.mkOption { |
121 | 121 | type = busIDType; |
122 | 122 | default = ""; |
123 | | - example = "PCI:1:0:0"; |
| 123 | + example = "PCI:1@0:0:0"; |
124 | 124 | description = '' |
125 | 125 | Bus ID of the NVIDIA GPU. You can find it using lspci; for example if lspci |
126 | | - shows the NVIDIA GPU at "01:00.0", set this option to "PCI:1:0:0". |
| 126 | + shows the NVIDIA GPU at "0001:02:03.4", set this option to "PCI:2@1:3:4". |
| 127 | +
|
| 128 | + lspci might omit the PCI domain (0001 in above example) if it is zero. |
| 129 | + In which case, use "@0" instead. |
| 130 | +
|
| 131 | + Please be aware that this option takes decimal address while lspci reports |
| 132 | + hexadecimal address. So for device at domain "10000", use "@65536". |
127 | 133 | ''; |
128 | 134 | }; |
129 | 135 |
|
130 | 136 | prime.intelBusId = lib.mkOption { |
131 | 137 | type = busIDType; |
132 | 138 | default = ""; |
133 | | - example = "PCI:0:2:0"; |
| 139 | + example = "PCI:0@0:2:0"; |
134 | 140 | description = '' |
135 | 141 | Bus ID of the Intel GPU. You can find it using lspci; for example if lspci |
136 | | - shows the Intel GPU at "00:02.0", set this option to "PCI:0:2:0". |
| 142 | + shows the Intel GPU at "0001:02:03.4", set this option to "PCI:2@1:3:4". |
| 143 | +
|
| 144 | + lspci might omit the PCI domain (0001 in above example) if it is zero. |
| 145 | + In which case, use "@0" instead. |
| 146 | +
|
| 147 | + Please be aware that this option takes decimal address while lspci reports |
| 148 | + hexadecimal address. So for device at domain "10000", use "@65536". |
137 | 149 | ''; |
138 | 150 | }; |
139 | 151 |
|
140 | 152 | prime.amdgpuBusId = lib.mkOption { |
141 | 153 | type = busIDType; |
142 | 154 | default = ""; |
143 | | - example = "PCI:4:0:0"; |
| 155 | + example = "PCI:4@0:0:0"; |
144 | 156 | description = '' |
145 | 157 | Bus ID of the AMD APU. You can find it using lspci; for example if lspci |
146 | | - shows the AMD APU at "04:00.0", set this option to "PCI:4:0:0". |
| 158 | + shows the AMD APU at "0001:02:03.4", set this option to "PCI:2@1:3:4". |
| 159 | +
|
| 160 | + lspci might omit the PCI domain (0001 in above example) if it is zero. |
| 161 | + In which case, use "@0" instead. |
| 162 | +
|
| 163 | + Please be aware that this option takes decimal address while lspci reports |
| 164 | + hexadecimal address. So for device at domain "10000", use "@65536". |
147 | 165 | ''; |
148 | 166 | }; |
149 | 167 |
|
|
0 commit comments