mirror of
https://github.com/Atmosphere-NX/Atmosphere
synced 2024-11-09 22:56:35 +00:00
exo: fix SE driver coherency bug (closes #384)
This commit is contained in:
parent
991fe78740
commit
3fcad4bc65
1 changed files with 5 additions and 0 deletions
|
@ -315,6 +315,7 @@ void se_aes_crypt_insecure_internal(unsigned int keyslot, uint32_t out_ll_paddr,
|
|||
se->ERR_STATUS_REG = se->ERR_STATUS_REG;
|
||||
se->INT_STATUS_REG = se->INT_STATUS_REG;
|
||||
se->OPERATION_REG = 1;
|
||||
(void)(se->OPERATION_REG);
|
||||
|
||||
/* Ensure writes go through. */
|
||||
__dsb_ish();
|
||||
|
@ -477,6 +478,7 @@ void trigger_se_rsa_op(void *buf, size_t size) {
|
|||
se->ERR_STATUS_REG = se->ERR_STATUS_REG;
|
||||
se->INT_STATUS_REG = se->INT_STATUS_REG;
|
||||
se->OPERATION_REG = 1;
|
||||
(void)(se->OPERATION_REG);
|
||||
|
||||
/* Ensure writes go through. */
|
||||
__dsb_ish();
|
||||
|
@ -500,6 +502,9 @@ void trigger_se_blocking_op(unsigned int op, void *dst, size_t dst_size, const v
|
|||
se->ERR_STATUS_REG = se->ERR_STATUS_REG;
|
||||
se->INT_STATUS_REG = se->INT_STATUS_REG;
|
||||
se->OPERATION_REG = op;
|
||||
(void)(se->OPERATION_REG);
|
||||
|
||||
__dsb_ish();
|
||||
|
||||
while (!(se->INT_STATUS_REG & 0x10)) { /* Wait a while */ }
|
||||
|
||||
|
|
Loading…
Reference in a new issue