From: Alan Cox Date: Tue, 11 Nov 2014 21:41:44 +0000 (+0000) Subject: swap: correct sign of pointers X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=85338f6fb5c1cad520569a05521642571a8edc3f;p=FUZIX.git swap: correct sign of pointers --- diff --git a/Kernel/include/kdata.h b/Kernel/include/kdata.h index 771674ae..7524c085 100644 --- a/Kernel/include/kdata.h +++ b/Kernel/include/kdata.h @@ -33,7 +33,7 @@ extern uint16_t runticks; /* Number of ticks current process has been swapped i extern time_t tod; /* Time of day */ extern clock_t ticks; /* Cumulative tick counter, in minutes and ticks */ -extern char *swapbase; /* Used by device driver for swapping */ +extern uint8_t *swapbase; /* Used by device driver for swapping */ extern unsigned swapcnt; extern blkno_t swapblk; diff --git a/Kernel/include/kernel.h b/Kernel/include/kernel.h index 177e915a..79ed3c24 100644 --- a/Kernel/include/kernel.h +++ b/Kernel/include/kernel.h @@ -671,7 +671,7 @@ extern int _select(void); /* swap.c */ extern ptptr swapproc; -extern char *swapbase; +extern uint8_t *swapbase; extern unsigned int swapcnt; extern blkno_t swapblk; diff --git a/Kernel/swap.c b/Kernel/swap.c index 4f5af056..f2cedbb7 100644 --- a/Kernel/swap.c +++ b/Kernel/swap.c @@ -17,7 +17,7 @@ #endif -char *swapbase; +uint8_t *swapbase; unsigned int swapcnt; blkno_t swapblk; ptptr swapproc; /* Target process space */ @@ -128,7 +128,7 @@ static void swapin(ptptr p) #ifdef UDATA_SWAPSIZE ptr = swapin_prepare_uarea(p); if (ptr) - swapread(SWAPDEV, blk, UDATA_SWAPSIZE, (char *) &udata); + swapread(SWAPDEV, blk, UDATA_SWAPSIZE, (uint8_t *) &udata); #endif #ifdef DEBUG kprintf("%x: swapin done %d\n", p, p->p_page);