From: Minkyu Kang <mk7.kang@samsung.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v4 1/3] S5P: serial: Use the inline function instead of static value
Date: Mon, 24 Jan 2011 16:33:29 +0900 [thread overview]
Message-ID: <4D3D2B49.9050100@samsung.com> (raw)
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
---
arch/arm/include/asm/arch-s5pc1xx/uart.h | 5 ++++-
drivers/serial/serial_s5p.c | 2 +-
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/arch/arm/include/asm/arch-s5pc1xx/uart.h b/arch/arm/include/asm/arch-s5pc1xx/uart.h
index f6eeab4..1c56739 100644
--- a/arch/arm/include/asm/arch-s5pc1xx/uart.h
+++ b/arch/arm/include/asm/arch-s5pc1xx/uart.h
@@ -48,7 +48,10 @@ struct s5p_uart {
unsigned char res3[0x3d0];
};
-static int use_divslot = 1;
+static inline int s5p_uart_divslot(void)
+{
+ return 1;
+}
#endif /* __ASSEMBLY__ */
diff --git a/drivers/serial/serial_s5p.c b/drivers/serial/serial_s5p.c
index 9c1cbf4..f1ffa29 100644
--- a/drivers/serial/serial_s5p.c
+++ b/drivers/serial/serial_s5p.c
@@ -72,7 +72,7 @@ void serial_setbrg_dev(const int dev_index)
writel(val / 16 - 1, &uart->ubrdiv);
- if (use_divslot)
+ if (s5p_uart_divslot())
writew(udivslot[val % 16], &uart->rest.slot);
else
writeb(val % 16, &uart->rest.value);
--
1.7.1
next reply other threads:[~2011-01-24 7:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-01-24 7:33 Minkyu Kang [this message]
2011-01-27 12:25 ` [U-Boot] [PATCH v4 1/3] S5P: serial: Use the inline function instead of static value Minkyu Kang
2011-01-27 21:33 ` Graeme Russ
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=4D3D2B49.9050100@samsung.com \
--to=mk7.kang@samsung.com \
--cc=u-boot@lists.denx.de \
/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