mirror of
https://github.com/drasko/codezero.git
synced 2026-02-11 01:13:16 +01:00
exchange_registers(), modified thread_control calls seem to work
- Fixed do_mmap() so that it returns mapped address, and various bugs. - A child seems to fork with new setup, but with incorrect return value. Need to use and test exregs() for fork + clone. - Shmat searches an unmapped area if input arg is invalid, do_mmap() should do this.
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
void exregs_set_stack(struct exregs_data *s, unsigned long sp);
|
||||
void exregs_set_mr_return(struct exregs_data *s, unsigned long retreg);
|
||||
void exregs_set_pc(struct exregs_data *s, unsigned long pc);
|
||||
void exregs_set_pager(struct exregs_data *s, l4id_t pagerid);
|
||||
|
||||
/*
|
||||
exregs_set_stack(unsigned long sp)
|
||||
|
||||
@@ -21,7 +21,4 @@ void init_mm_descriptors(struct page_bitmap *page_map,
|
||||
struct bootdesc *bootdesc, struct membank *membank);
|
||||
void init_physmem(struct initdata *initdata, struct membank *membank);
|
||||
|
||||
int do_mmap(struct vm_file *mapfile, unsigned long f_offset, struct tcb *t,
|
||||
unsigned long map_address, unsigned int flags, unsigned int pages);
|
||||
|
||||
#endif /* __MEMORY_H__ */
|
||||
|
||||
@@ -26,8 +26,8 @@ struct vm_area *vma_new(unsigned long pfn_start, unsigned long npages,
|
||||
|
||||
int do_munmap(void *vaddr, unsigned long size, struct tcb *task);
|
||||
|
||||
int do_mmap(struct vm_file *mapfile, unsigned long f_offset, struct tcb *t,
|
||||
unsigned long map_address, unsigned int flags, unsigned int pages);
|
||||
void *do_mmap(struct vm_file *mapfile, unsigned long f_offset, struct tcb *t,
|
||||
unsigned long map_address, unsigned int flags, unsigned int pages);
|
||||
|
||||
int mmap_address_validate(struct tcb *t, unsigned long map_address,
|
||||
unsigned int vm_flags);
|
||||
|
||||
Reference in New Issue
Block a user