From d30ec2a75ba659b1bfd4adc1354e23a799c1b005 Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Fri, 27 Feb 2015 17:36:35 +0000 Subject: [PATCH] pcw8256: Get back building The floppy driver is still not behaving and I'm not sure why --- Kernel/bank16k.c | 6 ++++-- Kernel/platform-pcw8256/devtty.c | 5 +++++ Kernel/platform-pcw8256/fdc765.s | 1 + 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/Kernel/bank16k.c b/Kernel/bank16k.c index 5addb2e6..00b8a256 100644 --- a/Kernel/bank16k.c +++ b/Kernel/bank16k.c @@ -170,6 +170,7 @@ int swapout(ptptr p) uint16_t map; uint16_t base = SWAPBASE; uint16_t size = (0x4000 - SWAPBASE) >> 9; + uint16_t i; swapproc = p; @@ -186,7 +187,7 @@ int swapout(ptptr p) blk = map * SWAP_SIZE; /* Write the app (and possibly the uarea etc..) to disk */ for (i = 0; i < 4; i ++) { - swapwrite(SWAPDEV, blk, size, base); + swapwrite(SWAPDEV, blk, size, (uint8_t *)base); base += 0x4000; /* Last bank is determined by SWAP SIZE. We do the maths in 512's (0x60 = 0xC000) */ @@ -213,6 +214,7 @@ void swapin(ptptr p) uint16_t blk = p->p_page2 * SWAP_SIZE; uint16_t base = SWAPBASE; uint16_t size = (0x4000 - SWAPBASE) >> 9; + uint16_t i; #ifdef DEBUG kprintf("Swapin %x, %d\n", p, p->p_page); @@ -227,7 +229,7 @@ void swapin(ptptr p) swapproc = p; /* always ourself */ for (i = 0; i < 4; i ++) { - swapread(SWAPDEV, blk, size, base); + swapread(SWAPDEV, blk, size, (uint8_t *)base); base += 0x4000; /* Last bank is determined by SWAP SIZE. We do the maths in 512's (0x60 = 0xC000) */ diff --git a/Kernel/platform-pcw8256/devtty.c b/Kernel/platform-pcw8256/devtty.c index 603a8762..a7a8f7bd 100644 --- a/Kernel/platform-pcw8256/devtty.c +++ b/Kernel/platform-pcw8256/devtty.c @@ -120,6 +120,11 @@ int tty_carrier(uint8_t minor) return 1; } +void tty_sleeping(uint8_t minor) +{ + minor; +} + /* Pending better ioctl bits set up for 9600 8N1 */ void tty_init_port(void) diff --git a/Kernel/platform-pcw8256/fdc765.s b/Kernel/platform-pcw8256/fdc765.s index bbd40bc2..52849c5e 100644 --- a/Kernel/platform-pcw8256/fdc765.s +++ b/Kernel/platform-pcw8256/fdc765.s @@ -275,6 +275,7 @@ fd765_cmdop: ld hl, #_fd765_cmdbuf call fd765_sendcmd jr nz, read_failed + call _fd765_intwait call fd765_status_a ret -- 2.34.1