summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorSrinivasarao P <spathi@codeaurora.org>2019-09-11 10:07:56 +0530
committerSrinivasarao P <spathi@codeaurora.org>2019-09-11 10:08:38 +0530
commit79fcbddd736bfcc606ccf4555d0879af3b20da26 (patch)
tree34256cc6ab4ab9ce971a80b91127579b3157d916 /arch
parent4bd32b7ba749e007b5e2962e12c13afadee1e193 (diff)
parentda6d147f98d198c3d9059e609ca492a4824d9ef5 (diff)
Merge android-4.4.192 (da6d147) into msm-4.4
* refs/heads/tmp-da6d147 Linux 4.4.192 net: stmmac: dwmac-rk: Don't fail if phy regulator is absent net: fix skb use after free in netpoll Revert "x86/apic: Include the LDR when clearing out APIC registers" spi: bcm2835aux: fix corruptions for longer spi transfers spi: bcm2835aux: remove dangerous uncontrolled read of fifo spi: bcm2835aux: unifying code between polling and interrupt driven code spi: bcm2835aux: ensure interrupts are enabled for shared handler libceph: allow ceph_buffer_put() to receive a NULL ceph_buffer KVM: arm/arm64: Only skip MMIO insn once ceph: fix buffer free while holding i_ceph_lock in __ceph_setxattr() IB/mlx4: Fix memory leaks Tools: hv: kvp: eliminate 'may be used uninitialized' warning ravb: Fix use-after-free ravb_tstamp_skb wimax/i2400m: fix a memory leak bug net: kalmia: fix memory leaks cx82310_eth: fix a memory leak bug net: myri10ge: fix memory leaks cxgb4: fix a memory leak bug gpio: Fix build error of function redefinition ibmveth: Convert multicast list size for little-endian system Bluetooth: btqca: Add a short delay before downloading the NVM net: tc35815: Explicitly check NET_IP_ALIGN is not zero in tc35815_rx net: tundra: tsi108: use spin_lock_irqsave instead of spin_lock_irq in IRQ context Change-Id: I5109a0608129d345ee2a16a1315ef2edab23545a Signed-off-by: Srinivasarao P <spathi@codeaurora.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/kvm/mmio.c7
-rw-r--r--arch/x86/kernel/apic/apic.c4
2 files changed, 7 insertions, 4 deletions
diff --git a/arch/arm/kvm/mmio.c b/arch/arm/kvm/mmio.c
index ae61e2ea7255..d2efc033ef8b 100644
--- a/arch/arm/kvm/mmio.c
+++ b/arch/arm/kvm/mmio.c
@@ -98,6 +98,12 @@ int kvm_handle_mmio_return(struct kvm_vcpu *vcpu, struct kvm_run *run)
unsigned int len;
int mask;
+ /* Detect an already handled MMIO return */
+ if (unlikely(!vcpu->mmio_needed))
+ return 0;
+
+ vcpu->mmio_needed = 0;
+
if (!run->mmio.is_write) {
len = run->mmio.len;
if (len > sizeof(unsigned long))
@@ -206,6 +212,7 @@ int io_mem_abort(struct kvm_vcpu *vcpu, struct kvm_run *run,
run->mmio.is_write = is_write;
run->mmio.phys_addr = fault_ipa;
run->mmio.len = len;
+ vcpu->mmio_needed = 1;
if (!ret) {
/* We handled the access successfully in the kernel. */
diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c
index 80c94fc8ad5a..834d1b5b4355 100644
--- a/arch/x86/kernel/apic/apic.c
+++ b/arch/x86/kernel/apic/apic.c
@@ -1031,10 +1031,6 @@ void clear_local_APIC(void)
apic_write(APIC_LVT0, v | APIC_LVT_MASKED);
v = apic_read(APIC_LVT1);
apic_write(APIC_LVT1, v | APIC_LVT_MASKED);
- if (!x2apic_enabled()) {
- v = apic_read(APIC_LDR) & ~APIC_LDR_MASK;
- apic_write(APIC_LDR, v);
- }
if (maxlvt >= 4) {
v = apic_read(APIC_LVTPC);
apic_write(APIC_LVTPC, v | APIC_LVT_MASKED);