From: Feng Tang <feng.tang@intel.com>
To: linux-serial@vger.kernel.org, gregkh@linuxfoundation.org,
alan@linux.intel.com, tomoya.rohm@gmail.com
Cc: Feng Tang <feng.tang@intel.com>
Subject: [PATCH 3/3] serial: pch_uart: trivail cleanup by removing the pch_uart_hal_request()
Date: Mon, 6 Feb 2012 17:24:45 +0800 [thread overview]
Message-ID: <1328520285-10826-3-git-send-email-feng.tang@intel.com> (raw)
In-Reply-To: <1328520285-10826-1-git-send-email-feng.tang@intel.com>
pch_uart_hal_request() has parameters which it never uses, also
it is very short, so merge it with its caller to make code cleaner.
No functional changes at all.
Signed-off-by: Feng Tang <feng.tang@intel.com>
---
drivers/tty/serial/pch_uart.c | 16 +++-------------
1 files changed, 3 insertions(+), 13 deletions(-)
diff --git a/drivers/tty/serial/pch_uart.c b/drivers/tty/serial/pch_uart.c
index 811edcb..aa4d07b 100644
--- a/drivers/tty/serial/pch_uart.c
+++ b/drivers/tty/serial/pch_uart.c
@@ -364,15 +364,6 @@ static const struct file_operations port_regs_ops = {
};
#endif /* CONFIG_DEBUG_FS */
-static void pch_uart_hal_request(struct pci_dev *pdev, int fifosize,
- int base_baud)
-{
- struct eg20t_port *priv = pci_get_drvdata(pdev);
-
- priv->trigger_level = 1;
- priv->fcr = 0;
-}
-
static void pch_uart_hal_enable_interrupt(struct eg20t_port *priv,
unsigned int flag)
{
@@ -1674,7 +1665,8 @@ static struct eg20t_port *pch_uart_init_port(struct pci_dev *pdev,
spin_lock_init(&priv->port.lock);
pci_set_drvdata(pdev, priv);
- pch_uart_hal_request(pdev, fifosize, base_baud);
+ priv->trigger_level = 1;
+ priv->fcr = 0;
#ifdef CONFIG_SERIAL_PCH_UART_CONSOLE
pch_uart_ports[board->line_no] = priv;
@@ -1717,9 +1709,7 @@ static void pch_uart_exit_port(struct eg20t_port *priv)
static void pch_uart_pci_remove(struct pci_dev *pdev)
{
- struct eg20t_port *priv;
-
- priv = (struct eg20t_port *)pci_get_drvdata(pdev);
+ struct eg20t_port *priv = pci_get_drvdata(pdev);
pci_disable_msi(pdev);
--
1.7.1
prev parent reply other threads:[~2012-02-06 9:25 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-06 9:24 [PATCH 1/3] serial: pch_uart: add debugfs hook for register dump Feng Tang
2012-02-06 9:24 ` [PATCH 2/3] serial: pch_uart: trivial cleanup by removing the get_msr() Feng Tang
2012-02-06 9:24 ` Feng Tang [this message]
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=1328520285-10826-3-git-send-email-feng.tang@intel.com \
--to=feng.tang@intel.com \
--cc=alan@linux.intel.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-serial@vger.kernel.org \
--cc=tomoya.rohm@gmail.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 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).