aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/controller/pci-hyperv.c
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2018-08-05 10:39:29 -0400
committerThomas Gleixner <tglx@linutronix.de>2018-08-05 10:39:29 -0400
commitf2701b77bbd992f3df4631de8493f21db0830452 (patch)
treeb05b2bf8b47002ae81c79aaa9de2a311b8ee075e /drivers/pci/controller/pci-hyperv.c
parent18b57ce2eb8c8b9a24174a89250cf5f57c76ecdc (diff)
parentacb1872577b346bd15ab3a3f8dff780d6cca4b70 (diff)
Merge 4.18-rc7 into master to pick up the KVM dependcy
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'drivers/pci/controller/pci-hyperv.c')
-rw-r--r--drivers/pci/controller/pci-hyperv.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/pci/controller/pci-hyperv.c b/drivers/pci/controller/pci-hyperv.c
index fadc305533d9..d4d4a55f09f8 100644
--- a/drivers/pci/controller/pci-hyperv.c
+++ b/drivers/pci/controller/pci-hyperv.c
@@ -1074,6 +1074,7 @@ static void hv_compose_msi_msg(struct irq_data *data, struct msi_msg *msg)
1074 struct pci_bus *pbus; 1074 struct pci_bus *pbus;
1075 struct pci_dev *pdev; 1075 struct pci_dev *pdev;
1076 struct cpumask *dest; 1076 struct cpumask *dest;
1077 unsigned long flags;
1077 struct compose_comp_ctxt comp; 1078 struct compose_comp_ctxt comp;
1078 struct tran_int_desc *int_desc; 1079 struct tran_int_desc *int_desc;
1079 struct { 1080 struct {
@@ -1165,14 +1166,15 @@ static void hv_compose_msi_msg(struct irq_data *data, struct msi_msg *msg)
1165 * the channel callback directly when channel->target_cpu is 1166 * the channel callback directly when channel->target_cpu is
1166 * the current CPU. When the higher level interrupt code 1167 * the current CPU. When the higher level interrupt code
1167 * calls us with interrupt enabled, let's add the 1168 * calls us with interrupt enabled, let's add the
1168 * local_bh_disable()/enable() to avoid race. 1169 * local_irq_save()/restore() to avoid race:
1170 * hv_pci_onchannelcallback() can also run in tasklet.
1169 */ 1171 */
1170 local_bh_disable(); 1172 local_irq_save(flags);
1171 1173
1172 if (hbus->hdev->channel->target_cpu == smp_processor_id()) 1174 if (hbus->hdev->channel->target_cpu == smp_processor_id())
1173 hv_pci_onchannelcallback(hbus); 1175 hv_pci_onchannelcallback(hbus);
1174 1176
1175 local_bh_enable(); 1177 local_irq_restore(flags);
1176 1178
1177 if (hpdev->state == hv_pcichild_ejecting) { 1179 if (hpdev->state == hv_pcichild_ejecting) {
1178 dev_err_once(&hbus->hdev->device, 1180 dev_err_once(&hbus->hdev->device,