diff options
author | bde <bde@FreeBSD.org> | 2000-09-17 16:37:30 +0000 |
---|---|---|
committer | bde <bde@FreeBSD.org> | 2000-09-17 16:37:30 +0000 |
commit | 41483dda6f386f6f95a914fff78c848fa42398f9 (patch) | |
tree | 1d7482e063d571648f590491896133a42627f340 | |
parent | 62e0e10410c07cfb086acfffd093bbecd52cff35 (diff) | |
download | FreeBSD-src-41483dda6f386f6f95a914fff78c848fa42398f9.zip FreeBSD-src-41483dda6f386f6f95a914fff78c848fa42398f9.tar.gz |
Brought back schedsofttty() (SMPng casualty). Didn't bring back the
other schedsoft*() functions since they have never been used.
Removed confused comment about not needing these functions. The
functions delay scheduling of SWIs until the next hardclock tick.
For devices that only deliver a few characters per interrupt, this
reduces the number of calls to the scheduler by a large factor (about
115 for each sio port at 115200 bps).
-rw-r--r-- | sys/i386/isa/ipl_funcs.c | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/sys/i386/isa/ipl_funcs.c b/sys/i386/isa/ipl_funcs.c index 14eb240..1cd6070 100644 --- a/sys/i386/isa/ipl_funcs.c +++ b/sys/i386/isa/ipl_funcs.c @@ -50,6 +50,12 @@ void name(void) \ sched_ithd((void *) SOFTINTR); \ } +#define DO_SETBITS_AND_NO_MORE(name, var, bits) \ +void name(void) \ +{ \ + atomic_set_int(var, bits); \ +} + DO_SETBITS(setdelayed, &spending, loadandclear(&idelayed)) DO_SETBITS(setsoftcamnet,&spending, SWI_CAMNET_PENDING) DO_SETBITS(setsoftcambio,&spending, SWI_CAMBIO_PENDING) @@ -59,16 +65,7 @@ DO_SETBITS(setsofttty, &spending, SWI_TTY_PENDING) DO_SETBITS(setsoftvm, &spending, SWI_VM_PENDING) DO_SETBITS(setsofttq, &spending, SWI_TQ_PENDING) -/* - * We don't need to schedule soft interrupts any more, it happens - * automatically. - */ -#define schedsoftcamnet -#define schedsoftcambio -#define schedsoftnet -#define schedsofttty -#define schedsoftvm -#define schedsofttq +DO_SETBITS_AND_NO_MORE(schedsofttty, &idelayed, SWI_TTY_PENDING) unsigned softclockpending(void) |