1 /* SPDX-License-Identifier: GPL-2.0 */ 1 /* SPDX-License-Identifier: GPL-2.0 */ 2 /* 2 /* 3 * Copyright (c) 2023 Hannes Reinecke, SUSE La 3 * Copyright (c) 2023 Hannes Reinecke, SUSE Labs 4 */ 4 */ 5 5 6 #ifndef _NVME_KEYRING_H 6 #ifndef _NVME_KEYRING_H 7 #define _NVME_KEYRING_H 7 #define _NVME_KEYRING_H 8 8 9 #if IS_ENABLED(CONFIG_NVME_KEYRING) 9 #if IS_ENABLED(CONFIG_NVME_KEYRING) 10 10 11 key_serial_t nvme_tls_psk_default(struct key * 11 key_serial_t nvme_tls_psk_default(struct key *keyring, 12 const char *hostnqn, const cha 12 const char *hostnqn, const char *subnqn); 13 13 14 key_serial_t nvme_keyring_id(void); 14 key_serial_t nvme_keyring_id(void); 15 struct key *nvme_tls_key_lookup(key_serial_t k !! 15 16 #else 16 #else 17 17 18 static inline key_serial_t nvme_tls_psk_defaul 18 static inline key_serial_t nvme_tls_psk_default(struct key *keyring, 19 const char *hostnqn, const cha 19 const char *hostnqn, const char *subnqn) 20 { 20 { 21 return 0; 21 return 0; 22 } 22 } 23 static inline key_serial_t nvme_keyring_id(voi 23 static inline key_serial_t nvme_keyring_id(void) 24 { 24 { 25 return 0; 25 return 0; 26 } << 27 static inline struct key *nvme_tls_key_lookup( << 28 { << 29 return ERR_PTR(-ENOTSUPP); << 30 } 26 } 31 #endif /* !CONFIG_NVME_KEYRING */ 27 #endif /* !CONFIG_NVME_KEYRING */ 32 #endif /* _NVME_KEYRING_H */ 28 #endif /* _NVME_KEYRING_H */ 33 29
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.