[syslinux] [PATCH]: ifplop.c32: COM32 module for detection of PLoP USB boot-loader

Gert Hulselmans gerth at zytor.com
Sun Jun 13 13:14:16 PDT 2010


I wrote a COM32 module which detects if the PLoP bootmanager was used to
boot a CDROM drive or USB drive, by checking for the presence of the PLoP
INT13h hook.

The PLoP INT13h hook check works like this (NASM syntax):

   mov eax,'PoLP'  ; Reverse of 'PLoP'
   mov ebp,'DKHC'  ; Reverse of 'CHKD'
   int 13h
   cmp eax,' sey'  ; Reverse of 'yes '
   jz plop_int13_active

More info: http://forum.plop.at/index.php/topic,165.0.html

The syntax for using this module is the same as for ifcpu.c32 and
ifcpu64.c32:

Usage:   ifplop.c32 [<plop_detected>] -- [<plop_not_detected>]

Example: ifplop.c32 menu.c32 another.cfg -- plpbt.bin

Below, you can find and example of a syslinux.cfg:
===========================================================================
  DEFAULT plopcheck

  # Check for the presence of PLoP (run by default)
  #   When PLoP INT13h hook is found, run the first command (plop_detected)
  #   When PLoP INT13h hook isn't found, run the second command
(plop_not_detected)

  LABEL plopcheck
      COM32 ifplop.c32
      APPEND plop_detected -- plop_not_detected

  # When PLoP INT13 hook was found, boot the menu system.
  # PLoP can have added USB 2.0 speed, so the entries we want to boot
  # will be read from disk much faster (supposing that we have a BIOS
  # that only supports USB 1.1 speed, but a mobo with USB 2.0 controllers).

  LABEL plop_detected
      COM32 menu.c32
      APPEND another.cfg

  # PLoP INT13 hook wasn't found, so we boot PLoP, so it can add USB 2.0
support
 LABEL plop_not_detected
      LINUX plpbt.bin
===========================================================================

Now, maybe the most important part.
Why is/can this be useful?

1. PLoP bootloader is a bootloader that can add USB support (USB-HDD
only/UHCI, OHCI and EHCI)) to BIOSes that don't have USB BIOS support.
2. It can also upgrade USB 1.1 speed to USB 2.0 speed if you have USB 2.0
controllers in your mobo.
3. Some BIOSes (like mine) have a 128GiB (137GB) limit for USB drives
(internal hard drives don't have the 128GiB problem). Using PLoPs USB
capabilities, allow me to access the whole drive.

In case 1, ifplop.c32 won't be very useful.

In case 2, it will be. You can let PLoP boot by default when you boot (USB
1.1 speed) your USB drive. Selecting 'USB' from the PLoP submenu will boot
your USB drive (with Syslinux) again. Now we have USB 2.0 speed. Now
ifplop.c32 will detect the PLoP INT13h hook and will boot our menu (see
syslinux.cfg example above).

In case 3, it will be when you have a large USB drive from which you want
to boot.
More info:
http://www.boot-land.net/forums/index.php?showtopic=11684&pid=102235&mode=threaded&start=0#entry102235

The code can be pulled from (cosmetic: maybe INT13 should be changed to
INT13h):
http://git.zytor.com/?p=users/sha0/syslinux.git;a=commitdiff;h=9d7dd4adf945e40c9959ca62afed132301257dfc

It uses also the spaces patch fix of Sha0 (ifcpuXX.c32).

- Gert Hulselmans




More information about the Syslinux mailing list