Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 147098
b: refs/heads/master
c: 4376818
h: refs/heads/master
v: v3
  • Loading branch information
Jens Axboe authored and Jeff Garzik committed Jun 10, 2009
1 parent 2b0419e commit 6c8a1c2
Show file tree
Hide file tree
Showing 2 changed files with 6 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: 31f80112cc7e7ea4c220d6f62b0a7052754befb3
refs/heads/master: 437681800bdaa9feb58cf943dfbbd239c21d3705
11 changes: 5 additions & 6 deletions trunk/drivers/ata/libata-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -5031,7 +5031,6 @@ int ata_qc_complete_multiple(struct ata_port *ap, u32 qc_active)
{
int nr_done = 0;
u32 done_mask;
int i;

done_mask = ap->qc_active ^ qc_active;

Expand All @@ -5041,16 +5040,16 @@ int ata_qc_complete_multiple(struct ata_port *ap, u32 qc_active)
return -EINVAL;
}

for (i = 0; i < ATA_MAX_QUEUE; i++) {
while (done_mask) {
struct ata_queued_cmd *qc;
unsigned int tag = __ffs(done_mask);

if (!(done_mask & (1 << i)))
continue;

if ((qc = ata_qc_from_tag(ap, i))) {
qc = ata_qc_from_tag(ap, tag);
if (qc) {
ata_qc_complete(qc);
nr_done++;
}
done_mask &= ~(1 << tag);
}

return nr_done;
Expand Down

0 comments on commit 6c8a1c2

Please sign in to comment.