Commit fc82e843 authored by Xiang W's avatar Xiang W Committed by Anup Patel
Browse files

lib: sbi: Fix is_region_valid()



When order is equal to __riscv_xlen, the shift operation will not perform
any operation, which will cause reg->base & (BIT(reg->order) - 1) to always
be 0, and the condition has not been established.

This patch fixes this bug.

Signed-off-by: default avatarXiang W <wxjstz@126.com>
Reviewed-by: default avatarAnup Patel <anup@brainfault.org>
parent 74e20293
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment