Operation Manual
Programming—Chapter 7
219700 Series Color Mobile Computer User’s Manual
IOCTL_HAL_GET_BOOT_DEVICE
This IOCTL code allows software to check which device CE booted from.
Usage
#include “oemioctl.h”
Syntax
BOOL KernelIoControl( IOCTL_HAL_GET_BOOT_DEVICE,LPVOID lpInBuf,DWORD
nInBufSize,LPVOID lpOutBuf,DWORD nOutBufSize,LPDWORD lpBytesReturned );
Parameters
lpInBuf Should be set to NULL.
lpInBufSize Should be set to zero.
lpOutBuf Must point to a buffer large enough to hold a DWORD (4 bytes)
with the boot device. The following boot devices are supported:
#define HAL_BOOT_DEVICE_UNKNOWN 0
#define HAL_BOOT_DEVICE_ROM_XIP 1
#define HAL_BOOT_DEVICE_ROM 2
#define HAL_BOOT_DEVICE_PCMCIA_ATA 3
#define HAL_BOOT_DEVICE_PCMCIA_LINEAR 4
#define HAL_BOOT_DEVICE_IDE_ATA 5
#define HAL_BOOT_DEVICE_IDE_ATAPI 6
nOutBufSize ThesizeoflpOutBuf in bytes (4).
lpBytesReturned The nu mber of bytes re turned by the function.
Return Values
Returns TRUE if function succeeds. Returns FALSE if the function fails.
GetLastError() may be used to get the extended error value.
IOCTL_HAL_REBOOT
Note: Using this is no longer recommended, use IOCTL_HAL_WARM-
BOOT (page 217) or IOCTL _HAL_COLDBOOT (page 217). This is
supported for backward-compatibility but its use can lead to difficulties.
Causes the system to perform a warm-boot. The object store is retained.
Usage
#include “oemioctl.h”
Syntax
BOOL KernelIoControl( IOCTL_HAL_REBOOT,LPVOID lpInBuf,DWORD nInBufSize,LPVOID
lpOutBuf,DWORD nOutBufSize,LPDWORD lpBytesReturned );
Parameters
lpInBuf Should be set to NULL. lpOutBuf Should be NULL.
lpInBufSize Should be set to zero. nOutBufSize Should be zero.
Return Values
None.