1 /* SPDX-License-Identifier: GPL-2.0-only */ 2 /* 3 * Copyright (C) 2016 Endless Mobile, Inc. 4 * Author: Carlo Caione <carlo@endlessm.com> 5 */ 6 7 #ifndef _MESON_SM_FW_H_ 8 #define _MESON_SM_FW_H_ 9 10 enum { 11 SM_EFUSE_READ, 12 SM_EFUSE_WRITE, 13 SM_EFUSE_USER_MAX, 14 SM_GET_CHIP_ID, 15 }; 16 17 struct meson_sm_firmware; 18 19 int meson_sm_call(unsigned int cmd_index, u32 *ret, u32 arg0, u32 arg1, 20 u32 arg2, u32 arg3, u32 arg4); 21 int meson_sm_call_write(void *buffer, unsigned int b_size, unsigned int cmd_index, 22 u32 arg0, u32 arg1, u32 arg2, u32 arg3, u32 arg4); 23 int meson_sm_call_read(void *buffer, unsigned int bsize, unsigned int cmd_index, 24 u32 arg0, u32 arg1, u32 arg2, u32 arg3, u32 arg4); 25 26 #endif /* _MESON_SM_FW_H_ */ 27