Re: [PATCH] goldfish_rtc: Fix non-atomic read behaviour of TIME_LOW/TIME_HIGH

2020-07-17 Thread Richard Henderson
On 7/17/20 5:20 PM, Jessica Clarke wrote: > The specification says: > >0x00 TIME_LOW R: Get current time, then return low-order 32-bits. >0x04 TIME_HIGH R: Return high 32-bits from previous TIME_LOW read. > >... > >To read the value, the kernel must perform an IO_READ(TIME_L

[PATCH] goldfish_rtc: Fix non-atomic read behaviour of TIME_LOW/TIME_HIGH

2020-07-17 Thread Jessica Clarke
The specification says: 0x00 TIME_LOW R: Get current time, then return low-order 32-bits. 0x04 TIME_HIGH R: Return high 32-bits from previous TIME_LOW read. ... To read the value, the kernel must perform an IO_READ(TIME_LOW), which returns an unsigned 32-bit value, before an