Commit graph

892,914 commits

Author SHA1 Message Date
Jack Pham
79b9a2c111 usb: gadget: f_accessory: avoid requeuing write req if disconnected
There is a race condition when a write operation is blocked
waiting for an available request and the function is disabled
due to disconnection or reset. usb_ep_disable() is called from
acc_function_disable() and causes the UDC to call the pending
requests' completions, which will wake up the writer thread and
proceed to call usb_ep_queue() before the endpoint is fully
disabled. The UDC driver may not handle this and could allow
the request to be requeued inadvertently. In DWC3's case, this
allows the HW to attempt a transfer with stale TRBs that point
to invalid DMA buffers.

Let's ensure the function driver acts as a good citizen and handle
it by moving the check for dev->offline || dev->disconnected to
after the wait_event to make sure the endpoint is enabled before
attempting to queue another request.

Change-Id: I1aa005e0c1e3ed1e1d814ff79496b70fdb401571
Signed-off-by: Jack Pham <jackp@codeaurora.org>
2020-11-20 09:38:26 -08:00
Veerabhadrarao Badiganti
1fd4b879d4 mmc: sdhci-msm: Add dbg_state sysfs
Add dbg_state sysfs to facilitate trace instance to be enabled
only on debug flavor builds.

Change-Id: I6524e6184e2a81b2e39b0f0338e4d8a9b7989542
Signed-off-by: Veerabhadrarao Badiganti <vbadigan@codeaurora.org>
2020-11-20 21:10:10 +05:30
Elson Roy Serrao
7098fc425e defconfig: Enable USB PD on sdxlemur
Enable USB PD config flag on sdxlemur to add
PD support.

Change-Id: If7a91abb4c6d1b0f368a931c9c686012a310eb99
Signed-off-by: Elson Roy Serrao <eserrao@codeaurora.org>
2020-11-20 07:30:07 -08:00
Sarannya S
5078b14d69 soc: qcom: glink_probe: Defer SSR unregister
Calling SSR unregister for other peripherals from glink_ssr device remove
call back results in deadlock if multiple SSRs happens in parallel.

SSR unregister is defer to other worker to avoid notifier SRCU deadlock.

Change-Id: Ifa5c461201eec4b4beb8bf405bd0a2904a2cc90f
Signed-off-by: Arun Kumar Neelakantam <aneela@codeaurora.org>
Signed-off-by: Sarannya S <sarannya@codeaurora.org>
2020-11-20 18:41:30 +05:30
Jeya R
e42e8c386e msm: ADSPRPC: Add start and end timer for map and buffer
Get kernel time during start and end of map create
to keep track of time taken to create map. The time
variables are added as member of map struct. Same
time variables are added for buffers also.

Change-Id: I6454f5b60bec1a24a43ea1b7539ec45ba5358f2e
Acked-by: Ekansh Gupta <ekangupt@qti.qualcomm.com>
Signed-off-by: Jeya R <jeyr@codeaurora.org>
2020-11-20 04:53:23 -08:00
Odelu Kukatla
79a4656918 interconnect: qcom: Fix the issue with uninitialized variable for Holi
There is potential issue where uninitialized variable can be
used, so fix it.

Change-Id: If725b7efc2979889415da2673c68d4be71e41631
Signed-off-by: Odelu Kukatla <okukatla@codeaurora.org>
2020-11-20 15:59:03 +05:30
Saurabh Sahu
2089519099 dt-bindings: clock: Add support for clock ids for MONACO
Add clock ids for GCC/DISPCC/GPUCC for clients to be able
to request for clocks from these clock controllers for
monaco.

Change-Id: Ie09a5a7a5fd1101fb863e836a0e554198e699511
Signed-off-by: Saurabh Sahu <sausah@codeaurora.org>
2020-11-20 15:53:23 +05:30
Naman Padhiar
599bec2e07 icnss2: Avoid race between soc wake release threads
Avoid race condition between soc wake release from queue
context and host driver context.

Change-Id: I6e20a9a8781f65447e89160ff4e362a04ec4ec5c
Signed-off-by: Naman Padhiar <npadhiar@codeaurora.org>
2020-11-20 01:54:27 -08:00
Naman Padhiar
af089f3e48 icnss2: Add support for host triggered recovery
Send force FW crash message to FW via smp2p to trigger
SSR. This will be used by host to recover FW bad state.

Change-Id: If840a94c9102acb775fc67e6fd2098e9ae3b8a33
Signed-off-by: Naman Padhiar <npadhiar@codeaurora.org>
2020-11-20 01:53:25 -08:00
Sarthak Garg
fceb94ab29 mmc: sdhci-msm: Add NULL check before dereferencing var_info
Add NULL check before dereferencing var_info.

Change-Id: I8f3acd69118bedd0b156cb8764d3d172ac4576cc
Signed-off-by: Sarthak Garg <sartgarg@codeaurora.org>
2020-11-20 13:40:02 +05:30
qctecmdr
6a4a49544d Merge "msm: net: Add support to packet threshold events." 2020-11-20 00:08:15 -08:00
qctecmdr
370af6a367 Merge "usb: dwc3: Resume parent before resuming child device while in host mode" 2020-11-20 00:08:14 -08:00
qctecmdr
871acc5263 Merge "mmc: host: Handle config dependencies for cqhci crypto" 2020-11-20 00:08:14 -08:00
Sarthak Garg
ca95a2bdb5 mmc: core: Dereference dev pointer after NULL check
Dereference dev pointer after NULL check.

Change-Id: I39bc175eb53ff486577672b1c3175475bbf394e2
Signed-off-by: Sarthak Garg <sartgarg@codeaurora.org>
2020-11-20 13:32:59 +05:30
Mohammed Javid
a604ebfe67 msm: ipa: CV2X header file changes
For QMI dpm port to open, control manager needs
to know about usb/mhi ep details corresponding to
RMNET and RMNET_CV2X tethering.
IPA driver has all endpoint info at one place.
 - provide IOCTL interface to get ep_pair info.
 - Add support for new dtsi entry specifying auto config.
 - Add support in ipa-usb driver for rmnet_cv2x.

Change-Id: Ia5ec0df955ef7794ca992129dab538f65af36211
Signed-off-by: Mohammed Javid <mjavid@codeaurora.org>
2020-11-20 12:28:18 +05:30
Aman Gupta
4c85ebff25 net: Kconfig changes to enable sfe feature
Shortcut forward Engine (SFE) is a software packet accelerator
It depends on packet tuple entries based on conntrack information
The change adds its config entry in net Kconfig.

Change-Id: Ied018e83e26f69682590989242b333754f367556
Signed-off-by: Aman Gupta <amangupt@codeaurora.org>
2020-11-19 21:43:13 -08:00
Sarthak Garg
b54b4aac61 mtd: msm_qpic_nand: Update bus voting with the new icb framework
Update bus voting for sdxlemur nand driver with the new icb framework.

Change-Id: I59108be9545780adc5f9040f97ae0d07536cc6bf
Signed-off-by: Sarthak Garg <sartgarg@codeaurora.org>
2020-11-20 10:46:05 +05:30
Nitin Rawat
3b52295bc6 scsi: ufs: update pm_lvl during probe only when current pm_lvl is invalid
As per current code, pm_lvl is read from DT on every probe
during system resume after suspend.

Therefore, rpm_lvl and spm_lvl updated by sysfs will be overwritten
with the pm_lvl read from DT during probe after resume from
system suspend.

To avoid this read pm_lvl from DT only when current pm_lvl
is invalid or during the first ufs probe after boot.

Change-Id: I059d574a81d0e0f7cee8b6492e495819579a2d4c
Signed-off-by: Nitin Rawat <nitirawa@codeaurora.org>
2020-11-20 10:29:02 +05:30
qctecmdr
6151ff0c6a Merge "defconfig: enable QGKI & GKI apis of msm_performance driver" 2020-11-19 20:09:40 -08:00
Subbaraman Narayanamurthy
0d4a229e92 defconfig: sdxlemur: Enable CONFIG_SPMI_MSM_PMIC_ARB{_DEBUG}
Enable SPMI debug bus driver which is useful for writing to PMIC
peripheral registers over debug bus on devices when the fuse is
not blown. While at it, enable CONFIG_SPMI_MSM_PMIC_ARB as well
explicitly though it's selected for sdxlemur already.

Change-Id: I8d04c96efcdb089f8950e57fd1b152cd1cc5a84f
Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
2020-11-19 20:01:42 -08:00
Yue Ma
130ead3ce6 cnss2: Group dev_boot debugfs handling by contexts
To handle dev_boot debugfs, group the API calls based on contexts
to avoid exiting because of irrelevant invalid context.

Change-Id: I3d031ca53fc2739ae4947a40c4b3b0e7f7a74bb3
Signed-off-by: Yue Ma <yuem@codeaurora.org>
2020-11-19 14:54:52 -08:00
qctecmdr
e0f5b51058 Merge "clk: qcom: clk-debug: Add support for debug clock API's" 2020-11-19 14:10:19 -08:00
qctecmdr
d4154e6672 Merge "pinctrl: qcom: Add support for Monaco SoC pin control" 2020-11-19 14:10:18 -08:00
qctecmdr
815d09f601 Merge "net: Changes to support Shortcut Forward Engine" 2020-11-19 14:10:17 -08:00
qctecmdr
1d6b783303 Merge "bridge: Add bridge API to access the bridge slave port" 2020-11-19 14:10:16 -08:00
qctecmdr
e61a99a64e Merge "msm: kgsl: Disable gpu_llc flags by default" 2020-11-19 14:10:16 -08:00
qctecmdr
f74ca3bb50 Merge "arm64: defconfig: Enable CRYPTO_SHA1_ARM64_CE algorithm" 2020-11-19 14:10:16 -08:00
Yue Ma
5d627425fd cnss2: Check device status before suspending PCIe bus
Avoid suspending PCIe bus from QMI send put path if device is
already down.

Change-Id: I3ac7e37af3f81ec9f4ad8ae84de111a730a1f90f
Signed-off-by: Yue Ma <yuem@codeaurora.org>
2020-11-19 12:11:08 -08:00
Puranam V G Tejaswi
a18eecda80 msm: kgsl: Poll GDCSR for holi target to ensure CX collapse
The regulator_is_enabled() API doesn't guarantee that CX gdsc has
collapsed at hardware. There could be a vote on the GDSC from another
subsystem like TZ. So poll the CX GDSCR register to ensure that CX has
indeed collapsed.

Change-Id: Ic07cde5ba3442689cb73b33fe57c3d4371cb9565
Signed-off-by: Puranam V G Tejaswi <pvgtejas@codeaurora.org>
2020-11-20 01:35:49 +05:30
Puranam V G Tejaswi
f021cc3c5d msm: kgsl: Halt GBIF before moving to NAP state
It has been observed that without gmu_clk, any active transactions will
cause that transaction to be stuck in QSMMU. As of now we don't halt
GBIF when moving to NAP state. So there is a possibility of transactions
inflight when gmu_clk is gated. This will cause transactions to be stuck
in QSMMU forever. This can eventually lead to GPU hang or TLB sync
timeout. So halt GBIF before moving to NAP.

Change-Id: I13bbe3b21b327d0d5c962bb2133c6d5d0f3a43c3
Signed-off-by: Puranam V G Tejaswi <pvgtejas@codeaurora.org>
2020-11-20 01:35:35 +05:30
Puranam V G Tejaswi
8e0b5e5aaa msm: kgsl: Move deassert_gbif_halt to a6xx specific space
deassert_gbif_halt is needed only for the a6xx targets that use
clear_pending_transactions. So move deassert_gbif_halt to a6xx specific
space. This helps to provide some clarity and avoid gmu and gbif
related checks.

Change-Id: If46fa22a54737c2dbc35205318ed75ead351760a
Signed-off-by: Puranam V G Tejaswi <pvgtejas@codeaurora.org>
2020-11-20 01:35:32 +05:30
Puranam V G Tejaswi
b2cdc0d790 msm: kgsl: Don't deassert GBIF halt for non-GMU targets
During adreno_stop, GBIF halt is asserted to halt any new transaction from
GPU before GPU power collapse, but in current code it is cleared
immediately which can allow few GPU transactions to go through before gdsc
is turned-off and can result in issues.

To avoid this situation don't deassert this halt before GPU gdsc goes off.
It will deassert automatically when gdsc goes off but in case gdsc doesn't
toggle as it is a shared resource, it is deasserted during adreno_start to
ensure wake-up doesn't fail.

Change-Id: If0a892470d04a0f3a79a1ea882ee5bfd16ad24ed
Signed-off-by: Puranam V G Tejaswi <pvgtejas@codeaurora.org>
2020-11-20 01:35:29 +05:30
Puranam V G Tejaswi
ed12df75f6 msm: kgsl: Simplify GBIF halt sequence for stall-on-fault case
Currently during stall-on-fault recovery, we keep resuming SMMU and
check if GBIF halt succeeded. This is done to recover from a case where
a GPU block continuously initiated faulty transactions, which would keep
stalling SMMU. If we set CFCFG to 0 as part of handling the first fault,
all these transactions will be terminated and will not stall SMMU. This
simplifies the GBIF halt sequence and avoids resuming every time.

Change-Id: Iada83d6a08e5e0a4f6241b17d1b178ab680f1364
Signed-off-by: Puranam V G Tejaswi <pvgtejas@codeaurora.org>
2020-11-20 01:34:56 +05:30
Blagovest Kolenichev
c47e2335cc Merge android11-5.4.61+ (3720133) into msm-5.4
* refs/heads/tmp-3720133:
  ANDROID: ABI: Update allowed list for QCOM
  FROMGIT: Input: Add devices for HID_QUIRK_INCREMENT_USAGE_ON_DUPLICATE
  ANDROID: GKI: add allowed list for Exynosauto SoC
  ANDROID: GKI: update allowed list for Exynosauto SoC
  UPSTREAM: mfd: sprd: Add wakeup capability for PMIC IRQ
  UPSTREAM: tick/common: Touch watchdog in tick_unfreeze() on all CPUs
  FROMLIST: thermal: Fix NULL pointer dereference issue
  ANDROID: ABI: Update allowed list for QCOM
  UPSTREAM: spi: Fix regression to return zero on success instead of positive value
  UPSTREAM: thermal: power_allocator: Fix Kconfig warning
  UPSTREAM: of/platform: Unconditionally pause/resume sync state during kernel init
  UPSTREAM: selinux: ensure the policy has been loaded before reading the sidtab stats
  UPSTREAM: MIPS: vdso: Define BUILD_VDSO32 when building a 32bit kernel
  UPSTREAM: mfd: syscon: Fix syscon_regmap_lookup_by_phandle_args() dummy
  UPSTREAM: ARM: bcm2835_defconfig: Explicitly restore CONFIG_DEBUG_FS
  UPSTREAM: ARM: socfpga_defconfig: Add back DEBUG_FS
  UPSTREAM: um: Fix header inclusion
  UPSTREAM: net: fix fraglist segmentation reference count leak
  UPSTREAM: ipv6: ndisc: RFC-ietf-6man-ra-pref64-09 is now published as RFC8781
  UPSTREAM: of: property: Fix create device links for all child-supplier dependencies
  UPSTREAM: of: property: Do not link to disabled devices
  UPSTREAM: mmc: sdhci: Fix SDHCI_QUIRK_BROKEN_CQE
  UPSTREAM: usb: renesas-xhci: include correct header for get_unaligned_le16()
  UPSTREAM: wil6210: account for napi_gro_receive never returning GRO_DROP
  UPSTREAM: nl80211: fix memory leak when parsing NL80211_ATTR_HE_BSS_COLOR
  UPSTREAM: thermal/drivers/sprd: Fix return value of sprd_thm_probe()
  UPSTREAM: fscrypt: restrict IV_INO_LBLK_* to AES-256-XTS
  UPSTREAM: fscrypt: use smp_load_acquire() for fscrypt_prepared_key
  UPSTREAM: nvmem: sprd: Fix return value of sprd_efuse_probe()
  UPSTREAM: mac80211: fix warning in 6 GHz IE addition in mesh mode
  UPSTREAM: scsi: ufs: Fix interrupt error message for shared interrupts
  UPSTREAM: sched/fair: Fix wrong negative conversion in find_energy_efficient_cpu()
  UPSTREAM: driver core: Fix device_pm_lock() locking for device links
  UPSTREAM: fscrypt: restrict IV_INO_LBLK_32 to ino_bits <= 32
  UPSTREAM: scsi: ufs: ufs-mediatek: Eliminate error message for unbound mphy
  UPSTREAM: scsi: ufs: ufs-mediatek: Fix HOST_PA_TACTIVATE quirk
  UPSTREAM: cfg80211: fix 6 GHz channel conversion
  ANDROID: GKI: update symbol list for exynosauto soc
  ANDROID: ABI: update allowed list for galaxy
  ANDROID: GKI: initial upload list for exynosauto soc
  ANDROID: ABI: Update allowed list for QCOM

 Conflicts:
	drivers/thermal/thermal_sysfs.c
	kernel/sched/fair.c

Change-Id: I9a0af53ba055157468e6b3cee41f4c8bda1f34af
Signed-off-by: Blagovest Kolenichev <bkolenichev@codeaurora.org>
2020-11-19 11:55:48 -08:00
Tony Truong
7a81e0a1ef msm: pcie: add support to vote and scale MX rail
Chipsets which have PCIe Gen4 PHY and controller on MX rail
requires explicit vote for higher corners than the default.
Therefore add support to vote for and scale MX rail based on the
Gen speed which PCIe link operates at.

Change-Id: I1c2896d083fd57e02e1b19f7a75f356129d0e40f
Signed-off-by: Tony Truong <truong@codeaurora.org>
2020-11-19 10:57:52 -08:00
Tony Truong
ce1c29932d msm: pcie: support tuning of minimum time spent in EQ Master Phase
During Gen3 and Gen4 link training, PCIe PHY may require
additional time during the equalization master phase before
proceeding to the next LTSSM state. Add the support to configure
the minimum amount of time spent during equalization master
phase.

Change-Id: Id3e7ff631f6ce004829065ad798223d7d774edc1
Signed-off-by: Tony Truong <truong@codeaurora.org>
2020-11-19 10:57:50 -08:00
Tony Truong
f83ec092e8 msm: pcie: support controller PHY settings for Gen3 and Gen4
There are PCIe Gen3 and Gen4 PHY related settings which has to be
programmed at the PCIe controller. Add the infrastructure to
support such settings. Settings for Gen3 also needs to be
applied to Gen4 controllers. Move existing settings to the
new infrastructure.

Change-Id: I67c7c3d7c5bfa13ed30c8fca55f941c8cab0a7f0
Signed-off-by: Tony Truong <truong@codeaurora.org>
2020-11-19 10:57:47 -08:00
Tony Truong
e5596ea3e8 msm: pcie: add support for configuring Gen4 PCIe core preset
For chipsets which are Gen4 capable, the PCIe core preset
settings need to be configured accordingly based on trace
length. Therefore add the support to configure PCIe core
preset.

Change-Id: I6968e24135482aa356dd94fde4988ef342747337
Signed-off-by: Tony Truong <truong@codeaurora.org>
2020-11-19 10:57:43 -08:00
Tony Truong
d55326176c msm: pcie: scale PCIe resources based on Gen speed after link is up
After PCIe link is up, scale PCIe resources based on the Gen
speed rather than the value of CX vote for the Gen speed. Before
CX vote was the only factor for scaling resources. This is an
incorrect assumption as additional resources can be added and
do not have any dependency with CX. Therefore, remove the
dependency on CX and bind it to the Gen speed instead.

Change-Id: I64ca90892769e43d694a21e172f51d7fd4c76e68
Signed-off-by: Tony Truong <truong@codeaurora.org>
2020-11-19 10:57:40 -08:00
Tony Truong
ac98449e76 msm: pcie: cache PCIe current link speed
Add support to cache PCIe current link speed after each link
training and Gen switching. This will help check users check
which Gen speed the link was operating at all times.

Change-Id: I64487dff10cf9c5a6dc87dad42239c7cd119763c
Signed-off-by: Tony Truong <truong@codeaurora.org>
2020-11-19 10:57:35 -08:00
Hemant Kumar
2f8b47007a mhi: core: Disable preemption while processing data events
If data processing of an event is scheduled out because core
is busy handling multiple irqs, this can starves the processing
of MHI M0 state change event on another core. Fix this issue by
disabling irq on the core processing data events.

Change-Id: I4d784d2c343d4a9c50741f3e72df4c373993ae79
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
2020-11-19 10:38:55 -08:00
qctecmdr
a8aba15775 Merge "usb: dwc3: add DWC3_CONTROLLER_PULLUP event" 2020-11-19 10:34:33 -08:00
qctecmdr
ac721dc63f Merge "defconfig: sdxlemur: Enable writeable thermal zone trips" 2020-11-19 10:34:32 -08:00
qctecmdr
5c6fcbcc1b Merge "msm: ipa4: mhi qmap flow control pipe definitions for LE" 2020-11-19 10:34:32 -08:00
qctecmdr
15d2f647b5 Merge "defconfig: arm64: Enable DDR cooling device for lahaina" 2020-11-19 10:34:32 -08:00
qctecmdr
6f437f7519 Merge "usb: dwc3: Add support for nominal elastic buffer" 2020-11-19 10:34:31 -08:00
Neeraj Soni
274fdbe87f ANDROID: ABI: Update allowed list for QCOM
Leaf changes summary: 1 artifact changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 1 Added function
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 0 Added variable

1 Added function:

  [A] 'function bool bio_crypt_should_process(request*)'

Bug: 173684180
Signed-off-by: Neeraj Soni <neersoni@codeaurora.org>
Change-Id: I0c4b63609d08a11aa6ca38c7afc3327832f31894
2020-11-19 16:56:18 +00:00
hajun.sung
5b622f9fc0 ANDROID: GKI: Update abi_gki_aarch64_exynos
Leaf changes summary: 0 artifact changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 0 Added function
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 0 Added variable

Added pci_find_ext_capability symbol

Bug: 173187552
Change-Id: I419ab952f69f1da2b1867ab743da3830238a1912
Signed-off-by: hajun.sung <hajun.sung@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2020-11-19 16:48:13 +00:00
Charan Teja Reddy
9c71673f9e mm: memory_hotplug: migration failure info of a page under DEBUG_VM
Put the migration failure info of a page under DEBUG_VM as most of
the times this info is not required.

Change-Id: I798f0bef9c558a272c6aa94424236d8f65f801dd
Signed-off-by: Charan Teja Reddy <charante@codeaurora.org>
2020-11-19 21:33:52 +05:30
qctecmdr
a1702cebeb Merge "spi: spi-msm-geni: Clear the RX fifo if FIFO has data after timeout" 2020-11-19 06:55:49 -08:00