|
#define | WINVER 0x0502 |
|
#define | _WIN32_WINNT WINVER |
|
#define | assert(x) /* */ |
|
#define | _WIN32 |
|
#define | SELECT_WIN_32_64(x32, x64) (x32) |
|
#define | IOCTL_IDE_PASS_THROUGH CTL_CODE(IOCTL_SCSI_BASE, 0x040A, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS) |
|
#define | FILE_DEVICE_SCSI 0x001b |
|
#define | IOCTL_SCSI_MINIPORT_SMART_VERSION ((FILE_DEVICE_SCSI << 16) + 0x0500) |
|
#define | IOCTL_SCSI_MINIPORT_IDENTIFY ((FILE_DEVICE_SCSI << 16) + 0x0501) |
|
#define | IOCTL_SCSI_MINIPORT_READ_SMART_ATTRIBS ((FILE_DEVICE_SCSI << 16) + 0x0502) |
|
#define | IOCTL_SCSI_MINIPORT_READ_SMART_THRESHOLDS ((FILE_DEVICE_SCSI << 16) + 0x0503) |
|
#define | IOCTL_SCSI_MINIPORT_ENABLE_SMART ((FILE_DEVICE_SCSI << 16) + 0x0504) |
|
#define | IOCTL_SCSI_MINIPORT_DISABLE_SMART ((FILE_DEVICE_SCSI << 16) + 0x0505) |
|
#define | IOCTL_SCSI_MINIPORT_RETURN_STATUS ((FILE_DEVICE_SCSI << 16) + 0x0506) |
|
#define | IOCTL_SCSI_MINIPORT_ENABLE_DISABLE_AUTOSAVE ((FILE_DEVICE_SCSI << 16) + 0x0507) |
|
#define | IOCTL_SCSI_MINIPORT_SAVE_ATTRIBUTE_VALUES ((FILE_DEVICE_SCSI << 16) + 0x0508) |
|
#define | IOCTL_SCSI_MINIPORT_EXECUTE_OFFLINE_DIAGS ((FILE_DEVICE_SCSI << 16) + 0x0509) |
|
#define | IOCTL_SCSI_MINIPORT_ENABLE_DISABLE_AUTO_OFFLINE ((FILE_DEVICE_SCSI << 16) + 0x050a) |
|
#define | IOCTL_SCSI_MINIPORT_READ_SMART_LOG ((FILE_DEVICE_SCSI << 16) + 0x050b) |
|
#define | IOCTL_SCSI_MINIPORT_WRITE_SMART_LOG ((FILE_DEVICE_SCSI << 16) + 0x050c) |
|
#define | IOCTL_STORAGE_PROTOCOL_COMMAND CTL_CODE(IOCTL_STORAGE_BASE, 0x04f0, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS) |
|
#define | STORAGE_PROTOCOL_STRUCTURE_VERSION 1 |
|
#define | STORAGE_PROTOCOL_COMMAND_FLAG_ADAPTER_REQUEST 0x80000000 |
|
#define | STORAGE_PROTOCOL_SPECIFIC_NVME_ADMIN_COMMAND 0x01 |
|
#define | STORAGE_PROTOCOL_COMMAND_LENGTH_NVME 0x40 |
|
#define | SMART_VENDOR_3WARE 0x13C1 |
|
#define | NVME_SIG_STR "NvmeMini" |
|
#define | NVME_STORPORT_DRIVER 0xe000 |
|
#define | NVME_PASS_THROUGH_SRB_IO_CODE CTL_CODE(NVME_STORPORT_DRIVER, 0x0800, METHOD_BUFFERED, FILE_ANY_ACCESS) |
|
#define | SMART_CYL_LOW 0x4F |
|
#define | SMART_CYL_HI 0xC2 |
|
#define | SYNCOBJNAME "Global\\SynIoctlMutex" |
|
#define | SYNCOBJNAME "Global\\SynIoctlMutex" |
|
#define | ARECA_MAX_CTLR_NUM 16 |
|
#define | aacraid_MAX_CTLR_NUM 16 |
|
|
| STATIC_ASSERT (SMART_GET_VERSION==0x074080) |
|
| STATIC_ASSERT (SMART_SEND_DRIVE_COMMAND==0x07c084) |
|
| STATIC_ASSERT (SMART_RCV_DRIVE_DATA==0x07c088) |
|
| STATIC_ASSERT (sizeof(GETVERSIONINPARAMS)==24) |
|
| STATIC_ASSERT (sizeof(SENDCMDINPARAMS)==32+1) |
|
| STATIC_ASSERT (sizeof(SENDCMDOUTPARAMS)==16+1) |
|
| STATIC_ASSERT (IOCTL_IDE_PASS_THROUGH==0x04d028) |
|
| STATIC_ASSERT (sizeof(ATA_PASS_THROUGH)==12+1) |
|
| STATIC_ASSERT (IOCTL_ATA_PASS_THROUGH==0x04d02c) |
|
| STATIC_ASSERT (sizeof(ATA_PASS_THROUGH_EX)==SELECT_WIN_32_64(40, 48)) |
|
| STATIC_ASSERT (IOCTL_SCSI_PASS_THROUGH==0x04d004) |
|
| STATIC_ASSERT (IOCTL_SCSI_PASS_THROUGH_DIRECT==0x04d014) |
|
| STATIC_ASSERT (sizeof(SCSI_PASS_THROUGH)==SELECT_WIN_32_64(44, 56)) |
|
| STATIC_ASSERT (sizeof(SCSI_PASS_THROUGH_DIRECT)==SELECT_WIN_32_64(44, 56)) |
|
| STATIC_ASSERT (IOCTL_SCSI_MINIPORT==0x04d008) |
|
| STATIC_ASSERT (IOCTL_SCSI_MINIPORT_SMART_VERSION==0x1b0500) |
|
| STATIC_ASSERT (sizeof(SRB_IO_CONTROL)==28) |
|
| STATIC_ASSERT (IOCTL_STORAGE_QUERY_PROPERTY==0x002d1400) |
|
| STATIC_ASSERT (sizeof(STORAGE_DEVICE_DESCRIPTOR)==36+1+3) |
|
| STATIC_ASSERT (sizeof(STORAGE_PROPERTY_QUERY)==8+1+3) |
|
| win10::STATIC_ASSERT (sizeof(STORAGE_PROTOCOL_SPECIFIC_DATA)==40) |
|
| STATIC_ASSERT (IOCTL_STORAGE_PREDICT_FAILURE==0x002d1100) |
|
| STATIC_ASSERT (sizeof(STORAGE_PREDICT_FAILURE)==4+512) |
|
| STATIC_ASSERT (IOCTL_STORAGE_PROTOCOL_COMMAND==0x002dd3c0) |
|
| STATIC_ASSERT (offsetof(STORAGE_PROTOCOL_COMMAND, Command)==80) |
|
| STATIC_ASSERT (sizeof(STORAGE_PROTOCOL_COMMAND)==84) |
|
| STATIC_ASSERT (sizeof(NVME_COMMAND)==STORAGE_PROTOCOL_COMMAND_LENGTH_NVME) |
|
| STATIC_ASSERT (offsetof(NVME_COMMAND, u.GENERAL.CDW10)==40) |
|
| STATIC_ASSERT (sizeof(GETVERSIONINPARAMS_EX)==sizeof(GETVERSIONINPARAMS)) |
|
| STATIC_ASSERT (sizeof(SENDCMDINPARAMS_EX)==sizeof(SENDCMDINPARAMS)) |
|
| STATIC_ASSERT (NVME_PASS_THROUGH_SRB_IO_CODE==(int) 0xe0002000) |
|
| STATIC_ASSERT (sizeof(NVME_PASS_THROUGH_IOCTL)==152+1) |
|
| STATIC_ASSERT (sizeof(IOCTL_HEADER)==sizeof(SRB_IO_CONTROL)) |
|
| STATIC_ASSERT (sizeof(CSMI_SAS_DRIVER_INFO_BUFFER)==204) |
|
| STATIC_ASSERT (sizeof(CSMI_SAS_PHY_INFO_BUFFER)==2080) |
|
| STATIC_ASSERT (sizeof(CSMI_SAS_STP_PASSTHRU_BUFFER)==168) |
|
| STATIC_ASSERT (sizeof(SCSI_REQUEST_BLOCK)==SELECT_WIN_32_64(64, 88)) |
|
static int | os_win32::is_permissive () |
|
static int | os_win32::drive_letter (const char *s) |
|
static const char * | os_win32::skipdev (const char *s) |
|
static int | os_win32::sdxy_to_phydrive (const char(&xy)[2+1]) |
|
static void | os_win32::copy_swapped (unsigned char *dest, const char *src, int destsize) |
|
static void | os_win32::print_ide_regs (const IDEREGS *r, int out) |
|
static void | os_win32::print_ide_regs_io (const IDEREGS *ri, const IDEREGS *ro) |
|
static int | os_win32::smart_get_version (HANDLE hdevice, GETVERSIONINPARAMS_EX *ata_version_ex=0) |
|
static int | os_win32::smart_ioctl (HANDLE hdevice, IDEREGS *regs, char *data, unsigned datasize, int port) |
|
static int | os_win32::ide_pass_through_ioctl (HANDLE hdevice, IDEREGS *regs, char *data, unsigned datasize) |
|
static int | os_win32::ata_pass_through_ioctl (HANDLE hdevice, IDEREGS *regs, IDEREGS *prev_regs, char *data, int datasize) |
|
static int | os_win32::ata_via_scsi_miniport_smart_ioctl (HANDLE hdevice, IDEREGS *regs, char *data, int datasize) |
|
static int | os_win32::ata_via_3ware_miniport_ioctl (HANDLE hdevice, IDEREGS *regs, char *data, int datasize, int port) |
|
static int | os_win32::update_3ware_devicemap_ioctl (HANDLE hdevice) |
|
static int | os_win32::storage_query_property_ioctl (HANDLE hdevice, STORAGE_DEVICE_DESCRIPTOR_DATA *data) |
|
static int | os_win32::storage_predict_failure_ioctl (HANDLE hdevice, char *data=0) |
|
static int | os_win32::get_identify_from_device_property (HANDLE hdevice, ata_identify_device *id) |
|
static bool | os_win32::get_serial_from_wmi (int drive, ata_identify_device *id) |
|
static bool | os_win32::get_usb_id (int phydrive, int logdrive, unsigned short &vendor_id, unsigned short &product_id) |
|
static int | os_win32::get_device_power_state (HANDLE hdevice) |
|
static const char * | os_win32::ata_get_def_options () |
|
static int | os_win32::get_clipboard (char *data, int datasize) |
|
static const char * | os_win32::findstr (const char *str, const char *sub) |
|
static long | os_win32::scsi_pass_through_indirect (HANDLE h, SCSI_PASS_THROUGH_DIRECT_WITH_BUFFER *sbd) |
|
static long | os_win32::scsi_pass_through_direct (HANDLE fd, UCHAR targetid, struct scsi_cmnd_io *iop) |
| Areca RAID support.
|
|
static bool | os_win32::is_wow64 () |
|
static bool | os_win32::is_sat (const STORAGE_DEVICE_DESCRIPTOR_DATA *data) |
|
static bool | os_win32::is_intel_raid_volume (const STORAGE_DEVICE_DESCRIPTOR_DATA *data) |
|
static win_dev_type | os_win32::get_controller_type (HANDLE hdevice, bool admin, GETVERSIONINPARAMS_EX *ata_version_ex) |
|
static win_dev_type | os_win32::get_controller_type (const char *path, GETVERSIONINPARAMS_EX *ata_version_ex=0) |
|
static win_dev_type | os_win32::get_phy_drive_type (int drive, GETVERSIONINPARAMS_EX *ata_version_ex) |
|
static win_dev_type | os_win32::get_phy_drive_type (int drive) |
|
static win_dev_type | os_win32::get_log_drive_type (int drive) |
|
static win_dev_type | os_win32::get_dev_type (const char *name, int &phydrive, int &logdrive) |
|
std::string | get_exe_dir () |
|