Commit de593dca authored by Christian Colic's avatar Christian Colic Committed by Greg Kroah-Hartman

staging: fwserial: (coding-style) rewrite comparisons to NULL as "!fifo->data"

Rewrite multiple comparisons to NULL as "!fifo->data"
to fix the last coding style problems of this file.
Signed-off-by: default avatarChristian Colic <colic.christian@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 3dd0af86
...@@ -106,7 +106,7 @@ void dma_fifo_free(struct dma_fifo *fifo) ...@@ -106,7 +106,7 @@ void dma_fifo_free(struct dma_fifo *fifo)
{ {
struct dma_pending *pending, *next; struct dma_pending *pending, *next;
if (fifo->data == NULL) if (!fifo->data)
return; return;
list_for_each_entry_safe(pending, next, &fifo->pending, link) list_for_each_entry_safe(pending, next, &fifo->pending, link)
...@@ -123,7 +123,7 @@ void dma_fifo_reset(struct dma_fifo *fifo) ...@@ -123,7 +123,7 @@ void dma_fifo_reset(struct dma_fifo *fifo)
{ {
struct dma_pending *pending, *next; struct dma_pending *pending, *next;
if (fifo->data == NULL) if (!fifo->data)
return; return;
list_for_each_entry_safe(pending, next, &fifo->pending, link) list_for_each_entry_safe(pending, next, &fifo->pending, link)
...@@ -149,7 +149,7 @@ int dma_fifo_in(struct dma_fifo *fifo, const void *src, int n) ...@@ -149,7 +149,7 @@ int dma_fifo_in(struct dma_fifo *fifo, const void *src, int n)
{ {
int ofs, l; int ofs, l;
if (fifo->data == NULL) if (!fifo->data)
return -ENOENT; return -ENOENT;
if (fifo->corrupt) if (fifo->corrupt)
return -ENXIO; return -ENXIO;
...@@ -192,7 +192,7 @@ int dma_fifo_out_pend(struct dma_fifo *fifo, struct dma_pending *pended) ...@@ -192,7 +192,7 @@ int dma_fifo_out_pend(struct dma_fifo *fifo, struct dma_pending *pended)
{ {
unsigned len, n, ofs, l, limit; unsigned len, n, ofs, l, limit;
if (fifo->data == NULL) if (!fifo->data)
return -ENOENT; return -ENOENT;
if (fifo->corrupt) if (fifo->corrupt)
return -ENXIO; return -ENXIO;
...@@ -252,7 +252,7 @@ int dma_fifo_out_complete(struct dma_fifo *fifo, struct dma_pending *complete) ...@@ -252,7 +252,7 @@ int dma_fifo_out_complete(struct dma_fifo *fifo, struct dma_pending *complete)
{ {
struct dma_pending *pending, *next, *tmp; struct dma_pending *pending, *next, *tmp;
if (fifo->data == NULL) if (!fifo->data)
return -ENOENT; return -ENOENT;
if (fifo->corrupt) if (fifo->corrupt)
return -ENXIO; return -ENXIO;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment