From: Kevin Hilman <khilman@deeprootsystems.com>
To: "Govindraj.R" <govindraj.raja@ti.com>
Cc: linux-omap@vger.kernel.org
Subject: Re: [pm-wip/uart][PATCH 0/5 v2] Serial HWMOD updation and uart4 support for 3630
Date: Thu, 17 Jun 2010 17:05:21 -0700 [thread overview]
Message-ID: <87d3vpciim.fsf@deeprootsystems.com> (raw)
In-Reply-To: <2134.10.24.255.18.1276697618.squirrel@dbdmail.itg.ti.com> (Govindraj R.'s message of "Wed\, 16 Jun 2010 19\:43\:38 +0530 \(IST\)")
"Govindraj.R" <govindraj.raja@ti.com> writes:
> Changes from v1:
> * Incorporated : OMAP clock: Add uart4_ick/fck definitions for 3630
> * using omap_mux_request_signal to retreive padconf offset
> as per Tony's comments.
> http://marc.info/?l=linux-omap&m=127609369220618&w=2
> This patch series as a dependecy on the patch
> for "omap_mux_request_signal" posted earlier
> https://patchwork.kernel.org/patch/105962/
> * Clean up certain comments.
> http://www.mail-archive.com/linux-omap@vger.kernel.org/msg30348.html
>
> Patch series is based on remotes/origin/pm-wip/uart
> branch from Kevin's PM tree.
>
> 1.) Add support for UART4 for 3630.
> 2.) Modify Serial hwmod to avoid hwmod lookup using name string.
>
> Govindraj.R (5):
> OMAP clock: Add uart4_ick/fck definitions for 3630
> OMAP3: PRCM: Consider UART4 for 3630 chip in prcm_setup_regs
> OMAP3: serial: Fix uart4 handling for 3630
> OMAP3: PM: Add prepare idle and resume idle call for uart4
> Serial: Avoid using hwmod lookup using name string.
Govindraj,
Can you add this one to your series and test it on your boards?
Kevin
>From f63426a68cd4048e6a09e5aed2b101b7cb2ef141 Mon Sep 17 00:00:00 2001
From: Kevin Hilman <khilman@deeprootsystems.com>
Date: Thu, 17 Jun 2010 16:59:10 -0700
Subject: [PATCH] OMAP: UART: separate list of detected UARTs from registered UARTs
Use separate lists to track detected UARTs (available hwmods) and
registered UARTs (ones activated via board code.)
The hwmod_list is populated as soon as the UART hwmods are detected,
but the uart_list is only populated when a UART is registered via
board code. This ensures that the various PM operaions are done only
on UARTs registered via board code.
This is particularily useful for boards where no OMAP UARTs are
registered (Zoom3). Since all the PM operations only need to be done
on registered UARTs, when none are registered, these functions do
nothing as the list iteratates on an empty list.
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
---
arch/arm/mach-omap2/serial.c | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/arch/arm/mach-omap2/serial.c b/arch/arm/mach-omap2/serial.c
index 2ab8f25..37cc28e 100644
--- a/arch/arm/mach-omap2/serial.c
+++ b/arch/arm/mach-omap2/serial.c
@@ -98,7 +98,9 @@ struct omap_uart_state {
#endif
};
-static LIST_HEAD(uart_list);
+static LIST_HEAD(hwmod_list); /* list of detected UART hwmods */
+static LIST_HEAD(uart_list); /* list of initialized UARTs */
+
static u8 num_uarts;
static struct omap_device_pm_latency omap_uart_latency[] = {
@@ -612,7 +614,7 @@ static int omap_serial_port_init(struct omap_hwmod *oh, void *user)
uart->oh = oh;
uart->num = i++;
- list_add_tail(&uart->node, &uart_list);
+ list_add_tail(&uart->node, &hwmod_list);
num_uarts++;
/*
@@ -676,7 +678,7 @@ void __init omap_serial_init_port(int port)
if (WARN_ON(port >= num_uarts))
return;
- list_for_each_entry(uart, &uart_list, node)
+ list_for_each_entry(uart, &hwmod_list, node)
if (port == uart->num)
break;
@@ -789,6 +791,8 @@ void __init omap_serial_init_port(int port)
device_init_wakeup(&od->pdev.dev, true);
DEV_CREATE_FILE(&od->pdev.dev, &dev_attr_sleep_timeout);
}
+
+ list_add_tail(&uart->node, &uart_list);
}
/**
--
1.7.0.2
next prev parent reply other threads:[~2010-06-18 0:05 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-16 14:13 [pm-wip/uart][PATCH 0/5 v2] Serial HWMOD updation and uart4 support for 3630 Govindraj.R
2010-06-18 0:05 ` Kevin Hilman [this message]
2010-06-18 18:23 ` Kevin Hilman
2010-06-22 14:23 ` Govindraj
2010-06-22 14:49 ` Kevin Hilman
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=87d3vpciim.fsf@deeprootsystems.com \
--to=khilman@deeprootsystems.com \
--cc=govindraj.raja@ti.com \
--cc=linux-omap@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