linux/ataidle.c
// initialize the ata_cmd structure with supplied values
initialize the ata_cmd structure with supplied values
initialize the ata_cmd structure with supplied values
int32_t
ata_setataparams(struct ATA *ata, int seccount, int count)
{
	memset(&ata->atacmd, 0, sizeof(struct ata_cmd));
	if(seccount != 0)
		ata->atacmd.sector_number = seccount;
	else
		ata->atacmd.sector_count = 1;
	return 0;
}
int32_t ata_setataparams ( struct ATA * ata , int seccount , int count ) { memset ( & ata -> atacmd , 0 , sizeof ( struct ata_cmd ) ) ; if ( seccount != 0 ) ata -> atacmd . sector_number = seccount ; else ata -> atacmd . sector_count = 1 ; return 0 ; }
initialize the ata_cmd structure with supplied values
initialize the ata_cmd structure with supplied values
// clear the structure to remove any random values