As debugfs interface is intended to test the respective ssr, remove
from the driver to make sure it won't be available by default.
CRs-Fixed: 2025661
Change-Id: I6af9a8333c8028611f889cc2f9b0beb37ef12c9b
Signed-off-by: Satya Durga Srinivasu Prabhala <satyap@codeaurora.org>
After sending a sysmon shutdown request to the SSCTL service on the
subsystem, wait for the service to set a shutdown_ack smp2p bit in
addition to sending the indication message back.
CRs-Fixed: 987855
Change-Id: I231607a8ade983c9a2c2c0a39d53023ced6e81fb
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
Add support to make scm_calls to TZ to inform modem start
address and size so that TZ can unmap this range to avoid
speculative access.
Change-Id: I4640ddab56991522870e9879d17fe5732dc40223
Signed-off-by: Avaneesh Kumar Dwivedi <akdwived@codeaurora.org>
After sending a sysmon shutdown request to the SSCTL service on the
subsystem, wait for the service to set a shutdown_ack smp2p bit in
addition to sending the indication message back.
Change-Id: I231607a8ade983c9a2c2c0a39d53023ced6e81fb
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
It is useful to retrieve small memory areas from a device
when performing a subsystem restart. For example, shared
memory may contain logging information that can help
triage a problem. Implementations may choose to dump such
memory sections when the enable_mini_ramdumps flag is set.
Change-Id: I217ceed0a5d1ba3130757428b5f48cba4d1203ad
Signed-off-by: Vikram Mulukutla <markivx@codeaurora.org>
Certain subsystems may require memory associated with
a subsystem to be freed after a memory dump has been
taken. Previously, this was expected to be done in the
shutdown callback. Add a new callback that implementations
can take advantage of to free memory when they see fit,
either in shutdown or in the new callback.
Change-Id: I28e5ab2d7be6937e15b9c129dcabc7963462249e
Signed-off-by: Vikram Mulukutla <markivx@codeaurora.org>
On newer targets having a common single binary, subsystem
clients will need the option to specify the firmware image
to use for booting up the subsystem. Provide a new API for
the same.
Clients will now be able to specify the firmware name to use
as one of the parameters to this API. Also, for clients which
trigger subsystem boot and shutdown via the open and close file
ops, a sysfs node "firmware_name" is exposed. By writing to this
node, the client can change the firmware used to boot dynamically.
Change-Id: I294bd8c23bb208d0f7168e7bd7d81980223275d2
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
Add a new system_debug subsystem property. This is set as
"reset" by default. When this parameter is listed as "set"
for a subsystem and a wdog bite happens, the SSR framework
goes ahead and triggers a kernel panic.
This feature is strictly intented only for debugging cases
where a system ramdump is more desirable than subsystem
ramdumps.
CRs-Fixed: 746414
Change-Id: Ie8f364fe0f9fd8f417f080135ab497e816f7fcf4
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
Add and derive the err_fatal_gpio property for the subsystem
from the existing entry in DT.
CRs-Fixed: 746414
Change-Id: I20e587a0a3c4be923a126733a2300529f0120b06
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
A feature in the modem requires that the modem be
restarted as part of normal operation rather than
as a response to a fatal error. In these instances,
it is preferred that ramdump collection be avoided.
If a certain GPIO is set, disable ramdump collection
during a subsystem restart sequence.
Change-Id: I5eaedf8f43c06124cc30c3e8f5e8ed882e25dd49
Signed-off-by: Vikram Mulukutla <markivx@codeaurora.org>
When the ref-count for a subsystem goes down to 0, i.e.
there are no current clients for it, the subsystem is
shutdown by calling the shutdown callbacks registered
by the subsystem driver.
Before doing so, send the sysmon shutdown command to
the subsystem so that it could take care of any cleanup
required at its end.
Change-Id: I36559de328581b9c856e042eadcf45b02e2c764b
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
Add a "qcom,sysmon-id" property to subsystem dt entries
for storing the platform device id that sysmon is probed
with for that subsystem. This information is required to
remove having to statically store the names of subsystems
that have sysmon support.
Change-Id: I2fcc8718076877d80786dba4ed5c6216bbb67312
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
Add a "qcom,ssctl-instance-id" property to subsystem dt entries
for storing the instance id with which the subsystem driver
connects to the QMI Subsystem Control(SSCTL) service. This
service is hosted by a hardware subsystem with the APSS being
the client, to issue commands such as shutdown or to pass event
information.
Change-Id: Ic874d8e6e5d6fee5349c0fb8f460eec7b5a1d388
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
Several small fixes so that the wcnss module shall compile on
32/64-bit platforms.
CRs-Fixed: 645621
Change-Id: I34cb18418f7f49ad27f75982499509b9e20ff2ed
Signed-off-by: Shete Mihir <smihir@codeaurora.org>
Add sending the platform device pointer and the no_auth boolean
in the notif_data struct. It is left upto the drivers who have
registered for notifications about the individual subsystems to
use this information according to their need.
This change is required to enable drivers to authenticate and
bring subsystems out of reset instead of using the PIL ops.
Change-Id: I179e13768b1ede720ede542e4ca0d7376625ed0b
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
Add functionality to the subsys-pil-tz driver to allow
subsystems to be booted up by other drivers. Add the
"qcom,pil-no-auth" flag to the individual subsystem dt
entry to enable this feature. Doing so converts the
PIL ops to no-ops.
Change-Id: I5791cadadd85ad542b985552deba7a61072be5e3
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
Add a 'notif_data' structure which is sent with the subsystem
restart notifications. The drivers that have registered with the
framework for its notifications can use this structure to decide
upon specific tasks at their end.
CRs-Fixed: 625452
Change-Id: I0bfc277e569a72b2884837829009e96a51399874
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
Fix a couple of function declarations to ensure
compilation succeeds if the SUBSYSTEM_RESTART config
isn't defined.
Change-Id: I8fb220b622b7ecee58ba5423863693df555651bd
Signed-off-by: Vikram Mulukutla <markivx@codeaurora.org>
Architectural changes in the ARM Linux kernel require moving
some MSM specific headers related to the peripheral image
loader and the subsystem restart drivers to include/soc/qcom.
subsystem_restart.h is used by external modules and thus
leave a proxy in include/soc/qcom for now. Once external modules
switch over to this new include path, the header in the
old location can be deleted.
Change-Id: I0680dc34481d09170ce2609259c5318a9e6dbf37
Signed-off-by: Vikram Mulukutla <markivx@codeaurora.org>