Fix more warnings

This commit is contained in:
pjht 2019-05-05 07:31:13 -05:00
parent 21a395de3b
commit 630769065d
5 changed files with 4 additions and 4 deletions

View File

@ -180,7 +180,7 @@ void isr_handler(registers_t r) {
} else if (r.eax==5) {
r.ebx=(uint32_t)tasking_get_errno_address();
} else if (r.eax==6) {
r.ebx=tasking_get_msg((uint32_t*)r.ebx);
r.ebx=(uint32_t)tasking_get_msg((uint32_t*)r.ebx);
} else if (r.eax==7) {
tasking_send_msg(r.ebx,(void*)r.ecx,r.edx);
}

View File

@ -1,5 +1,6 @@
#include <grub/multiboot2.h>
#include "../halt.h"
#include "../../drivers/vga.h"
#include <stdint.h>
#include <stdlib.h>
#include <klog.h>
@ -38,7 +39,6 @@ void pmem_init(struct multiboot_boot_header_tag* tags) {
struct multiboot_mmap_entry* orig_ptr=(struct multiboot_mmap_entry*)(((char*)tag)+16);
for (struct multiboot_mmap_entry* ptr=orig_ptr;(char*)ptr<((char*)orig_ptr)+tag->size;ptr++) {
if (ptr->type!=MULTIBOOT_MEMORY_AVAILABLE) continue;
uint32_t size=ptr->len;
uint32_t start=ptr->addr;
if (start<0x100000) continue;
uint32_t end=start+ptr->len-1;
@ -51,7 +51,6 @@ void pmem_init(struct multiboot_boot_header_tag* tags) {
clear_bmap_bit(i);
}
}
char str[256];
break;
}
}

View File

@ -86,7 +86,7 @@ void tasking_send_msg(uint32_t pid,void* msg,uint32_t size) {
void* phys_addr=virt_to_phys(msg);
load_address_space(task->regs.cr3);
uint32_t page=find_free_pages((size/4096)+1);
map_pages(page<<12,phys_addr,(size/4096)+1,1,0);
map_pages((void*)(page<<12),phys_addr,(size/4096)+1,1,0);
if (task->msg_store==NULL) {
task->msg_store=malloc(sizeof(void*)*256);
task->sender_store=malloc(sizeof(uint32_t)*256);

Binary file not shown.

View File

@ -1,4 +1,5 @@
#include "../libc/string.h"
#include "vga.h"
#include <grub/text_fb_info.h>
int main() {