1 /* 2 * Copyright (C) 2022 Huawei Technologies Co., Ltd. 3 * 4 * This software is licensed under the terms of the GNU General Public 5 * License version 2, as published by the Free Software Foundation, and 6 * may be copied, distributed, and modified under those terms. 7 * 8 * This program is distributed in the hope that it will be useful, 9 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11 * GNU General Public License for more details. 12 */ 13 #ifndef SMC_CALL_H 14 #define SMC_CALL_H 15 16 #include <linux/types.h> 17 18 struct smc_in_params { 19 unsigned long x0; 20 unsigned long x1; 21 unsigned long x2; 22 unsigned long x3; 23 unsigned long x4; 24 unsigned long x5; 25 unsigned long x6; 26 unsigned long x7; 27 }; 28 29 struct smc_out_params { 30 unsigned long ret; 31 unsigned long exit_reason; 32 unsigned long ta; 33 unsigned long target; 34 }; 35 36 void smc_req(struct smc_in_params *in, struct smc_out_params *out, uint8_t wait); 37 38 #endif 39