Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 343608
b: refs/heads/master
c: edba9bf
h: refs/heads/master
v: v3
  • Loading branch information
Guennadi Liakhovetski authored and Grant Likely committed Nov 14, 2012
1 parent b993a92 commit 0f8eb44
Show file tree
Hide file tree
Showing 2 changed files with 4 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: b82b576bc7ffb9785ad3248825ab20496b018e0c
refs/heads/master: edba9bf99dfb20d316abd164d9027479010dbf9d
8 changes: 3 additions & 5 deletions trunk/drivers/spi/spi-bitbang.c
Original file line number Diff line number Diff line change
Expand Up @@ -260,11 +260,11 @@ static void bitbang_work(struct work_struct *work)
struct spi_bitbang *bitbang =
container_of(work, struct spi_bitbang, work);
unsigned long flags;
struct spi_message *m, *_m;

spin_lock_irqsave(&bitbang->lock, flags);
bitbang->busy = 1;
while (!list_empty(&bitbang->queue)) {
struct spi_message *m;
list_for_each_entry_safe(m, _m, &bitbang->queue, queue) {
struct spi_device *spi;
unsigned nsecs;
struct spi_transfer *t = NULL;
Expand All @@ -273,9 +273,7 @@ static void bitbang_work(struct work_struct *work)
int status;
int do_setup = -1;

m = container_of(bitbang->queue.next, struct spi_message,
queue);
list_del_init(&m->queue);
list_del(&m->queue);
spin_unlock_irqrestore(&bitbang->lock, flags);

/* FIXME this is made-up ... the correct value is known to
Expand Down

0 comments on commit 0f8eb44

Please sign in to comment.