Get Attribute information from the device.
int CoHWRaidGetDrvID(int fd, PCoHWRAIDDrvID id, void* pv)
int fd
Please specify handle acquired by CoHWRaidOpen function.
PCoHWRAIDDrvID id
Specify a pointer variable to store the Identify information.
enum hwraid_drives {
HWRAID_BOARD = 0, // RAID Board
HWRAID_DRIVE1, // RAID Drive 1
HWRAID_DRIVE2, // RAID Drive 2
HWRAID_DRIVE_NUM // max_num
};
typedef struct co_hwraid_drive_id {
struct cohwraid_id_data {
struct id_parsed {
char serial[21]; // serial number
char firmware[9]; // firmware revesion
char model[41]; // model
} id;
uint8_t id_raw[512]; // identify(raw)
} id_data[HWRAID_DRIVE_NUM];
} CoHWRAIDDrvID, *PCoHWRAIDDrvID;
RAID board identification information is stored in id.idata[HWRAID_BOARD],
drive1 identification information is stored in id.idata[HWRAID_DRIVE1],
and drive2 identification information is stored in id.idata[HWRAID_DRIVE2].
The obtained 512-byte raw value is stored in the id_raw structure member.
Each structure member of struct id_parsed contains serial, firmware revision,
and model information obtained from identify. If the function fails,
0 or an indeterminate value is returned.
void* pv
Reserved. Please set NULL.
If the function succeeds, NO_ERROR is returned.
If the function fails, DRIVER_FAIL is returned.
The other errors : Error code details
Function List