mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git
synced 2026-04-23 05:56:14 -04:00
drm/amdgpu: add sysfs to shows psp vbflash status
Add new sysfs interface to shows the status of psp vbflash status.
V2: rename the sysfs interface, and set more return value.
(0: not start; 1: in progress; MBX115 value when vbflash finish)
V3: warning fixes
Signed-off-by: Likun Gao <Likun.Gao@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
@@ -130,6 +130,7 @@ struct psp_funcs
|
||||
int (*load_usbc_pd_fw)(struct psp_context *psp, uint64_t fw_pri_mc_addr);
|
||||
int (*read_usbc_pd_fw)(struct psp_context *psp, uint32_t *fw_ver);
|
||||
int (*update_spirom)(struct psp_context *psp, uint64_t fw_pri_mc_addr);
|
||||
int (*vbflash_stat)(struct psp_context *psp);
|
||||
};
|
||||
|
||||
#define AMDGPU_XGMI_MAX_CONNECTED_NODES 64
|
||||
@@ -375,6 +376,7 @@ struct psp_context
|
||||
|
||||
char *vbflash_tmp_buf;
|
||||
size_t vbflash_image_size;
|
||||
bool vbflash_done;
|
||||
};
|
||||
|
||||
struct amdgpu_psp_funcs {
|
||||
@@ -425,6 +427,10 @@ struct amdgpu_psp_funcs {
|
||||
((psp)->funcs->update_spirom ? \
|
||||
(psp)->funcs->update_spirom((psp), fw_pri_mc_addr) : -EINVAL)
|
||||
|
||||
#define psp_vbflash_status(psp) \
|
||||
((psp)->funcs->vbflash_stat ? \
|
||||
(psp)->funcs->vbflash_stat((psp)) : -EINVAL)
|
||||
|
||||
extern const struct amd_ip_funcs psp_ip_funcs;
|
||||
|
||||
extern const struct amdgpu_ip_block_version psp_v3_1_ip_block;
|
||||
|
||||
Reference in New Issue
Block a user