mirror of
https://github.com/ipxe/ipxe
synced 2026-01-23 04:29:01 +03:00
[time] Use currticks() to provide the null system time
For platforms with no real-time clock (such as RISC-V SBI) we use the null time source, which currently just returns a constant zero. Switch to using currticks() to provide a clock that does not represent the real current time, but does at least advance at approximately the correct rate. In conjunction with the "ntp" command, this allows these platforms to use time-dependent features such as X.509 certificate verification for HTTPS connections. Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
@@ -15,9 +15,4 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
|
||||
#define TIME_PREFIX_null __null_
|
||||
#endif
|
||||
|
||||
static inline __always_inline time_t
|
||||
TIME_INLINE ( null, time_now ) ( void ) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
#endif /* _IPXE_NULL_TIME_H */
|
||||
|
||||
Reference in New Issue
Block a user