summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornatrixaeria <upezu@student.kit.edu>2019-11-07 16:55:32 +0100
committernatrixaeria <upezu@student.kit.edu>2019-11-07 16:55:32 +0100
commitbfdafd91058b91d5d4e8ab36076e05ae29355f7b (patch)
tree670eb1c4e77e6f82bb81995d2cf3f08a01ec869f
parente19c8879eb7732d3bcb62194065c9cb2892cf1ab (diff)
Represent rust vga text structs as C structs
-rw-r--r--kernel/src/io/vga_text.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/kernel/src/io/vga_text.rs b/kernel/src/io/vga_text.rs
index fddb3e1..620aa32 100644
--- a/kernel/src/io/vga_text.rs
+++ b/kernel/src/io/vga_text.rs
@@ -23,6 +23,7 @@ pub const WIDTH: usize = 80;
pub const HEIGHT: usize = 25;
#[derive(Clone, Copy)]
+#[repr(C)]
pub struct CharState(pub u8);
impl CharState {
@@ -41,6 +42,7 @@ impl CharState {
#[no_mangle]
#[derive(Clone, Copy)]
+#[repr(C)]
pub struct VgaChar {
pub byte: u8,
pub state: CharState,