Commit graph

599157 commits

Author SHA1 Message Date
Linux Build Service Account
9da06237e8 Merge "Merge android-4.4.129 (b1c4836) into msm-4.4" 2018-05-02 13:38:40 -07:00
Linux Build Service Account
6fa93fc89f Merge "ANDROID: sound: rawmidi: Hold lock around realloc" 2018-05-02 13:38:38 -07:00
Linux Build Service Account
c4afe0cea6 Merge "msm: ipa: using debug logging instead of error logging" 2018-05-02 13:38:37 -07:00
Linux Build Service Account
db7e413924 Merge "mmc: core: power cycle card when sd card switch voltage operation fails" 2018-05-02 13:38:37 -07:00
Linux Build Service Account
02a4346ae7 Merge "mmc: card: WARN_ON in cmdq completion context" 2018-05-02 13:38:35 -07:00
Linux Build Service Account
29bde1572e Merge "defconfig: Enable cellular hints in regulatory cfg80211" 2018-05-02 13:38:34 -07:00
Daniel Rosenberg
742017e8de ANDROID: sound: rawmidi: Hold lock around realloc
The SNDRV_RAWMIDI_STREAM_{OUTPUT,INPUT} ioctls may reallocate
runtime->buffer while other kernel threads are accessing it.  If the
underlying krealloc() call frees the original buffer, then this can turn
into a use-after-free.

Most of these accesses happen while the thread is holding runtime->lock,
and can be fixed by just holding the same lock while replacing
runtime->buffer, however we can't hold this spinlock while
snd_rawmidi_kernel_{read1,write1} are copying to/from userspace.  We
need to add and acquire a new mutex to prevent this from happening
concurrently with reallocation.  We hold this mutex during the entire
reallocation process, to also prevent multiple concurrent reallocations
leading to a double-free.

Signed-off-by: Daniel Rosenberg <drosen@google.com>
bug: 64315347
Change-Id: I05764d4f1a38f373eb7c0ac1c98607ee5ff0eded
[dcagle@codeaurora.org: Resolve trivial merge conflict]
Git-repo: https://android.googlesource.com/kernel/msm
Git-commit: d7193540482d11ff0ad3a07fc18717811641c6eb
Signed-off-by: Dennis Cagle <dcagle@codeaurora.org>
2018-05-02 05:13:18 -07:00
Linux Build Service Account
cb0e8e7c96 Merge "leds: qpnp-flash-v2: Modify current code calculation" 2018-05-02 04:54:41 -07:00
Linux Build Service Account
bf8090cf06 Merge "hab: import/export between remote buffer and dmafd" 2018-05-02 04:54:40 -07:00
Linux Build Service Account
2542cb864f Merge "i2c-msm-v2: Add support for suspend to disk" 2018-05-02 04:54:39 -07:00
Linux Build Service Account
aab4834f1e Merge "diag: Validate query dci event and log mask size properly" 2018-05-02 04:54:38 -07:00
Linux Build Service Account
c38b834398 Merge "Merge android-4.4.128 (89904cc) into msm-4.4" 2018-05-02 04:54:37 -07:00
Linux Build Service Account
1c294945bc Merge "usb: gadget: ffs: Multi-instance fix for use after free case" 2018-05-02 04:54:36 -07:00
Linux Build Service Account
b0b4c8bfd4 Merge "tracing: always define trace_{irq,preempt}_{enable_disable}" 2018-05-02 04:54:35 -07:00
Linux Build Service Account
e16f4fa16b Merge "cpuidle: lpm-levels: Fix snprintf string format" 2018-05-02 04:54:33 -07:00
Linux Build Service Account
ff39bce7b8 Merge "soc: qcom: rpm_stats: Fix snprintf string format" 2018-05-02 04:54:32 -07:00
Mohammed Javid
f01d00d213 msm: ipa: using debug logging instead of error logging
Adding code changes to controlling logs printing
on the console changing error logging to debug logging

Change-Id: I35f4c0e3380ad700899808d9cd6c260befb8be8f
Acked-by: Ashok Vuyyuru <avuyyuru@qti.qualcomm.com>
Signed-off-by: Mohammed Javid <mjavid@codeaurora.org>
2018-05-02 03:24:26 -07:00
Ram Prakash Gupta
7716fb9b8f mmc: core: power cycle card when sd card switch voltage operation fails
As per the sd card spec, mmc need to power cycle sd card in case sd
card voltage switch operation fails. Currently we are directly going
for low speed mode without power cycle, which is in violation of sd
card spec. Now we will retry for 10 times in case timeout happens
while switching voltage and at last, in case, it did not succeed in
switching sd card voltage, mmc would go for low speed mode.

Change-Id: Icece08732b8d52104e0890dce81ad16844265edd
Signed-off-by: Ram Prakash Gupta <rampraka@codeaurora.org>
2018-05-02 15:14:25 +05:30
Pradeep P V K
4c4c2ded21 mmc: card: WARN_ON in cmdq completion context
Due to command queuing, there is a possibility of servicing
completion of multiple requests from hw irq context. So in
this case, hw irq will launch softirq for all requests which
were completed (irrespective of whether it was success or failure).

If one of the requests failed, then the softirq corresponding
to error ed request will set current cmdq state to CMDQ_STATE_ERR.
Because of this, subsequent completion softirqs for successful
requests will BUG_ON.

We should let higher layers know of completion of successful
requests. Hence change the BUG_ON to WARN_ON and skip
blk_end_request() only if the corresponding request has
an error (instead of checking if the cmdq state is in error)

Change-Id: Ieb7f9d12ba04b6ab6499bf29f3716b0ddfb880fb
Signed-off-by: Pradeep P V K <ppvk@codeaurora.org>
2018-05-02 00:04:40 -07:00
Linux Build Service Account
d1507b1236 Merge "usb: dwc3-msm: Resume PHY before notify_connect on start_host" 2018-05-01 17:00:40 -07:00
Linux Build Service Account
6934044c51 Merge "ASoC: msm: move tdm grp mgt to afe for anc support" 2018-05-01 17:00:37 -07:00
Amar Singhal
2f15a9ac96 defconfig: Enable cellular hints in regulatory cfg80211
The user-space may send regulatory hint that has cellular sub-type
enabled. To process such events, enable
CONFIG_CFG80211_REG_CELLULAR_HINTS.

Signed-off-by: Amar Singhal <asinghal@codeaurora.org>
Change-Id: I79aceece8e7f17bbcf8186b03c74d82be82c5a4c
CRs-Fixed: 2201959
2018-05-01 16:38:48 -07:00
Linux Build Service Account
2223ffa69b Merge "drm/msm/sde: increase gpu input fence timeout to 10 seconds" 2018-05-01 06:26:41 -07:00
Linux Build Service Account
e6e01da7c4 Merge "drm: msm: add uevent handler to release pipes" 2018-05-01 06:26:39 -07:00
Linux Build Service Account
8517b96791 Merge "drm: msm: add early splash support on triple displays" 2018-05-01 06:26:38 -07:00
Linux Build Service Account
f43d6a5263 Merge "msm: ipa: rmnet: Make code changes with respect to CR#2046006" 2018-05-01 06:26:37 -07:00
Linux Build Service Account
f7b7bdea5a Merge "Revert "adv7481: return error when PLL lock fails"" 2018-05-01 06:26:36 -07:00
Linux Build Service Account
58d23d8d65 Merge "ath10k: update wowlan config and rekey data store method" 2018-05-01 06:26:35 -07:00
Linux Build Service Account
aa6d4b9770 Merge "net: ipc_router: Remove wakeup-source for Sensor ports" 2018-05-01 06:26:34 -07:00
Linux Build Service Account
0af3c13aa0 Merge "ASoC: msm: Update channel mixer weight mixer control" 2018-05-01 06:26:32 -07:00
Linux Build Service Account
036d89dd56 Merge "soc: msm: add apr sensor domain support" 2018-05-01 06:26:31 -07:00
Linux Build Service Account
7df7eae8eb Merge "audio: qdsp6v2: add retry when EAGAIN for habmm_socket_recv" 2018-05-01 06:26:28 -07:00
Linux Build Service Account
b98369d69b Merge "msm: camera: sensor: Adjust csiphy skew filter setting" 2018-04-30 21:09:08 -07:00
Linux Build Service Account
b09928fabb Merge "msm: camera: Change data type of data rate" 2018-04-30 21:09:06 -07:00
Linux Build Service Account
1a61dab660 Merge "esoc: Use standard reset time for mdm9x55 atomic reset" 2018-04-30 21:09:02 -07:00
Mohammed Javid
4987fb136c msm: ipa: rmnet: Make code changes with respect to CR#2046006
Check for CAP_NET_ADMIN capability of the user
space application who tries to access rmnet driver IOCTL.

Change-Id: If6bb4b54659306c5103b5e34bf02c7234c851e0a
CRs-Fixed: 2226355
Signed-off-by: Mohammed Javid <mjavid@codeaurora.org>
2018-04-30 00:07:34 -07:00
Vijay kumar Tumati
f35c51fe09 msm: camera: sensor: Adjust csiphy skew filter setting
Change camera csiphy skew filter setting to match HPG.

Change-Id: I21d63daa95bd1901b6343e7ff47f05e259a1a8a1
Signed-off-by: Vijay kumar Tumati <vtumati@codeaurora.org>
2018-04-30 10:41:26 +05:30
Linux Build Service Account
866d379212 Merge "msm: Allocate fd with O_CLOEXEC flag" 2018-04-29 21:09:50 -07:00
Linux Build Service Account
8d9b6ddf04 Merge "ASoC: msm: update listen service dai to low latency pcm" 2018-04-29 21:09:49 -07:00
Linux Build Service Account
5282e9782d Merge "clk: qcom: Retrieve pre_div from freq_tbl for shared RCG" 2018-04-29 21:09:46 -07:00
Sachin Bhayare
b2edddb0e7 msm: Allocate fd with O_CLOEXEC flag
(cherry-pick from 'commit 580ec70acac4 ("fbdev: msm: Allocate fd
 with O_CLOEXEC flag")') and made similar changes
for MDP3.

When fd is requested during get_metadata call, create
fd using O_CLOEXEC flag.

Change-Id: Iaa55927ac04b019ea45fbdfe9c64b10d1f0e3ceb
Signed-off-by: Nirmal Abraham <nabrah@codeaurora.org>
Signed-off-by: Sachin Bhayare <sachin.bhayare@codeaurora.org>
2018-04-27 14:18:05 +05:30
Suprith Malligere Shankaregowda
0f6827e465 Revert "adv7481: return error when PLL lock fails"
This reverts commit 44d8abb6e0.

If we return error on PLL lock failure, it results in open_stream
failure for TIF. So, if we open the TV app first and then connect
HDMI cable, it will not start streaming. Therefore reverting this
change.

Change-Id: Ic99a6986a3138bc3abb9e65eb598a743f1634c5c
Signed-off-by: Suprith Malligere Shankaregowda <supgow@codeaurora.org>
2018-04-26 23:56:40 -07:00
Samyukta Mogily
fd4aade756 msm: camera: Change data type of data rate
Change data rate to uint64, to ensure that the value sent
to kernel is not corrupted.

Change-Id: I692c1c3e591cbac24931078e0fb8938900fc991c
Signed-off-by: Samyukta Mogily <smogily@codeaurora.org>
2018-04-27 10:28:51 +05:30
Subbaraman Narayanamurthy
a228cb4e8b leds: qpnp-flash-v2: Modify current code calculation
Currently, the code calculated for a desired target current and
IRES is rounded up since DIV_ROUND_UP is used in the calculation.
With a higher IRES (12.5 mA), code can be configured to a higher
value. Fix this by using DIV_ROUND_CLOSEST so that the optimal
code can be obtained.

Change-Id: I51c1b15fff3ff2a23cb256f2ae1d341f5271adf2
Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
2018-04-26 13:07:08 -07:00
Ajay Agarwal
19ca45e5ff usb: dwc3-msm: Resume PHY before notify_connect on start_host
Currently as a part of host cable connection, we are notifying
cable connect to phy driver first and then resuming the PHY. This
leads to bus resume case running instead of the cable connect
case resume, hence the phy driver does not vote for the LDOs. As
a result, PHY goes into bad state. Fix this by first resuming PHY
so that cable connect case resume runs.

Change-Id: Ica5b16e420c38b920688b86a24af396644487a6b
Signed-off-by: Ajay Agarwal <ajaya@codeaurora.org>
2018-04-26 18:46:45 +05:30
Yajun Li
0866bef74d hab: import/export between remote buffer and dmafd
currently hab only supports importing remote buffer
to cpu address, which can't be shared to other process.
Therefore we add dma_buf import/export function in hab

Change-Id: I156c925d7c0cefef5bf146ad8cff38de9c4b3bee
Signed-off-by: Yajun Li <yajunl@codeaurora.org>
2018-04-26 18:36:09 +08:00
Hardik Arya
31c280fe34 diag: Validate query dci event and log mask size properly
Currently there is possibility of out-of-bound read due to
incorrect validation of received dci event and log mask for
query. The patch update the validation for the same.

Change-Id: I4266eb0f69fdbfa48c5aacc17744dec83995e9e6
Signed-off-by: Hardik Arya <harya@codeaurora.org>
2018-04-25 08:43:24 -07:00
Sarada Prasanna Garnayak
c3e91de9c5 ath10k: update wowlan config and rekey data store method
In wow suspend method clean up the old configured wow events
before enabling the WLAN offloads and wakeup wow events.

The rekey data set ops is not part of the ieee80211 power
management ops so remove the rekey data set method from wow
and add it in ath10k mac layer.

CRs-Fixed: 2226944
Change-Id: Ida7592097f949734b5880c470845780295a695af
Signed-off-by: Sarada Prasanna Garnayak <sgarna@codeaurora.org>
2018-04-25 03:07:11 -07:00
Arun Kumar Neelakantam
3da30a8cb3 net: ipc_router: Remove wakeup-source for Sensor ports
In high speed sensor data stream case system is not entering into
suspend state due to edge and port specific wake-up sources.

Add flag to check and avoid the wakeup sources for all sensor ports.

CRs-Fixed: 2196601
Change-Id: Ibf642619b969925dc96e8a57e11f7e349b85c024
Signed-off-by: Arun Kumar Neelakantam <aneela@codeaurora.org>
2018-04-25 11:50:11 +05:30
Srinivasarao P
ee76c85f71 Merge android-4.4.129 (b1c4836) into msm-4.4
* refs/heads/tmp-b1c4836
  Linux 4.4.129
  writeback: safer lock nesting
  fanotify: fix logic of events on child
  ext4: bugfix for mmaped pages in mpage_release_unused_pages()
  mm/filemap.c: fix NULL pointer in page_cache_tree_insert()
  mm: allow GFP_{FS,IO} for page_cache_read page cache allocation
  autofs: mount point create should honour passed in mode
  Don't leak MNT_INTERNAL away from internal mounts
  rpc_pipefs: fix double-dput()
  hypfs_kill_super(): deal with failed allocations
  jffs2_kill_sb(): deal with failed allocations
  powerpc/lib: Fix off-by-one in alternate feature patching
  powerpc/eeh: Fix enabling bridge MMIO windows
  MIPS: memset.S: Fix clobber of v1 in last_fixup
  MIPS: memset.S: Fix return of __clear_user from Lpartial_fixup
  MIPS: memset.S: EVA & fault support for small_memset
  MIPS: uaccess: Add micromips clobbers to bzero invocation
  HID: hidraw: Fix crash on HIDIOCGFEATURE with a destroyed device
  ALSA: hda - New VIA controller suppor no-snoop path
  ALSA: rawmidi: Fix missing input substream checks in compat ioctls
  ALSA: line6: Use correct endpoint type for midi output
  ext4: fix deadlock between inline_data and ext4_expand_extra_isize_ea()
  ext4: fix crashes in dioread_nolock mode
  drm/radeon: Fix PCIe lane width calculation
  ext4: don't allow r/w mounts if metadata blocks overlap the superblock
  vfio/pci: Virtualize Maximum Read Request Size
  vfio/pci: Virtualize Maximum Payload Size
  vfio-pci: Virtualize PCIe & AF FLR
  ALSA: pcm: Fix endless loop for XRUN recovery in OSS emulation
  ALSA: pcm: Fix mutex unbalance in OSS emulation ioctls
  ALSA: pcm: Return -EBUSY for OSS ioctls changing busy streams
  ALSA: pcm: Avoid potential races between OSS ioctls and read/write
  ALSA: pcm: Use ERESTARTSYS instead of EINTR in OSS emulation
  ALSA: oss: consolidate kmalloc/memset 0 call to kzalloc
  watchdog: f71808e_wdt: Fix WD_EN register read
  thermal: imx: Fix race condition in imx_thermal_probe()
  clk: bcm2835: De-assert/assert PLL reset signal when appropriate
  clk: mvebu: armada-38x: add support for missing clocks
  clk: mvebu: armada-38x: add support for 1866MHz variants
  mmc: jz4740: Fix race condition in IRQ mask update
  iommu/vt-d: Fix a potential memory leak
  um: Use POSIX ucontext_t instead of struct ucontext
  dmaengine: at_xdmac: fix rare residue corruption
  IB/srp: Fix completion vector assignment algorithm
  IB/srp: Fix srp_abort()
  ALSA: pcm: Fix UAF at PCM release via PCM timer access
  RDMA/ucma: Don't allow setting RDMA_OPTION_IB_PATH without an RDMA device
  ext4: fail ext4_iget for root directory if unallocated
  ext4: don't update checksum of new initialized bitmaps
  jbd2: if the journal is aborted then don't allow update of the log tail
  random: use a tighter cap in credit_entropy_bits_safe()
  thunderbolt: Resume control channel after hibernation image is created
  ASoC: ssm2602: Replace reg_default_raw with reg_default
  HID: core: Fix size as type u32
  HID: Fix hid_report_len usage
  powerpc/powernv: Fix OPAL NVRAM driver OPAL_BUSY loops
  powerpc/powernv: define a standard delay for OPAL_BUSY type retry loops
  powerpc/64: Fix smp_wmb barrier definition use use lwsync consistently
  powerpc/powernv: Handle unknown OPAL errors in opal_nvram_write()
  HID: i2c-hid: fix size check and type usage
  usb: dwc3: pci: Properly cleanup resource
  USB:fix USB3 devices behind USB3 hubs not resuming at hibernate thaw
  ACPI / hotplug / PCI: Check presence of slot itself in get_slot_status()
  ACPI / video: Add quirk to force acpi-video backlight on Samsung 670Z5E
  regmap: Fix reversed bounds check in regmap_raw_write()
  xen-netfront: Fix hang on device removal
  ARM: dts: at91: sama5d4: fix pinctrl compatible string
  ARM: dts: at91: at91sam9g25: fix mux-mask pinctrl property
  usb: musb: gadget: misplaced out of bounds check
  mm, slab: reschedule cache_reap() on the same CPU
  ipc/shm: fix use-after-free of shm file via remap_file_pages()
  resource: fix integer overflow at reallocation
  fs/reiserfs/journal.c: add missing resierfs_warning() arg
  ubi: Reject MLC NAND
  ubi: Fix error for write access
  ubi: fastmap: Don't flush fastmap work on detach
  ubifs: Check ubifs_wbuf_sync() return code
  tty: make n_tty_read() always abort if hangup is in progress
  x86/hweight: Don't clobber %rdi
  x86/hweight: Get rid of the special calling convention
  lan78xx: Correctly indicate invalid OTP
  slip: Check if rstate is initialized before uncompressing
  cdc_ether: flag the Cinterion AHS8 modem by gemalto as WWAN
  hwmon: (ina2xx) Fix access to uninitialized mutex
  rtl8187: Fix NULL pointer dereference in priv->conf_mutex
  getname_kernel() needs to make sure that ->name != ->iname in long case
  s390/ipl: ensure loadparm valid flag is set
  s390/qdio: don't merge ERROR output buffers
  s390/qdio: don't retry EQBS after CCQ 96
  block/loop: fix deadlock after loop_set_status
  Revert "perf tests: Decompress kernel module before objdump"
  radeon: hide pointless #warning when compile testing
  perf intel-pt: Fix timestamp following overflow
  perf intel-pt: Fix error recovery from missing TIP packet
  perf intel-pt: Fix sync_switch
  perf intel-pt: Fix overlap detection to identify consecutive buffers correctly
  parisc: Fix out of array access in match_pci_device()
  media: v4l2-compat-ioctl32: don't oops on overlay
  f2fs: check cap_resource only for data blocks
  Revert "f2fs: introduce f2fs_set_page_dirty_nobuffer"
  f2fs: clear PageError on writepage
  UPSTREAM: timer: Export destroy_hrtimer_on_stack()
  BACKPORT: dm verity: add 'check_at_most_once' option to only validate hashes once
  f2fs: call unlock_new_inode() before d_instantiate()
  f2fs: refactor read path to allow multiple postprocessing steps
  fscrypt: allow synchronous bio decryption

Change-Id: I45f4ac10734d92023b53118d83dcd6c83974a283
Signed-off-by: Srinivasarao P <spathi@codeaurora.org>
2018-04-24 19:07:57 +05:30