diff options
author | rgrimes <rgrimes@FreeBSD.org> | 1995-06-11 19:33:05 +0000 |
---|---|---|
committer | rgrimes <rgrimes@FreeBSD.org> | 1995-06-11 19:33:05 +0000 |
commit | 1b1ee5553889e207087539ddafa5dfd4e28bd585 (patch) | |
tree | ba998dfb4fcad03e00a5cbf58e2a0ad648bab6e6 /sys/i386/isa | |
parent | b1a97daa1e06ab0de3071f979965878fd056292b (diff) | |
download | FreeBSD-src-1b1ee5553889e207087539ddafa5dfd4e28bd585.zip FreeBSD-src-1b1ee5553889e207087539ddafa5dfd4e28bd585.tar.gz |
Merge RELENG_2_0_5 into HEAD
Diffstat (limited to 'sys/i386/isa')
-rw-r--r-- | sys/i386/isa/clock.c | 4 | ||||
-rw-r--r-- | sys/i386/isa/fd.c | 6 | ||||
-rw-r--r-- | sys/i386/isa/if_el.c | 3 | ||||
-rw-r--r-- | sys/i386/isa/matcd/matcd.c | 18 |
4 files changed, 22 insertions, 9 deletions
diff --git a/sys/i386/isa/clock.c b/sys/i386/isa/clock.c index e1bc372..bf8b8ef 100644 --- a/sys/i386/isa/clock.c +++ b/sys/i386/isa/clock.c @@ -34,7 +34,7 @@ * SUCH DAMAGE. * * from: @(#)clock.c 7.2 (Berkeley) 5/12/91 - * $Id: clock.c,v 1.33 1995/05/11 07:44:40 bde Exp $ + * $Id: clock.c,v 1.34.2.1 1995/06/09 03:29:17 davidg Exp $ */ /* @@ -453,7 +453,7 @@ inittodr(time_t base) splx(s); /* Look if we have a RTC present and the time is valid */ - if (rtcin(RTC_STATUSD) != RTCSD_PWR) + if (!(rtcin(RTC_STATUSD) & RTCSD_PWR)) goto wrong_time; /* wait for time update to complete */ diff --git a/sys/i386/isa/fd.c b/sys/i386/isa/fd.c index be36035..3c46823 100644 --- a/sys/i386/isa/fd.c +++ b/sys/i386/isa/fd.c @@ -43,7 +43,7 @@ * SUCH DAMAGE. * * from: @(#)fd.c 7.4 (Berkeley) 5/25/91 - * $Id: fd.c,v 1.60 1995/05/09 12:25:52 rgrimes Exp $ + * $Id: fd.c,v 1.61.2.1 1995/06/08 10:26:23 davidg Exp $ * */ @@ -1080,12 +1080,11 @@ fdstrategy(struct buf *bp) fd = &fd_data[fdu]; fdc = fd->fdc; fdcu = fdc->fdcu; - fdblk = 128 << (fd->ft->secsize); #if NFT > 0 if (FDTYPE(minor(bp->b_dev)) & F_TAPE_TYPE) { /* ft tapes do not (yet) support strategy i/o */ - bp->b_error = ENXIO; + bp->b_error = ENODEV; bp->b_flags |= B_ERROR; goto bad; } @@ -1096,6 +1095,7 @@ fdstrategy(struct buf *bp) goto bad; } #endif + fdblk = 128 << (fd->ft->secsize); if (!(bp->b_flags & B_FORMAT)) { if ((fdu >= NFD) || (bp->b_blkno < 0)) { printf( diff --git a/sys/i386/isa/if_el.c b/sys/i386/isa/if_el.c index 2232a70..0571a8a 100644 --- a/sys/i386/isa/if_el.c +++ b/sys/i386/isa/if_el.c @@ -6,7 +6,7 @@ * * Questions, comments, bug reports and fixes to kimmel@cs.umass.edu. * - * $Id: if_el.c,v 1.12 1995/04/12 20:47:48 wollman Exp $ + * $Id: if_el.c,v 1.13.2.1 1995/06/09 18:12:09 davidg Exp $ */ /* Except of course for the portions of code lifted from other FreeBSD * drivers (mainly elread, elget and el_ioctl) @@ -768,6 +768,7 @@ el_ioctl(ifp, command, data) ((ifp->if_flags & IFF_RUNNING) == 0)) el_init(ifp->if_unit); } + break; case SIOCSIFMTU: diff --git a/sys/i386/isa/matcd/matcd.c b/sys/i386/isa/matcd/matcd.c index 1809ec9..e57f387 100644 --- a/sys/i386/isa/matcd/matcd.c +++ b/sys/i386/isa/matcd/matcd.c @@ -2405,9 +2405,21 @@ static int matcd_toc_entries(int ldrive, int cdrive, int controller, array from the kernel address space into the user address space */ - if (copyout(entries, ioc_entry->data, - (trk)*sizeof(struct cd_toc_entry)) != 0) { - return(EFAULT); + { + int len = ioc_entry->data_len; + int i = ioc_entry->starting_track - 1; + struct cd_toc_entry* from = &entries[i]; + struct cd_toc_entry* to = ioc_entry->data; + + while (i < trk && len >= sizeof(struct cd_toc_entry)) { + if (copyout(from, to, sizeof(struct cd_toc_entry)) != 0) { + return (EFAULT); + } + i++; + len -= sizeof(struct cd_toc_entry); + from++; + to++; + } } return(0); |