[Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Discussion of development and patch submission.
Battler
Posts: 793
Joined: Sun 06 Jul, 2014 7:05 pm

[Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby Battler » Mon 20 Mar, 2017 5:23 pm

This happens on any board and emulated CPU - when you're using Windows 95 OSR 2 with the S3 Trio64, the DOS prompt will hang the guest OS when in windowed mode. Basically, just clean install the OS, and try to enter the MS-DOS prompt by doing Start -> Run... -> dosprmpt . You will see the waiting cursor, and the OS will be stuck there. Does not happen with any other graphics card.
User avatar
leilei
Posts: 432
Joined: Fri 25 Apr, 2014 4:47 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby leilei » Tue 21 Mar, 2017 12:11 am

Cannot reproduce (with a proper self-dumped Phoenix Trio64 BIOS from a STB Powergraph 64)
Battler
Posts: 793
Joined: Sun 06 Jul, 2014 7:05 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby Battler » Tue 21 Mar, 2017 4:18 am

Except my emulation is supposed to work with the publicly available Phoenix Trio64 BIOS, because that's what's available online. And the issue also seems to hit OS/2 Warp 4. I guess the BIOS we have does something differently, most likely it tries to use a feature that is not implemented. Also, the problem does not happen on Virtual PC 2004, even with the same Phoenix S3 Trio64 BIOS replacing the original VPC BIOS. So it's still a PCem bug.

Edit: I just tried on two other Phoenix S3 Trio64 BIOS'es, and I still have the same bug. So there's definitely something wrong.
SA1988
Posts: 204
Joined: Wed 30 Apr, 2014 9:38 am

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby SA1988 » Tue 21 Mar, 2017 4:43 pm

leilei wrote:Cannot reproduce (with a proper self-dumped Phoenix Trio64 BIOS from a STB Powergraph 64)


Use the default drivers.
Battler
Posts: 793
Joined: Sun 06 Jul, 2014 7:05 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby Battler » Tue 21 Mar, 2017 7:01 pm

Yeah, you should use the default drivers, and the commonly available BIOS, as that's what I intended the Trio64 emulation to use in the first place when I added it.
Battler
Posts: 793
Joined: Sun 06 Jul, 2014 7:05 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby Battler » Tue 21 Mar, 2017 8:24 pm

Just tried with the Diamond Stealth64 764 BIOS, after fixing a minor bug in the SDAC RAMDAC emulation (mode 0xD 32bpp was not implemented), I got it to display 800x600x32bpp but it the DOS Prompt hang is still there.
Battler
Posts: 793
Joined: Sun 06 Jul, 2014 7:05 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby Battler » Tue 21 Mar, 2017 10:48 pm

Just tried with the Phoenix S3 Trio32, and the same bug occurs.

Remember also that the bug does not always occur so the inability to reproduce with the STG PowerGraph 64 BIOS might have been a matter of luck.
Battler
Posts: 793
Joined: Sun 06 Jul, 2014 7:05 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby Battler » Thu 23 Mar, 2017 4:49 pm

I enabled all logging on the S3 code to see what might be causing this hang, to no avail. All I see is the Windows driver talking to the BIOS, the BIOS attempting to change mode, and then nothing after, as if somehow the guest OS's code execution gets stuck. It's probably waiting for something on an I/O port, but I have no idea which.
Battler
Posts: 793
Joined: Sun 06 Jul, 2014 7:05 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby Battler » Fri 24 Mar, 2017 1:11 am

OK, I've done more search on this bug, and I have noticed the following:
1. It only seems to happen if a DOS application will run at startup, otherwise it seems to work fine;
2. It does not happen if I force the emulated card to be VLB rather than PCI (I had to do that since I can not get this specific hard disk image to boot on any of the emulated 486 machines for some reason).

At this point I suspect it has something to do with the PCI registers.
SA1988
Posts: 204
Joined: Wed 30 Apr, 2014 9:38 am

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby SA1988 » Tue 02 May, 2017 6:55 pm

Still happening, ffs. And yes, this is definitely a bug, since it doesn't happen in VPC2007 or on DOSBox and they ought to emulate it normally (this is on s3mm.drv, not s3_2.drv or s3.drv).
Battler
Posts: 793
Joined: Sun 06 Jul, 2014 7:05 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby Battler » Tue 02 May, 2017 7:26 pm

I confirm that it doesn't happen on Virtual PC 2007 even if you replace its video BIOS with the same S3 Trio64 BIOS we're using with PCem. SA1988 and I have been trying to fix it, and it appears to have to do with a part of the blitter that DOSBox (and Virtual PC 2007) implements differently from PCem.
SA1988
Posts: 204
Joined: Wed 30 Apr, 2014 9:38 am

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby SA1988 » Wed 03 May, 2017 7:12 pm

Just tested with DOSBox-x, also happens there, with the built-in s3mm.drv as well as the ID (CRTC 0x30) set to 0xe1.
SarahWalker
Site Admin
Posts: 1326
Joined: Thu 24 Apr, 2014 4:18 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby SarahWalker » Sat 06 May, 2017 10:15 am

Think I have this working now - it looks to be a combination of buggy driver that works by accident, and mapping behaviour that isn't currently implemented in PCem. I want to confirm this on a real Trio64 though, as if I'm correct this isn't be the most stable driver in the world. So I won't commit this until the board I've just ordered arrives in the post.
waltje
Posts: 12
Joined: Wed 15 Mar, 2017 10:17 pm
Location: Fort Wayne, IN
Contact:

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby waltje » Sat 06 May, 2017 10:42 pm

Got a patch for it? It's annoying ...
SarahWalker
Site Admin
Posts: 1326
Joined: Thu 24 Apr, 2014 4:18 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby SarahWalker » Sun 07 May, 2017 7:30 am

See attached...
Attachments
trio64.patch
(4.63 KiB) Downloaded 39 times
Battler
Posts: 793
Joined: Sun 06 Jul, 2014 7:05 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby Battler » Mon 22 May, 2017 10:04 am

Based on my tests, the SVGA return changes of 0xFF to 0x00 are not needed, I have tested with them back at 0xFF, but the rest of the patch still applied, and the bug is still gone.
SarahWalker
Site Admin
Posts: 1326
Joined: Thu 24 Apr, 2014 4:18 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby SarahWalker » Mon 22 May, 2017 5:03 pm

My Trio64 turned up in the post today, so hopefully I should actually be able to test all of this at the weekend.
SarahWalker
Site Admin
Posts: 1326
Joined: Thu 24 Apr, 2014 4:18 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby SarahWalker » Sun 22 Oct, 2017 11:49 am

Finally got around to doing some testing with the Trio64, revs 903 and 904 are the results. This fixes _most_ of the cases of this hang. There are still one or two cases where this can happen - eg 800x600x16 with 1MB VRAM - but most are okay now.
ecksemmess
Posts: 122
Joined: Wed 18 Mar, 2015 5:27 am

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby ecksemmess » Mon 23 Oct, 2017 8:58 am

Thanks Sarah, great to finally have this sorted!
SarahWalker
Site Admin
Posts: 1326
Joined: Thu 24 Apr, 2014 4:18 pm

Re: [Bug] DOS Prompt on Windows 95 OSR 2 and S3 Trio64...

Postby SarahWalker » Fri 27 Oct, 2017 9:16 pm

And this is now _properly_ fixed in rev 908. I'm annoyed I didn't spot what the Trio64 drivers were doing earlier, but it's working now.

Return to “Development”

Who is online

Users browsing this forum: terub56 and 1 guest