Commit 7a41dcb
iommu/amd: Set the pgsize_bitmap correctly
When using io_pgtable the correct pgsize_bitmap is stored in the cfg, both
v1_alloc_pgtable() and v2_alloc_pgtable() set it correctly.
This fixes a bug where the v2 pgtable had the wrong pgsize as
protection_domain_init_v2() would set it and then do_iommu_domain_alloc()
immediately resets it.
Remove the confusing ops.pgsize_bitmap since that is not used if the
driver sets domain.pgsize_bitmap.
Fixes: 1342881 ("iommu/amd: Add domain_alloc_user based domain allocation")
Reviewed-by: Vasant Hegde <[email protected]>
Signed-off-by: Jason Gunthorpe <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Joerg Roedel <[email protected]>1 parent b0a6c88 commit 7a41dcb
1 file changed
+4
-24
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2264 | 2264 | | |
2265 | 2265 | | |
2266 | 2266 | | |
2267 | | - | |
2268 | | - | |
2269 | | - | |
2270 | | - | |
2271 | | - | |
2272 | | - | |
2273 | | - | |
2274 | | - | |
2275 | | - | |
2276 | | - | |
2277 | | - | |
2278 | | - | |
2279 | | - | |
2280 | | - | |
2281 | 2267 | | |
2282 | 2268 | | |
2283 | 2269 | | |
2284 | 2270 | | |
2285 | 2271 | | |
2286 | | - | |
2287 | 2272 | | |
2288 | 2273 | | |
2289 | 2274 | | |
| |||
2319 | 2304 | | |
2320 | 2305 | | |
2321 | 2306 | | |
2322 | | - | |
| 2307 | + | |
2323 | 2308 | | |
2324 | 2309 | | |
2325 | | - | |
| 2310 | + | |
2326 | 2311 | | |
2327 | 2312 | | |
2328 | | - | |
2329 | | - | |
2330 | | - | |
2331 | | - | |
2332 | | - | |
2333 | 2313 | | |
| 2314 | + | |
2334 | 2315 | | |
2335 | 2316 | | |
2336 | 2317 | | |
| |||
2383 | 2364 | | |
2384 | 2365 | | |
2385 | 2366 | | |
| 2367 | + | |
2386 | 2368 | | |
2387 | 2369 | | |
2388 | 2370 | | |
2389 | | - | |
2390 | 2371 | | |
2391 | 2372 | | |
2392 | 2373 | | |
| |||
2869 | 2850 | | |
2870 | 2851 | | |
2871 | 2852 | | |
2872 | | - | |
2873 | 2853 | | |
2874 | 2854 | | |
2875 | 2855 | | |
| |||
0 commit comments