License rust and c source files

This commit is contained in:
Jianfeng Jiang
2024-01-03 03:22:36 +00:00
committed by Tate, Hongliang Tian
parent 5fb8a9f7e5
commit faaa4438d6
559 changed files with 1192 additions and 89 deletions

View File

@ -1,3 +1,5 @@
// SPDX-License-Identifier: MPL-2.0
//! This module provides abstractions for hardware-assisted timing mechanisms, encapsulated by the `ClockSource` struct.
//! A `ClockSource` can be constructed from any counter with a stable frequency, enabling precise time measurements to be taken
//! by retrieving instances of `Instant`.

View File

@ -1,3 +1,5 @@
// SPDX-License-Identifier: MPL-2.0
//! The system time of Asterinas.
#![no_std]
#![forbid(unsafe_code)]

View File

@ -1,3 +1,5 @@
// SPDX-License-Identifier: MPL-2.0
use aster_frame::arch::x86::device::cmos::{get_century_register, CMOS_ADDRESS, CMOS_DATA};
use core::sync::atomic::AtomicU8;
use core::sync::atomic::Ordering::Relaxed;

View File

@ -1,3 +1,5 @@
// SPDX-License-Identifier: MPL-2.0
//! This module provide a instance of `ClockSource` based on TSC.
//!
//! Use `init` to initialize this module.