Skip to content
Snippets Groups Projects
Commit 3d68339e authored by Michael Davis's avatar Michael Davis Committed by Cedric Caffy
Browse files

[LTO_RAO] Adds stDeviceFile::ioctlRequestSense

parent 7c7c45c8
No related branches found
No related tags found
No related merge requests found
......@@ -214,6 +214,20 @@ int System::stDeviceFile::ioctlReadPosition(sg_io_hdr_t* sgio_h) {
return 0;
}
int System::stDeviceFile::ioctlRequestSense(sg_io_hdr_t* sgio_h) {
if (SG_DXFER_FROM_DEV != sgio_h->dxfer_direction) {
errno = EINVAL;
return -1;
}
SCSI::Structures::requestSenseData_t &requestSenseData =
*reinterpret_cast<SCSI::Structures::requestSenseData_t*>(sgio_h->dxferp);
if(sizeof(requestSenseData) > sgio_h->dxfer_len) {
errno = EINVAL;
return -1;
}
return 0;
}
int System::stDeviceFile::ioctlLogSelect(sg_io_hdr_t * sgio_h) {
if (SG_DXFER_NONE != sgio_h->dxfer_direction) {
errno = EINVAL;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment