blob: 0f50a60013a0011d4fabf4e307bd9c7bf82ed5dc [file] [log] [blame]
Neeraj Sonic692cb92018-04-18 17:20:22 +05301/* Copyright (c) 2015-2018, The Linux Foundation. All rights reserved.
2 *
3 * This program is free software; you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License version 2 and
5 * only version 2 as published by the Free Software Foundation.
6 *
7 * This program is distributed in the hope that it will be useful,
8 * but WITHOUT ANY WARRANTY; without even the implied warranty of
9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10 * GNU General Public License for more details.
11 */
12
13#ifndef PFK_KC_H_
14#define PFK_KC_H_
15
16#include <linux/types.h>
17
18int pfk_kc_init(void);
19int pfk_kc_deinit(void);
20int pfk_kc_load_key_start(const unsigned char *key, size_t key_size,
21 const unsigned char *salt, size_t salt_size, u32 *key_index,
Neeraj Sonie3af8d52018-09-05 14:32:49 +053022 bool async, unsigned int data_unit, int ice_rev);
Neeraj Sonic692cb92018-04-18 17:20:22 +053023void pfk_kc_load_key_end(const unsigned char *key, size_t key_size,
24 const unsigned char *salt, size_t salt_size);
25int pfk_kc_remove_key_with_salt(const unsigned char *key, size_t key_size,
26 const unsigned char *salt, size_t salt_size);
27int pfk_kc_remove_key(const unsigned char *key, size_t key_size);
28int pfk_kc_clear(void);
29void pfk_kc_clear_on_reset(void);
Neeraj Soniefb33112018-08-17 20:39:35 +053030const char *pfk_kc_get_storage_type(void);
Neeraj Sonic692cb92018-04-18 17:20:22 +053031extern char *saved_command_line;
32
33
34#endif /* PFK_KC_H_ */