All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rajendra Nayak <rnayak@ti.com>
To: Govindraj <govindraj.ti@gmail.com>
Cc: "Govindraj.R" <govindraj.raja@ti.com>,
	linux-omap@vger.kernel.org, linux-serial@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	Kevin Hilman <khilman@ti.com>, Tony Lindgren <tony@atomide.com>,
	Partha Basak <p-basak2@ti.com>,
	Vishwanath Sripathy <vishwanath.bs@ti.com>,
	Santosh Shilimkar <santosh.shilimkar@ti.com>
Subject: Re: [PATCH v6 02/16] OMAP2+: hwmod: Add API to check IO PAD wakeup status
Date: Mon, 03 Oct 2011 10:53:09 +0530	[thread overview]
Message-ID: <4E8946BD.1010108@ti.com> (raw)
In-Reply-To: <CAAL8m4zLz4kv+nNPKHD6zKG0pdXifXpmWiHnLAyn_bq228qHXA@mail.gmail.com>

On Monday 03 October 2011 10:30 AM, Govindraj wrote:
> Thanks for the review,
>
>
> On Sat, Oct 1, 2011 at 8:03 PM, Rajendra Nayak<rnayak@ti.com>  wrote:
>> On Friday 30 September 2011 04:31 PM, Govindraj.R wrote:
>>>
>>> Add API to determine IO-PAD wakeup event status for a given
>>> hwmod dynamic_mux pad.
>>>
>>> Wake up event set will be cleared on pad mux_read.
>>
>> Are these api's even getting used in this series?
>
> Used in Tero's irq_chaining patches.

So shouldn't this patch be part of his series instead?

>
> http://lkml.org/lkml/2011/9/23/121
>
> --
> Thanks,
> Govindraj.R
>
>
>>
>>>
>>> Signed-off-by: Govindraj.R<govindraj.raja@ti.com>
>>> ---
>>>   arch/arm/mach-omap2/mux.c                    |   30
>>> ++++++++++++++++++++++++++
>>>   arch/arm/mach-omap2/mux.h                    |   13 +++++++++++
>>>   arch/arm/mach-omap2/omap_hwmod.c             |    7 ++++++
>>>   arch/arm/plat-omap/include/plat/omap_hwmod.h |    1 +
>>>   4 files changed, 51 insertions(+), 0 deletions(-)
>>>
>>> diff --git a/arch/arm/mach-omap2/mux.c b/arch/arm/mach-omap2/mux.c
>>> index 655e948..fb75aae 100644
>>> --- a/arch/arm/mach-omap2/mux.c
>>> +++ b/arch/arm/mach-omap2/mux.c
>>> @@ -351,6 +351,36 @@ err1:
>>>         return NULL;
>>>   }
>>>
>>> +/**
>>> + * omap_hwmod_mux_get_wake_status - omap hwmod check pad wakeup
>>> + * @hmux:              Pads for a hwmod
>>> + *
>>> + * Gets the wakeup status of given pad from omap-hwmod.
>>> + * Returns true if wakeup capability is set and wakeup event occurred.
>>> + * Returns false if wakeup event has not occurred or pads are not
>>> available.
>>> + */
>>> +bool omap_hwmod_mux_get_wake_status(struct omap_hwmod_mux_info *hmux)
>>> +{
>>> +       int i;
>>> +       unsigned int val;
>>> +       u8 ret = false;
>>> +
>>> +       for (i = 0; i<    hmux->nr_pads; i++) {
>>> +               struct omap_device_pad *pad =&hmux->pads[i];
>>> +
>>> +               if (pad->flags&    OMAP_DEVICE_PAD_WAKEUP) {
>>> +                       val = omap_mux_read(pad->partition,
>>> +                                       pad->mux->reg_offset);
>>> +                       if (val&    OMAP_WAKEUP_EVENT) {
>>> +                               ret = true;
>>> +                               break;
>>> +                       }
>>> +               }
>>> +       }
>>> +
>>> +       return ret;
>>> +}
>>> +
>>>   /* Assumes the calling function takes care of locking */
>>>   void omap_hwmod_mux(struct omap_hwmod_mux_info *hmux, u8 state)
>>>   {
>>> diff --git a/arch/arm/mach-omap2/mux.h b/arch/arm/mach-omap2/mux.h
>>> index 2132308..8b2150a 100644
>>> --- a/arch/arm/mach-omap2/mux.h
>>> +++ b/arch/arm/mach-omap2/mux.h
>>> @@ -225,8 +225,21 @@ omap_hwmod_mux_init(struct omap_device_pad *bpads,
>>> int nr_pads);
>>>    */
>>>   void omap_hwmod_mux(struct omap_hwmod_mux_info *hmux, u8 state);
>>>
>>> +/**
>>> + * omap_hwmod_mux_get_wake_status - omap hwmod check pad wakeup
>>> + * @hmux:              Pads for a hwmod
>>> + *
>>> + * Called only from omap_hwmod.c, do not use.
>>> + */
>>> +bool omap_hwmod_mux_get_wake_status(struct omap_hwmod_mux_info *hmux);
>>>   #else
>>>
>>> +static inline bool
>>> +omap_hwmod_mux_get_wake_status(struct omap_hwmod_mux_info *hmux)
>>> +{
>>> +       return 0;
>>> +}
>>> +
>>>   static inline int omap_mux_init_gpio(int gpio, int val)
>>>   {
>>>         return 0;
>>> diff --git a/arch/arm/mach-omap2/omap_hwmod.c
>>> b/arch/arm/mach-omap2/omap_hwmod.c
>>> index e751dd9..a8b24d7 100644
>>> --- a/arch/arm/mach-omap2/omap_hwmod.c
>>> +++ b/arch/arm/mach-omap2/omap_hwmod.c
>>> @@ -2724,3 +2724,10 @@ int omap_hwmod_no_setup_reset(struct omap_hwmod
>>> *oh)
>>>
>>>         return 0;
>>>   }
>>> +
>>> +int omap_hwmod_pad_get_wakeup_status(struct omap_hwmod *oh)
>>> +{
>>> +       if (oh&&    oh->mux)
>>> +               return omap_hwmod_mux_get_wake_status(oh->mux);
>>> +       return -EINVAL;
>>> +}
>>> diff --git a/arch/arm/plat-omap/include/plat/omap_hwmod.h
>>> b/arch/arm/plat-omap/include/plat/omap_hwmod.h
>>> index 0e329ca..9a6195c 100644
>>> --- a/arch/arm/plat-omap/include/plat/omap_hwmod.h
>>> +++ b/arch/arm/plat-omap/include/plat/omap_hwmod.h
>>> @@ -607,6 +607,7 @@ u32 omap_hwmod_get_context_loss_count(struct
>>> omap_hwmod *oh);
>>>
>>>   int omap_hwmod_no_setup_reset(struct omap_hwmod *oh);
>>>
>>> +int omap_hwmod_pad_get_wakeup_status(struct omap_hwmod *oh);
>>>   /*
>>>    * Chip variant-specific hwmod init routines - XXX should be converted
>>>    * to use initcalls once the initial boot ordering is straightened out
>>
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-serial" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>


WARNING: multiple messages have this Message-ID (diff)
From: rnayak@ti.com (Rajendra Nayak)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v6 02/16] OMAP2+: hwmod: Add API to check IO PAD wakeup status
Date: Mon, 03 Oct 2011 10:53:09 +0530	[thread overview]
Message-ID: <4E8946BD.1010108@ti.com> (raw)
In-Reply-To: <CAAL8m4zLz4kv+nNPKHD6zKG0pdXifXpmWiHnLAyn_bq228qHXA@mail.gmail.com>

On Monday 03 October 2011 10:30 AM, Govindraj wrote:
> Thanks for the review,
>
>
> On Sat, Oct 1, 2011 at 8:03 PM, Rajendra Nayak<rnayak@ti.com>  wrote:
>> On Friday 30 September 2011 04:31 PM, Govindraj.R wrote:
>>>
>>> Add API to determine IO-PAD wakeup event status for a given
>>> hwmod dynamic_mux pad.
>>>
>>> Wake up event set will be cleared on pad mux_read.
>>
>> Are these api's even getting used in this series?
>
> Used in Tero's irq_chaining patches.

So shouldn't this patch be part of his series instead?

>
> http://lkml.org/lkml/2011/9/23/121
>
> --
> Thanks,
> Govindraj.R
>
>
>>
>>>
>>> Signed-off-by: Govindraj.R<govindraj.raja@ti.com>
>>> ---
>>>   arch/arm/mach-omap2/mux.c                    |   30
>>> ++++++++++++++++++++++++++
>>>   arch/arm/mach-omap2/mux.h                    |   13 +++++++++++
>>>   arch/arm/mach-omap2/omap_hwmod.c             |    7 ++++++
>>>   arch/arm/plat-omap/include/plat/omap_hwmod.h |    1 +
>>>   4 files changed, 51 insertions(+), 0 deletions(-)
>>>
>>> diff --git a/arch/arm/mach-omap2/mux.c b/arch/arm/mach-omap2/mux.c
>>> index 655e948..fb75aae 100644
>>> --- a/arch/arm/mach-omap2/mux.c
>>> +++ b/arch/arm/mach-omap2/mux.c
>>> @@ -351,6 +351,36 @@ err1:
>>>         return NULL;
>>>   }
>>>
>>> +/**
>>> + * omap_hwmod_mux_get_wake_status - omap hwmod check pad wakeup
>>> + * @hmux:              Pads for a hwmod
>>> + *
>>> + * Gets the wakeup status of given pad from omap-hwmod.
>>> + * Returns true if wakeup capability is set and wakeup event occurred.
>>> + * Returns false if wakeup event has not occurred or pads are not
>>> available.
>>> + */
>>> +bool omap_hwmod_mux_get_wake_status(struct omap_hwmod_mux_info *hmux)
>>> +{
>>> +       int i;
>>> +       unsigned int val;
>>> +       u8 ret = false;
>>> +
>>> +       for (i = 0; i<    hmux->nr_pads; i++) {
>>> +               struct omap_device_pad *pad =&hmux->pads[i];
>>> +
>>> +               if (pad->flags&    OMAP_DEVICE_PAD_WAKEUP) {
>>> +                       val = omap_mux_read(pad->partition,
>>> +                                       pad->mux->reg_offset);
>>> +                       if (val&    OMAP_WAKEUP_EVENT) {
>>> +                               ret = true;
>>> +                               break;
>>> +                       }
>>> +               }
>>> +       }
>>> +
>>> +       return ret;
>>> +}
>>> +
>>>   /* Assumes the calling function takes care of locking */
>>>   void omap_hwmod_mux(struct omap_hwmod_mux_info *hmux, u8 state)
>>>   {
>>> diff --git a/arch/arm/mach-omap2/mux.h b/arch/arm/mach-omap2/mux.h
>>> index 2132308..8b2150a 100644
>>> --- a/arch/arm/mach-omap2/mux.h
>>> +++ b/arch/arm/mach-omap2/mux.h
>>> @@ -225,8 +225,21 @@ omap_hwmod_mux_init(struct omap_device_pad *bpads,
>>> int nr_pads);
>>>    */
>>>   void omap_hwmod_mux(struct omap_hwmod_mux_info *hmux, u8 state);
>>>
>>> +/**
>>> + * omap_hwmod_mux_get_wake_status - omap hwmod check pad wakeup
>>> + * @hmux:              Pads for a hwmod
>>> + *
>>> + * Called only from omap_hwmod.c, do not use.
>>> + */
>>> +bool omap_hwmod_mux_get_wake_status(struct omap_hwmod_mux_info *hmux);
>>>   #else
>>>
>>> +static inline bool
>>> +omap_hwmod_mux_get_wake_status(struct omap_hwmod_mux_info *hmux)
>>> +{
>>> +       return 0;
>>> +}
>>> +
>>>   static inline int omap_mux_init_gpio(int gpio, int val)
>>>   {
>>>         return 0;
>>> diff --git a/arch/arm/mach-omap2/omap_hwmod.c
>>> b/arch/arm/mach-omap2/omap_hwmod.c
>>> index e751dd9..a8b24d7 100644
>>> --- a/arch/arm/mach-omap2/omap_hwmod.c
>>> +++ b/arch/arm/mach-omap2/omap_hwmod.c
>>> @@ -2724,3 +2724,10 @@ int omap_hwmod_no_setup_reset(struct omap_hwmod
>>> *oh)
>>>
>>>         return 0;
>>>   }
>>> +
>>> +int omap_hwmod_pad_get_wakeup_status(struct omap_hwmod *oh)
>>> +{
>>> +       if (oh&&    oh->mux)
>>> +               return omap_hwmod_mux_get_wake_status(oh->mux);
>>> +       return -EINVAL;
>>> +}
>>> diff --git a/arch/arm/plat-omap/include/plat/omap_hwmod.h
>>> b/arch/arm/plat-omap/include/plat/omap_hwmod.h
>>> index 0e329ca..9a6195c 100644
>>> --- a/arch/arm/plat-omap/include/plat/omap_hwmod.h
>>> +++ b/arch/arm/plat-omap/include/plat/omap_hwmod.h
>>> @@ -607,6 +607,7 @@ u32 omap_hwmod_get_context_loss_count(struct
>>> omap_hwmod *oh);
>>>
>>>   int omap_hwmod_no_setup_reset(struct omap_hwmod *oh);
>>>
>>> +int omap_hwmod_pad_get_wakeup_status(struct omap_hwmod *oh);
>>>   /*
>>>    * Chip variant-specific hwmod init routines - XXX should be converted
>>>    * to use initcalls once the initial boot ordering is straightened out
>>
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-serial" in
>> the body of a message to majordomo at vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>

  reply	other threads:[~2011-10-03  5:23 UTC|newest]

Thread overview: 82+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-30 11:01 [PATCH v6 01/16] OMAP2+: hwmod: Add API to enable IO ring wakeup Govindraj.R
2011-09-30 11:01 ` Govindraj.R
2011-09-30 11:01 ` [PATCH v6 02/16] OMAP2+: hwmod: Add API to check IO PAD wakeup status Govindraj.R
2011-09-30 11:01   ` Govindraj.R
2011-10-01 14:33   ` Rajendra Nayak
2011-10-01 14:33     ` Rajendra Nayak
2011-10-03  5:00     ` Govindraj
2011-10-03  5:00       ` Govindraj
2011-10-03  5:23       ` Rajendra Nayak [this message]
2011-10-03  5:23         ` Rajendra Nayak
2011-10-03  5:56         ` Govindraj
2011-10-03  5:56           ` Govindraj
2011-10-10 22:24           ` Kevin Hilman
2011-10-10 22:24             ` Kevin Hilman
2011-10-11  6:17             ` Govindraj
2011-10-11  6:17               ` Govindraj
2011-09-30 11:01 ` [PATCH v6 03/16] OMAP2+: UART: cleanup + remove uart pm specific API Govindraj.R
2011-09-30 11:01   ` Govindraj.R
2011-09-30 11:01 ` [PATCH v6 04/16] OMAP2+: UART: cleanup 8250 console driver support Govindraj.R
2011-09-30 11:01   ` Govindraj.R
2011-10-04 21:42   ` Kevin Hilman
2011-10-04 21:42     ` Kevin Hilman
2011-10-05  6:54     ` Govindraj
2011-10-05  6:54       ` Govindraj
2011-10-05 18:42       ` Kevin Hilman
2011-10-05 18:42         ` Kevin Hilman
2011-10-06  8:16         ` Govindraj
2011-10-06  8:16           ` Govindraj
2011-09-30 11:01 ` [PATCH v6 05/16] OMAP2+: UART: Cleanup part of clock gating mechanism for uart Govindraj.R
2011-09-30 11:01   ` Govindraj.R
2011-10-10 22:30   ` Kevin Hilman
2011-10-10 22:30     ` Kevin Hilman
2011-10-11  6:45     ` Govindraj
2011-10-11  6:45       ` Govindraj
2011-09-30 11:01 ` [PATCH v6 06/16] OMAP2+: UART: Remove certain feilds from omap_uart_state struct Govindraj.R
2011-09-30 11:01   ` Govindraj.R
2011-10-10 23:31   ` Kevin Hilman
2011-10-10 23:31     ` Kevin Hilman
2011-10-12 10:25     ` Govindraj
2011-10-12 10:25       ` Govindraj
2011-09-30 11:01 ` [PATCH v6 07/16] OMAP2+: UART: Add default mux for all uarts Govindraj.R
2011-09-30 11:01   ` Govindraj.R
2011-10-05 19:04   ` Kevin Hilman
2011-10-05 19:04     ` Kevin Hilman
2011-10-06  8:21     ` Govindraj
2011-10-06  8:21       ` Govindraj
2011-09-30 11:01 ` [PATCH v6 08/16] OMAP2+: UART: Store certain reg values to port structure Govindraj.R
2011-09-30 11:01   ` Govindraj.R
2011-10-10 23:58   ` Kevin Hilman
2011-10-10 23:58     ` Kevin Hilman
2011-10-11 13:21     ` Govindraj
2011-10-11 13:21       ` Govindraj
2011-09-30 11:01 ` [PATCH v6 09/16] OMAP2+: UART: Add runtime pm support for omap-serial driver Govindraj.R
2011-09-30 11:01   ` Govindraj.R
2011-10-10 23:42   ` Kevin Hilman
2011-10-10 23:42     ` Kevin Hilman
2011-10-12 10:37     ` Govindraj
2011-10-12 10:37       ` Govindraj
2011-10-10 23:56   ` Kevin Hilman
2011-10-10 23:56     ` Kevin Hilman
2011-10-12 10:35     ` Govindraj
2011-10-12 10:35       ` Govindraj
2011-10-13  0:06   ` Kevin Hilman
2011-10-13  0:06     ` Kevin Hilman
2011-10-13  1:28     ` Govindraj
2011-10-13  1:28       ` Govindraj
2011-10-13 21:22       ` Kevin Hilman
2011-10-13 21:22         ` Kevin Hilman
2011-10-14 12:32         ` Govindraj
2011-10-14 12:32           ` Govindraj
2011-10-14 17:04           ` Kevin Hilman
2011-10-14 17:04             ` Kevin Hilman
2011-10-14 18:29             ` Govindraj
2011-10-14 18:29               ` Govindraj
2011-10-01 13:41 ` [PATCH v6 01/16] OMAP2+: hwmod: Add API to enable IO ring wakeup Rajendra Nayak
2011-10-01 13:41   ` Rajendra Nayak
2011-10-03 15:10   ` Vishwanath Sripathy
2011-10-03 15:10     ` Vishwanath Sripathy
2011-10-04 21:03   ` Kevin Hilman
2011-10-04 21:03     ` Kevin Hilman
2011-10-05 11:57     ` Rajendra Nayak
2011-10-05 11:57       ` Rajendra Nayak

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=4E8946BD.1010108@ti.com \
    --to=rnayak@ti.com \
    --cc=govindraj.raja@ti.com \
    --cc=govindraj.ti@gmail.com \
    --cc=khilman@ti.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=p-basak2@ti.com \
    --cc=santosh.shilimkar@ti.com \
    --cc=tony@atomide.com \
    --cc=vishwanath.bs@ti.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.