// kommiscioctl.h
//
// Define control codes for Misc driver
//

#ifndef __kommiscioctl__h_
#define __kommiscioctl__h_

#define KOMMISC_IOCTL_WDG_SET_TIMEOUT CTL_CODE(FILE_DEVICE_UNKNOWN, 0x800, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_WDG_RETRIGGER CTL_CODE(FILE_DEVICE_UNKNOWN, 0x801, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_WDG_START CTL_CODE(FILE_DEVICE_UNKNOWN, 0x802, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_WDG_CHECK_FOR_TIMEOUT CTL_CODE(FILE_DEVICE_UNKNOWN, 0x803, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_WDG_GET_CONFIG CTL_CODE(FILE_DEVICE_UNKNOWN, 0x804, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_HSWP_GET_HANDLE_STATE CTL_CODE(FILE_DEVICE_UNKNOWN, 0x805, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_HSWP_SET_LED CTL_CODE(FILE_DEVICE_UNKNOWN, 0x806, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_HSWP_GET_LED CTL_CODE(FILE_DEVICE_UNKNOWN, 0x807, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_USR_SET_LED CTL_CODE(FILE_DEVICE_UNKNOWN, 0x808, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_USR_GET_OVRTEMP_LED CTL_CODE(FILE_DEVICE_UNKNOWN, 0x809, METHOD_BUFFERED, FILE_ANY_ACCESS)

#define KOMMISC_IOCTL_BOARD_GET_ID CTL_CODE(FILE_DEVICE_UNKNOWN, 0x810, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_USR_ASGN_OVRTEMP_LED CTL_CODE(FILE_DEVICE_UNKNOWN, 0x811, METHOD_BUFFERED, FILE_ANY_ACCESS)

#define KOMMISC_IOCTL_SVPC_GET_POWERDOWN_REQ CTL_CODE(FILE_DEVICE_UNKNOWN, 0x812, METHOD_BUFFERED, FILE_ANY_ACCESS)

#define KOMMISC_IOCTL_WDG_SET_HWRESET CTL_CODE(FILE_DEVICE_UNKNOWN, 0x813, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_WDG_SET_IRQ5ROUTING CTL_CODE(FILE_DEVICE_UNKNOWN, 0x814, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_WDG_GET_HWRESET CTL_CODE(FILE_DEVICE_UNKNOWN, 0x815, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define KOMMISC_IOCTL_WDG_GET_IRQ5ROUTING CTL_CODE(FILE_DEVICE_UNKNOWN, 0x816, METHOD_BUFFERED, FILE_ANY_ACCESS)



// for future use: uncomment if ness.
//#define KOMMISC_IOCTL_WDG_SET_NMIROUTING CTL_CODE(FILE_DEVICE_UNKNOWN, 0x817, METHOD_BUFFERED, FILE_ANY_ACCESS)
//#define KOMMISC_IOCTL_WDG_GET_NMIROUTING CTL_CODE(FILE_DEVICE_UNKNOWN, 0x818, METHOD_BUFFERED, FILE_ANY_ACCESS)







/*
#define	MISC_WDG_125MSEC	0
#define	MISC_WDG_250MSEC	1
#define	MISC_WDG_500MSEC	2
#define	MISC_WDG_1SEC		3
#define	MISC_WDG_2SEC		4
#define	MISC_WDG_4SEC		5
#define	MISC_WDG_8SEC		6
#define	MISC_WDG_16SEC		7
#define	MISC_WDG_32SEC		8
#define	MISC_WDG_64SEC		9
#define	MISC_WDG_128SEC		10
#define	MISC_WDG_256SEC		11
*/


#define MISC_LED_MAX		        0xFF
#define SVPC_POWER_POWERDOWN_REQ	0x01	// request for power down

/* typedefs */
/* structure to be used for watchdog configuration request */
typedef struct
{
	UCHAR bTimeout;
	BOOLEAN bEnable;
}tMiscWdgConfig, *ptMiscWdgConfig;

#endif
