18aa05055SPaul BeesleyArm SiP Services 28aa05055SPaul Beesley================ 340d553cfSPaul Beesley 440d553cfSPaul BeesleyThis document enumerates and describes the Arm SiP (Silicon Provider) services. 540d553cfSPaul Beesley 640d553cfSPaul BeesleySiP services are non-standard, platform-specific services offered by the silicon 740d553cfSPaul Beesleyimplementer or platform provider. They are accessed via ``SMC`` ("SMC calls") 840d553cfSPaul Beesleyinstruction executed from Exception Levels below EL3. SMC calls for SiP 940d553cfSPaul Beesleyservices: 1040d553cfSPaul Beesley 1140d553cfSPaul Beesley- Follow `SMC Calling Convention`_; 1240d553cfSPaul Beesley- Use SMC function IDs that fall in the SiP range, which are ``0xc2000000`` - 1340d553cfSPaul Beesley ``0xc200ffff`` for 64-bit calls, and ``0x82000000`` - ``0x8200ffff`` for 32-bit 1440d553cfSPaul Beesley calls. 1540d553cfSPaul Beesley 1640d553cfSPaul BeesleyThe Arm SiP implementation offers the following services: 1740d553cfSPaul Beesley 1840d553cfSPaul Beesley- Performance Measurement Framework (PMF) 1940d553cfSPaul Beesley- Execution State Switching service 20*992f091bSAmbroise Vincent- DebugFS interface 2140d553cfSPaul Beesley 2240d553cfSPaul BeesleySource definitions for Arm SiP service are located in the ``arm_sip_svc.h`` header 2340d553cfSPaul Beesleyfile. 2440d553cfSPaul Beesley 2540d553cfSPaul BeesleyPerformance Measurement Framework (PMF) 2640d553cfSPaul Beesley--------------------------------------- 2740d553cfSPaul Beesley 2834760951SPaul BeesleyThe :ref:`Performance Measurement Framework <firmware_design_pmf>` 2940d553cfSPaul Beesleyallows callers to retrieve timestamps captured at various paths in TF-A 3034760951SPaul Beesleyexecution. 3140d553cfSPaul Beesley 3240d553cfSPaul BeesleyExecution State Switching service 3340d553cfSPaul Beesley--------------------------------- 3440d553cfSPaul Beesley 3540d553cfSPaul BeesleyExecution State Switching service provides a mechanism for a non-secure lower 3640d553cfSPaul BeesleyException Level (either EL2, or NS EL1 if EL2 isn't implemented) to request to 3740d553cfSPaul Beesleyswitch its execution state (a.k.a. Register Width), either from AArch64 to 3840d553cfSPaul BeesleyAArch32, or from AArch32 to AArch64, for the calling CPU. This service is only 3940d553cfSPaul Beesleyavailable when Trusted Firmware-A (TF-A) is built for AArch64 (i.e. when build 4040d553cfSPaul Beesleyoption ``ARCH`` is set to ``aarch64``). 4140d553cfSPaul Beesley 4240d553cfSPaul Beesley``ARM_SIP_SVC_EXE_STATE_SWITCH`` 4340d553cfSPaul Beesley~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4440d553cfSPaul Beesley 4540d553cfSPaul Beesley:: 4640d553cfSPaul Beesley 4740d553cfSPaul Beesley Arguments: 4840d553cfSPaul Beesley uint32_t Function ID 4940d553cfSPaul Beesley uint32_t PC hi 5040d553cfSPaul Beesley uint32_t PC lo 5140d553cfSPaul Beesley uint32_t Cookie hi 5240d553cfSPaul Beesley uint32_t Cookie lo 5340d553cfSPaul Beesley 5440d553cfSPaul Beesley Return: 5540d553cfSPaul Beesley uint32_t 5640d553cfSPaul Beesley 5740d553cfSPaul BeesleyThe function ID parameter must be ``0x82000020``. It uniquely identifies the 5840d553cfSPaul BeesleyExecution State Switching service being requested. 5940d553cfSPaul Beesley 6040d553cfSPaul BeesleyThe parameters *PC hi* and *PC lo* defines upper and lower words, respectively, 6140d553cfSPaul Beesleyof the entry point (physical address) at which execution should start, after 6240d553cfSPaul BeesleyExecution State has been switched. When calling from AArch64, *PC hi* must be 0. 6340d553cfSPaul Beesley 6440d553cfSPaul BeesleyWhen execution starts at the supplied entry point after Execution State has been 6540d553cfSPaul Beesleyswitched, the parameters *Cookie hi* and *Cookie lo* are passed in CPU registers 6640d553cfSPaul Beesley0 and 1, respectively. When calling from AArch64, *Cookie hi* must be 0. 6740d553cfSPaul Beesley 6840d553cfSPaul BeesleyThis call can only be made on the primary CPU, before any secondaries were 6940d553cfSPaul Beesleybrought up with ``CPU_ON`` PSCI call. Otherwise, the call will always fail. 7040d553cfSPaul Beesley 7140d553cfSPaul BeesleyThe effect of switching execution state is as if the Exception Level were 7240d553cfSPaul Beesleyentered for the first time, following power on. This means CPU registers that 7340d553cfSPaul Beesleyhave a defined reset value by the Architecture will assume that value. Other 7440d553cfSPaul Beesleyregisters should not be expected to hold their values before the call was made. 7540d553cfSPaul BeesleyCPU endianness, however, is preserved from the previous execution state. Note 7640d553cfSPaul Beesleythat this switches the execution state of the calling CPU only. This is not a 7740d553cfSPaul Beesleysubstitute for PSCI ``SYSTEM_RESET``. 7840d553cfSPaul Beesley 7940d553cfSPaul BeesleyThe service may return the following error codes: 8040d553cfSPaul Beesley 8140d553cfSPaul Beesley- ``STATE_SW_E_PARAM``: If any of the parameters were deemed invalid for 8240d553cfSPaul Beesley a specific request. 8340d553cfSPaul Beesley- ``STATE_SW_E_DENIED``: If the call is not successful, or when TF-A is 8440d553cfSPaul Beesley built for AArch32. 8540d553cfSPaul Beesley 8640d553cfSPaul BeesleyIf the call is successful, the caller wouldn't observe the SMC returning. 8740d553cfSPaul BeesleyInstead, execution starts at the supplied entry point, with the CPU registers 0 8840d553cfSPaul Beesleyand 1 populated with the supplied *Cookie hi* and *Cookie lo* values, 8940d553cfSPaul Beesleyrespectively. 9040d553cfSPaul Beesley 91*992f091bSAmbroise VincentDebugFS interface 92*992f091bSAmbroise Vincent----------------- 93*992f091bSAmbroise Vincent 94*992f091bSAmbroise VincentThe optional DebugFS interface is accessed through an SMC SiP service. Refer 95*992f091bSAmbroise Vincentto the component documentation for details. 96*992f091bSAmbroise Vincent 97*992f091bSAmbroise VincentString parameters are passed through a shared buffer using a specific union: 98*992f091bSAmbroise Vincent 99*992f091bSAmbroise Vincent.. code:: c 100*992f091bSAmbroise Vincent 101*992f091bSAmbroise Vincent union debugfs_parms { 102*992f091bSAmbroise Vincent struct { 103*992f091bSAmbroise Vincent char fname[MAX_PATH_LEN]; 104*992f091bSAmbroise Vincent } open; 105*992f091bSAmbroise Vincent 106*992f091bSAmbroise Vincent struct mount { 107*992f091bSAmbroise Vincent char srv[MAX_PATH_LEN]; 108*992f091bSAmbroise Vincent char where[MAX_PATH_LEN]; 109*992f091bSAmbroise Vincent char spec[MAX_PATH_LEN]; 110*992f091bSAmbroise Vincent } mount; 111*992f091bSAmbroise Vincent 112*992f091bSAmbroise Vincent struct { 113*992f091bSAmbroise Vincent char path[MAX_PATH_LEN]; 114*992f091bSAmbroise Vincent dir_t dir; 115*992f091bSAmbroise Vincent } stat; 116*992f091bSAmbroise Vincent 117*992f091bSAmbroise Vincent struct { 118*992f091bSAmbroise Vincent char oldpath[MAX_PATH_LEN]; 119*992f091bSAmbroise Vincent char newpath[MAX_PATH_LEN]; 120*992f091bSAmbroise Vincent } bind; 121*992f091bSAmbroise Vincent }; 122*992f091bSAmbroise Vincent 123*992f091bSAmbroise VincentFormat of the dir_t structure as such: 124*992f091bSAmbroise Vincent 125*992f091bSAmbroise Vincent.. code:: c 126*992f091bSAmbroise Vincent 127*992f091bSAmbroise Vincent typedef struct { 128*992f091bSAmbroise Vincent char name[NAMELEN]; 129*992f091bSAmbroise Vincent long length; 130*992f091bSAmbroise Vincent unsigned char mode; 131*992f091bSAmbroise Vincent unsigned char index; 132*992f091bSAmbroise Vincent unsigned char dev; 133*992f091bSAmbroise Vincent qid_t qid; 134*992f091bSAmbroise Vincent } dir_t; 135*992f091bSAmbroise Vincent 136*992f091bSAmbroise Vincent 137*992f091bSAmbroise Vincent* Identifiers 138*992f091bSAmbroise Vincent 139*992f091bSAmbroise Vincent======================== ============================================= 140*992f091bSAmbroise VincentSMC_OK 0 141*992f091bSAmbroise VincentSMC_UNK -1 142*992f091bSAmbroise VincentDEBUGFS_E_INVALID_PARAMS -2 143*992f091bSAmbroise Vincent======================== ============================================= 144*992f091bSAmbroise Vincent 145*992f091bSAmbroise Vincent======================== ============================================= 146*992f091bSAmbroise VincentMOUNT 0 147*992f091bSAmbroise VincentCREATE 1 148*992f091bSAmbroise VincentOPEN 2 149*992f091bSAmbroise VincentCLOSE 3 150*992f091bSAmbroise VincentREAD 4 151*992f091bSAmbroise VincentWRITE 5 152*992f091bSAmbroise VincentSEEK 6 153*992f091bSAmbroise VincentBIND 7 154*992f091bSAmbroise VincentSTAT 8 155*992f091bSAmbroise VincentINIT 10 156*992f091bSAmbroise VincentVERSION 11 157*992f091bSAmbroise Vincent======================== ============================================= 158*992f091bSAmbroise Vincent 159*992f091bSAmbroise VincentMOUNT 160*992f091bSAmbroise Vincent~~~~~ 161*992f091bSAmbroise Vincent 162*992f091bSAmbroise VincentDescription 163*992f091bSAmbroise Vincent^^^^^^^^^^^ 164*992f091bSAmbroise VincentThis operation mounts a blob of data pointed to by path stored in `src`, at 165*992f091bSAmbroise Vincentfilesystem location pointed to by path stored in `where`, using driver pointed 166*992f091bSAmbroise Vincentto by path in `spec`. 167*992f091bSAmbroise Vincent 168*992f091bSAmbroise VincentParameters 169*992f091bSAmbroise Vincent^^^^^^^^^^ 170*992f091bSAmbroise Vincent======== ============================================================ 171*992f091bSAmbroise Vincentuint32_t FunctionID (0x82000030 / 0xC2000030) 172*992f091bSAmbroise Vincentuint32_t ``MOUNT`` 173*992f091bSAmbroise Vincent======== ============================================================ 174*992f091bSAmbroise Vincent 175*992f091bSAmbroise VincentReturn values 176*992f091bSAmbroise Vincent^^^^^^^^^^^^^ 177*992f091bSAmbroise Vincent 178*992f091bSAmbroise Vincent=============== ========================================================== 179*992f091bSAmbroise Vincentint32_t w0 == SMC_OK on success 180*992f091bSAmbroise Vincent 181*992f091bSAmbroise Vincent w0 == DEBUGFS_E_INVALID_PARAMS if mount operation failed 182*992f091bSAmbroise Vincent=============== ========================================================== 183*992f091bSAmbroise Vincent 184*992f091bSAmbroise VincentOPEN 185*992f091bSAmbroise Vincent~~~~ 186*992f091bSAmbroise Vincent 187*992f091bSAmbroise VincentDescription 188*992f091bSAmbroise Vincent^^^^^^^^^^^ 189*992f091bSAmbroise VincentThis operation opens the file path pointed to by `fname`. 190*992f091bSAmbroise Vincent 191*992f091bSAmbroise VincentParameters 192*992f091bSAmbroise Vincent^^^^^^^^^^ 193*992f091bSAmbroise Vincent 194*992f091bSAmbroise Vincent======== ============================================================ 195*992f091bSAmbroise Vincentuint32_t FunctionID (0x82000030 / 0xC2000030) 196*992f091bSAmbroise Vincentuint32_t ``OPEN`` 197*992f091bSAmbroise Vincentuint32_t mode 198*992f091bSAmbroise Vincent======== ============================================================ 199*992f091bSAmbroise Vincent 200*992f091bSAmbroise Vincentmode can be one of: 201*992f091bSAmbroise Vincent 202*992f091bSAmbroise Vincent.. code:: c 203*992f091bSAmbroise Vincent 204*992f091bSAmbroise Vincent enum mode { 205*992f091bSAmbroise Vincent O_READ = 1 << 0, 206*992f091bSAmbroise Vincent O_WRITE = 1 << 1, 207*992f091bSAmbroise Vincent O_RDWR = 1 << 2, 208*992f091bSAmbroise Vincent O_BIND = 1 << 3, 209*992f091bSAmbroise Vincent O_DIR = 1 << 4, 210*992f091bSAmbroise Vincent O_STAT = 1 << 5 211*992f091bSAmbroise Vincent }; 212*992f091bSAmbroise Vincent 213*992f091bSAmbroise VincentReturn values 214*992f091bSAmbroise Vincent^^^^^^^^^^^^^ 215*992f091bSAmbroise Vincent 216*992f091bSAmbroise Vincent=============== ========================================================== 217*992f091bSAmbroise Vincentint32_t w0 == SMC_OK on success 218*992f091bSAmbroise Vincent 219*992f091bSAmbroise Vincent w0 == DEBUGFS_E_INVALID_PARAMS if open operation failed 220*992f091bSAmbroise Vincent 221*992f091bSAmbroise Vincentuint32_t w1: file descriptor id on success. 222*992f091bSAmbroise Vincent=============== ========================================================== 223*992f091bSAmbroise Vincent 224*992f091bSAmbroise VincentCLOSE 225*992f091bSAmbroise Vincent~~~~~ 226*992f091bSAmbroise Vincent 227*992f091bSAmbroise VincentDescription 228*992f091bSAmbroise Vincent^^^^^^^^^^^ 229*992f091bSAmbroise Vincent 230*992f091bSAmbroise VincentThis operation closes a file described by a file descriptor obtained by a 231*992f091bSAmbroise Vincentprevious call to OPEN. 232*992f091bSAmbroise Vincent 233*992f091bSAmbroise VincentParameters 234*992f091bSAmbroise Vincent^^^^^^^^^^ 235*992f091bSAmbroise Vincent 236*992f091bSAmbroise Vincent======== ============================================================ 237*992f091bSAmbroise Vincentuint32_t FunctionID (0x82000030 / 0xC2000030) 238*992f091bSAmbroise Vincentuint32_t ``CLOSE`` 239*992f091bSAmbroise Vincentuint32_t File descriptor id returned by OPEN 240*992f091bSAmbroise Vincent======== ============================================================ 241*992f091bSAmbroise Vincent 242*992f091bSAmbroise VincentReturn values 243*992f091bSAmbroise Vincent^^^^^^^^^^^^^ 244*992f091bSAmbroise Vincent=============== ========================================================== 245*992f091bSAmbroise Vincentint32_t w0 == SMC_OK on success 246*992f091bSAmbroise Vincent 247*992f091bSAmbroise Vincent w0 == DEBUGFS_E_INVALID_PARAMS if close operation failed 248*992f091bSAmbroise Vincent=============== ========================================================== 249*992f091bSAmbroise Vincent 250*992f091bSAmbroise VincentREAD 251*992f091bSAmbroise Vincent~~~~ 252*992f091bSAmbroise Vincent 253*992f091bSAmbroise VincentDescription 254*992f091bSAmbroise Vincent^^^^^^^^^^^ 255*992f091bSAmbroise Vincent 256*992f091bSAmbroise VincentThis operation reads a number of bytes from a file descriptor obtained by 257*992f091bSAmbroise Vincenta previous call to OPEN. 258*992f091bSAmbroise Vincent 259*992f091bSAmbroise VincentParameters 260*992f091bSAmbroise Vincent^^^^^^^^^^ 261*992f091bSAmbroise Vincent 262*992f091bSAmbroise Vincent======== ============================================================ 263*992f091bSAmbroise Vincentuint32_t FunctionID (0x82000030 / 0xC2000030) 264*992f091bSAmbroise Vincentuint32_t ``READ`` 265*992f091bSAmbroise Vincentuint32_t File descriptor id returned by OPEN 266*992f091bSAmbroise Vincentuint32_t Number of bytes to read 267*992f091bSAmbroise Vincent======== ============================================================ 268*992f091bSAmbroise Vincent 269*992f091bSAmbroise VincentReturn values 270*992f091bSAmbroise Vincent^^^^^^^^^^^^^ 271*992f091bSAmbroise Vincent 272*992f091bSAmbroise VincentOn success, the read data is retrieved from the shared buffer after the 273*992f091bSAmbroise Vincentoperation. 274*992f091bSAmbroise Vincent 275*992f091bSAmbroise Vincent=============== ========================================================== 276*992f091bSAmbroise Vincentint32_t w0 == SMC_OK on success 277*992f091bSAmbroise Vincent 278*992f091bSAmbroise Vincent w0 == DEBUGFS_E_INVALID_PARAMS if read operation failed 279*992f091bSAmbroise Vincent 280*992f091bSAmbroise Vincentuint32_t w1: number of bytes read on success. 281*992f091bSAmbroise Vincent=============== ========================================================== 282*992f091bSAmbroise Vincent 283*992f091bSAmbroise VincentSEEK 284*992f091bSAmbroise Vincent~~~~ 285*992f091bSAmbroise Vincent 286*992f091bSAmbroise VincentDescription 287*992f091bSAmbroise Vincent^^^^^^^^^^^ 288*992f091bSAmbroise Vincent 289*992f091bSAmbroise VincentMove file pointer for file described by given `file descriptor` of given 290*992f091bSAmbroise Vincent`offset` related to `whence`. 291*992f091bSAmbroise Vincent 292*992f091bSAmbroise VincentParameters 293*992f091bSAmbroise Vincent^^^^^^^^^^ 294*992f091bSAmbroise Vincent 295*992f091bSAmbroise Vincent======== ============================================================ 296*992f091bSAmbroise Vincentuint32_t FunctionID (0x82000030 / 0xC2000030) 297*992f091bSAmbroise Vincentuint32_t ``SEEK`` 298*992f091bSAmbroise Vincentuint32_t File descriptor id returned by OPEN 299*992f091bSAmbroise Vincentsint32_t offset in the file relative to whence 300*992f091bSAmbroise Vincentuint32_t whence 301*992f091bSAmbroise Vincent======== ============================================================ 302*992f091bSAmbroise Vincent 303*992f091bSAmbroise Vincentwhence can be one of: 304*992f091bSAmbroise Vincent 305*992f091bSAmbroise Vincent========= ============================================================ 306*992f091bSAmbroise VincentKSEEK_SET 0 307*992f091bSAmbroise VincentKSEEK_CUR 1 308*992f091bSAmbroise VincentKSEEK_END 2 309*992f091bSAmbroise Vincent========= ============================================================ 310*992f091bSAmbroise Vincent 311*992f091bSAmbroise VincentReturn values 312*992f091bSAmbroise Vincent^^^^^^^^^^^^^ 313*992f091bSAmbroise Vincent 314*992f091bSAmbroise Vincent=============== ========================================================== 315*992f091bSAmbroise Vincentint32_t w0 == SMC_OK on success 316*992f091bSAmbroise Vincent 317*992f091bSAmbroise Vincent w0 == DEBUGFS_E_INVALID_PARAMS if seek operation failed 318*992f091bSAmbroise Vincent=============== ========================================================== 319*992f091bSAmbroise Vincent 320*992f091bSAmbroise VincentBIND 321*992f091bSAmbroise Vincent~~~~ 322*992f091bSAmbroise Vincent 323*992f091bSAmbroise VincentDescription 324*992f091bSAmbroise Vincent^^^^^^^^^^^ 325*992f091bSAmbroise Vincent 326*992f091bSAmbroise VincentCreate a link from `oldpath` to `newpath`. 327*992f091bSAmbroise Vincent 328*992f091bSAmbroise VincentParameters 329*992f091bSAmbroise Vincent^^^^^^^^^^ 330*992f091bSAmbroise Vincent 331*992f091bSAmbroise Vincent======== ============================================================ 332*992f091bSAmbroise Vincentuint32_t FunctionID (0x82000030 / 0xC2000030) 333*992f091bSAmbroise Vincentuint32_t ``BIND`` 334*992f091bSAmbroise Vincent======== ============================================================ 335*992f091bSAmbroise Vincent 336*992f091bSAmbroise VincentReturn values 337*992f091bSAmbroise Vincent^^^^^^^^^^^^^ 338*992f091bSAmbroise Vincent 339*992f091bSAmbroise Vincent=============== ========================================================== 340*992f091bSAmbroise Vincentint32_t w0 == SMC_OK on success 341*992f091bSAmbroise Vincent 342*992f091bSAmbroise Vincent w0 == DEBUGFS_E_INVALID_PARAMS if bind operation failed 343*992f091bSAmbroise Vincent=============== ========================================================== 344*992f091bSAmbroise Vincent 345*992f091bSAmbroise VincentSTAT 346*992f091bSAmbroise Vincent~~~~ 347*992f091bSAmbroise Vincent 348*992f091bSAmbroise VincentDescription 349*992f091bSAmbroise Vincent^^^^^^^^^^^ 350*992f091bSAmbroise Vincent 351*992f091bSAmbroise VincentPerform a stat operation on provided file `name` and returns the directory 352*992f091bSAmbroise Vincententry statistics into `dir`. 353*992f091bSAmbroise Vincent 354*992f091bSAmbroise VincentParameters 355*992f091bSAmbroise Vincent^^^^^^^^^^ 356*992f091bSAmbroise Vincent 357*992f091bSAmbroise Vincent======== ============================================================ 358*992f091bSAmbroise Vincentuint32_t FunctionID (0x82000030 / 0xC2000030) 359*992f091bSAmbroise Vincentuint32_t ``STAT`` 360*992f091bSAmbroise Vincent======== ============================================================ 361*992f091bSAmbroise Vincent 362*992f091bSAmbroise VincentReturn values 363*992f091bSAmbroise Vincent^^^^^^^^^^^^^ 364*992f091bSAmbroise Vincent 365*992f091bSAmbroise Vincent=============== ========================================================== 366*992f091bSAmbroise Vincentint32_t w0 == SMC_OK on success 367*992f091bSAmbroise Vincent 368*992f091bSAmbroise Vincent w0 == DEBUGFS_E_INVALID_PARAMS if stat operation failed 369*992f091bSAmbroise Vincent=============== ========================================================== 370*992f091bSAmbroise Vincent 371*992f091bSAmbroise VincentINIT 372*992f091bSAmbroise Vincent~~~~ 373*992f091bSAmbroise Vincent 374*992f091bSAmbroise VincentDescription 375*992f091bSAmbroise Vincent^^^^^^^^^^^ 376*992f091bSAmbroise VincentInitial call to setup the shared exchange buffer. Notice if successful once, 377*992f091bSAmbroise Vincentsubsequent calls fail after a first initialization. The caller maps the same 378*992f091bSAmbroise Vincentpage frame in its virtual space and uses this buffer to exchange string 379*992f091bSAmbroise Vincentparameters with filesystem primitives. 380*992f091bSAmbroise Vincent 381*992f091bSAmbroise VincentParameters 382*992f091bSAmbroise Vincent^^^^^^^^^^ 383*992f091bSAmbroise Vincent 384*992f091bSAmbroise Vincent======== ============================================================ 385*992f091bSAmbroise Vincentuint32_t FunctionID (0x82000030 / 0xC2000030) 386*992f091bSAmbroise Vincentuint32_t ``INIT`` 387*992f091bSAmbroise Vincentuint64_t Physical address of the shared buffer. 388*992f091bSAmbroise Vincent======== ============================================================ 389*992f091bSAmbroise Vincent 390*992f091bSAmbroise VincentReturn values 391*992f091bSAmbroise Vincent^^^^^^^^^^^^^ 392*992f091bSAmbroise Vincent 393*992f091bSAmbroise Vincent=============== ====================================================== 394*992f091bSAmbroise Vincentint32_t w0 == SMC_OK on success 395*992f091bSAmbroise Vincent 396*992f091bSAmbroise Vincent w0 == DEBUGFS_E_INVALID_PARAMS if already initialized, 397*992f091bSAmbroise Vincent or internal error occurred. 398*992f091bSAmbroise Vincent=============== ====================================================== 399*992f091bSAmbroise Vincent 400*992f091bSAmbroise VincentVERSION 401*992f091bSAmbroise Vincent~~~~~~~ 402*992f091bSAmbroise Vincent 403*992f091bSAmbroise VincentDescription 404*992f091bSAmbroise Vincent^^^^^^^^^^^ 405*992f091bSAmbroise VincentReturns the debugfs interface version if implemented in TF-A. 406*992f091bSAmbroise Vincent 407*992f091bSAmbroise VincentParameters 408*992f091bSAmbroise Vincent^^^^^^^^^^ 409*992f091bSAmbroise Vincent 410*992f091bSAmbroise Vincent======== ============================================================ 411*992f091bSAmbroise Vincentuint32_t FunctionID (0x82000030 / 0xC2000030) 412*992f091bSAmbroise Vincentuint32_t ``VERSION`` 413*992f091bSAmbroise Vincent======== ============================================================ 414*992f091bSAmbroise Vincent 415*992f091bSAmbroise VincentReturn values 416*992f091bSAmbroise Vincent^^^^^^^^^^^^^ 417*992f091bSAmbroise Vincent 418*992f091bSAmbroise Vincent=============== ====================================================== 419*992f091bSAmbroise Vincentint32_t w0 == SMC_OK on success 420*992f091bSAmbroise Vincent 421*992f091bSAmbroise Vincent w0 == SMC_UNK if interface is not implemented 422*992f091bSAmbroise Vincent 423*992f091bSAmbroise Vincentuint32_t w1: On success, debugfs interface version, 32 bits 424*992f091bSAmbroise Vincent value with major version number in upper 16 bits and 425*992f091bSAmbroise Vincent minor version in lower 16 bits. 426*992f091bSAmbroise Vincent=============== ====================================================== 427*992f091bSAmbroise Vincent 428*992f091bSAmbroise Vincent* CREATE(1) and WRITE (5) command identifiers are unimplemented and 429*992f091bSAmbroise Vincent return `SMC_UNK`. 430*992f091bSAmbroise Vincent 43140d553cfSPaul Beesley-------------- 43240d553cfSPaul Beesley 43334760951SPaul Beesley*Copyright (c) 2017-2019, Arm Limited and Contributors. All rights reserved.* 43440d553cfSPaul Beesley 43540d553cfSPaul Beesley.. _SMC Calling Convention: http://infocenter.arm.com/help/topic/com.arm.doc.den0028a/index.html 436