Lines Matching refs:stm32_cryp
162 struct stm32_cryp *cryp;
172 struct stm32_cryp { struct
213 static inline bool is_aes(struct stm32_cryp *cryp) in is_aes() argument
218 static inline bool is_des(struct stm32_cryp *cryp) in is_des()
223 static inline bool is_tdes(struct stm32_cryp *cryp) in is_tdes()
228 static inline bool is_ecb(struct stm32_cryp *cryp) in is_ecb()
233 static inline bool is_cbc(struct stm32_cryp *cryp) in is_cbc()
238 static inline bool is_ctr(struct stm32_cryp *cryp) in is_ctr()
243 static inline bool is_gcm(struct stm32_cryp *cryp) in is_gcm()
248 static inline bool is_ccm(struct stm32_cryp *cryp) in is_ccm()
253 static inline bool is_encrypt(struct stm32_cryp *cryp) in is_encrypt()
258 static inline bool is_decrypt(struct stm32_cryp *cryp) in is_decrypt()
263 static inline u32 stm32_cryp_read(struct stm32_cryp *cryp, u32 ofst) in stm32_cryp_read()
268 static inline void stm32_cryp_write(struct stm32_cryp *cryp, u32 ofst, u32 val) in stm32_cryp_write()
273 static inline int stm32_cryp_wait_busy(struct stm32_cryp *cryp) in stm32_cryp_wait_busy()
281 static inline void stm32_cryp_enable(struct stm32_cryp *cryp) in stm32_cryp_enable()
287 static inline int stm32_cryp_wait_enable(struct stm32_cryp *cryp) in stm32_cryp_wait_enable()
295 static inline int stm32_cryp_wait_output(struct stm32_cryp *cryp) in stm32_cryp_wait_output()
303 static inline void stm32_cryp_key_read_enable(struct stm32_cryp *cryp) in stm32_cryp_key_read_enable()
309 static inline void stm32_cryp_key_read_disable(struct stm32_cryp *cryp) in stm32_cryp_key_read_disable()
315 static int stm32_cryp_read_auth_tag(struct stm32_cryp *cryp);
316 static void stm32_cryp_finish_req(struct stm32_cryp *cryp, int err);
318 static struct stm32_cryp *stm32_cryp_find_dev(struct stm32_cryp_ctx *ctx) in stm32_cryp_find_dev()
320 struct stm32_cryp *tmp, *cryp = NULL; in stm32_cryp_find_dev()
338 static void stm32_cryp_hw_write_iv(struct stm32_cryp *cryp, __be32 *iv) in stm32_cryp_hw_write_iv()
352 static void stm32_cryp_get_iv(struct stm32_cryp *cryp) in stm32_cryp_get_iv()
459 static void stm32_cryp_hw_write_key(struct stm32_cryp *c) in stm32_cryp_hw_write_key()
494 static u32 stm32_cryp_get_hw_mode(struct stm32_cryp *cryp) in stm32_cryp_get_hw_mode()
527 static unsigned int stm32_cryp_get_input_text_len(struct stm32_cryp *cryp) in stm32_cryp_get_input_text_len()
533 static int stm32_cryp_gcm_init(struct stm32_cryp *cryp, u32 cfg) in stm32_cryp_gcm_init()
565 static void stm32_crypt_gcmccm_end_header(struct stm32_cryp *cryp) in stm32_crypt_gcmccm_end_header()
600 static void stm32_cryp_write_ccm_first_header(struct stm32_cryp *cryp) in stm32_cryp_write_ccm_first_header()
635 static int stm32_cryp_ccm_init(struct stm32_cryp *cryp, u32 cfg) in stm32_cryp_ccm_init()
700 static int stm32_cryp_hw_init(struct stm32_cryp *cryp) in stm32_cryp_hw_init()
802 static void stm32_cryp_finish_req(struct stm32_cryp *cryp, int err) in stm32_cryp_finish_req()
821 static int stm32_cryp_cpu_start(struct stm32_cryp *cryp) in stm32_cryp_cpu_start()
852 struct stm32_cryp *cryp = stm32_cryp_find_dev(ctx); in stm32_cryp_crypt()
866 struct stm32_cryp *cryp = stm32_cryp_find_dev(ctx); in stm32_cryp_aead_crypt()
1157 struct stm32_cryp *cryp; in stm32_cryp_prepare_req()
1242 struct stm32_cryp *cryp = ctx->cryp; in stm32_cryp_cipher_one_req()
1256 struct stm32_cryp *cryp = ctx->cryp; in stm32_cryp_aead_one_req()
1275 static int stm32_cryp_read_auth_tag(struct stm32_cryp *cryp) in stm32_cryp_read_auth_tag()
1357 static void stm32_cryp_check_ctr_counter(struct stm32_cryp *cryp) in stm32_cryp_check_ctr_counter()
1383 static void stm32_cryp_irq_read_data(struct stm32_cryp *cryp) in stm32_cryp_irq_read_data()
1394 static void stm32_cryp_irq_write_block(struct stm32_cryp *cryp) in stm32_cryp_irq_write_block()
1404 static void stm32_cryp_irq_write_gcm_padded_data(struct stm32_cryp *cryp) in stm32_cryp_irq_write_gcm_padded_data()
1478 static void stm32_cryp_irq_set_npblb(struct stm32_cryp *cryp) in stm32_cryp_irq_set_npblb()
1492 static void stm32_cryp_irq_write_ccm_padded_data(struct stm32_cryp *cryp) in stm32_cryp_irq_write_ccm_padded_data()
1578 static void stm32_cryp_irq_write_data(struct stm32_cryp *cryp) in stm32_cryp_irq_write_data()
1619 static void stm32_cryp_irq_write_gcmccm_header(struct stm32_cryp *cryp) in stm32_cryp_irq_write_gcmccm_header()
1637 struct stm32_cryp *cryp = arg; in stm32_cryp_irq_thread()
1680 struct stm32_cryp *cryp = arg; in stm32_cryp_irq()
1974 struct stm32_cryp *cryp; in stm32_cryp_probe()
2093 struct stm32_cryp *cryp = platform_get_drvdata(pdev); in stm32_cryp_remove()
2124 struct stm32_cryp *cryp = dev_get_drvdata(dev); in stm32_cryp_runtime_suspend()
2133 struct stm32_cryp *cryp = dev_get_drvdata(dev); in stm32_cryp_runtime_resume()