Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'x86-urgent-2020-11-15' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull x86 fixes from Thomas Gleixner:
"A small set of fixes for x86:

- Cure the fallout from the MSI irqdomain overhaul which missed that
the Intel IOMMU does not register virtual function devices and
therefore never reaches the point where the MSI interrupt domain is
assigned. This made the VF devices use the non-remapped MSI domain
which is trapped by the IOMMU/remap unit

- Remove an extra space in the SGI_UV architecture type procfs output
for UV5

- Remove a unused function which was missed when removing the UV BAU
TLB shootdown handler"

* tag 'x86-urgent-2020-11-15' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
iommu/vt-d: Cure VF irqdomain hickup
x86/platform/uv: Fix copied UV5 output archtype
x86/platform/uv: Drop last traces of uv_flush_tlb_others

+21 -14
-10
arch/x86/include/asm/uv/uv.h
··· 2 2 #ifndef _ASM_X86_UV_UV_H 3 3 #define _ASM_X86_UV_UV_H 4 4 5 - #include <asm/tlbflush.h> 6 - 7 5 enum uv_system_type {UV_NONE, UV_LEGACY_APIC, UV_X2APIC}; 8 - 9 - struct cpumask; 10 - struct mm_struct; 11 - struct flush_tlb_info; 12 6 13 7 #ifdef CONFIG_X86_UV 14 8 #include <linux/efi.h> ··· 38 44 static inline int is_uv_hubbed(int uv) { return 0; } 39 45 static inline void uv_cpu_init(void) { } 40 46 static inline void uv_system_init(void) { } 41 - static inline const struct cpumask * 42 - uv_flush_tlb_others(const struct cpumask *cpumask, 43 - const struct flush_tlb_info *info) 44 - { return cpumask; } 45 47 46 48 #endif /* X86_UV */ 47 49
+3 -3
arch/x86/kernel/apic/x2apic_uv_x.c
··· 33 33 static int uv_node_id; 34 34 35 35 /* Unpack AT/OEM/TABLE ID's to be NULL terminated strings */ 36 - static u8 uv_archtype[UV_AT_SIZE]; 36 + static u8 uv_archtype[UV_AT_SIZE + 1]; 37 37 static u8 oem_id[ACPI_OEM_ID_SIZE + 1]; 38 38 static u8 oem_table_id[ACPI_OEM_TABLE_ID_SIZE + 1]; 39 39 ··· 320 320 321 321 if (n > 0 && n < sizeof(uv_ate->archtype)) { 322 322 pr_info("UV: UVarchtype received from BIOS\n"); 323 - uv_stringify(UV_AT_SIZE, uv_archtype, uv_ate->archtype); 323 + uv_stringify(sizeof(uv_archtype), uv_archtype, uv_ate->archtype); 324 324 return 1; 325 325 } 326 326 return 0; ··· 378 378 if (!early_get_arch_type()) 379 379 380 380 /* If not use OEM ID for UVarchtype */ 381 - uv_stringify(UV_AT_SIZE, uv_archtype, _oem_id); 381 + uv_stringify(sizeof(uv_archtype), uv_archtype, oem_id); 382 382 383 383 /* Check if not hubbed */ 384 384 if (strncmp(uv_archtype, "SGI", 3) != 0) {
+18 -1
drivers/iommu/intel/dmar.c
··· 333 333 dmar_iommu_notify_scope_dev(info); 334 334 } 335 335 336 + static inline void vf_inherit_msi_domain(struct pci_dev *pdev) 337 + { 338 + dev_set_msi_domain(&pdev->dev, dev_get_msi_domain(&pdev->physfn->dev)); 339 + } 340 + 336 341 static int dmar_pci_bus_notifier(struct notifier_block *nb, 337 342 unsigned long action, void *data) 338 343 { ··· 347 342 /* Only care about add/remove events for physical functions. 348 343 * For VFs we actually do the lookup based on the corresponding 349 344 * PF in device_to_iommu() anyway. */ 350 - if (pdev->is_virtfn) 345 + if (pdev->is_virtfn) { 346 + /* 347 + * Ensure that the VF device inherits the irq domain of the 348 + * PF device. Ideally the device would inherit the domain 349 + * from the bus, but DMAR can have multiple units per bus 350 + * which makes this impossible. The VF 'bus' could inherit 351 + * from the PF device, but that's yet another x86'sism to 352 + * inflict on everybody else. 353 + */ 354 + if (action == BUS_NOTIFY_ADD_DEVICE) 355 + vf_inherit_msi_domain(pdev); 351 356 return NOTIFY_DONE; 357 + } 358 + 352 359 if (action != BUS_NOTIFY_ADD_DEVICE && 353 360 action != BUS_NOTIFY_REMOVED_DEVICE) 354 361 return NOTIFY_DONE;