Skip to content

Commit

Permalink
ieee1394: Use shorter list_splice_init() for brevity.
Browse files Browse the repository at this point in the history
Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
  • Loading branch information
Robert P. J. Day authored and Stefan Richter committed Apr 18, 2008
1 parent b1ce1fd commit e351c4d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
6 changes: 2 additions & 4 deletions drivers/ieee1394/ohci1394.c
Original file line number Diff line number Diff line change
Expand Up @@ -2089,10 +2089,8 @@ static void dma_trm_reset(struct dma_trm_ctx *d)

spin_lock_irqsave(&d->lock, flags);

list_splice(&d->fifo_list, &packet_list);
list_splice(&d->pending_list, &packet_list);
INIT_LIST_HEAD(&d->fifo_list);
INIT_LIST_HEAD(&d->pending_list);
list_splice_init(&d->fifo_list, &packet_list);
list_splice_init(&d->pending_list, &packet_list);

d->branchAddrPtr = NULL;
d->sent_ind = d->prg_ind;
Expand Down
3 changes: 1 addition & 2 deletions drivers/ieee1394/pcilynx.c
Original file line number Diff line number Diff line change
Expand Up @@ -738,8 +738,7 @@ static int lynx_devctl(struct hpsb_host *host, enum devctl_cmd cmd, int arg)
spin_lock_irqsave(&lynx->async.queue_lock, flags);

reg_write(lynx, DMA_CHAN_CTRL(CHANNEL_ASYNC_SEND), 0);
list_splice(&lynx->async.queue, &packet_list);
INIT_LIST_HEAD(&lynx->async.queue);
list_splice_init(&lynx->async.queue, &packet_list);

if (list_empty(&lynx->async.pcl_queue)) {
spin_unlock_irqrestore(&lynx->async.queue_lock, flags);
Expand Down

0 comments on commit e351c4d

Please sign in to comment.