mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
vmm: Implement GDB event handler to enable --gdb flag
This commit adds event fds and the event handler to send/receive requests and responses from the GDB thread. It also adds `--gdb` flag to enable GDB stub feature. Signed-off-by: Akira Moroo <retrage01@gmail.com>
This commit is contained in:
committed by
Rob Bradford
parent
23bb629241
commit
2451c4d833
+2
-2
@@ -488,7 +488,7 @@ impl run_blocking::BlockingEventLoop for GdbEventLoop {
|
||||
}
|
||||
}
|
||||
|
||||
pub fn gdb_thread(mut gdbstub: GdbStub, path: &str) {
|
||||
pub fn gdb_thread(mut gdbstub: GdbStub, path: &std::path::Path) {
|
||||
let listener = match UnixListener::bind(path) {
|
||||
Ok(s) => s,
|
||||
Err(e) => {
|
||||
@@ -496,7 +496,7 @@ pub fn gdb_thread(mut gdbstub: GdbStub, path: &str) {
|
||||
return;
|
||||
}
|
||||
};
|
||||
info!("Waiting for a GDB connection on {}...", path);
|
||||
info!("Waiting for a GDB connection on {}...", path.display());
|
||||
|
||||
let (stream, addr) = match listener.accept() {
|
||||
Ok(v) => v,
|
||||
|
||||
Reference in New Issue
Block a user