From: Stas Sergeev <stsp@aknet.ru>
To: linux-msdos@vger.kernel.org
Subject: Re: [announce] dosemu-1.2.2
Date: Fri, 16 Jul 2004 21:40:08 +0400 [thread overview]
Message-ID: <40F812F8.7050107@aknet.ru> (raw)
[-- Attachment #1: Type: text/plain, Size: 204 bytes --]
Hello.
Ralph Alvy wrote:
> With version 1.2.1, hogthreshold at 2 keeps the CPU at 60% and printing
> is almost immediate at a timeout value of 10.
Probably the attached patch can
rectify the problem?
[-- Attachment #2: lpt.diff --]
[-- Type: text/x-patch, Size: 1521 bytes --]
--- src/base/dev/misc/lpt.c 2004-06-07 00:14:59.000000000 +0400
+++ src/base/dev/misc/lpt.c 2004-07-16 21:26:10.157433832 +0400
@@ -20,6 +20,7 @@
#include <sys/wait.h>
#include "emu.h"
+#include "timers.h"
#include "lpt.h"
#include "utilities.h"
#include "dos2linux.h"
@@ -53,11 +54,13 @@
return 1;
}
+ reset_idle();
+
switch (HI(ax)) {
case 0: /* write char */
/* p_printf("print character on lpt%d : %c (%d)\n",
LO(dx), LO(ax), LO(ax)); */
- HI(ax) = (lpt[LO(dx)].fops.write) (LO(dx), LO(ax));
+ HI(ax) = printer_write(LO(dx), LO(ax));
break;
case 1: /* init */
@@ -178,12 +181,12 @@
int
stub_printer_write(int prnum, int outchar)
{
- (lpt[prnum].fops.open) (prnum);
+ printer_open(prnum);
/* from now on, use real write */
lpt[prnum].fops.write = lpt[prnum].fops.realwrite;
- return ((lpt[prnum].fops.write) (prnum, outchar));
+ return printer_write(prnum, outchar);
}
int
@@ -234,8 +237,7 @@
for (loop = 0; loop < NUM_PRINTERS; loop++) {
p_printf("LPT: closing printer %d (%s)\n", loop,
lpt[loop].dev ? lpt[loop].dev : "<<NODEV>>");
- if (lpt[loop].fops.close)
- (lpt[loop].fops.close) (loop);
+ printer_close(loop);
}
}
@@ -248,9 +250,10 @@
if (lpt[i].remaining >= 0) {
p_printf("LPT: doing real tick for %d\n", i);
if (lpt[i].remaining) {
+ reset_idle();
lpt[i].remaining--;
if (!lpt[i].remaining)
- (lpt[i].fops.flush) (i);
+ printer_flush(i);
}
}
}
[-- Attachment #3: Type: text/plain, Size: 82 bytes --]
Scanned by evaluation version of Dr.Web antivirus Daemon
http://drweb.ru/unix/
next reply other threads:[~2004-07-16 17:40 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-07-16 17:40 Stas Sergeev [this message]
2004-07-19 4:05 ` [announce] dosemu-1.2.2 Ralph Alvy
-- strict thread matches above, loose matches on Subject: below --
2004-07-20 21:35 Stas Sergeev
2004-07-21 1:39 ` Ralph Alvy
2004-07-21 2:16 ` Bart Oldeman
2004-07-21 2:25 ` Ralph Alvy
2004-07-21 3:24 ` Bart Oldeman
2004-07-21 3:39 ` Ralph Alvy
2004-07-21 3:44 ` Ralph Alvy
2004-07-21 3:52 ` Bart Oldeman
2004-07-21 4:09 ` Ralph Alvy
2004-07-22 14:03 ` Ryan Underwood
2004-07-22 15:26 ` Ralph Alvy
2004-07-21 3:42 ` Ralph Alvy
2004-07-19 10:04 Stas Sergeev
2004-07-19 14:47 ` Ralph Alvy
2004-07-20 4:48 ` Ralph Alvy
2004-07-20 4:56 ` Bart Oldeman
2004-07-20 6:26 ` Ralph Alvy
2004-07-11 8:43 Bart Oldeman
2004-07-11 19:28 ` Ralph Alvy
2004-07-13 0:17 ` Ralph Alvy
2004-07-13 16:41 ` Ralph Alvy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=40F812F8.7050107@aknet.ru \
--to=stsp@aknet.ru \
--cc=linux-msdos@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox