Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
task.c File Reference
#include <linux/completion.h>
#include <linux/irqflags.h>
#include "sas.h"
#include <scsi/libsas.h>
#include "remote_device.h"
#include "remote_node_context.h"
#include "isci.h"
#include "request.h"
#include "task.h"
#include "host.h"

Go to the source code of this file.

Macros

#define for_each_sas_task(num, task)
 
#define ISCI_LU_RESET_TIMEOUT_MS   2000 /* 2 second timeout. */
 
#define ISCI_ABORT_TASK_TIMEOUT_MS   500 /* 1/2 second timeout */
 

Functions

int isci_task_execute_task (struct sas_task *task, int num, gfp_t gfp_flags)
 
int isci_task_lu_reset (struct domain_device *dev, u8 *lun)
 
int isci_task_clear_nexus_port (struct asd_sas_port *port)
 
int isci_task_clear_nexus_ha (struct sas_ha_struct *ha)
 
int isci_task_abort_task (struct sas_task *task)
 
int isci_task_abort_task_set (struct domain_device *d_device, u8 *lun)
 
int isci_task_clear_aca (struct domain_device *d_device, u8 *lun)
 
int isci_task_clear_task_set (struct domain_device *d_device, u8 *lun)
 
int isci_task_query_task (struct sas_task *task)
 
void isci_task_request_complete (struct isci_host *ihost, struct isci_request *ireq, enum sci_task_status completion_status)
 
int isci_task_I_T_nexus_reset (struct domain_device *dev)
 

Macro Definition Documentation

#define for_each_sas_task (   num,
  task 
)
Value:
for (; num > 0; num--,\
task = list_entry(task->list.next, struct sas_task, list))

Definition at line 102 of file task.c.

#define ISCI_ABORT_TASK_TIMEOUT_MS   500 /* 1/2 second timeout */
#define ISCI_LU_RESET_TIMEOUT_MS   2000 /* 2 second timeout. */

Function Documentation

int isci_task_abort_task ( struct sas_task task)

isci_task_abort_task() - This function is one of the SAS Domain Template functions. This function is called by libsas to abort a specified task. : This parameter specifies the SAS task to abort.

status, zero indicates success.

Definition at line 485 of file task.c.

int isci_task_abort_task_set ( struct domain_device d_device,
u8 lun 
)

isci_task_abort_task_set() - This function is one of the SAS Domain Template functions. This is one of the Task Management functoins called by libsas, to abort all task for the given lun. : This parameter specifies the domain device associated with this request. : This parameter specifies the lun associated with this request.

status, zero indicates success.

Definition at line 624 of file task.c.

int isci_task_clear_aca ( struct domain_device d_device,
u8 lun 
)

isci_task_clear_aca() - This function is one of the SAS Domain Template functions. This is one of the Task Management functoins called by libsas. : This parameter specifies the domain device associated with this request. : This parameter specifies the lun associated with this request.

status, zero indicates success.

Definition at line 641 of file task.c.

int isci_task_clear_nexus_ha ( struct sas_ha_struct ha)

Definition at line 471 of file task.c.

int isci_task_clear_nexus_port ( struct asd_sas_port port)

Definition at line 464 of file task.c.

int isci_task_clear_task_set ( struct domain_device d_device,
u8 lun 
)

isci_task_clear_task_set() - This function is one of the SAS Domain Template functions. This is one of the Task Management functoins called by libsas. : This parameter specifies the domain device associated with this request. : This parameter specifies the lun associated with this request.

status, zero indicates success.

Definition at line 659 of file task.c.

int isci_task_execute_task ( struct sas_task task,
int  num,
gfp_t  gfp_flags 
)

isci_task_execute_task() - This function is one of the SAS Domain Template functions. This function is called by libsas to send a task down to hardware. : This parameter specifies the SAS task to send. : This parameter specifies the number of tasks to queue. : This parameter specifies the context of this call.

status, zero indicates success.

Definition at line 125 of file task.c.

int isci_task_I_T_nexus_reset ( struct domain_device dev)

Definition at line 786 of file task.c.

int isci_task_lu_reset ( struct domain_device dev,
u8 lun 
)

Definition at line 419 of file task.c.

int isci_task_query_task ( struct sas_task task)

isci_task_query_task() - This function is implemented to cause libsas to correctly escalate the failed abort to a LUN or target reset (this is because sas_scsi_find_task libsas function does not correctly interpret all return codes from the abort task call). When TMF_RESP_FUNC_SUCC is returned, libsas turns this into a LUN reset; when FUNC_FAILED is returned, libsas will turn this into a target reset : This parameter specifies the sas task being queried. : This parameter specifies the lun associated with this request.

status, zero indicates success.

Definition at line 679 of file task.c.

void isci_task_request_complete ( struct isci_host ihost,
struct isci_request ireq,
enum sci_task_status  completion_status 
)

Definition at line 700 of file task.c.