### Method

# FwupdPlugin BlockDevice sg_io_cmd_write

#### Declaration [src]

    gboolean
    fu_block_device_sg_io_cmd_write (
      FuBlockDevice* self,
      const guint8* cdb,
      gsize cdbsz,
      const guint8* buf,
      gsize bufsz,
      GError** error
    )

#### Description [src]

Performs a SCSI IO write command.

Available since: | 2.0.0

#### Parameters

`cdb` | `const guint8*`
| A cdb command.
| The data is owned by the caller of the function.
`cdbsz` | `gsize`
| Sizeof `cdb`.
`buf` | `const guint8*`
| Buffer to read from.
| The data is owned by the caller of the function.
`bufsz` | `gsize`
| Sizeof `buf`.
`error` | `GError **`
| The return location for a `GError*`, or `NULL`.

#### Return value

Returns: | `gboolean`
| `TRUE` on success.