1What:		/sys/devices/platform/firmware\:zynqmp-firmware/ggs*
2Date:		March 2020
3KernelVersion:	5.6
4Contact:	"Jolly Shah" <jollys@xilinx.com>
5Description:
6		Read/Write PMU global general storage register value,
7		GLOBAL_GEN_STORAGE{0:3}.
8		Global general storage register that can be used
9		by system to pass information between masters.
10
11		The register is reset during system or power-on
12		resets. Three registers are used by the FSBL and
13		other Xilinx software products: GLOBAL_GEN_STORAGE{4:6}.
14
15		Usage::
16
17		    # cat /sys/devices/platform/firmware\:zynqmp-firmware/ggs0
18		    # echo <value> > /sys/devices/platform/firmware\:zynqmp-firmware/ggs0
19
20		Example::
21
22		    # cat /sys/devices/platform/firmware\:zynqmp-firmware/ggs0
23		    # echo 0x1234ABCD > /sys/devices/platform/firmware\:zynqmp-firmware/ggs0
24
25Users:		Xilinx
26
27What:		/sys/devices/platform/firmware\:zynqmp-firmware/pggs*
28Date:		March 2020
29KernelVersion:	5.6
30Contact:	"Jolly Shah" <jollys@xilinx.com>
31Description:
32		Read/Write PMU persistent global general storage register
33		value, PERS_GLOB_GEN_STORAGE{0:3}.
34		Persistent global general storage register that
35		can be used by system to pass information between
36		masters.
37
38		This register is only reset by the power-on reset
39		and maintains its value through a system reset.
40		Four registers are used by the FSBL and other Xilinx
41		software products: PERS_GLOB_GEN_STORAGE{4:7}.
42		Register is reset only by a POR reset.
43
44		Usage::
45
46		    # cat /sys/devices/platform/firmware\:zynqmp-firmware/pggs0
47		    # echo <value> > /sys/devices/platform/firmware\:zynqmp-firmware/pggs0
48
49		Example::
50
51		    # cat /sys/devices/platform/firmware\:zynqmp-firmware/pggs0
52		    # echo 0x1234ABCD > /sys/devices/platform/firmware\:zynqmp-firmware/pggs0
53
54Users:		Xilinx
55
56What:		/sys/devices/platform/firmware\:zynqmp-firmware/shutdown_scope
57Date:		March 2020
58KernelVersion:	5.6
59Contact:	"Jolly Shah" <jollys@xilinx.com>
60Description:
61		This sysfs interface allows to set the shutdown scope for the
62		next shutdown request. When the next shutdown is performed, the
63		platform specific portion of PSCI-system_off can use the chosen
64		shutdown scope.
65
66		Following are available shutdown scopes(subtypes):
67
68		subsystem:
69				Only the APU along with all of its peripherals
70				not used by other processing units will be
71				shut down. This may result in the FPD power
72				domain being shut down provided that no other
73				processing unit uses FPD peripherals or DRAM.
74		ps_only:
75				The complete PS will be shut down, including the
76				RPU, PMU, etc.  Only the PL domain (FPGA)
77				remains untouched.
78		system:
79				The complete system/device is shut down.
80
81		Usage::
82
83		    # cat /sys/devices/platform/firmware\:zynqmp-firmware/shutdown_scope
84		    # echo <scope> > /sys/devices/platform/firmware\:zynqmp-firmware/shutdown_scope
85
86		Example::
87
88		    # cat /sys/devices/platform/firmware\:zynqmp-firmware/shutdown_scope
89		    # echo "subsystem" > /sys/devices/platform/firmware\:zynqmp-firmware/shutdown_scope
90
91Users:		Xilinx
92
93What:		/sys/devices/platform/firmware\:zynqmp-firmware/health_status
94Date:		March 2020
95KernelVersion:	5.6
96Contact:	"Jolly Shah" <jollys@xilinx.com>
97Description:
98		This sysfs interface allows to set the health status. If PMUFW
99		is compiled with CHECK_HEALTHY_BOOT, it will check the healthy
100		bit on FPD WDT expiration. If healthy bit is set by a user
101		application running in Linux, PMUFW will do APU only restart. If
102		healthy bit is not set during FPD WDT expiration, PMUFW will do
103		system restart.
104
105		Usage:
106
107		Set healthy bit::
108
109		    # echo 1 > /sys/devices/platform/firmware\:zynqmp-firmware/health_status
110
111		Unset healthy bit::
112
113		    # echo 0 > /sys/devices/platform/firmware\:zynqmp-firmware/health_status
114
115Users:		Xilinx
116
117What:		/sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
118Date:		Feb 2022
119KernelVersion:	5.18
120Contact:	"Ronak Jain" <ronak.jain@xilinx.com>
121Description:
122		This sysfs interface allows user to configure features at
123		runtime. The user can enable or disable features running at
124		firmware as well as the user can configure the parameters of
125		the features at runtime. The supported features are over
126		temperature and external watchdog. Here, the external watchdog
127		is completely different than the /dev/watchdog as the external
128		watchdog is running on the firmware and it is used to monitor
129		the health of firmware not APU(Linux). Also, the external
130		watchdog is interfaced outside of the zynqmp soc.
131
132		The supported config ids are for the feature configuration is,
133		1. PM_FEATURE_OVERTEMP_STATUS = 1, the user can enable or
134		disable the over temperature feature.
135		2. PM_FEATURE_OVERTEMP_VALUE = 2, the user can configure the
136		over temperature limit in Degree Celsius.
137		3. PM_FEATURE_EXTWDT_STATUS = 3, the user can enable or disable
138		the external watchdog feature.
139		4. PM_FEATURE_EXTWDT_VALUE = 4, the user can configure the
140		external watchdog feature.
141
142		Usage:
143
144		Select over temperature config ID to enable/disable feature
145		# echo 1 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
146
147		Check over temperature config ID is selected or not
148		# cat /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
149		The expected result is 1.
150
151		Select over temperature config ID to configure OT limit
152		# echo 2 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
153
154		Check over temperature config ID is selected or not
155		# cat /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
156		The expected result is 2.
157
158		Select external watchdog config ID to enable/disable feature
159		# echo 3 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
160
161		Check external watchdog config ID is selected or not
162		# cat /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
163		The expected result is 3.
164
165		Select external watchdog config ID to configure time interval
166		# echo 4 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
167
168		Check external watchdog config ID is selected or not
169		# cat /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
170		The expected result is 4.
171
172Users:		Xilinx
173
174What:		/sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
175Date:		Feb 2022
176KernelVersion:	5.18
177Contact:	"Ronak Jain" <ronak.jain@xilinx.com>
178Description:
179		This sysfs interface allows to configure features at runtime.
180		The user can enable or disable features running at firmware.
181		Also, the user can configure the parameters of the features
182		at runtime. The supported features are over temperature and
183		external watchdog. Here, the external watchdog is completely
184		different than the /dev/watchdog as the external watchdog is
185		running on the firmware and it is used to monitor the health
186		of firmware not APU(Linux). Also, the external watchdog is
187		interfaced outside of the zynqmp soc.
188
189		By default the features are disabled in the firmware. The user
190		can enable features by querying appropriate config id of the
191		features.
192
193		The default limit for the over temperature is 90 Degree Celsius.
194		The default timer interval for the external watchdog is 570ms.
195
196		The supported config ids are for the feature configuration is,
197		1. PM_FEATURE_OVERTEMP_STATUS = 1, the user can enable or
198		disable the over temperature feature.
199		2. PM_FEATURE_OVERTEMP_VALUE = 2, the user can configure the
200		over temperature limit in Degree Celsius.
201		3. PM_FEATURE_EXTWDT_STATUS = 3, the user can enable or disable
202		the external watchdog feature.
203		4. PM_FEATURE_EXTWDT_VALUE = 4, the user can configure the
204		external watchdog feature.
205
206		Usage:
207
208		Enable over temperature feature
209		# echo 1 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
210		# echo 1 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
211
212		Check whether the over temperature feature is enabled or not
213		# cat /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
214		The expected result is 1.
215
216		Disable over temperature feature
217		# echo 1 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
218		# echo 0 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
219
220		Check whether the over temperature feature is disabled or not
221		# cat /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
222		The expected result is 0.
223
224		Configure over temperature limit to 50 Degree Celsius
225		# echo 2 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
226		# echo 50 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
227
228		Check whether the over temperature limit is configured or not
229		# cat /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
230		The expected result is 50.
231
232		Enable external watchdog feature
233		# echo 3 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
234		# echo 1 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
235
236		Check whether the external watchdog feature is enabled or not
237		# cat /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
238		The expected result is 1.
239
240		Disable external watchdog feature
241		# echo 3 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
242		# echo 0 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
243
244		Check whether the external watchdog feature is disabled or not
245		# cat /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
246		The expected result is 0.
247
248		Configure external watchdog timer interval to 500ms
249		# echo 4 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_id
250		# echo 500 > /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
251
252		Check whether the external watchdog timer interval is configured or not
253		# cat /sys/devices/platform/firmware\:zynqmp-firmware/feature_config_value
254		The expected result is 500.
255
256Users:		Xilinx
257