not fixed but I can't handle this anymore
This commit is contained in:
parent
dd6431ab84
commit
11dc2bbddd
4
.gdbinit
Normal file
4
.gdbinit
Normal file
|
@ -0,0 +1,4 @@
|
|||
set history save on
|
||||
file target/x86_64-ableos/debug/ableos
|
||||
target remote localhost:9000
|
||||
tui enable
|
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -7,5 +7,5 @@ userland/*/target
|
|||
kernel/target
|
||||
userland/root_fs/mnt/*
|
||||
target/
|
||||
|
||||
.gdb_history
|
||||
!*/.gitkeep
|
||||
|
|
|
@ -9,7 +9,7 @@ panic = "abort"
|
|||
|
||||
[package.metadata.bootimage]
|
||||
run-args = [
|
||||
"--nodefaults",
|
||||
# "--nodefaults",
|
||||
"-cpu",
|
||||
"Broadwell-v3",
|
||||
"-m",
|
||||
|
@ -33,8 +33,8 @@ run-args = [
|
|||
"../img.ext2",
|
||||
|
||||
|
||||
"-qmp",
|
||||
"unix:../qmp-sock,server,nowait",
|
||||
# "-qmp",
|
||||
# "unix:../qmp-sock,server,nowait",
|
||||
|
||||
]
|
||||
|
||||
|
|
|
@ -76,16 +76,16 @@ pub fn kernel_main() -> ! {
|
|||
// }
|
||||
/*
|
||||
log_version_data();
|
||||
// */
|
||||
x86_64::instructions::interrupts::without_interrupts(|| {
|
||||
let mut scheduler = SCHEDULER.lock();
|
||||
// comment this out to resume normal use
|
||||
// scheduler.enqueue_spawn(traceloop);
|
||||
|
||||
// scheduler.enqueue_spawn(scratchpad);
|
||||
scheduler.enqueue_spawn(scratchpad);
|
||||
});
|
||||
|
||||
// */
|
||||
scratchpad();
|
||||
// scratchpad();
|
||||
|
||||
sloop()
|
||||
}
|
||||
|
|
|
@ -51,8 +51,8 @@ impl log::Log for SimpleLogger {
|
|||
};
|
||||
|
||||
let line = match record.line() {
|
||||
Some(line_number) => line_number.to_string(),
|
||||
None => "??".to_string(),
|
||||
Some(line_number) => line_number,
|
||||
None => 0,
|
||||
};
|
||||
|
||||
if KERNEL_CONF.logging.log_to_serial {
|
||||
|
|
|
@ -137,7 +137,9 @@ pub fn real_shell() {
|
|||
buf.push(chr);
|
||||
print!("{}", chr);
|
||||
}
|
||||
None => (),
|
||||
None => {
|
||||
// trace!("{}", buf);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -54,14 +54,15 @@ fn main() -> anyhow::Result<()> {
|
|||
} => {
|
||||
let _dir = xshell::pushd("./ableos");
|
||||
|
||||
let debug_log: &[&str] = match debug {
|
||||
true => &["-D", "debug.log"],
|
||||
false => &[],
|
||||
};
|
||||
match machine.unwrap_or(MachineType::X86) {
|
||||
MachineType::X86 => {
|
||||
// export RUSTFLAGS=\"-Cforce-unwind-tables -Clink-arg=-Wl,eh_frame.ld\" &&
|
||||
xshell::cmd!("cargo run --release -- -D debug.log").run()?;
|
||||
|
||||
match debug {
|
||||
true => xshell::cmd!("cargo run -- -S -gdb tcp::9000").run()?,
|
||||
false => xshell::cmd!("cargo run --release").run()?,
|
||||
}
|
||||
|
||||
if profile {
|
||||
xshell::cmd!("python qprofiler.py --path=qmp-sock --filename=target/x86_64-ableos/release/ableos").run()?;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue