Linux Kernel
3.7.1
|
#include <linux/spinlock.h>
#include <linux/gfp.h>
#include "aic94xx.h"
#include "aic94xx_sas.h"
#include "aic94xx_hwi.h"
Go to the source code of this file.
Data Structures | |
struct | tasklet_completion_status |
Macros | |
#define | DECLARE_TCS(tcs) |
#define | CLEAR_NEXUS_PRE |
#define | CLEAR_NEXUS_POST |
Enumerations | |
enum | clear_nexus_phase { NEXUS_PHASE_PRE, NEXUS_PHASE_POST, NEXUS_PHASE_RESUME } |
Functions | |
int | asd_clear_nexus_ha (struct sas_ha_struct *sas_ha) |
int | asd_clear_nexus_port (struct asd_sas_port *port) |
int | asd_I_T_nexus_reset (struct domain_device *dev) |
int | asd_abort_task (struct sas_task *task) |
int | asd_abort_task_set (struct domain_device *dev, u8 *lun) |
int | asd_clear_aca (struct domain_device *dev, u8 *lun) |
int | asd_clear_task_set (struct domain_device *dev, u8 *lun) |
int | asd_lu_reset (struct domain_device *dev, u8 *lun) |
int | asd_query_task (struct sas_task *task) |
Variables | |
struct tasklet_completion_status | __attribute__ |
#define CLEAR_NEXUS_POST |
Definition at line 118 of file aic94xx_tmf.c.
#define CLEAR_NEXUS_PRE |
Definition at line 100 of file aic94xx_tmf.c.
#define DECLARE_TCS | ( | tcs | ) |
Definition at line 66 of file aic94xx_tmf.c.
enum clear_nexus_phase |
Definition at line 153 of file aic94xx_tmf.c.
asd_abort_task – ABORT TASK TMF : the task to be aborted
Before calling ABORT TASK the task state flags should be ORed with SAS_TASK_STATE_ABORTED (unless SAS_TASK_STATE_DONE is set) under the task_state_lock IRQ spinlock, then ABORT TASK must be called.
Implements the ABORT TASK TMF, I_T_L_Q nexus. Returns: SAS TMF responses (see sas_task.h), -ENOMEM, -SAS_QUEUE_FULL.
When ABORT TASK returns, the caller of ABORT TASK checks first the task->task_state_flags, and then the return value of ABORT TASK.
If the task has task state bit SAS_TASK_STATE_DONE set, then the task was completed successfully prior to it being aborted. The caller of ABORT TASK has responsibility to call task->task_done() xor free the task, depending on their framework. The return code is TMF_RESP_FUNC_FAILED in this case.
Else the SAS_TASK_STATE_DONE bit is not set, If the return code is TMF_RESP_FUNC_COMPLETE, then the task was aborted successfully. The caller of ABORT TASK has responsibility to call task->task_done() to finish the task, xor free the task depending on their framework. else the ABORT TASK returned some kind of error. The task was not cancelled. Nothing can be assumed. The caller of ABORT TASK may wish to retry.
Definition at line 405 of file aic94xx_tmf.c.
int asd_abort_task_set | ( | struct domain_device * | dev, |
u8 * | lun | ||
) |
Definition at line 657 of file aic94xx_tmf.c.
int asd_clear_aca | ( | struct domain_device * | dev, |
u8 * | lun | ||
) |
Definition at line 666 of file aic94xx_tmf.c.
int asd_clear_nexus_ha | ( | struct sas_ha_struct * | sas_ha | ) |
Definition at line 134 of file aic94xx_tmf.c.
int asd_clear_nexus_port | ( | struct asd_sas_port * | port | ) |
Definition at line 143 of file aic94xx_tmf.c.
int asd_clear_task_set | ( | struct domain_device * | dev, |
u8 * | lun | ||
) |
Definition at line 675 of file aic94xx_tmf.c.
int asd_I_T_nexus_reset | ( | struct domain_device * | dev | ) |
Definition at line 181 of file aic94xx_tmf.c.
int asd_lu_reset | ( | struct domain_device * | dev, |
u8 * | lun | ||
) |
Definition at line 684 of file aic94xx_tmf.c.
asd_query_task – send a QUERY TASK TMF to an I_T_L_Q nexus task: pointer to sas_task struct of interest
Returns: TMF_RESP_FUNC_COMPLETE if the task is not in the task set, or TMF_RESP_FUNC_SUCC if the task is in the task set.
Normally the management layer sets the task to aborted state, and then calls query task and then abort task.
Definition at line 703 of file aic94xx_tmf.c.