Reorganize mammoth lib in rust.

This commit is contained in:
Drew Galbraith 2024-07-28 19:26:23 -07:00
parent d5a5041c4b
commit d35e8d253f
12 changed files with 223 additions and 214 deletions

View file

@ -8,8 +8,8 @@ use alloc::string::ToString;
use mammoth::debug;
use mammoth::define_entry;
use mammoth::syscall::debug;
use mammoth::syscall::z_err_t;
use mammoth::thread;
use mammoth::zion::z_err_t;
use yellowstone::GetEndpointRequest;
use yellowstone::YellowstoneClient;
@ -22,16 +22,16 @@ pub extern "C" fn main() -> z_err_t {
debug(&x);
debug!("Formatted {}", "string");
let mut vmmo_cap: u64 = 0;
let obj_req = mammoth::syscall::ZMemoryObjectCreateReq {
let obj_req = mammoth::zion::ZMemoryObjectCreateReq {
size: 0,
vmmo_cap: &mut vmmo_cap as *mut u64,
};
mammoth::syscall::syscall(mammoth::syscall::kZionMemoryObjectCreate, &obj_req)
mammoth::syscall::syscall(mammoth::zion::kZionMemoryObjectCreate, &obj_req)
.expect("Failed to create memory object");
let mut yellowstone;
unsafe {
yellowstone = YellowstoneClient::new(mammoth::INIT_ENDPOINT);
yellowstone = YellowstoneClient::new(mammoth::init::INIT_ENDPOINT);
}
let endpoint = yellowstone