All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Staging: media: Enclose macro in a do - while loop
@ 2015-02-19  9:34 Vatika Harlalka
  0 siblings, 0 replies; only message in thread
From: Vatika Harlalka @ 2015-02-19  9:34 UTC (permalink / raw)
  To: outreachy-kernel

This patch is to enclose a multi line macro in a do - while loop.

Signed-off-by: Vatika Harlalka <vatikaharlalka@gmail.com>
---
 drivers/staging/media/bcm2048/radio-bcm2048.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/media/bcm2048/radio-bcm2048.c b/drivers/staging/media/bcm2048/radio-bcm2048.c
index 60a57b2..acd2088 100644
--- a/drivers/staging/media/bcm2048/radio-bcm2048.c
+++ b/drivers/staging/media/bcm2048/radio-bcm2048.c
@@ -2019,8 +2019,10 @@ static ssize_t bcm2048_##prop##_read(struct device *dev,		\
 }
 
 #define DEFINE_SYSFS_PROPERTY(prop, signal, size, mask, check)		\
-property_write(prop, signal size, mask, check)				\
-property_read(prop, size, mask)
+do {									\
+	property_write(prop, signal size, mask, check)			\
+	property_read(prop, size, mask)					\
+} while (0)
 
 #define property_str_read(prop, size)					\
 static ssize_t bcm2048_##prop##_read(struct device *dev,		\
-- 
1.9.1



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2015-02-19  9:34 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-19  9:34 [PATCH] Staging: media: Enclose macro in a do - while loop Vatika Harlalka

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.