Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 316845
b: refs/heads/master
c: 6cdd552
h: refs/heads/master
i:
  316843: 4719242
v: v3
  • Loading branch information
Dan Williams authored and James Bottomley committed Jul 20, 2012
1 parent a33382c commit b58e2aa
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 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: a4683487f90bfe3049686fc5c566bdc1ad03ace6
refs/heads/master: 6cdd55205d160f63003c321fcea608336953dd5b
12 changes: 6 additions & 6 deletions trunk/drivers/scsi/scsi_scan.c
Original file line number Diff line number Diff line change
Expand Up @@ -1845,14 +1845,13 @@ static void do_scsi_scan_host(struct Scsi_Host *shost)
}
}

static int do_scan_async(void *_data)
static void do_scan_async(void *_data, async_cookie_t c)
{
struct async_scan_data *data = _data;
struct Scsi_Host *shost = data->shost;

do_scsi_scan_host(shost);
scsi_finish_async_scan(data);
return 0;
}

/**
Expand All @@ -1861,7 +1860,6 @@ static int do_scan_async(void *_data)
**/
void scsi_scan_host(struct Scsi_Host *shost)
{
struct task_struct *p;
struct async_scan_data *data;

if (strncmp(scsi_scan_type, "none", 4) == 0)
Expand All @@ -1876,9 +1874,11 @@ void scsi_scan_host(struct Scsi_Host *shost)
return;
}

p = kthread_run(do_scan_async, data, "scsi_scan_%d", shost->host_no);
if (IS_ERR(p))
do_scan_async(data);
/* register with the async subsystem so wait_for_device_probe()
* will flush this work
*/
async_schedule(do_scan_async, data);

/* scsi_autopm_put_host(shost) is called in scsi_finish_async_scan() */
}
EXPORT_SYMBOL(scsi_scan_host);
Expand Down

0 comments on commit b58e2aa

Please sign in to comment.