kernel/riscv64: Fix GetChar data val assignment for sifive uart
Change-Id: I81981d23222f81ee936695c3257e8185a7bcebfd
This commit is contained in:
parent
f0e1bca09c
commit
cb256af95c
@ -80,7 +80,7 @@ ArchUARTSifive::GetChar(bool wait)
|
||||
{
|
||||
UARTSifiveRegs::Rxdata data;
|
||||
do {
|
||||
data = { .val = Regs()->rxdata.val };
|
||||
data.val = Regs()->rxdata.val;
|
||||
} while (!wait || data.isEmpty);
|
||||
|
||||
return data.isEmpty ? -1 : data.data;
|
||||
|
Loading…
x
Reference in New Issue
Block a user