mirror of
https://github.com/hardkernel/kernel_common_drivers.git
synced 2026-06-25 12:03:48 +09:00
92ffe3e6aa
PD#SWPL-143927 Problem: unifykey ready too late Solution: attach after flash probe Verify: g12b Change-Id: I637874304ea70f34074d32ac08c4728a1b80cef8 Signed-off-by: shufei.zhao <shufei.zhao@amlogic.com>
30 lines
615 B
C
30 lines
615 B
C
/* SPDX-License-Identifier: (GPL-2.0+ OR MIT) */
|
|
/*
|
|
* Copyright (c) 2019 Amlogic, Inc. All rights reserved.
|
|
*/
|
|
|
|
#ifndef __KEYMANAGE__
|
|
#define __KEYMANAGE__
|
|
|
|
enum {
|
|
UNIFYKEY_STORAGE_TYPE_INVALID = 0,
|
|
UNIFYKEY_STORAGE_TYPE_EMMC,
|
|
UNIFYKEY_STORAGE_TYPE_NAND,
|
|
UNIFYKEY_STORAGE_TYPE_MAX
|
|
};
|
|
|
|
struct unifykey_storage_ops {
|
|
s32 (*read)(u8 *buf, u32 len, u32 *actual_len);
|
|
s32 (*write)(u8 *buf, u32 len, u32 *actual_len);
|
|
};
|
|
|
|
struct unifykey_type {
|
|
u32 storage_type;
|
|
struct unifykey_storage_ops *ops;
|
|
};
|
|
|
|
int register_unifykey_types(struct unifykey_type *uk_type);
|
|
void auto_attach(void);
|
|
|
|
#endif /*__KEYMANAGE__*/
|