| 函数逻辑报告 | 
| Source Code: fs\crypto\keysetup_v1.c | Create Date:2022-07-29 10:57:44 | 
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick | 
| 首页 | 函数Tree | 
| 注解内核,赢得工具 | 下载SCCT | English | 
函数名称:Find/insert the given key into the fscrypt_direct_keys table. If found, it* is returned with elevated refcount, and 'to_insert' is freed if non-NULL. If* not found, 'to_insert' is inserted and returned if it's non-NULL; otherwise* NULL is returned.
函数原型:static struct fscrypt_direct_key *find_or_insert_direct_key(struct fscrypt_direct_key *to_insert, const u8 *raw_key, const struct fscrypt_info *ci)
返回类型:struct fscrypt_direct_key
参数:
| 类型 | 参数 | 名称 | 
|---|---|---|
| struct fscrypt_direct_key * | to_insert | |
| const u8 * | raw_key | |
| const struct fscrypt_info * | ci | 
| 192 | memcpy( & hash_key, master_key_descriptor, hash_key的长度) | 
| 195 | 加自旋锁 | 
| 197 | 如果内存比较不等于0则继续下一循环 | 
| 200 | 如果Encryption mode used for this inode. It corresponds to either the* contents or filenames encryption mode, depending on the inode type.不等于dk_mode则继续下一循环 | 
| 206 | 自旋锁解锁 | 
| 207 | free_direct_key(to_insert) | 
| 208 | 返回:dk | 
| 212 | 自旋锁解锁 | 
| 213 | 返回:to_insert | 
| 名称 | 描述 | 
|---|---|
| fscrypt_get_direct_key | Prepare to encrypt directly using the master key in the given mode | 
| 源代码转换工具 开放的插件接口 | X | 
|---|---|
| 支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |