smc_user: Correct cache_flush to flush_dcache_range (#48)

cache_flush is a non-existent function
This commit is contained in:
Mat M 2018-02-23 23:38:21 -05:00 committed by SciresM
parent 44a2b7a344
commit 56f5b56235

View File

@ -308,9 +308,9 @@ uint32_t user_generate_specific_aes_key(smc_args_t *args) {
uint8_t dev_specific_aes_key_ctr[0x10] = {0x3C, 0xD5, 0x92, 0xEC, 0x68, 0x31, 0x4A, 0x06, 0xD4, 0x1B, 0x0C, 0xD9, 0xF6, 0x2E, 0xD9, 0xE9};
uint8_t dev_specific_aes_key_mask[0x10] = {0xAC, 0xCA, 0x9A, 0xCA, 0xFF, 0x2E, 0xB9, 0x22, 0xCC, 0x1F, 0x4F, 0xAD, 0xDD, 0x77, 0x21, 0x1E};
cache_flush(key, key + 0x10);
flush_dcache_range(key, key + 0x10);
se_aes_ctr_crypt(keyslot, key, 0x10, dev_specific_aes_key_source, 0x10, dev_specific_aes_key_ctr, 0x10);
cache_flush(key, key + 0x10);
flush_dcache_range(key, key + 0x10);
if (should_mask) {
for (unsigned int i = 0; i < 0x10; i++) {