This document describes a workaround for the Warp 4 MDOS time slice bug.
Revision 4 from 04-19-1997

1. Problem description

   OS/2 Warp offers four different  methods  for  DOS programs to tell OS/2
   that they temporarily do not need the CPU ("timeslicing").  Two of  them
   are  broken  in Warp 4.0 (see MDOSBUG.TXT for a detailed description) as
   well  es  in  Warp  3.0  starting  with  Fixlevel  22.   This  leads  to
   inacceptably high system  load  when  running  certain DOS applications.
   (Please note that some DOS applications will cause 100% even if you  use
   Warp 3 - this problem only refers to certain "OS/2 aware" programs).

2. Will IBM fix this problem?

   The problem has - finally - been assigned the APAR number JR10024.  This
   means  that  IBM  will fix the problem sooner or later.  According to my
   information, a fix can be expected in Warp 4 Fixpack #2 or Fixpack #3 at
   latest.  Fixpack #1 is still affected by the problem.

3. Workaround principles

   If  you  don't  want  to wait until Fixpack #3, you can help yourself as
   follows:

   a) Write  a TSR that interecepts  the two broken calls and converts them
      into one that  still  works.  This  method,  which was described in
      MDOSBUG3.ZIP, using OSTSR and V4FIX, is not described here any  more,
      because it did not work reliably.

   b) Make the two broken calls work again.   The  coressponding  code  ist
      still  present  in a module of the OS2 kernel - only the call doesn't
      reach  the corresponding module.  We just have to reroute the call by
      changing two (!) bytes in the OS2KRNL.

      At this time I wish to make  clear that patching your OS/2 kernel can
      result  in  everything  up  to  completely   destroying   your   OS/2
      installation.  Although the automated patching method described below
      should  be protected against user errors, and although I have not got
      any reports about negative  side  effects  of  the kernel patch until
      now, I will not give any guarantees.

      Well then, open a "OS/2 Window Command Line".  At first you  have  to
      determine your system revision level by typing in

      VER /R

      The  revision  level  should  either be 9.023 (Warp 4 w/o any fixes),
      9.025 ( Warp 4 w/ official fixpack  #1 installed) or 8.246 (Warp 4 w/
      official fixpack #22 installed).  If your revision level is different
      - bad luck.  (If you are an expert, you can take a hex editor and try
      to find the following byte code sequence:  "66 25 80 00  74  45"  and
      replace  it  by "66 3D 80 00 7E 45", and see if it works.  If you are
      not an expert, don't do this).

      If you have any revision  level  mentioned above, proceed as follows:
      Copy the files MDOS*.PAT to the root directory of  your  boot  drive.
      Make  the  root  directory  of your boot drive to the current working
      directory and do the following:

      ATTRIB -r -s -h OS2KRNL
      COPY OS2KRNL OS2KRNL.ORG
      REM  ^Make a backup of the kernel ;-)

      In the following line,  you  have  to  replace MDOS<level>.PAT by the
      filename corresponding to your system revision level:

      PATCH MDOS<level>.PAT /A

      That  is,  if  your  system  revision  level  is  9.023,  type  PATCH
      MDOS9023.PAT /A, if it is 9.025, type PATCH MDOS9025.PAT /A, if it is
      8.246, type PATCH MDOS8246.PAT /A.

      After that, type in the following:

      ATTRIB +R +S +H OS2KRNL
      DEL *.PAT

      You will have to reboot your system in order to activate the changes.
      From then on all programs that have been releasing OS/2  time  slices
      will  behave  very  smartly.  Of course, there will still be some DOS
      programs sucking 100% system load  because they were not designed for
      multitasking envrionments at all.


4. Annotations

   OS/2 Warp is a registered trademark by IBM.

   Special thanks to
   - Stefan Briesenick for SliceTST
   - Ralf Brandt for developping the OS/2-Kernel patch.
   - Everybody who sent in feed-back and/or helped with "IBM connections",
     in particular Karlheinz Schmidthaus and Peter Hillenbrand.

   This document should normally be distributed in the MDOSBUG4.ZIP archive
   along with the required .PAT files.  If you don't have these files,  you
   can get the original archive at my mailbox (Menu Files/Magic File Menu):

   Badnerland BBS, +49-721-9374498 (V.34/X.75).

   For questions, comments, etc., you can reach me at:

   Fidonet:  Tobias Ernst @ 2:2476/418.0
   OS/2-Net: Tobias Ernst @ 81:449/7835.0
   e-mail:   tobi@bland.fido.de

[EOF]
