sio.c (98401) | sio.c (98619) |
---|---|
1/*- 2 * Copyright (c) 1991 The Regents of the University of California. 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 16 unchanged lines hidden (view full) --- 25 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 31 * SUCH DAMAGE. 32 * | 1/*- 2 * Copyright (c) 1991 The Regents of the University of California. 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 16 unchanged lines hidden (view full) --- 25 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 31 * SUCH DAMAGE. 32 * |
33 * $FreeBSD: head/sys/dev/sio/sio.c 98401 2002-06-18 21:30:37Z n_hibma $ | 33 * $FreeBSD: head/sys/dev/sio/sio.c 98619 2002-06-22 16:33:29Z n_hibma $ |
34 * from: @(#)com.c 7.5 (Berkeley) 5/16/91 35 * from: i386/isa sio.c,v 1.234 36 */ 37 38#include "opt_comconsole.h" 39#include "opt_compat.h" 40#include "opt_ddb.h" 41#include "opt_sio.h" --- 3168 unchanged lines hidden (view full) --- 3210siogdbgetc() 3211{ 3212 int c; 3213 Port_t iobase; 3214 speed_t speed; 3215 int s; 3216 struct siocnstate sp; 3217 | 34 * from: @(#)com.c 7.5 (Berkeley) 5/16/91 35 * from: i386/isa sio.c,v 1.234 36 */ 37 38#include "opt_comconsole.h" 39#include "opt_compat.h" 40#include "opt_ddb.h" 41#include "opt_sio.h" --- 3168 unchanged lines hidden (view full) --- 3210siogdbgetc() 3211{ 3212 int c; 3213 Port_t iobase; 3214 speed_t speed; 3215 int s; 3216 struct siocnstate sp; 3217 |
3218 if (minor(dev) == siocnunit) { | 3218 if (siogdbunit == siocnunit) { |
3219 iobase = siocniobase; 3220 speed = comdefaultrate; 3221 } else { 3222 iobase = siogdbiobase; 3223 speed = gdbdefaultrate; 3224 } 3225 3226 s = spltty(); --- 10 unchanged lines hidden (view full) --- 3237siogdbputc(c) 3238 int c; 3239{ 3240 Port_t iobase; 3241 speed_t speed; 3242 int s; 3243 struct siocnstate sp; 3244 | 3219 iobase = siocniobase; 3220 speed = comdefaultrate; 3221 } else { 3222 iobase = siogdbiobase; 3223 speed = gdbdefaultrate; 3224 } 3225 3226 s = spltty(); --- 10 unchanged lines hidden (view full) --- 3237siogdbputc(c) 3238 int c; 3239{ 3240 Port_t iobase; 3241 speed_t speed; 3242 int s; 3243 struct siocnstate sp; 3244 |
3245 if (minor(dev) == siocnunit) { | 3245 if (siogdbunit == siocnunit) { |
3246 iobase = siocniobase; 3247 speed = comdefaultrate; 3248 } else { 3249 iobase = siogdbiobase; 3250 speed = gdbdefaultrate; 3251 } 3252 3253 s = spltty(); 3254 siocnopen(&sp, iobase, speed); 3255 siocntxwait(siogdbiobase); 3256 outb(siogdbiobase + com_data, c); 3257 siocnclose(&sp, siogdbiobase); 3258 splx(s); 3259} 3260#endif | 3246 iobase = siocniobase; 3247 speed = comdefaultrate; 3248 } else { 3249 iobase = siogdbiobase; 3250 speed = gdbdefaultrate; 3251 } 3252 3253 s = spltty(); 3254 siocnopen(&sp, iobase, speed); 3255 siocntxwait(siogdbiobase); 3256 outb(siogdbiobase + com_data, c); 3257 siocnclose(&sp, siogdbiobase); 3258 splx(s); 3259} 3260#endif |