Rocksolid Light

Welcome to RetroBBS

mail  files  register  newsreader  groups  login

Message-ID:  

If Bill Gates is the Devil then Linus Torvalds must be the Messiah. -- Unknown source


devel / comp.os.os2.programmer.misc / another VIO attempt

SubjectAuthor
* another VIO attemptPaul Edwards
`* Re: another VIO attemptxhajt03
 `* Re: another VIO attemptPaul Edwards
  +* Re: another VIO attemptxhajt03
  |`* Re: another VIO attemptPaul Edwards
  | +* Re: another VIO attemptxhajt03
  | |`- Re: another VIO attemptDave Yeo
  | `* Re: another VIO attemptPaul Edwards
  |  `- Re: another VIO attemptPaul Edwards
  `* Re: another VIO attemptDave Yeo
   `* Re: another VIO attemptPaul Edwards
    `* Re: another VIO attemptDave Yeo
     `* Re: another VIO attemptPaul Edwards
      `* Re: another VIO attemptDave Yeo
       `- Re: another VIO attemptPaul Edwards

1
another VIO attempt

<uqk6ia$35m65$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=42&group=comp.os.os2.programmer.misc#42

  copy link   Newsgroups: comp.os.os2.programmer.misc
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: mutazilah@gmail.com (Paul Edwards)
Newsgroups: comp.os.os2.programmer.misc
Subject: another VIO attempt
Date: Thu, 15 Feb 2024 13:13:43 +0800
Organization: A noiseless patient Spider
Lines: 22
Message-ID: <uqk6ia$35m65$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Thu, 15 Feb 2024 05:13:46 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="72a1f3f0f8d76e7abf7981b6152d5087";
logging-data="3332293"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/0v79vHu7aw9M44IbOGg7/GEmzAtaA5Gs="
User-Agent: Mozilla/5.0 (OS/2; Warp 4.5; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:VISaSP5VEuSzC2fePSmR76XqRFo=
X-Mozilla-News-Host: news://news.eternal-september.org:119
 by: Paul Edwards - Thu, 15 Feb 2024 05:13 UTC

I made another attempt to get PDPCLIB to work
under VIO instead of requiring fullscreen.

This guy had the exact same problem in 1996:

https://groups.google.com/g/comp.os.os2.programmer.misc/c/59LqqodyzMo/m/eidgva-x0d8J

but no-one seems to have answered him (or else
the replies weren't archived).

Anyway, during one of my experiments I managed
to crash ArcaOS 5.0.8:

https://mantis.arcanoae.com/view.php?id=3604

I have attempted to create a logical keyboard,
but that isn't working under VIO (error 22
about PM), and in fullscreen it crashes ArcaOS
so I have paused before I try anything else.

BFN. Paul.

Re: another VIO attempt

<d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=43&group=comp.os.os2.programmer.misc#43

  copy link   Newsgroups: comp.os.os2.programmer.misc
X-Forwarded-Encrypted: i=1; AJvYcCXOCNLKsRaQM0xTlQ6aOyPFVlNsGRCNH5ahhQki1E8RD/kFwhtzkgS+vXgLpLKyJdyxnyko0Gv605O+EKFKkZdecldoOrr8aV7tlcqVpmr+8K8EX9qG12zXzkkoo+g=
X-Received: by 2002:a05:6214:301d:b0:68c:8fd4:11d0 with SMTP id ke29-20020a056214301d00b0068c8fd411d0mr133627qvb.10.1707999370045;
Thu, 15 Feb 2024 04:16:10 -0800 (PST)
X-Forwarded-Encrypted: i=1; AJvYcCUvgeOO3PwtzQoutrkMofOyP9K37sebBaQAXivQpLMpiMmLyj6REbqMa20U+y8m/+9Ky+ILpA9xeC5DHJcHrT+iSHs3UjU3w6pZw5/K57jFPOyvb0CZdVHi7IR/3Uo=
X-Received: by 2002:a05:6830:2685:b0:6e4:2faf:30b8 with SMTP id
l5-20020a056830268500b006e42faf30b8mr17686otu.1.1707999369774; Thu, 15 Feb
2024 04:16:09 -0800 (PST)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!border-2.nntp.ord.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.os.os2.programmer.misc
Date: Thu, 15 Feb 2024 04:16:09 -0800 (PST)
In-Reply-To: <uqk6ia$35m65$1@dont-email.me>
Injection-Info: google-groups.googlegroups.com; posting-host=147.161.254.174; posting-account=M0HM6QoAAADN6I0fdAn6f6_AFrdXmFjO
NNTP-Posting-Host: 147.161.254.174
References: <uqk6ia$35m65$1@dont-email.me>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
Subject: Re: another VIO attempt
From: xhajt03@gmail.com (xhajt03)
Injection-Date: Thu, 15 Feb 2024 12:16:10 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 35
 by: xhajt03 - Thu, 15 Feb 2024 12:16 UTC

On February 15, 2024 at 06:13:48 +0100 user Paul Edwards wrote:
> I made another attempt to get PDPCLIB to work
> under VIO instead of requiring fullscreen.
>
> This guy had the exact same problem in 1996:
>
> https://groups.google.com/g/comp.os.os2.programmer.misc/c/59LqqodyzMo/m/eidgva-x0d8J
>
> but no-one seems to have answered him (or else
> the replies weren't archived).
>
> Anyway, during one of my experiments I managed
> to crash ArcaOS 5.0.8:
>
> https://mantis.arcanoae.com/view.php?id=3604
>
> I have attempted to create a logical keyboard,
> but that isn't working under VIO (error 22
> about PM), and in fullscreen it crashes ArcaOS
> so I have paused before I try anything else.

While your persistance is admirable, I still miss the point why you decided using the more low-level access via the device driver rather than using the regularly supported means for accessing the keyboard inteded for VIO applications. Function KbdPeek, KbdCharIn and KbdGetStatus as provided in KbdCalls.dll provide (after proper initialization, setting the keyboard focus, etc.) full support for reading the keys and modifiers (i.e. shift, etc.) without any echo. Yes, you cannot treat the keyboard as a file in that case (i..e. you cannot use DosRead for retrieving the keys, etc.), but that is comparable to BIOS functions needed under plain DOS. And, obviously, the KbdCalls functions work both in full-screen and in VIO windows (except for minor documented exceptions which shouldn't be necessary for your purposes as far as I understand them).

Tomas

Re: another VIO attempt

<uql3ho$3arit$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=44&group=comp.os.os2.programmer.misc#44

  copy link   Newsgroups: comp.os.os2.programmer.misc
Path: i2pn2.org!i2pn.org!news.furie.org.uk!usenet.goja.nl.eu.org!3.eu.feeder.erje.net!feeder.erje.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: mutazilah@gmail.com (Paul Edwards)
Newsgroups: comp.os.os2.programmer.misc
Subject: Re: another VIO attempt
Date: Thu, 15 Feb 2024 21:28:21 +0800
Organization: A noiseless patient Spider
Lines: 68
Message-ID: <uql3ho$3arit$1@dont-email.me>
References: <uqk6ia$35m65$1@dont-email.me>
<d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Thu, 15 Feb 2024 13:28:24 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="72a1f3f0f8d76e7abf7981b6152d5087";
logging-data="3501661"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/T0rxDQUxV/rDsaEBJbv/Ge6h5hET+7U8="
User-Agent: Mozilla/5.0 (OS/2; Warp 4.5; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:uvQjfZeP1QVJhNburgTiP6xzBto=
In-Reply-To: <d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
 by: Paul Edwards - Thu, 15 Feb 2024 13:28 UTC

On 15/02/24 20:16, xhajt03 wrote:
> On February 15, 2024 at 06:13:48 +0100 user Paul Edwards wrote:

>> I have attempted to create a logical keyboard,
>> but that isn't working under VIO (error 22
>> about PM), and in fullscreen it crashes ArcaOS
>> so I have paused before I try anything else.
>
> While your persistance is admirable, I still miss

BTW, you wrote one very long line in this newsgroup
post instead of splitting it up. I have to manually
split it up instead.

> the point why you decided using the more low-level
> access via the device driver rather than using the
> regularly supported means for accessing the keyboard
> inteded for VIO applications. Function KbdPeek,
> KbdCharIn and KbdGetStatus as provided in KbdCalls.dll
> provide (after proper initialization, setting the
> keyboard focus, etc.) full support for reading the
> keys and modifiers (i.e. shift, etc.) without any echo.

I want to have a pure 32-bit executable.

> Yes, you cannot treat the keyboard as a file in that
> case (i.e. you cannot use DosRead for retrieving the
> keys, etc.), but that is comparable to BIOS functions
> needed under plain DOS.

You don't need to use the BIOS functions in plain DOS
to do the above.

So in that sense - yes, it is directly comparable.

My C library - PDPCLIB - doesn't use any BIOS calls,
and it is able to run micro-emacs etc.

> And, obviously, the KbdCalls functions work both in
> full-screen and in VIO windows (except for minor
> documented exceptions which shouldn't be necessary
> for your purposes as far as I understand them).

And I believe IBM intended that the 32-bit functions
they provided would be sufficient to do the job
instead. And it just didn't happen much for other
reasons.

And note that the functions they provided *do* do
the job in 32-bit. It's only when the program
terminates that I find I have an issue.

So they come very very close to working.

BTW, I'm not familiar with privilege levels in OS/2,
but I haven't done anything to attempt to get into
any sort of privileged mode.

It could be that the accessing of KBD$ is throwing
me into a privileged state regardless.

But maybe the 16-bit Kbd* functions do that too.

Maybe there's no security in OS/2 - I've never
asked the question.

BFN. Paul.

Re: another VIO attempt

<0f00a22e-65eb-4587-a626-be2f62f1b1a7n@googlegroups.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=45&group=comp.os.os2.programmer.misc#45

  copy link   Newsgroups: comp.os.os2.programmer.misc
X-Forwarded-Encrypted: i=1; AJvYcCVziZrJuup10Gzm7KVBd3UsAG1A+aonNBiXBuaLu/hZZOH/UCv0GnxRjyIe/NEa65cMSx6y95kiL2Qrk5yrB41l7EGlZ6wGJ9b5vZjHihHiMSHQonwDNnzDaibrC/kj/Q==
X-Received: by 2002:a05:6214:27e2:b0:68e:fadb:b18c with SMTP id jt2-20020a05621427e200b0068efadbb18cmr117963qvb.11.1708008439245;
Thu, 15 Feb 2024 06:47:19 -0800 (PST)
X-Forwarded-Encrypted: i=1; AJvYcCV7exoArb4c2pvvI9zKIQd5w7wQ9ZaGIiRkhumJnndQOTT0Z0MBhaZHLP4UIn2nIuw7a0SYAOCLKxinxTDFjr2dyLTg5Bb0inhnVra3NMwzycX8HAi5f1qzHMYcE4E=
X-Received: by 2002:a05:6830:4409:b0:6e4:323c:129 with SMTP id
q9-20020a056830440900b006e4323c0129mr1679otv.6.1708008438975; Thu, 15 Feb
2024 06:47:18 -0800 (PST)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.os.os2.programmer.misc
Date: Thu, 15 Feb 2024 06:47:18 -0800 (PST)
In-Reply-To: <uql3ho$3arit$1@dont-email.me>
Injection-Info: google-groups.googlegroups.com; posting-host=147.161.254.174; posting-account=M0HM6QoAAADN6I0fdAn6f6_AFrdXmFjO
NNTP-Posting-Host: 147.161.254.174
References: <uqk6ia$35m65$1@dont-email.me> <d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
<uql3ho$3arit$1@dont-email.me>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <0f00a22e-65eb-4587-a626-be2f62f1b1a7n@googlegroups.com>
Subject: Re: another VIO attempt
From: xhajt03@gmail.com (xhajt03)
Injection-Date: Thu, 15 Feb 2024 14:47:19 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 5056
 by: xhajt03 - Thu, 15 Feb 2024 14:47 UTC

On February 15, 2024 at 14:28:26 +0100 Paul Edwards wrote:

.
.
> BTW, you wrote one very long line in this newsgroup
> post instead of splitting it up. I have to manually
> split it up instead.

Well, sorry. I'm responding to these Usenet messages via Google Groups (which will stop working in one week from now :-( ). I don't have any Usenet client installed.

.
.
> I want to have a pure 32-bit executable.

I see. You can have that if you use a 3rd party DLL providing the translation from/to the 16-bit calls, but you'd probably need to distribute those with your application(s). There are multiple options for such a DLL, one of them being emxwrap.dll (part of the EMX runtime, already available on many OS/2 installations), but there are others (see e.g. https://hobbes.nmsu.edu/?detail=%2Fpub%2Fos2%2Fdev%2Ftools%2Ftoolkits%2FUniConAPI_1-0-3.zip).

> > Yes, you cannot treat the keyboard as a file in that
> > case (i.e. you cannot use DosRead for retrieving the
> > keys, etc.), but that is comparable to BIOS functions
> > needed under plain DOS.
> You don't need to use the BIOS functions in plain DOS
> to do the above.

Well, yes, you can access the modifiers by accessing the low part of the memory (modified by BIOS) there. ;-)

.
.
> > And, obviously, the KbdCalls functions work both in
> > full-screen and in VIO windows (except for minor
> > documented exceptions which shouldn't be necessary
> > for your purposes as far as I understand them).
> And I believe IBM intended that the 32-bit functions
> they provided would be sufficient to do the job
> instead. And it just didn't happen much for other
> reasons.

Not really, because they clearly documented a different solution (in particular using KbdCalls) as intended for scenarios described by you. Also, the fact that the (beta) PowerPC version of OS/2 included a 32-bit version of KbdCalls kind of suggests that they didn't consider other solutions as directly replacing this DLL. Not that it matters much nowadays. ;-)

> And note that the functions they provided *do* do
> the job in 32-bit. It's only when the program
> terminates that I find I have an issue.
>
> So they come very very close to working.

OK. Even if you get it fully working, it doesn't mean that it's the most efficient solution.

> BTW, I'm not familiar with privilege levels in OS/2,
> but I haven't done anything to attempt to get into
> any sort of privileged mode.

Accessing the 16-bit calls requires the specific binary (e.g. a DLL) to be marked for privilege level 2 (IOPL), but you don't need to bother with that when using a translation library like one of those mentioned above (and it doesn't mean much for you otherwise except for a necessity to have the right flag in the respective executable header).

> It could be that the accessing of KBD$ is throwing
> me into a privileged state regardless.

The device driver works at a higher privilege level, but the code accessing the logical device (e.g. KBD$) doesn't.

> But maybe the 16-bit Kbd* functions do that too.

See above.

> Maybe there's no security in OS/2 - I've never
> asked the question.

If you refer to privilege levels specifically, these are for sure enforced in OS/2. Talking about OS/2 security in other contexts would go beyond the scope of this thread considerably.

Tomas

Re: another VIO attempt

<uqlaa8$3c2rd$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=46&group=comp.os.os2.programmer.misc#46

  copy link   Newsgroups: comp.os.os2.programmer.misc
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: mutazilah@gmail.com (Paul Edwards)
Newsgroups: comp.os.os2.programmer.misc
Subject: Re: another VIO attempt
Date: Thu, 15 Feb 2024 23:23:50 +0800
Organization: A noiseless patient Spider
Lines: 144
Message-ID: <uqlaa8$3c2rd$1@dont-email.me>
References: <uqk6ia$35m65$1@dont-email.me>
<d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
<uql3ho$3arit$1@dont-email.me>
<0f00a22e-65eb-4587-a626-be2f62f1b1a7n@googlegroups.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Thu, 15 Feb 2024 15:23:52 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="72a1f3f0f8d76e7abf7981b6152d5087";
logging-data="3541869"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19rVxO0UH5kjYE8Bu5ujfXfZXW2AgJfTTE="
User-Agent: Mozilla/5.0 (OS/2; Warp 4.5; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:WYm+DZ1Vpa/K8YKXpHU/TGPfSmw=
In-Reply-To: <0f00a22e-65eb-4587-a626-be2f62f1b1a7n@googlegroups.com>
 by: Paul Edwards - Thu, 15 Feb 2024 15:23 UTC

On 15/02/24 22:47, xhajt03 wrote:
> On February 15, 2024 at 14:28:26 +0100 Paul Edwards wrote:

>> BTW, you wrote one very long line in this newsgroup
>> post instead of splitting it up. I have to manually
>> split it up instead.
>
> Well, sorry. I'm responding to these Usenet messages
> via Google Groups (which will stop working in one
> week from now :-( ).

I used to use that too. Just hit enter after a while.

> I don't have any Usenet client installed.

Don't you use ArcaOS? It comes with Thunderbird.

You can get a free account here:

https://www.eternal-september.org/

>> I want to have a pure 32-bit executable.
>
> I see. You can have that if you use a 3rd party DLL
> providing the translation from/to the 16-bit calls,
> but you'd probably need to distribute those with
> your application(s).

And I don't want to do that either.

Or if I was to do that, the 3rd party DLL would
be called PDPCRT.DLL and it would be comprised
of pure 32-bit pure public domain code from
PDPCLIB. I already produce my own msvcrt.dll too,
but it's normally not used.

>>> Yes, you cannot treat the keyboard as a file in that
>>> case (i.e. you cannot use DosRead for retrieving the
>>> keys, etc.), but that is comparable to BIOS functions
>>> needed under plain DOS.

>> You don't need to use the BIOS functions in plain DOS
>> to do the above.
>
> Well, yes, you can access the modifiers by accessing
> the low part of the memory (modified by BIOS) there. ;-)

No. You don't need to do that either. You can
follow pure MSDOS rules and do INT 21H calls
(ioctl and read).

> Not really, because they clearly documented a
> different solution (in particular using KbdCalls)
> as intended for scenarios described by you.

Well they did that for OS/2 1.x, and so at that
point there was a 16-bit solution, and of course
it was documented.

For 32-bit they apparently updated what they
thought was enough and then stopped. And it
may well be enough. Or they came very very
close, anyway.

> Also, the fact that the (beta) PowerPC version
> of OS/2 included a 32-bit version of KbdCalls
> kind of suggests that they didn't consider other
> solutions as directly replacing this DLL.

Well, they would have needed to do that for the
other documented solution to work.

They're not going to force everyone to migrate
to the alternate solution immediately.

And maybe not force it ever. Maybe in time they
would have updated the 16-bit x86 versions to
32-bit. But it was not a priority at all because
by then they were more interested in graphics.

>> So they come very very close to working.
>
> OK. Even if you get it fully working, it doesn't
> mean that it's the most efficient solution.

I'm not after the most efficient solution, nor
the solution (graphics) that will attract the
most customers.

I'm after a technically pure 32-bit application.

And I may produce my own version of OS/2 2.0
(similar to PDOS/386 being a mini Win32 clone).

I'm actually planning on converting PDOS/86 to
be a mini OS/2 1.x clone and abandoning MSDOS.

Or I may do the opposite of win32os2 - and run
OS/2 2.0 programs under Win32. Certain OS/2
programs. Ones that are dependent on pdpcrt.dll.
Although that last one would still work if it
was implemented using the 16-bit calls internally.

>> BTW, I'm not familiar with privilege levels in OS/2,
>> but I haven't done anything to attempt to get into
>> any sort of privileged mode.
>
> Accessing the 16-bit calls requires the specific
> binary (e.g. a DLL) to be marked for privilege
> level 2 (IOPL), but you don't need to bother with
> that when using a translation library like one
> of those mentioned above (and it doesn't mean much
> for you otherwise except for a necessity to have
> the right flag in the respective executable header).

One of my experiments involved calling the Kbd calls.
I was using the Watcom compiler and libraries for
that, and it produced a standalone executable. Would
that executable have been marked as level 2?

And when I switched to pure dos calls, would the
executable have not had that marker?

>> It could be that the accessing of KBD$ is throwing
>> me into a privileged state regardless.
>
> The device driver works at a higher privilege level,
> but the code accessing the logical device (e.g. KBD$) doesn't.

Ok, cool. I didn't want to have privileged code.

> If you refer to privilege levels specifically,
> these are for sure enforced in OS/2.

Ok, thanks for the info.

> Talking about OS/2 security in other contexts
> would go beyond the scope of this thread considerably.

Yeah, I'm not interested in security - just wanted
to make sure I was unprivileged.

BFN. Paul.

Re: another VIO attempt

<00f3a007-8f4e-444b-94ce-2a094ab7798dn@googlegroups.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=47&group=comp.os.os2.programmer.misc#47

  copy link   Newsgroups: comp.os.os2.programmer.misc
X-Forwarded-Encrypted: i=1; AJvYcCVBJzy5BTejrK/DG04SINh/kvCY0f4cY6nWww7mfCPxl6Lh7JNarY+78eMHpIyYwaQ0cTwPYkjdW3JIQ3GMc/dVtz5/zmx5iDfVdgPCNEGBUjLb8pdvZFRai4FF45FOsOM=
X-Received: by 2002:ad4:5f0d:0:b0:68e:e633:cdb9 with SMTP id fo13-20020ad45f0d000000b0068ee633cdb9mr179681qvb.12.1708016869889;
Thu, 15 Feb 2024 09:07:49 -0800 (PST)
X-Forwarded-Encrypted: i=1; AJvYcCWpBoPolazlJ9pWleol07oTeXqJItK2VGzC3pnbuHxMMc0L8DGdk+7xHCh20Mh+CXDFLCKqK1cZlavn4M5GJUtdtHFyjJ0LiMXR3UzDM7hquYz5e2QF7L58d1gaXnA=
X-Received: by 2002:a05:6808:2095:b0:3c0:45ef:710d with SMTP id
s21-20020a056808209500b003c045ef710dmr11455oiw.11.1708016869514; Thu, 15 Feb
2024 09:07:49 -0800 (PST)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.os.os2.programmer.misc
Date: Thu, 15 Feb 2024 09:07:49 -0800 (PST)
In-Reply-To: <uqlaa8$3c2rd$1@dont-email.me>
Injection-Info: google-groups.googlegroups.com; posting-host=147.161.254.174; posting-account=M0HM6QoAAADN6I0fdAn6f6_AFrdXmFjO
NNTP-Posting-Host: 147.161.254.174
References: <uqk6ia$35m65$1@dont-email.me> <d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
<uql3ho$3arit$1@dont-email.me> <0f00a22e-65eb-4587-a626-be2f62f1b1a7n@googlegroups.com>
<uqlaa8$3c2rd$1@dont-email.me>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <00f3a007-8f4e-444b-94ce-2a094ab7798dn@googlegroups.com>
Subject: Re: another VIO attempt
From: xhajt03@gmail.com (xhajt03)
Injection-Date: Thu, 15 Feb 2024 17:07:49 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
 by: xhajt03 - Thu, 15 Feb 2024 17:07 UTC

On February 15, 2024 at 16:23:54 +0100 Paul Edwards wrote:
.
.
> Don't you use ArcaOS? It comes with Thunderbird.

No, I use eCS (among others). I know I could install TB (on all my machines.... :/ ).

> You can get a free account here:
>
> https://www.eternal-september.org/

Thanks for the link.

.
.
> One of my experiments involved calling the Kbd calls.
> I was using the Watcom compiler and libraries for
> that, and it produced a standalone executable. Would
> that executable have been marked as level 2?

Actually, I was wrong, you don't need that for the 16-bit calls, sorry for the confusion. :-( I mixed it up with another functionality for which EMX run-time libraries might be used, in particular port access (level 2 allows that, level 3 doesn't). In other words, you can stay at level 3 all the time, regardless from being pure 32-bit code or calling 16-bit API functions via thunking.

Regards

Tomas

Re: another VIO attempt

<6FyzN.80205$SyNd.73871@fx33.iad>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=48&group=comp.os.os2.programmer.misc#48

  copy link   Newsgroups: comp.os.os2.programmer.misc
Path: i2pn2.org!i2pn.org!news.swapon.de!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!fx33.iad.POSTED!not-for-mail
Subject: Re: another VIO attempt
Newsgroups: comp.os.os2.programmer.misc
References: <uqk6ia$35m65$1@dont-email.me>
<d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
<uql3ho$3arit$1@dont-email.me>
<0f00a22e-65eb-4587-a626-be2f62f1b1a7n@googlegroups.com>
<uqlaa8$3c2rd$1@dont-email.me>
<00f3a007-8f4e-444b-94ce-2a094ab7798dn@googlegroups.com>
From: dave.r.yeo@gmail.com (Dave Yeo)
User-Agent: Mozilla/5.0 (OS/2; Warp 4.5; rv:45.0) Gecko/20100101 Firefox/45.0
SeaMonkey/2.42.9esr
MIME-Version: 1.0
In-Reply-To: <00f3a007-8f4e-444b-94ce-2a094ab7798dn@googlegroups.com>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Lines: 33
Message-ID: <6FyzN.80205$SyNd.73871@fx33.iad>
X-Complaints-To: https://www.astraweb.com/aup
NNTP-Posting-Date: Fri, 16 Feb 2024 01:13:38 UTC
Date: Thu, 15 Feb 2024 17:13:38 -0800
X-Received-Bytes: 2112
 by: Dave Yeo - Fri, 16 Feb 2024 01:13 UTC

xhajt03 wrote:
> On February 15, 2024 at 16:23:54 +0100 Paul Edwards wrote:
> .
> .
>> Don't you use ArcaOS? It comes with Thunderbird.
>
> No, I use eCS (among others). I know I could install TB (on all my machines... :/ ).

SeaMonkey works fine for news groups as well. For eCS, TB10 or TB17 or
the equivalent SM would be the simplest to install.

>
>
>> You can get a free account here:
>>
>> https://www.eternal-september.org/
>
> Thanks for the link.
>
>
> .
> .
>> One of my experiments involved calling the Kbd calls.
>> I was using the Watcom compiler and libraries for
>> that, and it produced a standalone executable. Would
>> that executable have been marked as level 2?
>
> Actually, I was wrong, you don't need that for the 16-bit calls, sorry for the confusion. :-( I mixed it up with another functionality for which EMX run-time libraries might be used, in particular port access (level 2 allows that, level 3 doesn't). In other words, you can stay at level 3 all the time, regardless from being pure 32-bit code or calling 16-bit API functions via thunking.
>

You can set PROTECTONLY=YES in config.sys to enforce level 3.
Dave

Re: another VIO attempt

<g0zzN.357630$c3Ea.117477@fx10.iad>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=49&group=comp.os.os2.programmer.misc#49

  copy link   Newsgroups: comp.os.os2.programmer.misc
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!newsfeed.hasname.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!fx10.iad.POSTED!not-for-mail
Subject: Re: another VIO attempt
Newsgroups: comp.os.os2.programmer.misc
References: <uqk6ia$35m65$1@dont-email.me>
<d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
<uql3ho$3arit$1@dont-email.me>
From: dave.r.yeo@gmail.com (Dave Yeo)
User-Agent: Mozilla/5.0 (OS/2; Warp 4.5; rv:45.0) Gecko/20100101 Firefox/45.0
SeaMonkey/2.42.9esr
MIME-Version: 1.0
In-Reply-To: <uql3ho$3arit$1@dont-email.me>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Lines: 83
Message-ID: <g0zzN.357630$c3Ea.117477@fx10.iad>
X-Complaints-To: https://www.astraweb.com/aup
NNTP-Posting-Date: Fri, 16 Feb 2024 01:38:20 UTC
Date: Thu, 15 Feb 2024 17:38:20 -0800
X-Received-Bytes: 3942
 by: Dave Yeo - Fri, 16 Feb 2024 01:38 UTC

Paul Edwards wrote:
> On 15/02/24 20:16, xhajt03 wrote:
>> On February 15, 2024 at 06:13:48 +0100 user Paul Edwards wrote:
....
>> the point why you decided using the more low-level
>> access via the device driver rather than using the
>> regularly supported means for accessing the keyboard
>> inteded for VIO applications. Function KbdPeek,
>> KbdCharIn and KbdGetStatus as provided in KbdCalls.dll
>> provide (after proper initialization, setting the
>> keyboard focus, etc.) full support for reading the
>> keys and modifiers (i.e. shift, etc.) without any echo.
>
> I want to have a pure 32-bit executable.

You can't, at least easily. Too much of the kernel(DOSCALL) and DOSCALL1
are 16 bit at their heart. This includes DosOpen() and DosOpenL() and
even DosDevIOCtl() or parts of it.
They do have 32 bit wrappers so they seem like 32 bit code but will fail
if you try to use them from high memory (above 1GB).
Search for os2safe.h for the full list of functions that need special
treatment if using high memory.
The simplest I found was KbdCharIn(), which libc wraps in a 32 bit
wrapper, likely the same as EMX. Even that spat out a scan code before
any chars IIRC.

>
>> Yes, you cannot treat the keyboard as a file in that
>> case (i.e. you cannot use DosRead for retrieving the
>> keys, etc.), but that is comparable to BIOS functions
>> needed under plain DOS.
>
> You don't need to use the BIOS functions in plain DOS
> to do the above.
>
> So in that sense - yes, it is directly comparable.
>
> My C library - PDPCLIB - doesn't use any BIOS calls,
> and it is able to run micro-emacs etc.
>
>> And, obviously, the KbdCalls functions work both in
>> full-screen and in VIO windows (except for minor
>> documented exceptions which shouldn't be necessary
>> for your purposes as far as I understand them).
>
> And I believe IBM intended that the 32-bit functions
> they provided would be sufficient to do the job
> instead. And it just didn't happen much for other
> reasons.

Unluckily they never finished porting the functions to 32 bit on X86.
There was a rumour that one of the devcon ISO's included 32 bit
versions. All I found were official wrappers to emulate the pure 32 bit
libraries when/if they got ported from the PowerPC OS/2. They never did
get ported.

>
> And note that the functions they provided *do* do
> the job in 32-bit. It's only when the program
> terminates that I find I have an issue.
>
> So they come very very close to working.

You are staying below the 1GB barrier? I think you mentioned OW1.6 which
didn't have much support for high memory IIRC.

>
> BTW, I'm not familiar with privilege levels in OS/2,
> but I haven't done anything to attempt to get into
> any sort of privileged mode.
>
> It could be that the accessing of KBD$ is throwing
> me into a privileged state regardless.
>
> But maybe the 16-bit Kbd* functions do that too.
>
> Maybe there's no security in OS/2 - I've never
> asked the question.

User programs run in Ring 3 or Ring 2 in the case of DOS. Ring 2 so most
DOS device drivers work. Drivers and Kernel often in Ring 0.
Dave

Re: another VIO attempt

<uqn5pe$3p9rk$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=50&group=comp.os.os2.programmer.misc#50

  copy link   Newsgroups: comp.os.os2.programmer.misc
Path: i2pn2.org!i2pn.org!usenet.goja.nl.eu.org!weretis.net!feeder8.news.weretis.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: mutazilah@gmail.com (Paul Edwards)
Newsgroups: comp.os.os2.programmer.misc
Subject: Re: another VIO attempt
Date: Fri, 16 Feb 2024 16:17:04 +0800
Organization: A noiseless patient Spider
Lines: 97
Message-ID: <uqn5pe$3p9rk$1@dont-email.me>
References: <uqk6ia$35m65$1@dont-email.me>
<d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
<uql3ho$3arit$1@dont-email.me> <g0zzN.357630$c3Ea.117477@fx10.iad>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Fri, 16 Feb 2024 08:18:55 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="a2f4b79c324191bbf5229a0e323da34d";
logging-data="3975028"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+KfONz8g6cpxLxYWBsYAFxfN7H202zfT0="
User-Agent: Mozilla/5.0 (OS/2; Warp 4.5; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:ORmuexH5jtbwrCxqB/XI1U9pklw=
In-Reply-To: <g0zzN.357630$c3Ea.117477@fx10.iad>
 by: Paul Edwards - Fri, 16 Feb 2024 08:17 UTC

On 16/02/24 09:38, Dave Yeo wrote:
> Paul Edwards wrote:

>>> the point why you decided using the more low-level
>>> access via the device driver rather than using the
>>> regularly supported means for accessing the keyboard
>>> inteded for VIO applications. Function KbdPeek,
>>> KbdCharIn and KbdGetStatus as provided in KbdCalls.dll
>>> provide (after proper initialization, setting the
>>> keyboard focus, etc.) full support for reading the
>>> keys and modifiers (i.e. shift, etc.) without any echo.
>>
>> I want to have a pure 32-bit executable.
>
> You can't, at least easily. Too much of the kernel(DOSCALL) and DOSCALL1
> are 16 bit at their heart. This includes DosOpen() and DosOpenL() and
> even DosDevIOCtl() or parts of it.

That is external to my executable. My executable
itself is 32-bit. I don't really care what OS/2
itself does internally. Note that PDOS/386 itself
transitions to RM16 in order to do I/O so that I
don't need to deal with drivers. That's fine too.
It's completely transparent to the applications.
The applications themselves are pure 32-bit. And
at any time PDOS/386 can be updated to use drivers
so that the 16-bit stuff is eliminated. That would
be transparent to the application.

> They do have 32 bit wrappers so they seem like 32 bit code

That's all I'm after. With the vendor providing
that, not a 3rd party.

> but will fail
> if you try to use them from high memory (above 1GB).
> Search for os2safe.h for the full list of functions that need special
> treatment if using high memory.

This is a deficiency in OS/2 itself that could
be corrected overnight by Arca. I will patiently
wait for Arca, or else replace ArcaOS with an
updated PDOS/386 that handles OS/2 2.0 calls.

>>> And, obviously, the KbdCalls functions work both in
>>> full-screen and in VIO windows (except for minor
>>> documented exceptions which shouldn't be necessary
>>> for your purposes as far as I understand them).
>>
>> And I believe IBM intended that the 32-bit functions
>> they provided would be sufficient to do the job
>> instead. And it just didn't happen much for other
>> reasons.
>
> Unluckily they never finished porting the functions to 32 bit on X86.
> There was a rumour that one of the devcon ISO's included 32 bit
> versions. All I found were official wrappers to emulate the pure 32 bit
> libraries when/if they got ported from the PowerPC OS/2. They never did
> get ported.

Yeah, that's fine. That's an internal thing that
can happen at any time (even if it never happens
at all).

It doesn't detract from the technical purity that
I am after.

>> And note that the functions they provided *do* do
>> the job in 32-bit. It's only when the program
>> terminates that I find I have an issue.
>>
>> So they come very very close to working.
>
> You are staying below the 1GB barrier? I think you mentioned OW1.6 which
> didn't have much support for high memory IIRC.

I am not familiar with any of that. I wasn't aware
of a barrier. But such a barrier can be lifted by
the OS/2 vendor whenever they have bandwidth.

My executable is "4 GiB-ready" (similar to 4k-ready
for sector sizes).

> User programs run in Ring 3 or Ring 2 in the case of DOS. Ring 2 so most
> DOS device drivers work. Drivers and Kernel often in Ring 0.

Ok, and that protectonly in config.sys would force
apps to be in the lowest ring 3?

But my 32-bit OS/2 executable would be ring 3 by
default and stay there unless I go to some effort
to elevate it, right?

That's all I'm after.

Thanks. Paul.

Re: another VIO attempt

<RSRzN.332642$Wp_8.301346@fx17.iad>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=53&group=comp.os.os2.programmer.misc#53

  copy link   Newsgroups: comp.os.os2.programmer.misc
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!fx17.iad.POSTED!not-for-mail
Subject: Re: another VIO attempt
Newsgroups: comp.os.os2.programmer.misc
References: <uqk6ia$35m65$1@dont-email.me>
<d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
<uql3ho$3arit$1@dont-email.me> <g0zzN.357630$c3Ea.117477@fx10.iad>
<uqn5pe$3p9rk$1@dont-email.me>
From: dave.r.yeo@gmail.com (Dave Yeo)
User-Agent: Mozilla/5.0 (OS/2; Warp 4.5; rv:45.0) Gecko/20100101 Firefox/45.0
SeaMonkey/2.42.9esr
MIME-Version: 1.0
In-Reply-To: <uqn5pe$3p9rk$1@dont-email.me>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Lines: 45
Message-ID: <RSRzN.332642$Wp_8.301346@fx17.iad>
X-Complaints-To: https://www.astraweb.com/aup
NNTP-Posting-Date: Fri, 16 Feb 2024 23:05:21 UTC
Date: Fri, 16 Feb 2024 15:05:20 -0800
X-Received-Bytes: 2358
 by: Dave Yeo - Fri, 16 Feb 2024 23:05 UTC

Paul Edwards wrote:

....
>> You are staying below the 1GB barrier? I think you mentioned OW1.6 which
>> didn't have much support for high memory IIRC.
>
> I am not familiar with any of that. I wasn't aware
> of a barrier. But such a barrier can be lifted by
> the OS/2 vendor whenever they have bandwidth.

The problem is 16 bit code is limited to addressing the lower 1GB of
address space. Before Warp 4.5 (V4+fp13), the client was limited to 512
MB's of address space, minus whatever DLL's were loaded, with the other
512MB's kernel space.
Now, by adding objany to DosAllocMem, can access most of the full 32 bit
address space, minus PCI space. VIRTUALADDRESSLIMIT in config.sys
actually controls address space, with 3072 as high as it will go. Often
need a lower setting to avoid PCI address space, things like video memory.
The fix would be redoing doscall1.dll.

>
> My executable is "4 GiB-ready" (similar to 4k-ready
> for sector sizes).
>
>> User programs run in Ring 3 or Ring 2 in the case of DOS. Ring 2 so most
>> DOS device drivers work. Drivers and Kernel often in Ring 0.
>
> Ok, and that protectonly in config.sys would force
> apps to be in the lowest ring 3?

Yes, no DOS support. Not sure about OS/2 1.x programs and whether any
would be affected.

>
> But my 32-bit OS/2 executable would be ring 3 by
> default and stay there unless I go to some effort
> to elevate it, right?

I don't think you can elevate it even if you try.

>
> That's all I'm after.

Dave

Re: another VIO attempt

<uqp327$3psl$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=56&group=comp.os.os2.programmer.misc#56

  copy link   Newsgroups: comp.os.os2.programmer.misc
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: mutazilah@gmail.com (Paul Edwards)
Newsgroups: comp.os.os2.programmer.misc
Subject: Re: another VIO attempt
Date: Sat, 17 Feb 2024 09:44:37 +0800
Organization: A noiseless patient Spider
Lines: 51
Message-ID: <uqp327$3psl$1@dont-email.me>
References: <uqk6ia$35m65$1@dont-email.me>
<d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
<uql3ho$3arit$1@dont-email.me> <g0zzN.357630$c3Ea.117477@fx10.iad>
<uqn5pe$3p9rk$1@dont-email.me> <RSRzN.332642$Wp_8.301346@fx17.iad>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sat, 17 Feb 2024 01:44:39 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="8f99487476e839855ee5a7cc038419c2";
logging-data="124821"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX190oEu8KZ9z7w96/34Q/Lk6eOmJs86K7eA="
User-Agent: Mozilla/5.0 (OS/2; Warp 4.5; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:RYPuOppJOqU6qpVEDX1by2/gtgk=
In-Reply-To: <RSRzN.332642$Wp_8.301346@fx17.iad>
 by: Paul Edwards - Sat, 17 Feb 2024 01:44 UTC

On 17/02/24 07:05, Dave Yeo wrote:

>>> You are staying below the 1GB barrier? I think you mentioned OW1.6 which
>>> didn't have much support for high memory IIRC.
>>
>> I am not familiar with any of that. I wasn't aware
>> of a barrier. But such a barrier can be lifted by
>> the OS/2 vendor whenever they have bandwidth.
>
> The problem is 16 bit code is limited to addressing the lower 1GB of
> address space. Before Warp 4.5 (V4+fp13), the client was limited to 512
> MB's of address space, minus whatever DLL's were loaded, with the other
> 512MB's kernel space.
> Now, by adding objany to DosAllocMem, can access most of the full 32 bit

Ok, so let's say I add something here:

D:\devel\pdos\pdpclib>grep DosAllocMem stdlib.c
stdlib.c: rc = DosAllocMem(&BaseAddress, ulObjectSize,
ulAllocationFlags);

D:\devel\pdos\pdpclib>grep ulAllocationFlags stdlib.c
stdlib.c: ULONG ulAllocationFlags;
stdlib.c: ulAllocationFlags = PAG_COMMIT | PAG_WRITE | PAG_READ;
stdlib.c: rc = DosAllocMem(&BaseAddress, ulObjectSize,
ulAllocationFlags);

D:\devel\pdos\pdpclib>

so that I start getting high memory, e.g. I might get
an address at the 2 GiB mark.

And then let's say I put in a filename at that address.

And then I give that filename as a parameter to DosOpen.

You mentioned that DosOpen had 16-bit stuff at its heart.

Does that mean DosOpen won't be able to cope with me
giving it that high address and crash?

> address space, minus PCI space. VIRTUALADDRESSLIMIT in config.sys
> actually controls address space, with 3072 as high as it will go. Often
> need a lower setting to avoid PCI address space, things like video memory.
> The fix would be redoing doscall1.dll.

Sure. I'm exactly preparing for the vendor to fix all that.

BFN. Paul.

Re: another VIO attempt

<uqpsf2$b74p$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=58&group=comp.os.os2.programmer.misc#58

  copy link   Newsgroups: comp.os.os2.programmer.misc
Path: i2pn2.org!rocksolid2!news.neodome.net!news.mixmin.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: mutazilah@gmail.com (Paul Edwards)
Newsgroups: comp.os.os2.programmer.misc
Subject: Re: another VIO attempt
Date: Sat, 17 Feb 2024 16:58:07 +0800
Organization: A noiseless patient Spider
Lines: 57
Message-ID: <uqpsf2$b74p$1@dont-email.me>
References: <uqk6ia$35m65$1@dont-email.me>
<d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
<uql3ho$3arit$1@dont-email.me>
<0f00a22e-65eb-4587-a626-be2f62f1b1a7n@googlegroups.com>
<uqlaa8$3c2rd$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sat, 17 Feb 2024 08:58:10 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="8f99487476e839855ee5a7cc038419c2";
logging-data="367769"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+uHyoSUE22OpEamI1CRtMtQcEWMUHcRpM="
User-Agent: Mozilla/5.0 (OS/2; Warp 4.5; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:NSanN1RrCw8iNdl6PLsJghkqWjw=
In-Reply-To: <uqlaa8$3c2rd$1@dont-email.me>
 by: Paul Edwards - Sat, 17 Feb 2024 08:58 UTC

On 15/02/24 23:23, Paul Edwards wrote:

> I'm after a technically pure 32-bit application.
>
> And I may produce my own version of OS/2 2.0
> (similar to PDOS/386 being a mini Win32 clone).
>
> Or I may do the opposite of win32os2 - and run
> OS/2 2.0 programs under Win32. Certain OS/2
> programs. Ones that are dependent on pdpcrt.dll.
> Although that last one would still work if it
> was implemented using the 16-bit calls internally.

Ok, there has been a development.

The author of pdld has agreed to support the output
of OS/2 2.0 LX executables if I add load support for
them in exeload.c (of PDOS/386).

And I have similar plans for ELF, now that I know
how to read command line parameters via a method
other than an unusual stack (which PDOS/386 doesn't
provide).

And thanks to my OS/2 2.0 executables being pure
32-bit that are only dependent on doscalls, I can
intercept at the doscalls level.

And I maintain a variation of gcc 3.2.3 for Windows
that should also be suitable for OS/2 2.0.

And we also have an assembler that is sufficiently
masm-compatible.

So put it all together and we should be able to
stand up a self-hosting mini clone of OS/2 2.0.

Not what I originally set out to do.

But my goals have always been vague and more of
a "see what happens if I do this".

Pushing onto the Amiga, and onto 16-bit MSDOS
and OS/2 in the end gave me a model that applied
to 64-bit too.

Here is the code that needs to be updated if
anyone else is interested (all code needs to
be explicit public domain though):

https://sourceforge.net/p/pdos/gitcode/ci/master/tree/bios/exeload.c

Executables will need to have relocation information
in order to work in a PDOS/386 environment.

BFN. Paul.

Re: another VIO attempt

<uqq0lc$bsbl$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=62&group=comp.os.os2.programmer.misc#62

  copy link   Newsgroups: comp.os.os2.programmer.misc
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: mutazilah@gmail.com (Paul Edwards)
Newsgroups: comp.os.os2.programmer.misc
Subject: Re: another VIO attempt
Date: Sat, 17 Feb 2024 18:09:44 +0800
Organization: A noiseless patient Spider
Lines: 20
Message-ID: <uqq0lc$bsbl$1@dont-email.me>
References: <uqk6ia$35m65$1@dont-email.me>
<d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
<uql3ho$3arit$1@dont-email.me>
<0f00a22e-65eb-4587-a626-be2f62f1b1a7n@googlegroups.com>
<uqlaa8$3c2rd$1@dont-email.me> <uqpsf2$b74p$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sat, 17 Feb 2024 10:09:49 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="8f99487476e839855ee5a7cc038419c2";
logging-data="389493"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/vnoS3izsV73T0PHt0sE+u4a/APLY39Fo="
User-Agent: Mozilla/5.0 (OS/2; Warp 4.5; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:YnYCbBRHuAjfLS7rL7emdwTjFjU=
In-Reply-To: <uqpsf2$b74p$1@dont-email.me>
 by: Paul Edwards - Sat, 17 Feb 2024 10:09 UTC

On 17/02/24 16:58, Paul Edwards wrote:

> So put it all together and we should be able to
> stand up a self-hosting mini clone of OS/2 2.0.

And I just realized that I can have a mini clone
of Linux the same way.

And I think the malloc kludge that I implemented
for Linux won't be an issue either if I introduce
msvcrt.dll.

Even without that, it would still be possible,
just chew up more memory I think.

All rolled into a single PDOS/386.

BFN. Paul.

Re: another VIO attempt

<bAbAN.96974$TSTa.67456@fx47.iad>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=65&group=comp.os.os2.programmer.misc#65

  copy link   Newsgroups: comp.os.os2.programmer.misc
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!fx47.iad.POSTED!not-for-mail
Subject: Re: another VIO attempt
Newsgroups: comp.os.os2.programmer.misc
References: <uqk6ia$35m65$1@dont-email.me>
<d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
<uql3ho$3arit$1@dont-email.me> <g0zzN.357630$c3Ea.117477@fx10.iad>
<uqn5pe$3p9rk$1@dont-email.me> <RSRzN.332642$Wp_8.301346@fx17.iad>
<uqp327$3psl$1@dont-email.me>
From: dave.r.yeo@gmail.com (Dave Yeo)
User-Agent: Mozilla/5.0 (OS/2; Warp 4.5; rv:45.0) Gecko/20100101 Firefox/45.0
SeaMonkey/2.42.9esr
MIME-Version: 1.0
In-Reply-To: <uqp327$3psl$1@dont-email.me>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Lines: 70
Message-ID: <bAbAN.96974$TSTa.67456@fx47.iad>
X-Complaints-To: https://www.astraweb.com/aup
NNTP-Posting-Date: Sat, 17 Feb 2024 23:47:19 UTC
Date: Sat, 17 Feb 2024 15:47:17 -0800
X-Received-Bytes: 3258
 by: Dave Yeo - Sat, 17 Feb 2024 23:47 UTC

Paul Edwards wrote:
> On 17/02/24 07:05, Dave Yeo wrote:
>
>>>> You are staying below the 1GB barrier? I think you mentioned OW1.6
>>>> which
>>>> didn't have much support for high memory IIRC.
>>>
>>> I am not familiar with any of that. I wasn't aware
>>> of a barrier. But such a barrier can be lifted by
>>> the OS/2 vendor whenever they have bandwidth.
>>
>> The problem is 16 bit code is limited to addressing the lower 1GB of
>> address space. Before Warp 4.5 (V4+fp13), the client was limited to 512
>> MB's of address space, minus whatever DLL's were loaded, with the other
>> 512MB's kernel space.
>> Now, by adding objany to DosAllocMem, can access most of the full 32 bit
>
> Ok, so let's say I add something here:
>
> D:\devel\pdos\pdpclib>grep DosAllocMem stdlib.c
> stdlib.c: rc = DosAllocMem(&BaseAddress, ulObjectSize,
> ulAllocationFlags);
>
> D:\devel\pdos\pdpclib>grep ulAllocationFlags stdlib.c
> stdlib.c: ULONG ulAllocationFlags;
> stdlib.c: ulAllocationFlags = PAG_COMMIT | PAG_WRITE | PAG_READ;
> stdlib.c: rc = DosAllocMem(&BaseAddress, ulObjectSize,
> ulAllocationFlags);
>
> D:\devel\pdos\pdpclib>
>
>
> so that I start getting high memory, e.g. I might get
> an address at the 2 GiB mark.

No, you won't get an address higher then 512MB, you need this for
allocating high memory,
stdlib.c: ulAllocationFlags = OBJ_ANY | PAG_COMMIT | PAG_WRITE |
PAG_READ;

>
> And then let's say I put in a filename at that address.
>
> And then I give that filename as a parameter to DosOpen.
>
> You mentioned that DosOpen had 16-bit stuff at its heart.
>
> Does that mean DosOpen won't be able to cope with me
> giving it that high address and crash?

I believe so. With GCC, there is os2safe.h which has this,
#define DosOpen SafeDosOpen
#define DosOpenL SafeDosOpenL
with the SafeDosOpen being a wrapper to handle the case of high memory.
DosOpenL() is used for files larger then 2GB

>
>> address space, minus PCI space. VIRTUALADDRESSLIMIT in config.sys
>> actually controls address space, with 3072 as high as it will go. Often
>> need a lower setting to avoid PCI address space, things like video
>> memory.
>> The fix would be redoing doscall1.dll.
>
> Sure. I'm exactly preparing for the vendor to fix all that.
>

OK
Dave

Re: another VIO attempt

<uqrnm3$mu5t$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=67&group=comp.os.os2.programmer.misc#67

  copy link   Newsgroups: comp.os.os2.programmer.misc
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: mutazilah@gmail.com (Paul Edwards)
Newsgroups: comp.os.os2.programmer.misc
Subject: Re: another VIO attempt
Date: Sun, 18 Feb 2024 09:48:49 +0800
Organization: A noiseless patient Spider
Lines: 40
Message-ID: <uqrnm3$mu5t$1@dont-email.me>
References: <uqk6ia$35m65$1@dont-email.me>
<d6855582-82fd-4883-8806-7bb0de30c63fn@googlegroups.com>
<uql3ho$3arit$1@dont-email.me> <g0zzN.357630$c3Ea.117477@fx10.iad>
<uqn5pe$3p9rk$1@dont-email.me> <RSRzN.332642$Wp_8.301346@fx17.iad>
<uqp327$3psl$1@dont-email.me> <bAbAN.96974$TSTa.67456@fx47.iad>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sun, 18 Feb 2024 01:48:51 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="9e488ae202dfd9b247fa9fce2ef32115";
logging-data="751805"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19iCX4euueJDHjKFO+ZMjEiAcQgmZdOWgI="
User-Agent: Mozilla/5.0 (OS/2; Warp 4.5; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:gVlcMX51ekxPby18cS774SSv374=
In-Reply-To: <bAbAN.96974$TSTa.67456@fx47.iad>
 by: Paul Edwards - Sun, 18 Feb 2024 01:48 UTC

On 18/02/24 07:47, Dave Yeo wrote:

> No, you won't get an address higher then 512MB, you need this for
> allocating high memory,
> stdlib.c: ulAllocationFlags = OBJ_ANY | PAG_COMMIT | PAG_WRITE |
> PAG_READ;

Ok, thanks.

I see this:

bsedos.h: #define OBJ_ANY 0x00000400

>> Does that mean DosOpen won't be able to cope with me
>> giving it that high address and crash?
>
> I believe so. With GCC, there is os2safe.h which has this,
> #define DosOpen SafeDosOpen
> #define DosOpenL SafeDosOpenL
> with the SafeDosOpen being a wrapper to handle the case of high memory.
> DosOpenL() is used for files larger then 2GB
>
>>
>>> address space, minus PCI space. VIRTUALADDRESSLIMIT in config.sys
>>> actually controls address space, with 3072 as high as it will go. Often
>>> need a lower setting to avoid PCI address space, things like video
>>> memory.
>>> The fix would be redoing doscall1.dll.
>>
>> Sure. I'm exactly preparing for the vendor to fix all that.
>>
>
> OK

Ok, so I will fix it in my mini-OS/2 clone. I will
allow the above program - without OBJ_ANY - to
allocate memory anywhere in the 4 GiB range.

BFN. Paul.


devel / comp.os.os2.programmer.misc / another VIO attempt

1
server_pubkey.txt

rocksolid light 0.9.81
clearnet tor