Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1371771 > unrolled thread
| Started by | Nicholas Sim <nicholassimws@gmail.com> |
|---|---|
| First post | 2016-04-05 18:30 +0200 |
| Last post | 2016-04-06 14:40 +0200 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH] staging: rts5208: ensure braces on all arms of if stmt Nicholas Sim <nicholassimws@gmail.com> - 2016-04-05 18:30 +0200
Re: [PATCH] staging: rts5208: ensure braces on all arms of if stmt Dan Carpenter <dan.carpenter@oracle.com> - 2016-04-06 14:40 +0200
| From | Nicholas Sim <nicholassimws@gmail.com> |
|---|---|
| Date | 2016-04-05 18:30 +0200 |
| Subject | [PATCH] staging: rts5208: ensure braces on all arms of if stmt |
| Message-ID | <rkC1C-6PL-51@gated-at.bofh.it> |
Added braces on if arm of if statement where else arm already needs braces
as suggested for clarity in Documentation/CodingStyle
Signed-off-by: Nicholas Sim <nicholassimws@gmail.com>
---
drivers/staging/rts5208/ms.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/staging/rts5208/ms.c b/drivers/staging/rts5208/ms.c
index 3e75db7..2ad4ea0 100644
--- a/drivers/staging/rts5208/ms.c
+++ b/drivers/staging/rts5208/ms.c
@@ -794,8 +794,9 @@ static int ms_confirm_cpu_startup(struct rtsx_chip *chip)
}
if (val & INT_REG_ERR) {
- if (val & INT_REG_CMDNK)
+ if (val & INT_REG_CMDNK) {
chip->card_wp |= (MS_CARD);
+ }
else {
rtsx_trace(chip);
return STATUS_FAIL;
--
2.4.3
[toc] | [next] | [standalone]
| From | Dan Carpenter <dan.carpenter@oracle.com> |
|---|---|
| Date | 2016-04-06 14:40 +0200 |
| Message-ID | <rkUUy-3Mo-23@gated-at.bofh.it> |
| In reply to | #1371771 |
On Tue, Apr 05, 2016 at 05:29:17PM +0100, Nicholas Sim wrote:
> Added braces on if arm of if statement where else arm already needs braces
> as suggested for clarity in Documentation/CodingStyle
>
> Signed-off-by: Nicholas Sim <nicholassimws@gmail.com>
> ---
> drivers/staging/rts5208/ms.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/staging/rts5208/ms.c b/drivers/staging/rts5208/ms.c
> index 3e75db7..2ad4ea0 100644
> --- a/drivers/staging/rts5208/ms.c
> +++ b/drivers/staging/rts5208/ms.c
> @@ -794,8 +794,9 @@ static int ms_confirm_cpu_startup(struct rtsx_chip *chip)
> }
>
> if (val & INT_REG_ERR) {
> - if (val & INT_REG_CMDNK)
> + if (val & INT_REG_CMDNK) {
> chip->card_wp |= (MS_CARD);
> + }
> else {
It should be } else { on one line.
regards,
dan carpenter
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web