Post-merge fixing to make the floppy driver work.
authorDavid Given <dg@cowlark.com>
Mon, 23 Apr 2018 20:27:03 +0000 (22:27 +0200)
committerDavid Given <dg@cowlark.com>
Mon, 23 Apr 2018 20:27:03 +0000 (22:27 +0200)
Kernel/platform-amstradnc/config.h
Kernel/platform-amstradnc/devfd.c
Kernel/platform-amstradnc/devices.c
Kernel/platform-amstradnc/nc200/Makefile
Kernel/platform-amstradnc/nc200/fuzix.lnk

index 45d347a..0da8f5e 100644 (file)
@@ -58,7 +58,7 @@
 #define NBUFS    10       /* Number of block buffers */
 #ifdef CONFIG_NC200
 #define NMOUNTS        2         /* Floppy can also be mounted */
-#define BOOTDEVICENAMES "fd#,hd#"
+#define BOOTDEVICENAMES "hd#,fd#"
 #define MAX_BLKDEV 1  /* Single floppy */
 #else
 #define NMOUNTS         1        /* Number of mounts at a time - nothing mountable! */
index aa1e687..4360bae 100644 (file)
@@ -3,7 +3,6 @@
 #include <printf.h>
 #include <devfd.h>
 #include <device.h>
-#include <blkdev.h>
 #include <timer.h>
 
 static timer_t spindown_timer = 0;
index 31f7815..6587f37 100644 (file)
 #include <printf.h>
 
 #if defined CONFIG_NC200
-#include <devfd.h>
-#include <blkdev.h>
+#include "devfd.h"
 #endif
 
 struct devsw dev_tab[] =  /* The device driver switch table */
 {
-  /* 0: /dev/fd                Floppy disc block devices (NC200 only) */
+  /* 0: /dev/hd                Hard disc block devices (Really PCMCIA) */
+  {  rd_open,     no_close,    rd_read,   rd_write,   no_ioctl },
+  /* 1: /dev/fd                Floppy disc block devices (NC200 only) */
 #if defined CONFIG_NC200
   {  devfd_open, no_close, devfd_read, devfd_write, no_ioctl },
 #else
   {  nxio_open,     no_close,    no_rdwr,   no_rdwr,   no_ioctl },
 #endif
-  /* 1: /dev/hd                Hard disc block devices (Really PCMCIA) */
-  {  rd_open,     no_close,    rd_read,   rd_write,   no_ioctl },
   /* 2: /dev/tty       TTY devices */
   {  nc100_tty_open,     nc100_tty_close,   tty_read,  tty_write,  gfx_ioctl },
   /* 3: /dev/lpr       Printer devices */
index 40b4f53..5ebc2c6 100644 (file)
@@ -1,4 +1,5 @@
 CSRCS = \
+       ../devfd.c \
        ../devlpr.c \
        ../devtty.c \
        ../devrd.c \
@@ -12,6 +13,7 @@ ASRCS = \
        ../crt0.s \
        ../tricks.s \
        ../commonmem.s \
+       ../fdc765.s
 
 COBJS = $(CSRCS:.c=.rel)
 AOBJS = $(ASRCS:.s=.rel)
index c6f21f7..d664db7 100644 (file)
@@ -35,6 +35,8 @@ devsys.rel
 audio.rel
 usermem.rel
 usermem_std-z80.rel
+platform-amstradnc/devfd.rel
+platform-amstradnc/fdc765.rel
 platform-amstradnc/devlpr.rel
 platform-amstradnc/devtty.rel
 platform-amstradnc/devaudio.rel