lib: sbi_scratch: use bitwise ops in sbi_scratch_alloc_offset()
authorLi Jinpei <leekingp1994@163.com>
Tue, 11 Feb 2020 09:57:49 +0000 (15:27 +0530)
committerAnup Patel <anup@brainfault.org>
Thu, 13 Feb 2020 03:40:55 +0000 (09:10 +0530)
commit179eddeb9ca5fc1869d40696e0d4cd9899b9d92d
tree514b5b655908512a5d6352a3bb2427e3897bb84b
parentd6fa7f95bbcaa080810656c79e8879357b312280
lib: sbi_scratch: use bitwise ops in sbi_scratch_alloc_offset()

Instead of using loop to make "size" machine word aligned, we should
use bitwise ops.

Signed-off-by: Li Jinpei <leekingp1994@163.com>
Signed-off-by: Anup Patel <anup.patel@wdc.com>
Reviewed-by: Atish Patra <atish.patra@wdc.com>
lib/sbi/sbi_scratch.c