summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorSrinivasarao P <spathi@codeaurora.org>2017-12-26 17:23:34 +0530
committerSrinivasarao P <spathi@codeaurora.org>2017-12-26 17:29:34 +0530
commit202fde333dc0065e2f2ca3539f5a06a9126f896d (patch)
tree61e9ae04c1d693ff0c498520a37bf7618ce5baea /kernel
parentbb6e8073112e0a7dd53e2cbd166b20f585a5bb79 (diff)
parent03d4af8271682742aa21bbbf3032a839764f591a (diff)
Merge android-4.4.98 (3d4af8) into msm-4.4
* refs/heads/tmp-03d4af8 Linux 4.4.98 PKCS#7: fix unitialized boolean 'want' x86/oprofile/ppro: Do not use __this_cpu*() in preemptible context can: c_can: don't indicate triple sampling support for D_CAN can: sun4i: handle overrun in RX FIFO rbd: use GFP_NOIO for parent stat and data requests drm/vmwgfx: Fix Ubuntu 17.10 Wayland black screen issue Input: elan_i2c - add ELAN060C to the ACPI table MIPS: AR7: Ensure that serial ports are properly set up MIPS: AR7: Defer registration of GPIO tools: firmware: check for distro fallback udev cancel rule selftests: firmware: send expected errors to /dev/null selftests: firmware: add empty string and async tests test: firmware_class: report errors properly on failure MIPS: SMP: Fix deadlock & online race MIPS: Fix race on setting and getting cpu_online_mask MIPS: SMP: Use a completion event to signal CPU up MIPS: Fix CM region target definitions MIPS: microMIPS: Fix incorrect mask in insn_table_MM ALSA: seq: Avoid invalid lockdep class warning ALSA: seq: Fix OSS sysex delivery in OSS emulation ARM: 8720/1: ensure dump_instr() checks addr_limit KEYS: fix NULL pointer dereference during ASN.1 parsing [ver #2] crypto: x86/sha1-mb - fix panic due to unaligned access workqueue: Fix NULL pointer dereference x86/uaccess, sched/preempt: Verify access_ok() context platform/x86: hp-wmi: Do not shadow error values platform/x86: hp-wmi: Fix error value for hp_wmi_tablet_state KEYS: trusted: fix writing past end of buffer in trusted_read() KEYS: trusted: sanitize all key material cdc_ncm: Set NTB format again after altsetting switch for Huawei devices platform/x86: hp-wmi: Fix detection for dock and tablet mode net: dsa: select NET_SWITCHDEV s390/qeth: issue STARTLAN as first IPA command IB/ipoib: Change list_del to list_del_init in the tx object Input: mpr121 - set missing event capability Input: mpr121 - handle multiple bits change of status register IPsec: do not ignore crypto err in ah4 input netfilter: nft_meta: deal with PACKET_LOOPBACK in netdev family usb: hcd: initialize hcd->flags to 0 when rm hcd serial: sh-sci: Fix register offsets for the IRDA serial port phy: increase size of MII_BUS_ID_SIZE and bus_id iio: trigger: free trigger resource correctly crypto: vmx - disable preemption to enable vsx in aes_ctr.c ARM: omap2plus_defconfig: Fix probe errors on UARTs 5 and 6 powerpc/corenet: explicitly disable the SDHC controller on kmcoge4 iommu/arm-smmu-v3: Clear prior settings when updating STEs KVM: PPC: Book 3S: XICS: correct the real mode ICP rejecting counter drm: drm_minor_register(): Clean up debugfs on failure xen/netback: set default upper limit of tx/rx queues to 8 PCI: mvebu: Handle changes to the bridge windows while enabled video: fbdev: pmag-ba-fb: Remove bad `__init' annotation adv7604: Initialize drive strength to default when using DT ANDROID: binder: clarify deferred thread work. FROMLIST: arm64: Avoid aligning normal memory pointers in __memcpy_{to,from}io Conflicts: arch/arm64/kernel/io.c Change-Id: I992fcf368dbc672ad7d6ae31e87f289f4d7df2bf Signed-off-by: Srinivasarao P <spathi@codeaurora.org>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/workqueue_internal.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/workqueue_internal.h b/kernel/workqueue_internal.h
index 45215870ac6c..3fa9c146fccb 100644
--- a/kernel/workqueue_internal.h
+++ b/kernel/workqueue_internal.h
@@ -9,6 +9,7 @@
#include <linux/workqueue.h>
#include <linux/kthread.h>
+#include <linux/preempt.h>
struct worker_pool;
@@ -59,7 +60,7 @@ struct worker {
*/
static inline struct worker *current_wq_worker(void)
{
- if (current->flags & PF_WQ_WORKER)
+ if (in_task() && (current->flags & PF_WQ_WORKER))
return kthread_data(current);
return NULL;
}