![]() |
![]() |
![]() |
UDisks Reference Manual | ![]() |
---|---|---|---|---|
Top | Description |
enum UDisksAtaCommandProtocol; UDisksAtaCommandInput; UDisksAtaCommandOutput; gboolean udisks_ata_send_command_sync (gint fd
,gint timeout_msec
,UDisksAtaCommandProtocol protocol
,UDisksAtaCommandInput *input
,UDisksAtaCommandOutput *output
,GError **error
);
typedef enum { UDISKS_ATA_COMMAND_PROTOCOL_NONE, UDISKS_ATA_COMMAND_PROTOCOL_DRIVE_TO_HOST, UDISKS_ATA_COMMAND_PROTOCOL_HOST_TO_DRIVE } UDisksAtaCommandProtocol;
Enumeration used to specify the protocol of an ATA command
typedef struct { guint8 command; guint8 feature; guint8 count; guint8 device; guint32 lba; gsize buffer_size; guchar *buffer; } UDisksAtaCommandInput;
Struct used for input data when sending ATA commands.
typedef struct { guint8 error; guint8 count; guint8 device; guint8 status; guint32 lba; gsize buffer_size; guchar *buffer; } UDisksAtaCommandOutput;
Struct used for output data when sending ATA commands.
gboolean udisks_ata_send_command_sync (gint fd
,gint timeout_msec
,UDisksAtaCommandProtocol protocol
,UDisksAtaCommandInput *input
,UDisksAtaCommandOutput *output
,GError **error
);
Sends a command to an ATA device. Blocks the calling thread while the command is pending.
|
A file descriptor for a ATA device. |
|
Timeout in milli-seconds for the command. Use -1 for the default (5 seconds) timeout and G_MAXINT for no timeout. |
|
The direction of the command. |
|
The input for the command. |
|
The output for the command. |
|
Return location for error or NULL . |
Returns : |
TRUE if the command succeded, FALSE if error is set. |