Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d8569878 authored by Abhijit Trivedi's avatar Abhijit Trivedi
Browse files

Fastforward AU160 to Topic branch



Merge commit 'a262fffa' into topic branch

* commit 'a262fffa':
  msm: ipa: Fix the problem with nested sleeping primitives
  msm: ipa: fix wrong usage and cleanup dead code
  arm64: unexport walk_stackframe
  arm64: traps: simplify die() and __die()
  arm64: factor out current_stack_pointer
  arm64: asm-offsets: remove unused definitions
  thread_info: include <current.h> for THREAD_INFO_IN_TASK
  thread_info: factor out restart_block
  ARM: dts: msm: Fix l3-cpu* devices' frequency maps for SDM845
  usb: gadget: f_cdev: Fix NULL pointer dereference in cser_free_inst
  defconfig: sdm670: update re-ordered configurations
  drm/msm: fix compilation error when bus_scaling disabled
  msm: msm_bus: Include init_time flag during handoff locking
  msm: vidc: Enable video system cache by default
  iio: rradc: Update thermistor scaling
  msm: msm_bus: Add check for empty clist in commit
  msm: kgsl: Add exceptions to snapshot based on GX and SPTP status
  msm: ipa: add L2TP/VLAN messaging
  msm: vidc: Fix hfi macro value of blur frame size
  drivers: mailbox: fix excessive logging
  ARM: dts: msm: Reduce IPA msm bus votes for sdm845
  drm/msm: start secure domain va from non-zero address
  drm/msm/sde: add support to select secure context bank
  ARM: dts: msm: add secure smmu cb node for sdm845
  drm/msm/sde: add secure use case properties
  drm/msm: get an iova from the address space instead of an id
  msm: ipa4: disable pa_mask_en
  cpufreq: schedutil: Fix sugov_start versus sugov_update_shared race
  msm: secure_buffer: Add SPSS_SP_SHARED vmid
  cnss_utils: Zero out cnss_utils priv structure during initalization
  drm: msm: Update and correct AD setting for suspend/resume
  msm: vidc: Fix memory leak and array abounds exceeding issues
  msm: vidc: Don't kill the session in response handler thread
  msm: vidc: Update controls and output buffers list check
  ARM: dts: msm: Add remote subsystem mitigation for sdm845
  ARM: dts: msm: Add QMI cooling devices for sdm845
  defconfig: Enable remote cooling devices for sdm845
  ARM: dts: msm: Add IPA dtsi entries for sdm670
  thermal: qti_qmi_cooling: Add remote subsystem cooling devices
  ARM: dts: msm: Add system_pm device bindings for sdm670
  ARM: dts: msm: Add APPS RSC device bindings for sdm670
  ARM: dts: msm: Add command DB node for sdm670
  ARM: dts: msm: Add device bindings for RPM stats for sdm670
  ARM: dts: msm: Add sleep driver for sdm670
  msm: kgsl: correctly disable SP clock before hw settings
  sched: compile sched_avg.c only for SMP
  power: qcom: smb-lib: handle dynamic Rp change
  qpnp-smb2: configure DRP mode after interrupt request
  power: qpnp-smb2: Unset ONLINE for UNKNOWN USB charger type
  power: smb-lib: Add support to detect weak charger
  cpufreq: schedutil: Fix race condition in computing hispeed_util
  cpufreq: schedutil: Update hispeed load condition
  cpufreq: schedutil: Keep track of average policy capacity
  cpufreq: schedutil: Add freq_to_util helper function
  drivers: qcom: rpmh: Do not send active votes in solver mode
  adreno_tz: Correct tz_buf pointer type to correct pointer arithmetic
  icnss: Change MSA permissions to collect dump
  Revert "mmc: enable MMC/SD/SDIO device to suspend/resume asynchronously"
  msm: ipa: add new IPA filtering bitmap
  msm: ipa: add support for new uC opcode
  msm: vidc: Fine tune PMS with on-target profiling
  soc: qcom: ramdump: Use cdev devices instead of misc devices
  drm/msm: add support for parsing YUV 420 deep color
  msm: kgsl: Add scm call for SMMU aperture programming
  sched: cpufreq: Limit governor updates to WALT changes alone
  sched: walt: Provide the most recent window_start value to cpufreq
  ARM: dts: msm: specify QDSS clock for SPMI debug bus on SDM845
  ARM: dts: msm: mark SPMI debug slave devices as can-sleep for SDM845
  mfd: qcom-spmi-pmic: add support for slow SPMI busses
  spmi: spmi-pmic-arb-debug: add clock management support
  clk: qcom: clk-cpu-osm: Cleanup the OSM clock driver
  ARM: dts: msm: Update Venus clock values on SDM845 v2
  power: smb-lib: Rearrange BOOST_BACK voting logic
  smb-lib: add support for float charger reporting
  power: power_supply_sysfs: Add support for Floating charger
  qpnp-fg-gen3: Move getting battery id and profile to profile_load_work
  power: qpnp-fg-gen3: Qualify aborting capacity learning
  power: qpnp-fg-gen3: fix an unbalanced irq disable for delta_bsoc irq
  qpnp-smb2: Fix QC_PULSE_COUNT reading logic
  defconfig: Disable hardlockup panic
  coresight: tmc: Fix use after free issue with tmc read
  msm: ion: Multiple vmids ION secure allocation
  msm: secure_buffer: Add SPSS_SP vmid
  cnss_utils: Add support of cnss_utils for WLAN
  Linux 4.9.36
  KVM: nVMX: Fix exception injection
  KVM: x86: zero base3 of unusable segments
  KVM: x86/vPMU: fix undefined shift in intel_pmu_refresh()
  KVM: x86: fix emulation of RSM and IRET instructions
  arm64: fix NULL dereference in have_cpu_die()
  mtd: nand: brcmnand: Check flash #WP pin status before nand erase/program
  i2c: brcmstb: Fix START and STOP conditions
  brcmfmac: avoid writing channel out of allocated array
  infiniband: hns: avoid gcc-7.0.1 warning for uninitialized data
  objtool: Fix another GCC jump table detection issue
  clk: scpi: don't add cpufreq device if the scpi dvfs node is disabled
  cpufreq: s3c2416: double free on driver init error path
  iommu/amd: Fix interrupt remapping when disable guest_mode
  iommu/amd: Fix incorrect error handling in amd_iommu_bind_pasid()
  iommu/dma: Don't reserve PCI I/O windows
  iommu: Handle default domain attach failure
  iommu/vt-d: Don't over-free page table directories
  ocfs2: o2hb: revert hb threshold to keep compatible
  x86/mm: Fix flush_tlb_page() on Xen
  x86/mpx: Correctly report do_mpx_bt_fault() failures to user-space
  x86/boot/KASLR: Fix kexec crash due to 'virt_addr' calculation bug
  tools arch: Sync arch/x86/lib/memcpy_64.S with the kernel
  ARM: 8685/1: ensure memblock-limit is pmd-aligned
  ARM64/ACPI: Fix BAD_MADT_GICC_ENTRY() macro implementation
  ARM: dts: OMAP3: Fix MFG ID EEPROM
  ARM: OMAP2+: omap_device: Sync omap_device and pm_runtime after probe defer
  regulator: tps65086: Fix DT node referencing in of_parse_cb
  regulator: tps65086: Fix expected switch DT node names
  spi: fix device-node leaks
  spi: When no dma_chan map buffers with spi_master's parent
  sched/loadavg: Avoid loadavg spikes caused by delayed NO_HZ accounting
  watchdog: bcm281xx: Fix use of uninitialized spinlock.
  netfilter: use skb_to_full_sk in ip_route_me_harder
  xfrm: Oops on error in pfkey_msg2xfrm_state()
  xfrm: NULL dereference on allocation failure
  xfrm: fix stack access out of bounds with CONFIG_XFRM_SUB_POLICY
  mm/vmalloc.c: huge-vmap: fail gracefully on unexpected huge vmap mappings
  ravb: Fix use-after-free on `ifconfig eth0 down`
  ip6_tunnel, ip6_gre: fix setting of DSCP on encapsulated packets
  sctp: check af before verify address in sctp_addr_id2transport
  net/mlx4_core: Eliminate warning messages for SRQ_LIMIT under SRIOV
  perf probe: Fix to probe on gcc generated functions in modules
  tipc: allocate user memory with GFP_KERNEL flag
  net: phy: dp83867: allow RGMII_TXID/RGMII_RXID interface types
  perf probe: Fix to show correct locations for events on modules
  be2net: fix MAC addr setting on privileged BE3 VFs
  be2net: don't delete MAC on close on unprivileged BE3 VFs
  be2net: fix status check in be_cmd_pmac_add()
  usb: dwc2: gadget: Fix GUSBCFG.USBTRDTIM value
  s390/ctl_reg: make __ctl_load a full memory barrier
  swiotlb: ensure that page-sized mappings are page-aligned
  coredump: Ensure proper size of sparse core files
  aio: fix lock dep warning
  perf/x86: Reject non sampling events with precise_ip
  perf/core: Fix sys_perf_event_open() vs. hotplug
  x86/mpx: Use compatible types in comparison to fix sparse error
  x86/tsc: Add the Denverton Processor to native_calibrate_tsc()
  mac80211: initialize SMPS field in HT capabilities
  pmem: return EIO on read_pmem() failure
  drm/amd/powerplay: refine vce dpm update code on Cz.
  drm/amd/powerplay: fix vce logic error on CZ/St.
  drm/radeon/si: load special ucode for certain MC configs
  net: thunderx: acpi: fix LMAC initialization
  arm64: assembler: make adr_l work in modules under KASLR
  spi: davinci: use dma_mapping_error()
  scsi: lpfc: avoid double free of resource identifiers
  HID: i2c-hid: Add sleep between POWER ON and RESET
  perf/x86/intel: Use ULL constant to prevent undefined shift behaviour
  mac80211: recalculate min channel width on VHT opmode changes
  net: phy: marvell: fix Marvell 88E1512 used in SGMII mode
  pinctrl: intel: Set pin direction properly
  perf/x86/intel/uncore: Fix hardcoded socket 0 assumption in the Haswell init code
  drm/etnaviv: trick drm_mm into giving out a low IOVA
  Documentation: devicetree: change the mediatek ethernet compatible string
  kernel/panic.c: add missing \n
  ibmveth: Add a proper check for the availability of the checksum features
  vxlan: do not age static remote mac entries
  ip6_tunnel: must reload ipv6h in ip6ip6_tnl_xmit()
  virtio_net: fix PAGE_SIZE > 64k
  mlxsw: spectrum_router: Correctly reallocate adjacency entries
  vfio/spapr: fail tce_iommu_attach_group() when iommu_data is null
  drm/amdgpu: check ring being ready before using
  net: dsa: Check return value of phy_connect_direct()
  amd-xgbe: Check xgbe_init() return code
  platform/x86: ideapad-laptop: handle ACPI event 1
  iwlwifi: fix kernel crash when unregistering thermal zone
  scsi: virtio_scsi: Reject commands when virtqueue is broken
  xen-netfront: Fix Rx stall during network stress and OOM
  swiotlb-xen: update dev_addr after swapping pages
  virtio_console: fix a crash in config_work_handler
  Btrfs: fix truncate down when no_holes feature is enabled
  Btrfs: Fix deadlock between direct IO and fast fsync
  gianfar: Do not reuse pages from emergency reserve
  objtool: Fix IRET's opcode
  bpf: don't trigger OOM killer under pressure with map alloc
  bnxt_en: Fix "uninitialized variable" bug in TPA code path.
  xen-netback: protect resource cleaning on XenBus disconnect
  xen-netback: fix memory leaks on XenBus disconnect
  net: ethtool: Initialize buffer when querying device channel settings
  powerpc/eeh: Enable IO path on permanent error
  net: korina: Fix NAPI versus resources freeing
  perf/x86/intel: Handle exclusive threadid correctly on CPU hotplug
  net: phy: dp83848: add DP83620 PHY support
  drm/amdgpu: add support for new hainan variants
  drm/amdgpu: fix program vce instance logic error.
  qla2xxx: Fix erroneous invalid handle message
  qla2xxx: Terminate exchange if corrupted
  scsi: lpfc: Set elsiocb contexts to NULL after freeing it
  stmmac: add missing of_node_put
  scsi: sd: Fix wrong DPOFUA disable in sd_read_cache_type
  KVM: x86: fix fixing of hypercalls
  xen/blkback: don't free be structure too early
  ARM64: dts: meson-gxbb-odroidc2: fix GbE tx link breakage
  dt: bindings: net: use boolean dt properties for eee broken modes
  net: phy: use boolean dt properties for eee broken modes
  net: phy: fix sign type error in genphy_config_eee_advert
  dt-bindings: net: add EEE capability constants
  net: phy: add an option to disable EEE advertisement
  net: ethtool: add support for 2500BaseT and 5000BaseT link modes
  sparc64: Zero pages on allocation for mondo and error queues.
  sparc64: Handle PIO & MEM non-resumable errors.
  mm: numa: avoid waiting on freed migrated pages
  l2tp: take a reference on sessions used in genetlink handlers
  l2tp: hold session while sending creation notifications
  l2tp: fix duplicate session creation
  l2tp: ensure session can't get removed during pppol2tp_session_ioctl()
  l2tp: fix race in l2tp_recv_common()
  usb: gadget: f_fs: Fix possibe deadlock
  x86/mm: Fix boot crash caused by incorrect loop count calculation in sync_global_pgds()
  dm thin: do not queue freed thin mapping for next stage processing
  drm/vmwgfx: Free hash table allocated by cmdbuf managed res mgr
  gpiolib: fix filtering out unwanted events
  NFSv4.1: Fix a race in nfs4_proc_layoutget
  ALSA: hda - set input_path bitmap to zero after moving it to new place
  ALSA: hda - Fix endless loop of codec configure
  MIPS: Fix IRQ tracing & lockdep when rescheduling
  MIPS: pm-cps: Drop manual cache-line alignment of ready_count
  MIPS: Avoid accidental raw backtrace
  MIPS: head: Reorder instructions missing a delay slot
  mm, : reschedule when neeed in
  drm/ast: Handle configuration without P2A bridge
  xen/blkback: don't use xen_blkif_get() in xen-blkback kthread
  NFSv4.x/callback: Create the callback service through svc_create_pooled
  NFSv4: fix a reference leak caused WARNING messages
  netfilter: synproxy: fix conntrackd interaction
  netfilter: xt_TCPMSS: add more sanity tests on tcph->doff
  rtnetlink: add IFLA_GROUP to ifla_policy
  ipv6: Do not leak throw route references
  sfc: provide dummy definitions of vswitch functions
  net: 8021q: Fix one possible panic caused by BUG_ON in free_netdev
  decnet: always not take dst->__refcnt when inserting dst into hash table
  net/mlx5e: Fix timestamping capabilities reporting
  net/mlx5: Wait for FW readiness before initializing command interface
  net/mlx5e: Avoid doing a cleanup call if the profile doesn't have it
  sctp: return next obj by passing pos + 1 into sctp_transport_get_idx
  ipv6: fix calling in6_ifa_hold incorrectly for dad work
  igmp: add a missing spin_lock_init()
  igmp: acquire pmc lock for ip_mc_clear_src()
  proc: snmp6: Use correct type in memset
  net/mlx5e: Fix wrong indications in DIM due to counter wraparound
  net/mlx5e: Added BW check for DIM decision mechanism
  net: tipc: Fix a sleep-in-atomic bug in tipc_msg_reverse
  net: caif: Fix a sleep-in-atomic bug in cfpkt_create_pfx
  sctp: disable BH in sctp_for_each_endpoint
  Fix an intermittent pr_emerg warning about lo becoming free.
  af_unix: Add sockaddr length checks before accessing sa_family in bind and connect handlers
  net: vrf: Make add_fib_rules per network namespace flag
  net: Zero ifla_vf_info in rtnl_fill_vfinfo()
  decnet: dn_rtmsg: Improve input length sanitization in dnrmg_receive_user_skb
  net: don't call strlen on non-terminated string in dev_set_alias()
  ipv6: release dst on error in ip6_dst_lookup_tail
  ASoC: msm: Add support to compile machine driver for SDM670
  ASoC: codecs: use correct function to create subdir entry
  ASoC: codecs: move DAPM widgets and routes out of codec driver structure
  pinctrl: lpi: Use gpiochip_get_data to get gpio state
  ASoC: msm: Disable HDMI audio codec for SDM670
  ASoC: msm: Update arguments for msm_swap_gnd_mic
  ASoC: msm: access aux_devs with component list
  ASoC: msm: update DAI link's be_id to id
  skb: printing port numbers with gso trace events
  skb: Adding trace event for gso.
  drm/msm/sde: take spin lock around encoder vblank registration
  firmware: qcom: tz_log: update interrupt info offset
  drm/msm/sde: select correct multirect op mode
  ASoC: audio-ext-clk: enable pinctrl after clock enable
  ASoC: msm_sdw: Move the delay logic inside bulk write loop
  ARM: dts: msm: Add support for Lpass PIL on sdm670
  ion: ion_system_heap: Fix null pointer dereference
  memshare: Perform Hypervisor mapping for boot-time allotted memory
  sensors: ssc: Add restart interface for SLPI
  defconfig: sdm670: move to sdm670 specific defconfig
  scsi: ufs: Factor out ufshcd_read_desc_param
  mmc: core: extend SDR104 workaround for other paths
  mmc: core: Fix card remove detect when use extcon
  msm: ADSPRPC: CRC request for remote invoke buffers
  ARM: dts: msm: Add QMP device for AOP on sdm670
  ARM: dts: msm: Add SMP2P entries for sdm670
  ARM: dts: msm: Set FDE key size to 256bit for sdm845
  soc: qcom: glink: Move tx_info allocation in beginning
  soc: qcom: glink: Move ctx initialization of xprt ptr
  soc: qcom: glink_smem_native_xport: Allocate smem item in non cache region
  ARM: dts: msm: Update cdsp memory map for sdm670
  genirq: Don't allow user space to set IRQ affinity to isolated CPUs
  genirq: honour default IRQ affinity setting during migration
  cpu-hotplug: Keep atleast 1 online and un-isolated CPU
  genriq: pick only one CPU while overriding the affinity during migration
  msm: kgsl: Directly return page size of the supported pool
  msm: kgsl: Limit the frequency of logging on memory allocation failure
  ARM: dts: msm: Enable UFS support for sdm670
  defconfig: msm: enable dvb demux modules compilation
  ARM: dts: msm: add TSPP node for sdm845
  memshare: Add support for memshare driver
  slim: msm: ngd: Fix incorrect casting of slimbus context-bank devices
  defconfig: msm: enable remote debugger driver on sdm845
  ARM: dts: msm: Add remote debugger device configuration for sdm845
  msm: rdbg: Add snapshot of remote debugger driver
  drivers: soc: qcom: Use number of bytes returned from PRNG for entropy
  msm: msm_bus: Do not set commit bit for RSCs in solver mode
  msm: vidc: Fix buffer count issue
  drm/msm/sde: avoid checking roi symmetry if zero mixers
  drm/msm/sde: move scaler config data into plane state
  drm/msm: exit from mode-2 if mdss gdsc power collapse fail
  drm/msm/sde: Add dither feature support
  ARM: dts: msm: align dither offset to pingpong offset for sdm845
  msm: ipa: move rndis_ipa and ecm_ipa to ipa folder
  UPSTREAM: selinux: enable genfscon labeling for tracefs
  ARM: dts: msm: Add IPC Router devices for sdm670
  ARM: dts: msm: Add glink_pkt devices for sdm670
  ARM: dts: msm: Add G-Link SSR device nodes for sdm670
  ARM: dts: msm: Add G-Link SMEM Transport device nodes for sdm670
  ARM: dts: msm: Add SMEM device node for sdm670
  ARM: dts: msm: Add ipc-spinlock device node for sdm670
  mmc: sdhci-msm: Don't turnoff Vcc during initialization
  clk: qcom: Fix the clock scaling issue for GFX3D clock
  ARM: dts: msm: Add new clock level for Venus for sdm845
  msm: vidc: Introduce Performance Monitoring System
  clk: qcom: clk-alpha-pll: Update round rate to use kHz for the divider
  drm/msm/sde: correct inline rotator qos remap loop
  kernel: power: qos: Set PM_QOS_SUM type for each cpu
  msm: kgsl: Trace GMU register writes before adjusting offset
  ASoC: wcd-spi: cleanup to remove unused SPI APIs
  ARM: dts: msm: Add the hw-trigger flag to the IPE and BPS GDSCs on SDM845
  mfd: wcd9xxx: Remove unused codec specific configs
  defconfig: msm: Remove codec specific config for core
  ASoC: wcd9xxx: Add wcd9xxx_core depends on relation for codecs
  mfd: wcd9xxx: Combine all codec configs into single config
  soundwire: update soundwire config depends on relation
  pinctrl: qcom: update wcd pinctrl config depends on relation
  msm: kgsl: Fix spinlock corruption in hfi receiver
  msm: kgsl: update SP clock gating setting
  ASoC: wcd9xxx: Add support to build codecs as module
  usb: pd: Start USB host mode functionality with SRC_STARTUP
  defconfig: msm: Add loadable wcd9xxx core driver config
  ARM: dts: msm: Add new property to DSPS IPC router node for SDM845
  net: ipc_router: Add dynamic enable/disable wakeup source feature
  drm/msm/sde: disable sspp multirect during plane disable
  Linux 4.9.35
  brcmfmac: fix uninitialized warning in brcmf_usb_probe_phase2()
  jump label: fix passing kbuild_cflags when checking for asm goto support
  net: phy: fix marvell phy status reading
  spi: double time out tolerance
  dmaengine: bcm2835: Fix cyclic DMA period splitting
  net: phy: Initialize mdio clock at probe function
  rt2x00: avoid introducing a USB dependency in the rt2x00lib module
  usb: gadget: f_fs: avoid out of bounds access on comp_desc
  mtd: spi-nor: fix spansion quad enable
  of: Add check to of_scan_flat_dt() before accessing initial_boot_params
  rxrpc: Fix several cases where a padded len isn't checked in ticket decode
  drm/amdgpu: adjust default display clock
  drm/amdgpu/atom: fix ps allocation size for EnableDispPowerGating
  drm/radeon: add a quirk for L20-183
  drm/radeon: add a PX quirk for another K53TK variant
  iscsi-target: Reject immediate data underflow larger than SCSI transfer length
  iscsi-target: Fix delayed logout processing greater than SECONDS_FOR_LOGOUT_COMP
  target: Fix kref->refcount underflow in transport_cmd_finish_abort
  arm64/vdso: Fix nsec handling for CLOCK_MONOTONIC_RAW
  time: Fix CLOCK_MONOTONIC_RAW sub-nanosecond accounting
  time: Fix clock->read(clock) race around clocksource changes
  brcmfmac: unbind all devices upon failure in firmware callback
  brcmfmac: use firmware callback upon failure to load
  brcmfmac: add parameter to pass error code in firmware callback
  Input: i8042 - add  AH544 to notimeout list
  powerpc/64s: Handle data breakpoints in Radix mode
  powerpc/kprobes: Pause function_graph tracing during jprobes handling
  signal: Only reschedule timers on signals timers have sent
  HID: Add quirk for OEM mouse
  cxgb4: notify uP to route ctrlq compl to rdma rspq
  CIFS: Improve readdir verbosity
  KVM: PPC: Book3S HV: Context-switch EBB registers properly
  KVM: PPC: Book3S HV: Preserve userspace HTM state properly
  KVM: s390: gaccess: fix real-space designation asce handling for gmap shadows
  perf/x86/intel: Add 1G DTLB load/store miss support for SKL
  lib/cmdline.c: fix get_options() overflow while parsing ranges
  autofs: sanity check status reported with AUTOFS_DEV_IOCTL_FAIL
  powerpc/perf: Fix oops when kthread execs user process
  fs/exec.c: account for argv/envp pointers
  ALSA: pcm: Don't treat NULL chmap as a fatal error
  ALSA: firewire-lib: Fix stall of process context at packet error
  xen-blkback: don't leak stack data via response ring
  xen/blkback: fix disconnect while I/Os in flight
  clk: sunxi-ng: a31: Correct lcd1-ch1 clock register offset
  drivers: mfd: Add support for wcd9xxx core module
  clk: qcom: Add support to round the frequency to kHz
  ASoC: wsa881x: Add loadable module support for WSA
  defconfig: Add loadable module machine driver config
  ASoC: msm: Add loadable module support for machine driver
  ASoC: msm: export symbols used by WCD
  ARM: dts: msm: Add audio device tree overlays for SDM845
  drivers: cpuidle: lpm-levels: Export symbols used by audio
  drm/msm/sde: remove release fence signal from frame done
  soc: qcom: glink_spi_xprt: Change to spi function pointer interface
  ASoC: wcd-spi: handle WDSP_EVENT_GETOPS in the event handler
  ASoC: wcd-dsp-mgr: add support to get ops from components
  soc: qcom: sleepstate: Increase notifier priority
  input: misc: hbtp_input: Add sysfs for suspend/resume
  msm: vidc: Update extradata buffer count calculations
  msm: vidc: Fix buffer count related issues
  drm: msm: sde: last command support for reg dma
  ARM: dts: msm: Add usb QoS clock references for sdm845
  ARM: dts: msm: specify RRADC temperature channels for smb1355
  qcom: smb1355: Add charger temp properties in parallel psy
  qcom: smb1355: Support connector_temp_health property
  msm: vidc: Fix lock issue in streamon failure
  ARM: dts: msm: Add regulator floor mitigation config for sdm845
  ARM: dts: msm: Add regulator cooling device for SDM845
  regulator: rpmh-regulator: initiate child device probe
  defconfig: Enable regulator cooling device
  thermal: regulator_cooling: Add AOP based regulator cooling device
  ARM: dts: msm: Add slimbus instance entries for SDM670
  drm/msm: Support different SMMU backends for address spaces
  drm/msm: support multiple address spaces
  drm/msm: Remove the 'len' parameter from mmu map/unmap functions
  drm/msm: add crash analysis for important debug registers
  ARM: dts: msm: add support to 4k DSC command mode on sdm845
  drm/msm: Fix naming for msm event notification
  ASoC: wcd_cpe: remove wcd9330 related code
  seemp: check array index range
  Migrate mpq demux driver from kernel 4.4 to 4.9
  Migrate mpq demux driver from kernel 4.4 to 4.9
  msm: kgsl: Correct the fence reference counting
  diag: Add mutex protection while closing diag channels
  ARM: dts: msm: Populate QUPV3 serial Engine device nodes for SDM670
  soc: qcom: avoid calling sleeping functions in interrupt context
  msm: rmnet_ipa3: fix QMAP command xfer
  msm: ipa: fix IPA MHI unit tests
  ARM: dts: msm: Add initial overlay for QRD on SDM845
  clk: qcom: Change the init level for the clock drivers to subsys
  drm/msm/sde: disable vblank irqs before triggering panic
  drm/msm/sde: remove out of bound access for qos lut parsing
  mfd: remove unused wcd9330 codec related files
  ASoC: wcd: remove unused wcd9330 codec driver
  msm: ipa3: Fix fast_replenish race condition.
  defconfig: sdm845: Enable stack protector strong
  usb: gadget: Bind android devices for all UDC gadgets
  Revert "ANDROID: hardlockup: detect hard lockups without NMIs using secondary cpus"
  Revert "ANDROID: kernel/watchdog: fix unused variable warning"
  Bluetooth: HID: Add Bus type for specific HID Keyboard
  defconfig: sdm845: Add support for BT uhid drivers
  spmi-pmic-arb: add support to dispatch interrupt based on IRQ status
  HID: Remove playstation4 as special driver
  defconfig: sdm845: enable iommu debug tracking
  mmc: core: Increase the runtime PM reference count in try_claim_host
  net: Reset NAPI bit if IPI failed
  tun: Set CHECKSUM_UNNECESSARY if userspace passes this indication
  net: add a per-cpu counter for the number of frames coalesced in GRO
  msm: ipa: prevent string buffer overflows
  msm: vidc: Misc bug fixes in platform specific data
  msm: kgsl: Fixed a warning when turning off GMU clock
  msm: vidc: Fix buffer requirement negotiations
  drm/msm/sde: fix null parameter checks in drm driver
  msm: ipa: fix mhi suspend logic
  ARM: dts: msm: Add property to identify TPDMs that need MSR fix for sdm845
  soc: qcom: pil: Avoid possible buffer overflow during Modem boot
  drivers: thermal: step-wise: Update the mitigation clear logic
  msm: vidc: Add support for decoder UBWC CR Stats
  drm/msm: add affected planes during idle power restore
  drm/msm/sde: support command mode autorefresh
  coresight: tmc: Add usb support for coresight
  UPSTREAM: usb: gadget: f_fs: avoid out of bounds access on comp_desc
  sched/fair: remove printk while schedule is in progress
  mmc: sdhci-msm: Corrected the '&' operator with '&&' in the 'if' statement
  drivers: thermal: virtual-sensor: update the virtual sensor name
  drivers: thermal: Use deferrable work and power efficient workqueue
  drivers: cpuidle: lpm-levels: Remove conversion to SCLK cycles
  drivers: cpuidle: lpm-levels: Support for different CPUs in a cluster
  msm: ipa3: Assert on GSI MHI event ring fatal error
  msm: ipa3: Ring IPA MHI event ring doorbell on channel start
  kthread: Ensure task isn't preempted before dequeue in kthread_parkme
  msm: ipa3: remove delay from AP if QMI fails
  Linux 4.9.34
  mm: fix new crash in unmapped_area_topdown()
  Allow stack to grow up to address space limit
  mm: larger stack guard gap, between vmas
  alarmtimer: Rate limit periodic intervals
  crypto: Work around deallocated stack frame reference gcc bug on sparc.
  vTPM: Fix missing NULL check
  MIPS: .its targets depend on vmlinux
  MIPS: Fix bnezc/jialc return address calculation
  usb: dwc3: exynos fix axius clock error path to do cleanup
  usb: gadget: composite: Fix function used to free memory
  alarmtimer: Prevent overflow of relative timers
  genirq: Release resources in __setup_irq() error path
  sched/core: Idle_task_exit() shouldn't use switch_mm_irqs_off()
  iio: imu: inv_mpu6050: add accel lpf setting for chip >= MPU6500
  swap: cond_resched in
  mm/memory-failure.c: use compound_head() flags for huge pages
  USB: gadgetfs, dummy-hcd, net2280: fix locking for callbacks
  USB: gadget: fix GPF in gadgetfs
  usb: xhci: ASMedia ASM1042A chipset need shorts TX quirk
  usb: xhci: Fix USB 3.1 supported protocol parsing
  drivers/misc/c2port/c2port-duramar2150.c: checking for NULL instead of IS_ERR()
  misc: mic: double free on ioctl error path
  ath10k: fix napi crash during rmmod when probe firmware fails
  usb: r8a66597-hcd: decrease timeout
  usb: r8a66597-hcd: select a different endpoint on timeout
  USB: gadget: dummy_hcd: fix hub-descriptor removable fields
  pvrusb2: reduce stack usage pvr2_eeprom_analyze()
  USB: usbip: fix nonconforming hub descriptor
  usb: core: fix potential memory leak in error path during hcd creation
  USB: hub: fix SS max number of ports
  usb: gadget: udc: renesas_usb3: lock for PN_ registers access
  usb: gadget: udc: renesas_usb3: fix deadlock by spinlock
  usb: gadget: udc: renesas_usb3: fix pm_runtime functions calling
  IB/mlx5: Fix kernel to user leak prevention logic
  iio: adc: ti_am335x_adc: allocating too much in probe
  iio: proximity: as3935: recalibrate RCO after resume
  iio: st_pressure: Fix data sign
  staging: iio: tsl2x7x_core: Fix standard deviation calculation
  staging: rtl8188eu: prevent an underflow in rtw_check_beacon_data()
  mfd: omap-usb-tll: Fix inverted bit use for USB TLL mode
  x86/mm/32: Set the '__vmalloc_start_set' flag in initmem_init()
  serial: sh-sci: Fix late enablement of AUTORTS
  serial: efm32: Fix parity management in 'efm32_uart_console_get_options()'
  drm/vc4: Fix OOPSes from trying to cache a partially constructed BO.
  drm/mediatek: fix mtk_hdmi_setup_vendor_specific_infoframe mistake
  mac80211: don't send SMPS action frame in AP mode when not needed
  mac80211: fix dropped counter in multiqueue RX
  mac80211: strictly check mesh address extension mode
  mac80211: fix IBSS presp allocation size
  mac80211: fix packet statistics for fast-RX
  mac80211: fix CSA in IBSS mode
  usb: musb: dsps: keep VBUS on for host-only mode
  drm/i915: Fix GVT-g PVINFO version compatibility check
  drm/amdgpu: Fix overflow of watermark calcs at > 4k resolutions.
  mac80211/wpa: use constant time memory comparison for MACs
  mac80211: don't look at the PM bit of BAR frames
  vb2: Fix an off by one error in 'vb2_plane_vaddr'
  cpufreq: conservative: Allow down_threshold to take values from 1 to 10
  ila_xlat: add missing hash secret initialization
  can: gs_usb: fix memory leak in gs_cmd_reset()
  configfs: Fix race between create_link and configfs_rmdir
  fs: pass on flags in compat_writev
  defconfig: sdm845: enable CONFIG_UFS_FAULT_INJECTION
  lib/Kconfig.debug: add UFS_FAULT_INJECTION config
  defconfig: sdxpoorwills: Enable USB driver for sdxpoorwills
  ARM: dts: msm: Enable dtsi entries for USB driver for sdxpoorwills
  usb: phy: snps: Implement PHY driver for femto PHY
  ARM: dts: msm: Modify the l3 memlat tables for SDM845
  ARM: dts: msm: Add priority to QMP device tree on sdm845
  mailbox: msm_qmp: Add multi client functionality
  drivers: thermal: cpu-cooling: unisolate CPU after hotplug
  msm: vidc: Update correct HFI config for QP
  drivers: cpuidle: lpm-levels: Remove unused code
  msm: kgsl: Add the per context preemption buffer
  msm: kgsl: Add A6XX preemption support
  sound: usb: Add quirk to issue SET_CUR volume on 2nd channel
  msm: kgsl: Increase the global memory size
  msm: sps: Fix race condition in SPS debugfs APIs
  defconfig: sdm845: Enable DM request driver
  md: dm-req-crypt: Fix compilation errors
  md: Add dm-req-crypt driver snapshot
  msm: kgsl: Dump some A6XX registers before crashdump
  sched: improve the scheduler
  mmc: sdhci-msm: Change pm_qos cpu groups latency to PM_QOS_DEFAULT_VALUE
  clk: qcom: Check for errors during  read
  Revert "msm: kgsl: Offload mementry destroy work to separate thread"
  mmc: bus: Handle error in case bus_ops suspend fails
  mmc: mmc: Handle error case in mmc_suspend
  ARM: dts: msm: Fix support for WSA device detection on QRD SDM845
  msm: vidc: Enable LLC bandwidth configuration
  drivers: edac: Fix error code parsing and initial check for bus errors
  ARM: dts: msm: Remove votes for LVS2 on SDM845
  soc: qcom: glink: Change dummy xprt allocation to kzalloc
  arm64: Dump memory surrounding PC, LR and SP registers only
  power: qcom: qpnp-fg-gen3: add missing break in switch statement
  msm: kgsl: Fix racing in HFI message deletion
  ASoC: msm: qdsp6v2: Apply gain based on app type
  ARM: dts: msm: add display bus paths for split voting to sdm845
  ARM: dts: msm: Add QoS settings for sdm845
  arm/arm64: Export save_stack_trace_tsk()
  ARM: dts: msm: Add support to pass phy auto resume offset for SDM845
  usb: phy-msm-qusb-v2: Use phy autoresume register offset from device tree
  ASoC: wcd-mbhc: Add support for unloading mbhc
  drm/msm/sde: return error code on multirect check failure
  drm: dp: add support to validate the modes reported by the sink
  msm: ADSPRPC: Initialize FastRPC invoke metadata
  soc: qcom: add config options for Audio SSR and PDR features
  defconfig: msm: Enable QPIC NAND driver for sdxpoorwills
  drm/msm/dsi-staging: remove display from active list
  msm: kgsl: update TP clock gating setting
  sched: introduce sched_{up,down}migrate knobs
  sched: WALT: introduce sched_group_{up,down}_migrate knobs
  Revert "msm: kgsl: Enable SPTP power collapse"
  msm: kgsl: Wait longer for CX headswitch off
  mmc: sdhci: add err_state to sdhci_dumpregs func
  mmc: mmc-debugfs: add error state
  msm: kgsl: Use GMU cold boot sequence for hard reset
  mmc: core: Retry claim host in mmc_sd_detect
  mmc: sdhci-msm: Cache mmc data structures for debugging
  diag: Update msg mask tables for new SSID
  diag: Update msg, log and event information
  diag: Add MSG SSID for DPM
  diag: Update msg, log and event information
  defconfig: sdxpoorwills: enable POWER_RESET and DLOAD_MODE
  ARM: dts: msm: Add imem and restart DT node for sdxpoorwills
  msm: msm_bus: Introduce QoS config for QNOC4
  usb : dwc3: Initialize kernel stack variables properly
  clk: qcom: gcc-sdm845: Populate the hw fields of branch clocks
  msm: sde: remove error message for probe defer handling
  defconfig: sdm845: enable vendor device specific HID support
  msm: kgsl: Provide the context bank in SMMU_TABLE_UPDATE packet
  msm: kgsl: Fix print log for SMMU API failure
  ARM: dts: msm: Add ADC nodes for SDM845 QRD
  cpufreq: schedutil: Fix hispeed_freq condition
  msm: pcie: Fix lots of static checker errors
  scsi: ufs: ufs-qcom-ice: Initialize local variable in ice_cfg_start()
  drm/msm/sde: fix excl_rect validation in crtc
  drm/msm/sde: update connector roi print to match crtc print
  drm/msm/dsi-staging: enable interrupt support
  ARM: dts: msm: Fix NFC PMIC gpio configuration
  slimbus: Add support for IOMMU S1 translation
  msm: vidc: Simplify buffer map and unmap sequence
  [media] videobuf2-v4l2.c: send data_offset field to vb2 framework
  ASoC: sdm845: Add mixer controls for MI2S bit format
  Revert "mmc: core: extend SDR104 workaround for other paths"
  drm/msm/sde: move vblank to event thread
  drm/msm/sde: move release fence to crtc frame done event for cmd mode
  ARM: dts: msm: reduce VDD_APC0/1 CPR floor voltage to 568 mV for sdm845
  Revert "sched: Remove synchronize rcu/sched calls from _cpu_down"
  drm/msm/sde: move crtc frame event handling to event thread
  usb: gsi: Don't disable endpoints as part of flow control
  usb: gsi: Update TRB RING initialization with USB GSI OUT endpoint
  kernel: cpu: send CPU_UP_CANCELLED notifcation
  drivers base/topology: Convert to hotplug state machine
  ANDROID: sdcardfs: remove dead function open_flags_to_access_mode()
  msm: sde: check stride alignment before disabling partial writes
  kernel: cpu: Handle hotplug failure for state CPUHP_AP_IDLE_DEAD
  mmc: host: create a specific workqueue for clk gate
  clk: qcom: Remove certain BCR reset references on SDM845
  drm/msm: add split voting support to sde power handle
  drm/msm: increase minimum bandwidth to match clock plan
  drm/msm/sde: don't dirty scaler properties if null
  drm/msm: add ability to flag properties as dirty
  drm/msm: register sde rsc, dsi and phy to dbg dump
  msm: pcie: switch dma layer to map QGIC MSI address
  drm/msm/sde: avoid virtual plane debug dump register
  msm: ipa4: IPA_CLKON_CFG register configuration
  ARM: dts: msm: add topology node support dsi video and cmd mode sim panels
  ANDROID: android-base.cfg: split out arm64-specific configs
  sched: EAS: fix idle_get_state_idx()
  sched: EAS: skip energy_diff() for placement boosted tasks
  Linux 4.9.33
  sparc64: make string buffers large enough
  drm/i915: Always recompute watermarks when distrust_bios_wm is set, v2.
  drm/i915: Workaround VLV/CHV DSI scanline counter hardware fail
  s390/kvm: do not rely on the ILC on kvm host protection fauls
  xtensa: don't use linux IRQ #0
  RDMA/qedr: Return max inline data in QP query result
  RDMA/qedr: Don't spam dmesg if QP is in error state
  RDMA/qedr: Don't reset QP when queues aren't flushed
  RDMA/qedr: Fix and simplify memory leak in PD alloc
  RDMA/qedr: Dispatch port active event from qedr_add
  netfilter: nft_log: restrict the log prefix length to 127
  netfilter: nf_tables: fix set->nelems counting with no NLM_F_EXCL
  tipc: fix nametbl_lock soft lockup at node/link events
  tipc: add subscription refcount to avoid invalid delete
  tipc: fix connection refcount error
  tipc: ignore requests when the connection state is not CONNECTED
  ARCv2: smp-boot: wake_flag polling by non-Masters needs to be uncached
  ARC: smp-boot: Decouple Non masters waiting API from jump to entry point
  vhost/vsock: handle vhost_vq_init_access() error
  kernel/watchdog: prevent false hardlockup on overloaded system
  kernel/watchdog.c: move shared definitions to nmi.h
  kernel/watchdog.c: move hardlockup detector to separate file
  userfaultfd: fix SIGBUS resulting from false rwsem wakeups
  proc: add a schedule point in proc_pid_readdir()
  frv: add missing atomic64 operations
  frv: add atomic64_add_unless()
  romfs: use different way to generate fsid for BLOCK or MTD
  mn10300: fix build error of missing fpu_save()
  usb: musb: Fix external abort on non-linefetch for musb_irq_work()
  sctp: sctp_addr_id2transport should verify the addr before looking up assoc
  sctp: sctp gso should set feature with NETIF_F_SG when calling skb_segment
  bnxt_en: Fix RTNL lock usage on bnxt_get_port_module_status().
  bnxt_en: Fix RTNL lock usage on bnxt_update_link().
  bnxt_en: Enhance autoneg support.
  bnxt_en: Fix bnxt_reset() in the slow path task.
  net-next: ethernet: mediatek: change the compatible string
  r8152: avoid start_xmit to schedule napi when napi is disabled
  r8152: fix rtl8152_post_reset function
  r8152: re-schedule napi for tx
  r8152: check rx after napi is enabled
  r8152: avoid start_xmit to call napi_schedule during autosuspend
  nvmet-rdma: Fix missing dma sync to nvme data structures
  nfs: Fix "Don't increment lock sequence ID after NFS4ERR_MOVED"
  ravb: unmap descriptors when freeing rings
  drm/ast: Fixed system hanged if disable P2A
  drm/nouveau: Fix drm poll_helper handling
  drm/nouveau: Don't enabling polling twice on runtime resume
  drm/nouveau: Handle fbcon suspend/resume in seperate worker
  drm/nouveau: Rename acpi_work to hpd_work
  drm/nouveau: Intercept ACPI_VIDEO_NOTIFY_PROBE
  gtp: add genl family modules alias
  net: phy: micrel: add support for KSZ8795
  parisc, parport_gsc: Fixes for printk continuation lines
  net/mlx5: Return EOPNOTSUPP when failing to get steering name-space
  net/mlx5: E-Switch, Err when retrieving steering name-space fails
  drm/i915: Check for NULL i915_vma in intel_unpin_fb_obj()
  net: adaptec: starfire: add checks for dma mapping errors
  pinctrl: berlin-bg4ct: fix the value for "sd1a" of pin SCRD0_CRD_PRES
  drm: Don't race connector registration
  drm: prevent double-(un)registration for connectors
  cec: fix wrong last_la determination
  pinctrl: baytrail: Rectify debounce support (part 2)
  gianfar: synchronize DMA API usage by free_skb_rx_queue w/ gfar_new_page
  net/mlx4_core: Avoid command timeouts during VF driver device shutdown
  drm/nouveau/fence/g84-: protect against concurrent access to semaphore buffers
  drm/nouveau: prevent userspace from deleting client object
  ipv6: fix flow labels when the traffic class is non-0
  FS-Cache: Initialise stores_lock in netfs cookie
  fscache: Clear outstanding writes when disabling a cookie
  fscache: Fix dead object requeue
  net: fix ndo_features_check/ndo_fix_features comment ordering
  net: phy: Fix PHY module checks and NULL deref in phy_attach_direct()
  net: phy: Fix lack of reference count on PHY driver
  ethtool: do not vzalloc(0) on registers dump
  log2: make order_base_2() behave correctly on const input value zero
  kasan: respect /proc/sys/kernel/traceoff_on_warning
  shmem: fix sleeping from atomic context
  jump label: pass kbuild_cflags when checking for asm goto support
  PM / runtime: Avoid false-positive warnings from might_sleep_if()
  ARM: defconfigs: make NF_CT_PROTO_SCTP and NF_CT_PROTO_UDPLITE built-in
  ipv6: Fix IPv6 packet loss in scenarios involving roaming + snooping switches
  vfio/spapr_tce: Set window when adding additional groups to container
  ipv6: addrconf: fix generation of new temporary addresses
  net: thunderx: Fix PHY autoneg for SGMII QLM mode
  kernel/ucount.c: mark user_header with kmemleak_ignore()
  powerpc/powernv: Properly set "host-ipi" on IPIs
  i2c: piix4: Fix request_region size
  i2c: piix4: Request the SMBUS semaphore inside the mutex
  sierra_net: Add support for IPv6 and Dual-Stack Link Sense Indications
  sierra_net: Skip validating irrelevant fields for IDLE LSIs
  net: hns: Fix the device being used for dma mapping during TX
  NET: mkiss: Fix panic
  ibmvnic: Initialize completion variables before starting work
  ibmvnic: Call napi_disable instead of napi_enable in failure path
  NET: Fix /proc/net/arp for AX.25
  gfs2: Use rhashtable walk interface in glock_hash_walk
  tipc: Fix tipc_sk_reinit race conditions
  ipv6: Inhibit IPv4-mapped src address on the wire.
  ipv6: Handle IPv4-mapped src to in6addr_any dst.
  tcp: tcp_probe: use spin_lock_bh()
  net: xilinx_emaclite: fix receive buffer overflow
  net: xilinx_emaclite: fix freezes due to unordered I/O
  ibmvnic: Fix endian error when requesting device capabilities
  ibmvnic: Fix endian errors in error reporting output
  netfilter: nf_conntrack_sip: fix wrong memory initialisation
  partitions/msdos: FreeBSD UFS2 file systems are not recognized
  drm/i915: Prevent the system suspend complete optimization
  PCI/PM: Add needs_resume flag to avoid suspend complete optimization
  ARM: dts: msm: make DisplayPort crypto clock standalone on SDM845
  drm: msm: dp: remove crypto clock parsing and rate setting
  msm: ipa: optimize state machine in ipa uc offload
  usb: gadget: f_fs: Fix possibe deadlock
  FROMLIST: Remove the redundant skb->dev initialization in ip6_fragment
  FROMLIST: bpf: Remove duplicate tcp_filter hook in ipv6
  FROMLIST: ipv6: Initial skb->dev and skb->protocol in ip6_output
  FROMLIST: bpf:  skb progs cannot access ld_abs/ind
  mmc: block: Disable clock scaling during shutdown
  mmc: core: Use mmc_reset instead of power_restore
  trace: ipc_logging: Fix potential dead in ipc_log_write
  msm: sde: simulate timestamp on skipped inline interrupt
  drm/msm/sde: get previous inline fbo during atomic check
  ANDROID: uid_sys_stats: check previous uid_entry before call find_or_register_uid
  ARM: dts: msm: Enable avb 2.0 verity for vendor partition for SDM845
  msm: ipa: support aggregated ipa stats query
  ARM: dts: msm: make DSC command mode as default panel for SDM845
  drm/msm: support multi-display bw vote and top config
  dwc3: resize txfifo of IN/INT endpoint before enabling it
  msm: kgsl: Put back the process refcount
  drivers: lmh-dcvsh: Add debug support
  qseecom: Fix accessing userspace memory in kernel space
  ASoC: wsa881x: Assign device number in reset
  ARM: dts: msm: convert SPSS heap into secure CMA heap type for sdm845
  msm: ion: remove unused ion CP flags
  drm/msm/sde: correct AD4 bypass register setting
  sched: Remove debug WARN_ONCE messages
  Bluetooth: Enhance logging in btfm slim & audio codec drivers
  msm: kgsl: Add support for A615 GPU
  ARM: dts: msm: reduce VDD_APC0 CPR voltage adjustments for SDM845
  soc: qcom: Clear the memory before freeing it up

Change-Id: I89fa4c8025a8831075b038e2073f2645eca55a5e
Signed-off-by: default avatarAbhijit Trivedi <abhijitt@codeaurora.org>
parents 6f935319 a262fffa
Loading
Loading
Loading
Loading
+468 −0
Original line number Diff line number Diff line
Introduction
============

The goal of this debug feature is to provide a reliable, responsive,
accurate and secure debug capability to developers interested in
debugging MSM subsystem processor images without the use of a hardware
debugger.

The Debug Agent along with the Remote Debug Driver implements a shared
memory based transport mechanism that allows for a debugger (ex. GDB)
running on a host PC to communicate with a remote stub running on
peripheral subsystems such as the ADSP, MODEM etc.

The diagram below depicts end to end the components involved to
support remote debugging:


:               :
:    HOST (PC)  :  MSM
:  ,--------,   :   ,-------,
:  |        |   :   | Debug |                         ,--------,
:  |Debugger|<--:-->| Agent |                         | Remote |
:  |        |   :   |  App  |                  +----->| Debug  |
:  `--------`   :   |-------|    ,--------,    |      | Stub   |
:               :   | Remote|    |        |<---+      `--------`
:               :   | Debug |<-->|--------|
:               :   | Driver|    |        |<---+      ,--------,
:               :   `-------`    `--------`    |      | Remote |
:               :       LA         Shared      +----->| Debug  |
:               :                  Memory             | Stub   |
:               :                                     `--------`
:               :                               Peripheral Subsystems
:               :                                 (ADSP, MODEM, ...)


Debugger:       Debugger application running on the host PC that
                communicates with the remote stub.
                Examples: GDB, LLDB

Debug Agent:    Software that runs on the Linux Android platform
                that provides connectivity from the MSM to the
                host PC. This involves two portions:
                1) User mode Debug Agent application that discovers
                processes running on the subsystems and creates
                TCP/IP sockets for the host to connect to. In addition
                to this, it creates an info (or meta) port that
                users can connect to discover the various
                processes and their corresponding debug ports.

Remote Debug    A character based driver that the Debug
Driver:         Agent uses to transport the payload received from the
                host to the debug stub running on the subsystem
                processor over shared memory and vice versa.

Shared Memory:  Shared memory from the SMEM pool that is accessible
                from the Applications Processor (AP) and the
                subsystem processors.

Remote Debug    Privileged code that runs in the kernels of the
Stub:           subsystem processors that receives debug commands
                from the debugger running on the host and
                acts on these commands. These commands include reading
                and writing to registers and memory belonging to the
                subsystem's address space, setting breakpoints,
                single stepping etc.

Hardware description
====================

The Remote Debug Driver interfaces with the Remote Debug stubs
running on the subsystem processors and does not drive or
manage any hardware resources.

Software description
====================

The debugger and the remote stubs use Remote Serial Protocol (RSP)
to communicate with each other. This is widely used protocol by both
software and hardware debuggers. RSP is an ASCII based protocol
and used when it is not possible to run GDB server on the target under
debug.

The Debug Agent application along with the Remote Debug Driver
is responsible for establishing a bi-directional connection from
the debugger application running on the host to the remote debug
stub running on a subsystem. The Debug Agent establishes connectivity
to the host PC via TCP/IP sockets.

This feature uses ADB port forwarding to establish connectivity
between the debugger running on the host and the target under debug.

Please note the Debug Agent does not expose HLOS memory to the
remote subsystem processors.

Design
======

Here is the overall flow:

1) When the Debug Agent application starts up, it opens up a shared memory
based transport channel to the various subsystem processor images.

2) The Debug Agent application sends messages across to the remote stubs
to discover the various processes that are running on the subsystem and
creates debug sockets for each of them.

3) Whenever a process running on a subsystem exits, the Debug Agent
is notified by the stub so that the debug port and other resources
can be reclaimed.

4) The Debug Agent uses the services of the Remote Debug Driver to
transport payload from the host debugger to the remote stub and vice versa.

5) Communication between the Remote Debug Driver and the Remote Debug stub
running on the subsystem processor is done over shared memory (see figure).
SMEM services are used to allocate the shared memory that will
be readable and writeable by the AP and the subsystem image under debug.

A separate SMEM allocation takes place for each subsystem processor
involved in remote debugging. The remote stub running on each of the
subsystems allocates a SMEM buffer using a unique identifier so that both
the AP and subsystem get the same physical block of memory. It should be
noted that subsystem images can be restarted at any time.
However, when a subsystem comes back up, its stub uses the same unique
SMEM identifier to allocate the SMEM block. This would not result in a
new allocation rather the same block of memory in the first bootup instance
is provided back to the stub running on the subsystem.

An 8KB chunk of shared memory is allocated and used for communication
per subsystem. For multi-process capable subsystems, 16KB chunk of shared
memory is allocated to allow for simultaneous debugging of more than one
process running on a single subsystem.

The shared memory is used as a circular ring buffer in each direction.
Thus we have a bi-directional shared memory channel between the AP
and a subsystem. We call this SMQ. Each memory channel contains a header,
data and a control mechanism that is used to synchronize read and write
of data between the AP and the remote subsystem.

Overall SMQ memory view:
:
:    +------------------------------------------------+
:    | SMEM buffer                                    |
:    |-----------------------+------------------------|
:    |Producer: LA           | Producer: Remote       |
:    |Consumer: Remote       |           subsystem    |
:    |          subsystem    | Consumer: LA           |
:    |                       |                        |
:    |               Producer|                Consumer|
:    +-----------------------+------------------------+
:    |                       |
:    |                       |
:    |                       +--------------------------------------+
:    |                                                              |
:    |                                                              |
:    v                                                              v
:    +--------------------------------------------------------------+
:    |   Header  |       Data      |            Control             |
:    +-----------+---+---+---+-----+----+--+--+-----+---+--+--+-----+
:    |           | b | b | b |     | S  |n |n |     | S |n |n |     |
:    |  Producer | l | l | l |     | M  |o |o |     | M |o |o |     |
:    |    Ver    | o | o | o |     | Q  |d |d |     | Q |d |d |     |
:    |-----------| c | c | c | ... |    |e |e | ... |   |e |e | ... |
:    |           | k | k | k |     | O  |  |  |     | I |  |  |     |
:    |  Consumer |   |   |   |     | u  |0 |1 |     | n |0 |1 |     |
:    |    Ver    | 0 | 1 | 2 |     | t  |  |  |     |   |  |  |     |
:    +-----------+---+---+---+-----+----+--+--+-----+---+--+--+-----+
:                                       |           |
:                                       +           |
:                                                   |
:                          +------------------------+
:                          |
:                          v
:                        +----+----+----+----+
:                        | SMQ Nodes         |
:                        |----|----|----|----|
:                 Node # |  0 |  1 |  2 | ...|
:                        |----|----|----|----|
: Starting Block Index # |  0 |  3 |  8 | ...|
:                        |----|----|----|----|
:            # of blocks |  3 |  5 |  1 | ...|
:                        +----+----+----+----+
:

Header: Contains version numbers for software compatibility to ensure
that both producers and consumers on the AP and subsystems know how to
read from and write to the queue.
Both the producer and consumer versions are 1.
:     +---------+-------------------+
:     | Size    | Field             |
:     +---------+-------------------+
:     | 1 byte  | Producer Version  |
:     +---------+-------------------+
:     | 1 byte  | Consumer Version  |
:     +---------+-------------------+


Data: The data portion contains multiple blocks [0..N] of a fixed size.
The block size SM_BLOCKSIZE is fixed to 128 bytes for header version #1.
Payload sent from the debug agent app is split (if necessary) and placed
in these blocks. The first data block is placed at the next 8 byte aligned
address after the header.

The number of blocks for a given SMEM allocation is derived as follows:
  Number of Blocks = ((Total Size - Alignment - Size of Header
                      - Size of SMQIn - Size of SMQOut)/(SM_BLOCKSIZE))

The producer maintains a private block map of each of these blocks to
determine which of these blocks in the queue is available and which are free.

Control:
The control portion contains a list of nodes [0..N] where N is number
of available data blocks. Each node identifies the data
block indexes that contain a particular debug message to be transferred,
and the number of blocks it took to hold the contents of the message.

Each node has the following structure:
:     +---------+-------------------+
:     | Size    | Field             |
:     +---------+-------------------+
:     | 2 bytes |Staring Block Index|
:     +---------+-------------------+
:     | 2 bytes |Number of Blocks   |
:     +---------+-------------------+

The producer and the consumer update different parts of the control channel
(SMQOut / SMQIn) respectively. Each of these control data structures contains
information about the last node that was written / read, and the actual nodes
that were written/read.

SMQOut Structure (R/W by producer, R by consumer):
:     +---------+-------------------+
:     | Size    | Field             |
:     +---------+-------------------+
:     | 4 bytes | Magic Init Number |
:     +---------+-------------------+
:     | 4 bytes | Reset             |
:     +---------+-------------------+
:     | 4 bytes | Last Sent Index   |
:     +---------+-------------------+
:     | 4 bytes | Index Free Read   |
:     +---------+-------------------+

SMQIn Structure (R/W by consumer, R by producer):
:     +---------+-------------------+
:     | Size    | Field             |
:     +---------+-------------------+
:     | 4 bytes | Magic Init Number |
:     +---------+-------------------+
:     | 4 bytes | Reset ACK         |
:     +---------+-------------------+
:     | 4 bytes | Last Read Index   |
:     +---------+-------------------+
:     | 4 bytes | Index Free Write  |
:     +---------+-------------------+

Magic Init Number:
Both SMQ Out and SMQ In initialize this field with a predefined magic
number so as to make sure that both the consumer and producer blocks
have fully initialized and have valid data in the shared memory control area.
  Producer Magic #: 0xFF00FF01
  Consumer Magic #: 0xFF00FF02

SMQ Out's Last Sent Index and Index Free Read:
  Only a producer can write to these indexes and they are updated whenever
  there is new payload to be inserted into the SMQ in order to be sent to a
  consumer.

  The number of blocks required for the SMQ allocation is determined as:
   (payload size + SM_BLOCKSIZE - 1) / SM_BLOCKSIZE

  The private block map is searched for a large enough continuous set of blocks
  and the user data is copied into the data blocks.

  The starting index of the free block(s) is updated in the SMQOut's Last Sent
  Index. This update keeps track of which index was last written to and the
  producer uses it to determine where the the next allocation could be done.

  Every allocation, a producer updates the Index Free Read from its
  collaborating consumer's Index Free Write field (if they are unequal).
  This index value indicates that the consumer has read all blocks associated
  with allocation on the SMQ and that the producer can reuse these blocks for
  subsquent allocations since this is a circular queue.

  At cold boot and restart, these indexes are initialized to zero and all
  blocks are marked as available for allocation.

SMQ In's Last Read Index and Index Free Write:
  These indexes are written to only by a consumer and are updated whenever
  there is new payload to be read from the SMQ. The Last Read Index keeps
  track of which index was last read by the consumer and using this, it
  determines where the next read should be done.
  After completing a read, Last Read Index is incremented to the
  next block index. A consumer updates Index Free Write to the starting
  index of an allocation whenever it has completed processing the blocks.
  This is an optimization that can be used to prevent an additional copy
  of data from the queue into a client's data buffer and the data in the queue
  itself can be used.
  Once Index Free Write is updated, the collaborating producer (on the next
  data allocation) reads the updated Index Free Write value and it then
  updates its corresponding SMQ Out's Index Free Read and marks the blocks
  associated with that index as available for allocation. At cold boot and
  restart, these indexes are initialized to zero.

SMQ Out Reset# and SMQ In Reset ACK #:
  Since subsystems can restart at anytime, the data blocks and control channel
  can be in an inconsistent state when a producer or consumer comes up.
  We use Reset and Reset ACK to manage this. At cold boot, the producer
  initializes the Reset# to a known number ex. 1. Every other reset that the
  producer undergoes, the Reset#1 is simply incremented by 1. All the producer
  indexes are reset.
  When the producer notifies the consumer of data availability, the consumer
  reads the producers Reset # and copies that into its SMQ In Reset ACK#
  field when they differ. When that occurs, the consumer resets its
  indexes to 0.

6) Asynchronous notifications between a producer and consumer are
done using the SMP2P service which is interrupt based.

Power Management
================

None

SMP/multi-core
==============

The driver uses completion to wake up the Debug Agent client threads.

Security
========

From the perspective of the subsystem, the AP is untrusted. The remote
stubs consult the secure debug fuses to determine whether or not the
remote debugging will be enabled at the subsystem.

If the hardware debug fuses indicate that debugging is disabled, the
remote stubs will not be functional on the subsystem. Writes to the
queue will only be done if the driver sees that the remote stub has been
initialized on the subsystem.

Therefore even if any untrusted software running on the AP requests
the services of the Remote Debug Driver and inject RSP messages
into the shared memory buffer, these RSP messages will be discarded and
an appropriate error code will be sent up to the invoking application.

Performance
===========

During operation, the Remote Debug Driver copies RSP messages
asynchronously sent from the host debugger to the remote stub and vice
versa. The debug messages are ASCII based and relatively short
(<25 bytes) and may once in a while go up to a maximum 700 bytes
depending on the command the user requested. Thus we do not
anticipate any major performance impact. Moreover, in a typical
functional debug scenario performance should not be a concern.

Interface
=========

The Remote Debug Driver is a character based device that manages
a piece of shared memory that is used as a bi-directional
single producer/consumer circular queue using a next fit allocator.
Every subsystem, has its own shared memory buffer that is managed
like a separate device.

The driver distinguishes each subsystem processor's buffer by
registering a node with a different minor number.

For each subsystem that is supported, the driver exposes a user space
interface through the following node:
    - /dev/rdbg-<subsystem>
    Ex. /dev/rdbg-adsp (for the ADSP subsystem)

The standard open(), close(), read() and write() API set is
implemented.

The open() syscall will fail if a subsystem is not present or supported
by the driver or a shared memory buffer cannot be allocated for the
AP - subsystem communication. It will also fail if the subsytem has
not initialized the queue on its side. Here are the error codes returned
in case a call to open() fails:
ENODEV - memory was not yet allocated for the device
EEXIST - device is already opened
ENOMEM - SMEM allocation failed
ECOMM - Subsytem queue is not yet setup
ENOMEM - Failure to initialize SMQ

read() is a blocking call that will return with the number of bytes written
by the subsystem whenever the subsystem sends it some payload. Here are the
error codes returned in case a call to read() fails:
EINVAL - Invalid input
ENODEV - Device has not been opened yet
ERESTARTSYS - call to wait_for_completion_interruptible is interrupted
ENODATA - call to smq_receive failed

write() attempts to send user mode payload out to the subsystem. It can fail
if the SMQ is full. The number of bytes written is returned back to the user.
Here are the error codes returned in case a call to write() fails:
EINVAL - Invalid input
ECOMM - SMQ send failed

In the close() syscall, the control information state of the SMQ is
initialized to zero thereby preventing any further communication between
the AP and the subsystem. Here is the error code returned in case
a call to close() fails:
ENODEV - device wasn't opened/initialized

The Remote Debug driver uses SMP2P for bi-directional AP to subsystem
notification. Notifications are sent to indicate that there are new
debug messages available for processing. Each subsystem that is
supported will need to add a device tree entry per the usage
specification of SMP2P driver.

In case the remote stub becomes non operational or the security configuration
on the subsystem does not permit debugging, any messages put in the SMQ will
not be responded to. It is the responsibility of the Debug Agent app and the
host debugger application such as GDB to timeout and notify the user of the
non availability of remote debugging.

Driver parameters
=================

None

Config options
==============

The driver is configured with a device tree entry to map an SMP2P entry
to the device. The SMP2P entry name used is "rdbg". Please see
kernel\Documentation\arm\msm\msm_smp2p.txt for information about the
device tree entry required to configure SMP2P.

The driver uses the SMEM allocation type SMEM_LC_DEBUGGER to allocate memory
for the queue that is used to share data with the subsystems.

Dependencies
============

The Debug Agent driver requires services of SMEM to
allocate shared memory buffers.

SMP2P is used as a bi-directional notification
mechanism between the AP and a subsystem processor.

User space utilities
====================

This driver is meant to be used in conjunction with the user mode
Remote Debug Agent application.

Other
=====

None

Known issues
============
For targets with an external subsystem, we cannot use
shared memory for communication and would have to use the prevailing
transport mechanisms that exists between the AP and the external subsystem.

This driver cannot be leveraged for such targets.

To do
=====

None
+44 −0
Original line number Diff line number Diff line
* Memory Share Driver (MEMSHARE)

The Memshare driver implements a Kernel QMI service on the
LA-APSS, which is responsible for providing contiguous physical
memory to MPSS for use cases when the modem requires additional
memory (e.g. GPS).

Required properties for Memshare

-Root Node-

- compatible:	Must be "qcom,memshare"

Required properties for child nodes:

- compatible:	Must be "qcom,memshare-peripheral"

- qcom,peripheral-size:	Indicates the size (in bytes) required for that child.

- qcom,client-id:	Indicates the client id of the child node.

- label:	Indicates the peripheral information for the node. Should be one of
  the following:
  - modem	/* Represent Modem Peripheral */
  - adsp	/* Represent ADSP Peripheral */
  - wcnss	/* Represent WCNSS Peripheral */

Optional properties for child nodes:

- qcom,allocate-boot-time:	Indicates whether clients needs boot time memory allocation.

Example:

qcom,memshare {
	compatible = "qcom,memshare";

	qcom,client_1 {
		compatible = "qcom,memshare-peripheral";
		qcom,peripheral-size = <0x200000>;
		qcom,client-id = <0>;
		qcom,allocate-boot-time;
		label = "modem";
	};
};
+9 −8
Original line number Diff line number Diff line
@@ -28,9 +28,6 @@ Required properties:
	- qcom,default-level: The default low power level that a cluster is
	programmed. The SPM of the corresponding device is configured at this
	low power mode by default.
	- qcom,cpu: List of CPU phandles to identify the CPUs associated with
	this cluster. This property is required if and only if the cluster
	node contains a qcom,pm-cpu node.

	qcom,pm-cluster contains qcom,pm-cluster-level nodes which identify
	the various low power modes that the cluster can enter. The
@@ -103,9 +100,13 @@ Required properties:
					power collapse (PC)

[Node bindings for qcom,pm-cpu]
qcom,pm-cpu contains the low power modes that a cpu could enter. Currently it
doesn't have any required properties and is a container for
qcom,pm-cpu-levels.
qcom,pm-cpu contains the low power modes that a cpu could enter and the CPUs
that share the parameters.It contains the following properties.
	- qcom,cpu: List of CPU phandles to identify the CPUs associated with
	this cluster.
	- qcom,pm-cpu-levels: The different low power modes that a CPU could
	enter. The following section explains the required properties of this
	node.

[Node bindings for qcom,pm-cpu-levels]
 Required properties:
@@ -184,7 +185,6 @@ qcom,lpm-levels {
			label = "a53";
			qcom,spm-device-names = "l2";
			qcom,default-level=<0>;
			qcom,cpu = <&CPU0 &CPU1 &CPU2 &CPU3>;

			qcom,pm-cluster-level@0{
				reg = <0>;
@@ -210,6 +210,7 @@ qcom,lpm-levels {
			qcom,pm-cpu {
				#address-cells = <1>;
				#size-cells = <0>;
				qcom,cpu = <&CPU0 &CPU1 &CPU2 &CPU3>;
				qcom,pm-cpu-level@0 {
					reg = <0>;
					qcom,spm-cpu-mode = "wfi";
@@ -255,7 +256,6 @@ qcom,lpm-levels {
			label = "a57";
			qcom,spm-device-names = "l2";
			qcom,default-level=<0>;
			qcom,cpu = <&CPU4 &CPU5 &CPU6 &CPU7>;

			qcom,pm-cluster-level@0{
				reg = <0>;
@@ -281,6 +281,7 @@ qcom,lpm-levels {
			qcom,pm-cpu {
				#address-cells = <1>;
				#size-cells = <0>;
				qcom,cpu = <&CPU4 &CPU5 &CPU6 &CPU7>;
				qcom,pm-cpu-level@0 {
					reg = <0>;
					qcom,spm-cpu-mode = "wfi";
+20 −0
Original line number Diff line number Diff line
@@ -121,6 +121,20 @@ qcom,blacklist: An array of phandles that represent devices that this de
			cannot connect to either directly or via any number of
			intermediate nodes.
qcom,agg-ports:		The number of aggregation ports on the bus.
qcom,node-qos-bcms:	Optional property to target specific BCMs to toggle during QoS configuration,
			this is to ensure QoS register space is clocked and accessible. Array is
			defined as follows: BCM node ID, VoteX, VoteY. The vectors must be defined in
			sets of the three values aforementioned.
qcom,prio:		Default fixed priority for bus master.
qcom,qos-lim-params:	Array containing QoS limiter configurations defined as: Bandwidth, Saturation.
			Must define "qcom,qos-lim-en" for these settings to take effect.
qcom,qos-lim-en:	Boolean to enable limiter settings, default is disabled.
qcom,qos-reg-params:	Array containing QoS regulator configurations defined as: Low Priority, High
			Priority, Bandwidth, Saturation. Must define "qcom,qos-reg-regmode" for these
			settings to take effect.
qcom,qos-reg-mode:	Array containing QoS regulator mode enablement: Read Enable, Write Enable,
			default is disabled.
qcom,forwarding:	Boolean indicate Urgent Forwarding enablement.

The following properties are optional as collecting data via coresight might
and are present on child nodes that represent NOC devices. The documentation
@@ -172,6 +186,12 @@ Example:
				<&clock_gcc clk_q1_clk>;
			q0-clk-supply = <&gdsc_q0_clk>;
		};
		qcom,node-qos-bcms = <0x7011 0 1>;
		qcom,prio = 1;
		qcom,qos-lim-params = <1000 1000>;
		qcom,qos-lim-en:
		qcom,qos-reg-params = <1 2 1000 1000>;
		qcom,qos-reg-mode = <1 1>;
        };

        mm_int_bimc: mm-int-bimc {
+2 −0
Original line number Diff line number Diff line
@@ -17,6 +17,8 @@ Optional properties:
			by pil. Absence of this property indicates that
			subsystem loading through pil voting is disabled for
			that subsystem.
-qcom,dynamic-wakeup-source:	Boolean property to indicate that G-Link
				transport supports dynamic wakeup source

Example:
	qcom,ipc_router_modem_xprt {
Loading