diff options
author | Ralf Baechle <ralf@linux-mips.org> | 1998-04-05 11:23:36 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 1998-04-05 11:23:36 +0000 |
commit | 4318fbda2a7ee51caafdc4eb1f8028a3f0605142 (patch) | |
tree | cddb50a81d7d1a628cc400519162080c6d87868e /drivers/misc | |
parent | 36ea5120664550fae6d31f1c6f695e4f8975cb06 (diff) |
o Merge with Linux 2.1.91.
o First round of bugfixes for the SC/MC CPUs.
o FPU context switch fixes.
o Lazy context switches.
o Faster syscalls.
o Removed dead code.
o Shitloads of other things I forgot ...
Diffstat (limited to 'drivers/misc')
-rw-r--r-- | drivers/misc/parport_pc.c | 24 | ||||
-rw-r--r-- | drivers/misc/parport_share.c | 4 |
2 files changed, 21 insertions, 7 deletions
diff --git a/drivers/misc/parport_pc.c b/drivers/misc/parport_pc.c index e5ba92c9e..bd542b4fd 100644 --- a/drivers/misc/parport_pc.c +++ b/drivers/misc/parport_pc.c @@ -134,12 +134,12 @@ void parport_pc_change_mode(struct parport *p, int m) void parport_pc_write_fifo(struct parport *p, unsigned char v) { - /* FIXME */ + outb (v, p->base+CONFIGA); } unsigned char parport_pc_read_fifo(struct parport *p) { - return 0; /* FIXME */ + return inb (p->base+CONFIGA); } void parport_pc_disable_irq(struct parport *p) @@ -186,22 +186,34 @@ void parport_pc_restore_state(struct parport *p, struct parport_state *s) size_t parport_pc_epp_read_block(struct parport *p, void *buf, size_t length) { - return 0; /* FIXME */ + size_t got = 0; + for (; got < length; got++) { + *((char*)buf)++ = inb (p->base+EPPREG); + if (inb (p->base+STATUS) & 0x01) + break; + } + return got; } size_t parport_pc_epp_write_block(struct parport *p, void *buf, size_t length) { - return 0; /* FIXME */ + size_t written = 0; + for (; written < length; written++) { + outb (*((char*)buf)++, p->base+EPPREG); + if (inb (p->base+STATUS) & 0x01) + break; + } + return written; } int parport_pc_ecp_read_block(struct parport *p, void *buf, size_t length, void (*fn)(struct parport *, void *, size_t), void *handle) { - return 0; /* FIXME */ + return -ENOSYS; /* FIXME */ } int parport_pc_ecp_write_block(struct parport *p, void *buf, size_t length, void (*fn)(struct parport *, void *, size_t), void *handle) { - return 0; /* FIXME */ + return -ENOSYS; /* FIXME */ } int parport_pc_examine_irq(struct parport *p) diff --git a/drivers/misc/parport_share.c b/drivers/misc/parport_share.c index bc39b351c..bd0ae3c8b 100644 --- a/drivers/misc/parport_share.c +++ b/drivers/misc/parport_share.c @@ -1,4 +1,4 @@ -/* $Id: parport_share.c,v 1.10 1998/03/18 06:32:19 ralf Exp $ +/* $Id: parport_share.c,v 1.11 1998/03/26 10:38:32 ralf Exp $ * Parallel-port resource manager code. * * Authors: David Campbell <campbell@tirian.che.curtin.edu.au> @@ -46,7 +46,9 @@ struct parport *parport_enumerate(void) { #ifdef CONFIG_KMOD if (portlist == NULL) { +#if defined(CONFIG_PARPORT_PC_MODULE) || defined(CONFIG_PARPORT_AX_MODULE) || defined(CONFIG_PARPORT_ARC_MODULE) request_module("parport_lowlevel"); +#endif /* CONFIG_PARPORT_LOWLEVEL_MODULE */ #ifdef CONFIG_PNP_PARPORT_MODULE request_module("parport_probe"); #endif /* CONFIG_PNP_PARPORT_MODULE */ |