提交 635c4efa 编写于 作者: J Jeremiah Mahler 提交者: Greg Kroah-Hartman

staging: dgnc: DGNC_VERIFY_BOARD macro in do while block

Enclose the body of the multi-statement DGNC_VERIFY_BOARD macro inside a
do - while block as per Documentation/CodingStyle.  Fixes 1 error found
by checkpatch.pl.

Cc: Lidza Louina <lidza.louina@gmail.com>
Signed-off-by: NJeremiah Mahler <jmmahler@gmail.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 1d3ade00
......@@ -150,15 +150,17 @@ void dgnc_remove_driver_sysfiles(struct pci_driver *dgnc_driver)
}
#define DGNC_VERIFY_BOARD(p, bd) \
if (!p) \
return 0; \
\
bd = dev_get_drvdata(p); \
if (!bd || bd->magic != DGNC_BOARD_MAGIC) \
return 0; \
if (bd->state != BOARD_READY) \
return 0; \
#define DGNC_VERIFY_BOARD(p, bd) \
do { \
if (!p) \
return 0; \
\
bd = dev_get_drvdata(p); \
if (!bd || bd->magic != DGNC_BOARD_MAGIC) \
return 0; \
if (bd->state != BOARD_READY) \
return 0; \
} while (0)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册