FreeBSD/sys/dev/isci/scil/sati_util.c
/**
 * @brief This method will construct the ATA IDLE command.\
 *
 * @pre It is expected that the user has properly set the current contents
 *      of the register FIS to 0.
 *
 * @param[out] ata_io This parameter specifies the ATA IO request structure
 *             for which to build the ATA IDLE command.
 * @param[in]  sequence This parameter specifies the translator sequence
 *             for which the command is being constructed.
 *
 * @return none.
 */
@brief This method will construct the ATA IDLE command.\
@pre It is expected that the user has properly set the current contents
of the register FIS to 0.

@param[out] ata_io This parameter specifies the ATA IO request structure
for which to build the ATA IDLE command.
@param[in]  sequence This parameter specifies the translator sequence
for which the command is being constructed.

@return none.
@brief This method will construct the ATA IDLE command . \ @pre It is expected that the user has properly set the current contents of the register FIS to 0 . @param [ out ] ata_io This parameter specifies the ATA IO request structure for which to build the ATA IDLE command . @param [ in ] sequence This parameter specifies the translator sequence for which the command is being constructed . @return none .
void sati_ata_idle_construct(
   void                       * ata_io,
   SATI_TRANSLATOR_SEQUENCE_T * sequence
)
{
   U8 * register_fis = sati_cb_get_h2d_register_fis_address(ata_io);
   sati_set_ata_command(register_fis, ATA_IDLE);
   sati_set_ata_features(register_fis, 0x00);
   sati_set_ata_sector_count(register_fis, 0x00);
   sequence->device->ata_standby_timer = 0x00;
   sati_set_ata_lba_high(register_fis, 0x00);
   sati_set_ata_lba_mid(register_fis, 0x00);
   sati_set_ata_lba_low(register_fis, 0x00);
   sati_ata_non_data_command(ata_io, sequence);
}
void sati_ata_idle_construct ( void * ata_io , SATI_TRANSLATOR_SEQUENCE_T * sequence ) { U8 * register_fis = sati_cb_get_h2d_register_fis_address ( ata_io ) ; sati_set_ata_command ( register_fis , ATA_IDLE ) ; sati_set_ata_features ( register_fis , 0x00 ) ; sati_set_ata_sector_count ( register_fis , 0x00 ) ; sequence -> device -> ata_standby_timer = 0x00 ; sati_set_ata_lba_high ( register_fis , 0x00 ) ; sati_set_ata_lba_mid ( register_fis , 0x00 ) ; sati_set_ata_lba_low ( register_fis , 0x00 ) ; sati_ata_non_data_command ( ata_io , sequence ) ; }
@brief This method will construct the ATA IDLE command.\
 @pre It is expected that the user has properly set the current contents
      of the register FIS to 0.
@brief This method will construct the ATA IDLE command . \ @pre It is expected that the user has properly set the current contents of the register FIS to 0 .