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

Commit 5d7a0721 authored by Linux Build Service Account's avatar Linux Build Service Account
Browse files

Promotion of kernel.lnx.4.4-161219.1.

CRs      Change ID                                   Subject
--------------------------------------------------------------------------------------------------------------
1100176   Id6787274bf5e1dce8b813835af66874f667144ff   ARM: dts: msm: Add device tree for msmfalcon QRD
1012955   I47eb863c4b384bb12e2ff21c44104847b0baa7ee   soc: qcom: pil-q6v5: Update cx_max to INT_MAX while voti
965207   Ib5ec650884ad06394280416ccf877c1ccce1eaaf   USB: dwc3-msm: Disable Update xfer for DBM on ep disable
1043997   I39c5ac30070ff8555ed712a99796b9405717b072   defconfig: Enable config INET_DIAG_DESTROY
1102531   I6a6ba17e2dffddc5cdc2de00da737fedf03c9476   soc: qcom: glink: Add pending remote done packets to int
1089373   I3301d822a3664869d8531d7ff0efa20e22996763   ARM: dts: msm: Enable CAM1 on msmfalcon interposer
1073433   Ieb5fd8429726efd7686387bccb55952fb053280a   mm: cma: check the max limit for cma allocation
1098101   Ib330c4f9b6d55c75aeb8e8fd5cea4dd92b0f64cf   qpnp-fg-gen3: add support to configure Rconn
1099374   I50681c877917a58c3d70262597300b0d66b1e3a8   phy: ufs: add UFS PHY support for msmfalcon
1094014   Iac5c25ba5dc7d22cd7a4961dd5058db0088995ca   ARM: dts: msm: specify a flag to control encryption key
1095803   Iedd9c4c0763c29b26e91e261d9a8d0e4e24b7bb2   msm: vidc: remove redundant init_completion() calls
1093630   If17c4ab996be31563a260ba3c326ee5e8f58e695   ARM: dts: msm: Add cpp src clock rates configuration for
1094014   If40f83a943e5ae8333d171c21823a16816d7ddd4   qseecom: add configurable encryption key size
1100431   I7b2e59606e73c467c2b862f0162a176611d7ae3d   clk: msm: clock-gpu-8998: Program the Droop Detector gfx
1091942   Ie9b7e35ad396ba8eed20dcca1f655b3e23f6626c   msm: vidc: Add port information to flush_done event
1089405   I8259722a890d8388b62294de40cb29a9005f1a3e   defconfig: enable qdss nodes in msmfalcon
1097035   I9f70b74b7ccfb84fec721dbfa1d838d183419cb9   ARM: dts: msm: Enable bluetooth for wcn3990 on msm8998 i
993786   I13c601f0e48d847b322a2761cd52268963cacf01   usb: gadget: composite: Add spinlock protection for usb
1078814   I82febbc28c05563d052c6eed034adc817df39790   smb138x-charger: enable the watchdog timer when parallel
1090409   Iafafa4bece8ea5b6afd782fede3d44af69114ba1   ARM: dts: msm: Add VDD_APC CPR voltage margins for msm89
1095127   I81c32a876b33f5a7773485a76897ff9cbed45a76   clk: qcom: Add support for debugfs measure clock
985849   If9307ffd47854afe6101671ce911631b52a6dff9   msm: fd: Support dynamic update of clock and bus setting
1084618   I6e84fc016a7bea69bb4d5d1991d8b5500244307d   msm: rdbg: Add snapshot of remote debugger driver
1088163 1088206   I04497bc11e01c3df4beadfd6d9b06ab4321f1723   msm: mdss: Clear compat structures before copying to use
1099374   I42e796ca7e1883f5c2077660dbcde87cd4b30038   ARM: dts: msm: add ufs support to msmfalcon
1098361   I57aa131a67242d53164a52784ebfe619d77aac15   defconfig: msm: Enable SMCInvoke driver for msmfalcon_32
1093947   I4f8ca4182f9807d970184c85a58989b41755b163   ARM: dts: msm: Add camera dtsi for msmfalcon interposer
1098361   Id85cea7720343cb4101155d5f33f93a1b9946abf   msm: mink: Fix compilation issues for 32bit targets
1100152   Ib2d83635af352513064a3c8b717541bc47b2f875   ARM: dts: msm: Move to RPM based regulators for msmtrito
1094763   I754a43a953a311938f4e4103879bff2c2a4551a0   ASoC: msm: Disable audio SSR for msmfalcon
961394   I1ed035c8a8efb20d31da9556c5d5b810f81c44d2   msm: camera: fd: Add CPP VBIF error handling
1097587   I4546a7994fc0442bf82d36ca0a404a57be8c7dd3   ARM: dts: msm: disable VDD_APC0/1 CPR aging adjustments
1097768   I8b69e8590e3de1aa79469003633b8837451bf3ed   defconfig: msmfalcon: enable host CDC-ECM class support
1089896   I242478408f8cb60fb5af5c741dbf2e8bf3e38af8   usb: gadget: Reset notify count to 0 upon completion for
1100450   Iba036ce43656979df0b9ea228b57bc980c4c53bc   defconfig: arm64: Enable USBNET driver
991135   I4b9cbba1261eafd83c67275c5d7dc3defbb3d990   msm: camera: isp: Fix HVX streaming after crash
1100152   Ib892e3c550e7486d615e9d29e701d2b0c19c45f0   ARM: dts: msm: Add SPMI and PMIC nodes for msmtriton
1098549   I38ef1c9478450c98c8379d8b1c085b31209cb48e   msm: cpp: Reset vbif and load firmware on poll failures
1097304   I9a7618850e45bd78f74fb2833932e3f4fd776392   msm: sensor: fixing errors due to csiphy clock release
994317   I165f1c39c1332737a644c6650bc40f4c718a7ee8   msm: camera: Initialize variables to default
1099743   I5e4e7beda47cbbd43783048c64fe5adb2beb7023   msm: ion: Export msm_ion_do_cache_offset_op to do cache
961394   I57d616e9cf89f7722483fe0d49a0b5e44f0e4782   msm: fd: Handle timeout on stream off
1100249   Ib3f719e218d972b75936d9960e342ecfe6787301   spcom: print error messages when remote SP subsystem cra
1058877   Id37ccc891bfd2bff48e3c2e9c3242cbe6148d3f7   msm: sensor: Fix to read the parameters from slave info
1001532   I81c87cac13e33e0678b3bb92f58da0699d9197c2   msm: camera: Initialize return value to 0
1098577   Ie70a698fbed442e8826f0bc30c5ef6bdfd5b3e1f   ARM: dts: msm: reduce VDD_GFX CPR max floor to ceiling r
1098648   I28a4f495293863361843eb30b2d20f1f57889f95   usb: qusb2: De-assert TCSR_QUSB2PHY_CLAMP_DIG_N_1P8 upon
1102057   I9082d4d40b70d0ca8cc8fbc6aadf14b2f0aedd0c   icnss: Do not collect MSA0 dump during Modem WDOG bite
961394   Id3612b134e3db19f1f8e2e2b3b444f0b6284c4d1   msm: camera: cpp: Add cpp bus error handler
1100015   I17c5d04d8492f237d75eaf433a34b3451428d537   ARM: dts: msm: Add temp alarm nodes for pm/pm2falcon
1097768   Ib283941037469833786b793c1e31e69e1c95d45d   ARM: dts: msm: Add qcom,msm-imem-diag-dload node on msmf
1100250   I6cca614327f7b8e3216e3872a36f08f33a65b23e   spcom: cleanup rx-abort flag when channel closed
1099837   Idad0f80eda6192ccae9e824f1f76c7071806ffec   usb: phy: qmp: Select usb3 phy mode before initializing
1102148   I073733b8a56b57f14906b25cba08012c2f0b414a   soc: qcom: ssr: add crash status to know why subsys cras
1097587   I4d413a2b3320d421c487aff1a97e72bd2678b19f   ARM: dts: msm: disable VDD_GFX CPR aging adjustments on
1099139   I2b8e28f6bfe1a5813410c7b1276d4e229eb67e84   qpnp-fg-gen3: fix a possible wake source count leak
1098099   I22ab702e10c310e4f847c6c81a48a8f0f3188429   qpnp-fg-gen3: Read debug battery id thresholds from RR_A
1091972   I295ea05892075c43d389b3b9a20ea4f68daeba3b   ARM: dts: msm: Configure lmh hardware for msmfalcon

Change-Id: Ia7d2513f9bea1c4272e5072184097f2146aeae3a
CRs-Fixed: 993786, 1095803, 1089896, 1001532, 965207, 1098101, 1099139, 1099374, 985849, 1098577, 1102148, 1102531, 1099743, 1095127, 961394, 1073433, 1084618, 1097587, 994317, 1094014, 1091972, 1097304, 1098648, 1100431, 1012955, 1100450, 1097768, 1098361, 1089405, 1102057, 1093947, 1093630, 1094763, 1043997, 1100015, 1089373, 1088163, 1097035, 1098549, 1100250, 1088206, 991135, 1078814, 1100152, 1100249, 1100176, 1058877, 1090409, 1091942, 1098099, 1099837
parents 2011e141 eac971fc
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
+1 −0
Original line number Diff line number Diff line
@@ -264,6 +264,7 @@ compatible = "qcom,msmfalcon-sim"
compatible = "qcom,msmfalcon-rumi"
compatible = "qcom,msmfalcon-cdp"
compatible = "qcom,msmfalcon-mtp"
compatible = "qcom,msmfalcon-qrd"
compatible = "qcom,msmtriton-rumi"
compatible = "qcom,msm8952-rumi"
compatible = "qcom,msm8952-sim"
+14 −0
Original line number Diff line number Diff line
@@ -36,6 +36,12 @@ First Level Node - FG Gen3 device
	Definition: For details about IIO bindings see:
		    Documentation/devicetree/bindings/iio/iio-bindings.txt

- qcom,rradc-base
	Usage:      required
	Value type: <u32>
	Definition: Should specify the base address of RR_ADC peripheral. This
		    is used for reading certain peripheral registers under it.

- qcom,fg-cutoff-voltage
	Usage:      optional
	Value type: <u32>
@@ -260,6 +266,13 @@ First Level Node - FG Gen3 device
		    is specified to make it fully functional. Value has no
		    unit. Allowed range is 0 to 62200 in micro units.

- qcom,fg-rconn-mohms
	Usage:      optional
	Value type: <u32>
	Definition: Battery connector resistance (Rconn) in milliohms. If Rconn
		    is specified, then ESR to Rslow scaling factors will be
		    updated to account it for an accurate ESR.

==========================================================
Second Level Nodes - Peripherals managed by FG Gen3 driver
==========================================================
@@ -290,6 +303,7 @@ pmi8998_fg: qpnp,fg {
	qcom,pmic-revid = <&pmi8998_revid>;
	io-channels = <&pmi8998_rradc 3>;
	io-channel-names = "rradc_batt_id";
	qcom,rradc-base = <0x4500>;
	qcom,ki-coeff-soc-dischg = <30 60 90>;
	qcom,ki-coeff-med-dischg = <800 1000 1400>;
	qcom,ki-coeff-hi-dischg = <1200 1500 2100>;
+3 −0
Original line number Diff line number Diff line
@@ -26,6 +26,7 @@ Optional properties:
  - vdd-hba-supply   : handle for fixed power regulator
  - qcom,qsee-reentrancy-support: indicates the qsee reentrancy phase supported by the target
  - qcom,commonlib64-loaded-by-uefi: indicates commonlib64 is loaded by uefi already
  - qcom,fde-key-size: indicates which FDE key size is used in device.

Example:
	qcom,qseecom@fe806000 {
@@ -46,6 +47,7 @@ Example:
		qcom,msm_bus,num_paths = <1>;
		qcom,no-clock-support;
		qcom,appsbl-qseecom-support;
                qcom,fde-key-size;
		qcom,msm_bus,vectors =
			<55 512 0 0>,
			<55 512 3936000000 393600000>,
@@ -72,6 +74,7 @@ Example: The following dts setup is the same as the example above.
		qcom,msm_bus,num_paths = <1>;
		qcom,no-clock-support;
		qcom,appsbl-qseecom-support;
                qcom,fde-key-size;
		qcom,msm_bus,vectors =
			<55 512 0 0>,
			<55 512 3936000000 393600000>,
+3 −1
Original line number Diff line number Diff line
@@ -9,7 +9,9 @@ contain a phandle reference to UFS PHY node.
Required properties:
- compatible        : compatible list, contains "qcom,ufs-phy-qmp-20nm"
		      or "qcom,ufs-phy-qmp-14nm" or "qcom,ufs-phy-qmp-v3"
		      or "qcom,ufs-phy-qrbtc-v2" according to the relevant phy in use.
		      or "qcom,ufs-phy-qrbtc-v2" or
		      "qcom,ufs-phy-qmp-v3-falcon"
		      according to the relevant phy in use.
- reg               : should contain PHY register address space (mandatory),
- reg-names         : indicates various resources passed to driver (via reg proptery) by name.
                      Required "reg-names" is "phy_mem".
Loading