remove redundant nightly features

master
WangRunji 6 years ago
parent a74b893bd2
commit 2f8cfabbca

@ -1,15 +1,10 @@
use core::ptr::Unique;
use core::fmt;
use spin::Mutex;
use volatile::Volatile;
use lazy_static::lazy_static;
use x86_64::instructions::port::Port;
use crate::logging::Color;
use crate::consts::KERNEL_OFFSET;
use lazy_static::lazy_static;
pub const VGA_BUFFER: Unique<VgaBuffer> = unsafe {
Unique::new_unchecked((KERNEL_OFFSET + 0xb8000) as *mut _)
};
#[derive(Debug, Clone, Copy)]
struct ColorCode(u8);
@ -73,8 +68,7 @@ impl VgaBuffer {
lazy_static! {
pub static ref VGA_WRITER: Mutex<VgaWriter> = Mutex::new(
// It is the only user of VGA_BUFFER. So it's safe.
VgaWriter::new(unsafe{ &mut *VGA_BUFFER.as_ptr() })
VgaWriter::new(unsafe{ &mut *((KERNEL_OFFSET + 0xb8000) as *mut VgaBuffer) })
);
}

@ -1,16 +1,10 @@
#![feature(ptr_internals)]
#![feature(lang_items)]
#![feature(const_fn)]
#![feature(alloc)]
#![feature(naked_functions)]
#![feature(asm)]
#![feature(optin_builtin_traits)]
#![feature(panic_info_message)]
#![feature(global_asm)]
#![feature(compiler_builtins_lib)]
#![feature(raw)]
#![feature(vec_resize_default)]
#![feature(extern_crate_item_prelude)]
#![no_std]
// just keep it ...

Loading…
Cancel
Save