diff options
| author | Axel Lin <axel.lin@ingics.com> | 2014-01-09 03:03:58 -0500 |
|---|---|---|
| committer | Mark Brown <broonie@linaro.org> | 2014-01-09 08:54:07 -0500 |
| commit | a89e2d2754246645959f1a2f91e37e9b367bfd36 (patch) | |
| tree | 2be6086e5c7681f2e91cd9b8c57023718a40ee0b | |
| parent | 1cfd97f93e36b3f8b5d2a26147aaccae0c847a9c (diff) | |
spi: core: Use list_first_entry to extract head of queue
For slightly better readability.
Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
| -rw-r--r-- | drivers/spi/spi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c index 401cd66770f9..36bfa7f820a6 100644 --- a/drivers/spi/spi.c +++ b/drivers/spi/spi.c | |||
| @@ -685,7 +685,7 @@ static void spi_pump_messages(struct kthread_work *work) | |||
| 685 | } | 685 | } |
| 686 | /* Extract head of queue */ | 686 | /* Extract head of queue */ |
| 687 | master->cur_msg = | 687 | master->cur_msg = |
| 688 | list_entry(master->queue.next, struct spi_message, queue); | 688 | list_first_entry(&master->queue, struct spi_message, queue); |
| 689 | 689 | ||
| 690 | list_del_init(&master->cur_msg->queue); | 690 | list_del_init(&master->cur_msg->queue); |
| 691 | if (master->busy) | 691 | if (master->busy) |
