From: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
To: kgene.kim@samsung.com, linux-samsung-soc@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org
Cc: gregkh@linuxfoundation.org, ben-linux@fluff.org, cpgs@samsung.com
Subject: [PATCH 2/3] serial: samsung: correct the case and default order in switch
Date: Mon, 14 Jul 2014 17:07:17 +0530 [thread overview]
Message-ID: <1405337838-30335-3-git-send-email-ch.naveen@samsung.com> (raw)
In-Reply-To: <1405337838-30335-1-git-send-email-ch.naveen@samsung.com>
The cases should comes before default in a switch.
Even if we want the case and default to share same code.
Its good to define the case first followed by default.
Signed-off-by: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
Cc: gregkh@linuxfoundation.org
---
drivers/tty/serial/samsung.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/tty/serial/samsung.c b/drivers/tty/serial/samsung.c
index e49a945..d98f93d 100644
--- a/drivers/tty/serial/samsung.c
+++ b/drivers/tty/serial/samsung.c
@@ -1542,8 +1542,8 @@ s3c24xx_serial_get_options(struct uart_port *port, int *baud,
case S3C2410_LCON_CS7:
*bits = 7;
break;
- default:
case S3C2410_LCON_CS8:
+ default:
*bits = 8;
break;
}
--
1.7.9.5
next prev parent reply other threads:[~2014-07-14 11:37 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-14 11:37 [PATCH 0/3] serial: samsung: get fifosize from DT and clean up Naveen Krishna Chatradhi
2014-07-14 11:37 ` [PATCH 1/3] serial: samsung: get fifosize via device tree Naveen Krishna Chatradhi
2014-07-14 11:37 ` Naveen Krishna Chatradhi [this message]
2014-07-14 11:37 ` [PATCH 3/3] serial: samsung: improve code clarity by defining a variable Naveen Krishna Chatradhi
2014-07-16 12:02 ` [PATCH 0/3] serial: samsung: get fifosize from DT and clean up Tomasz Figa
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=1405337838-30335-3-git-send-email-ch.naveen@samsung.com \
--to=ch.naveen@samsung.com \
--cc=ben-linux@fluff.org \
--cc=cpgs@samsung.com \
--cc=devicetree@vger.kernel.org \
--cc=gregkh@linuxfoundation.org \
--cc=kgene.kim@samsung.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-samsung-soc@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).