diff options
Diffstat (limited to 'lib/sbi/sbi_mpxy.c')
| -rw-r--r-- | lib/sbi/sbi_mpxy.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/lib/sbi/sbi_mpxy.c b/lib/sbi/sbi_mpxy.c index 19f59f3a..41fea0ae 100644 --- a/lib/sbi/sbi_mpxy.c +++ b/lib/sbi/sbi_mpxy.c @@ -401,10 +401,10 @@ int sbi_mpxy_set_shmem(unsigned long shmem_phys_lo, if (flags == SBI_EXT_MPXY_SHMEM_FLAG_OVERWRITE_RETURN) { ret_buf = (unsigned long *)(ulong)SHMEM_PHYS_ADDR(shmem_phys_hi, shmem_phys_lo); - sbi_hart_protection_map_range((unsigned long)ret_buf, mpxy_shmem_size); + sbi_hart_protection_temp_map_range((unsigned long)ret_buf, mpxy_shmem_size); ret_buf[0] = cpu_to_lle(ms->shmem.shmem_addr_lo); ret_buf[1] = cpu_to_lle(ms->shmem.shmem_addr_hi); - sbi_hart_protection_unmap_range((unsigned long)ret_buf, mpxy_shmem_size); + sbi_hart_protection_temp_unmap_range((unsigned long)ret_buf, mpxy_shmem_size); } /** Setup the new shared memory */ @@ -436,7 +436,7 @@ int sbi_mpxy_get_channel_ids(u32 start_index) return SBI_ERR_INVALID_PARAM; shmem_base = hart_shmem_base(ms); - sbi_hart_protection_map_range((unsigned long)hart_shmem_base(ms), mpxy_shmem_size); + sbi_hart_protection_temp_map_range((unsigned long)hart_shmem_base(ms), mpxy_shmem_size); /** number of channel ids which can be stored in shmem adjusting * for remaining and returned fields */ @@ -466,7 +466,7 @@ int sbi_mpxy_get_channel_ids(u32 start_index) shmem_base[0] = cpu_to_le32(remaining); shmem_base[1] = cpu_to_le32(returned); - sbi_hart_protection_unmap_range((unsigned long)hart_shmem_base(ms), mpxy_shmem_size); + sbi_hart_protection_temp_unmap_range((unsigned long)hart_shmem_base(ms), mpxy_shmem_size); return SBI_SUCCESS; } @@ -498,7 +498,7 @@ int sbi_mpxy_read_attrs(u32 channel_id, u32 base_attr_id, u32 attr_count) shmem_base = hart_shmem_base(ms); end_id = base_attr_id + attr_count - 1; - sbi_hart_protection_map_range((unsigned long)hart_shmem_base(ms), mpxy_shmem_size); + sbi_hart_protection_temp_map_range((unsigned long)hart_shmem_base(ms), mpxy_shmem_size); /* Standard attributes range check */ if (mpxy_is_std_attr(base_attr_id)) { @@ -537,7 +537,7 @@ int sbi_mpxy_read_attrs(u32 channel_id, u32 base_attr_id, u32 attr_count) base_attr_id, attr_count); } out: - sbi_hart_protection_unmap_range((unsigned long)hart_shmem_base(ms), mpxy_shmem_size); + sbi_hart_protection_temp_unmap_range((unsigned long)hart_shmem_base(ms), mpxy_shmem_size); return ret; } @@ -650,7 +650,7 @@ int sbi_mpxy_write_attrs(u32 channel_id, u32 base_attr_id, u32 attr_count) shmem_base = hart_shmem_base(ms); end_id = base_attr_id + attr_count - 1; - sbi_hart_protection_map_range((unsigned long)shmem_base, mpxy_shmem_size); + sbi_hart_protection_temp_map_range((unsigned long)shmem_base, mpxy_shmem_size); mem_ptr = (u32 *)shmem_base; @@ -707,7 +707,7 @@ int sbi_mpxy_write_attrs(u32 channel_id, u32 base_attr_id, u32 attr_count) base_attr_id, attr_count); } out: - sbi_hart_protection_unmap_range((unsigned long)shmem_base, mpxy_shmem_size); + sbi_hart_protection_temp_unmap_range((unsigned long)shmem_base, mpxy_shmem_size); return ret; } @@ -740,7 +740,7 @@ int sbi_mpxy_send_message(u32 channel_id, u8 msg_id, return SBI_ERR_INVALID_PARAM; shmem_base = hart_shmem_base(ms); - sbi_hart_protection_map_range((unsigned long)shmem_base, mpxy_shmem_size); + sbi_hart_protection_temp_map_range((unsigned long)shmem_base, mpxy_shmem_size); if (resp_data_len) { resp_buf = shmem_base; @@ -757,7 +757,7 @@ int sbi_mpxy_send_message(u32 channel_id, u8 msg_id, msg_data_len); } - sbi_hart_protection_unmap_range((unsigned long)shmem_base, mpxy_shmem_size); + sbi_hart_protection_temp_unmap_range((unsigned long)shmem_base, mpxy_shmem_size); if (ret == SBI_ERR_TIMEOUT || ret == SBI_ERR_IO) return ret; @@ -788,12 +788,12 @@ int sbi_mpxy_get_notification_events(u32 channel_id, unsigned long *events_len) return SBI_ERR_NOT_SUPPORTED; shmem_base = hart_shmem_base(ms); - sbi_hart_protection_map_range((unsigned long)shmem_base, mpxy_shmem_size); + sbi_hart_protection_temp_map_range((unsigned long)shmem_base, mpxy_shmem_size); eventsbuf = shmem_base; ret = channel->get_notification_events(channel, eventsbuf, mpxy_shmem_size, events_len); - sbi_hart_protection_unmap_range((unsigned long)shmem_base, mpxy_shmem_size); + sbi_hart_protection_temp_unmap_range((unsigned long)shmem_base, mpxy_shmem_size); if (ret) return ret; |
