blob: 663ea956d5260e88d4f347ad98bff5773107a630 [file] [log] [blame]
developere5e687d2023-08-08 16:05:33 +08001/* SPDX-License-Identifier: GPL-2.0-or-later */
2/*
3 * Copyright (c) 2023 MediaTek Inc. All Rights Reserved.
4 *
5 * Author: Ren-Ting Wang <ren-ting.wang@mediatek.com>
6 */
7
8#ifndef _TOPS_FW_H_
9#define _TOPS_FW_H_
10
11#include <linux/platform_device.h>
12#include <linux/time.h>
13
14enum tops_role_type {
15 TOPS_ROLE_TYPE_MGMT,
16 TOPS_ROLE_TYPE_CLUSTER,
17
18 __TOPS_ROLE_TYPE_MAX,
19};
20
21u64 mtk_tops_fw_get_git_commit_id(enum tops_role_type rtype);
22void mtk_tops_fw_get_built_date(enum tops_role_type rtype, struct tm *tm);
23u32 mtk_tops_fw_attr_get_num(enum tops_role_type rtype);
24const char *mtk_tops_fw_attr_get_property(enum tops_role_type rtype, u32 idx);
25const char *mtk_tops_fw_attr_get_value(enum tops_role_type rtype,
26 const char *property);
27
28int mtk_tops_fw_bring_up_default_cores(void);
29int mtk_tops_fw_bring_up_core(const char *fw_path);
30void mtk_tops_fw_clean_up(void);
31int mtk_tops_fw_init(struct platform_device *pdev);
32#endif /* _TOPS_FW_H_ */