diff options
author | Shayenne da Luz Moura <shayenneluzmoura@gmail.com> | 2018-10-26 22:22:55 +0300 |
---|---|---|
committer | Gerd Hoffmann <kraxel@redhat.com> | 2018-10-30 09:19:59 +0300 |
commit | 408799eb4ad46b8ae26da41be10e8678b3a40ec6 (patch) | |
tree | da50182a268833526dc5d25e816d03253da5c9f7 /drivers/gpu/drm/qxl/qxl_cmd.c | |
parent | 6ed00154cb4d5d8c159c806615b08c6072a48337 (diff) | |
download | linux-408799eb4ad46b8ae26da41be10e8678b3a40ec6.tar.xz |
drm/qxl: Add line after variable declarations
Add whiteline after variable declarations to remove the checkpath.pl
warning:
WARNING: Missing a blank line after declarations
Signed-off-by: Shayenne da Luz Moura <shayenneluzmoura@gmail.com>
Link: http://patchwork.freedesktop.org/patch/msgid/a1d44c4a30f9b52d0aa7113e4e5093e843f9913b.1540579956.git.shayenneluzmoura@gmail.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/qxl/qxl_cmd.c')
-rw-r--r-- | drivers/gpu/drm/qxl/qxl_cmd.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/qxl/qxl_cmd.c b/drivers/gpu/drm/qxl/qxl_cmd.c index 208af9f37914..25ec8e6544ee 100644 --- a/drivers/gpu/drm/qxl/qxl_cmd.c +++ b/drivers/gpu/drm/qxl/qxl_cmd.c @@ -84,6 +84,7 @@ static int qxl_check_header(struct qxl_ring *ring) int ret; struct qxl_ring_header *header = &(ring->ring->header); unsigned long flags; + spin_lock_irqsave(&ring->lock, flags); ret = header->prod - header->cons < header->num_items; if (ret == 0) @@ -97,6 +98,7 @@ int qxl_check_idle(struct qxl_ring *ring) int ret; struct qxl_ring_header *header = &(ring->ring->header); unsigned long flags; + spin_lock_irqsave(&ring->lock, flags); ret = header->prod == header->cons; spin_unlock_irqrestore(&ring->lock, flags); @@ -110,6 +112,7 @@ int qxl_ring_push(struct qxl_ring *ring, uint8_t *elt; int idx, ret; unsigned long flags; + spin_lock_irqsave(&ring->lock, flags); if (header->prod - header->cons == header->num_items) { header->notify_on_cons = header->cons + 1; @@ -156,6 +159,7 @@ static bool qxl_ring_pop(struct qxl_ring *ring, volatile uint8_t *ring_elt; int idx; unsigned long flags; + spin_lock_irqsave(&ring->lock, flags); if (header->cons == header->prod) { header->notify_on_prod = header->cons + 1; |