FreeBSD/sys/dev/isci/scil/sati_mode_sense_6.c
/**
 * @brief This method will perform data translation from the supplied ATA
 *        input data (i.e. an ATA IDENTIFY DEVICE block) into an ALL
 *        PAGES mode page format.  The ALL PAGES mode page is basically a
 *        conglomeration of all mode pages and sub-pages into a single
 *        page.  The data will be written into the user's mode page
 *        data buffer.  This function operates specifically for MODE
 *        SENSE 6 commands.
 *        For more information on the parameters passed to this method,
 *        please reference sati_translate_data().
 *
 * @return none.
 */
@brief This method will perform data translation from the supplied ATA
input data  into an ALL
PAGES mode page format.  The ALL PAGES mode page is basically a
conglomeration of all mode pages and sub-pages into a single
page.  The data will be written into the user's mode page
data buffer.  This function operates specifically for MODE
SENSE 6 commands.
For more information on the parameters passed to this method,
please reference sati_translate_data().

@return none.
@brief This method will perform data translation from the supplied ATA input data into an ALL PAGES mode page format . The ALL PAGES mode page is basically a conglomeration of all mode pages and sub - pages into a single page . The data will be written into the user ' s mode page data buffer . This function operates specifically for MODE SENSE 6 commands . For more information on the parameters passed to this method please reference sati_translate_data () . @return none .
void sati_mode_sense_6_all_pages_translate_data(
   SATI_TRANSLATOR_SEQUENCE_T * sequence,
   void                       * ata_input_data,
   void                       * scsi_io
)
{
   ATA_IDENTIFY_DEVICE_DATA_T * identify = (ATA_IDENTIFY_DEVICE_DATA_T*)
                                           ata_input_data;
   U8   data_length = (U8) sati_mode_sense_calculate_page_header(scsi_io, 6)
                           + SCSI_MODE_PAGE_01_LENGTH
                           + SCSI_MODE_PAGE_02_LENGTH
                           + SCSI_MODE_PAGE_08_LENGTH
                           + SCSI_MODE_PAGE_0A_LENGTH
                           + SCSI_MODE_PAGE_1C_LENGTH;
   U32  page_offset = sati_mode_sense_6_translate_data(
                         sequence, identify, scsi_io, data_length
                      );
   sati_mode_sense_all_pages_translate_data(
      sequence, scsi_io, identify, page_offset
   );
}
void sati_mode_sense_6_all_pages_translate_data ( SATI_TRANSLATOR_SEQUENCE_T * sequence , void * ata_input_data , void * scsi_io ) { ATA_IDENTIFY_DEVICE_DATA_T * identify = ( ATA_IDENTIFY_DEVICE_DATA_T * ) ata_input_data ; U8 data_length = ( U8 ) sati_mode_sense_calculate_page_header ( scsi_io , 6 ) + SCSI_MODE_PAGE_01_LENGTH + SCSI_MODE_PAGE_02_LENGTH + SCSI_MODE_PAGE_08_LENGTH + SCSI_MODE_PAGE_0A_LENGTH + SCSI_MODE_PAGE_1C_LENGTH ; U32 page_offset = sati_mode_sense_6_translate_data ( sequence , identify , scsi_io , data_length ) ; sati_mode_sense_all_pages_translate_data ( sequence , scsi_io , identify , page_offset ) ; }
@brief This method will perform data translation from the supplied ATA
        input data (i.e.
@brief This method will perform data translation from the supplied ATA input data ( i . e .