From: Vatika Harlalka <vatikaharlalka@gmail.com>
To: outreachy-kernel@googlegroups.com
Subject: [PATCH] Staging: media: Enclose macro in a do - while loop
Date: Thu, 19 Feb 2015 15:04:27 +0530 [thread overview]
Message-ID: <20150219093427.GA28027@gmail.com> (raw)
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
reply other threads:[~2015-02-19 9:34 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150219093427.GA28027@gmail.com \
--to=vatikaharlalka@gmail.com \
--cc=outreachy-kernel@googlegroups.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.