Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 254368
b: refs/heads/master
c: c3f42fe
h: refs/heads/master
v: v3
  • Loading branch information
Jeff Skirvin authored and Dan Williams committed Jul 3, 2011
1 parent 1375e7e commit fa331c5
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 4dc043c41037fc6e369270daaa626465a8766565
refs/heads/master: c3f42feb0c3d20dc7007336e7de949408b93afef
24 changes: 19 additions & 5 deletions trunk/drivers/scsi/isci/task.c
Original file line number Diff line number Diff line change
Expand Up @@ -545,7 +545,7 @@ void isci_task_build_tmf(
void (*tmf_sent_cb)(enum isci_tmf_cb_state,
struct isci_tmf *,
void *),
struct isci_request *old_request)
void *cb_data)
{
dev_dbg(&isci_device->isci_port->isci_host->pdev->dev,
"%s: isci_device = %p\n", __func__, isci_device);
Expand All @@ -556,9 +556,21 @@ void isci_task_build_tmf(
tmf->tmf_code = code;
tmf->timeout_timer = NULL;
tmf->cb_state_func = tmf_sent_cb;
tmf->cb_data = old_request;
tmf->io_tag = old_request->io_tag;
tmf->cb_data = cb_data;
}

void isci_task_build_abort_task_tmf(
struct isci_tmf *tmf,
struct isci_remote_device *isci_device,
enum isci_tmf_function_codes code,
void (*tmf_sent_cb)(enum isci_tmf_cb_state,
struct isci_tmf *,
void *),
struct isci_request *old_request)
{
isci_task_build_tmf(tmf, isci_device, code, tmf_sent_cb,
(void *)old_request);
tmf->io_tag = old_request->io_tag;
}

static struct isci_request *isci_task_get_request_from_task(
Expand Down Expand Up @@ -1300,8 +1312,10 @@ int isci_task_abort_task(struct sas_task *task)
*/
} else {
/* Fill in the tmf stucture */
isci_task_build_tmf(&tmf, isci_device, isci_tmf_ssp_task_abort,
isci_abort_task_process_cb, old_request);
isci_task_build_abort_task_tmf(&tmf, isci_device,
isci_tmf_ssp_task_abort,
isci_abort_task_process_cb,
old_request);

spin_unlock_irqrestore(&isci_host->scic_lock, flags);

Expand Down
9 changes: 9 additions & 0 deletions trunk/drivers/scsi/isci/task.h
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,15 @@ int isci_queuecommand(
int isci_bus_reset_handler(struct scsi_cmnd *cmd);

void isci_task_build_tmf(
struct isci_tmf *tmf,
struct isci_remote_device *isci_device,
enum isci_tmf_function_codes code,
void (*tmf_sent_cb)(enum isci_tmf_cb_state,
struct isci_tmf *,
void *),
void *cb_data);

void isci_task_build_abort_task_tmf(
struct isci_tmf *tmf,
struct isci_remote_device *isci_device,
enum isci_tmf_function_codes code,
Expand Down

0 comments on commit fa331c5

Please sign in to comment.