[Go to CFHT Home Page] Man Pages
Back to Software Index  BORDER=0Manpage Top Level
    scsi_poll(9F) manual page Table of Contents

Name

scsi_poll - run a polled SCSI command on behalf of a target driver

Synopsis


#include <sys/scsi/scsi.h>

int scsi_poll(struct scsi_pkt *pkt);

Interface Level

Solaris DDI specific (Solaris DDI).

Arguments

pkt
Pointer to the scsi_pkt(9S) structure.

Description

scsi_poll() requests the host adapter driver to run a polled command. Unlike scsi_transport(9F) which runs commands asynchronously, scsi_poll() runs commands to completion before returning. If the pkt_time member of pkt is 0, the value of pkt_time is defaulted to SCSI_POLL_TIMEOUT to prevent an indefinite hang of the system.

Return Values

scsi_poll() returns:
  1. command completed successfully.
    -1
    command failed.

    Context

    scsi_poll() can be called from user or interrupt level.

    See Also

    makecom(9F) , scsi_transport(9F) , scsi_pkt(9S)

    Warnings

    Since scsi_poll() runs commands to completion before returning, it may require more time than is desirable when called from interrupt context. Therefore, calling scsi_poll from interrupt context is not recommended.


    Table of Contents