public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
From: rnayak@ti.com (Rajendra Nayak)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: OMAP: hwmod: Fix error handling in functions used OMAP4 onwards
Date: Thu, 29 Mar 2012 11:42:34 +0530	[thread overview]
Message-ID: <4F73FD52.60209@ti.com> (raw)
In-Reply-To: <79CD15C6BA57404B839C016229A409A83183E0CE@DBDE01.ent.ti.com>

On Wednesday 28 March 2012 12:02 PM, Hiremath, Vaibhav wrote:
> On Tue, Mar 27, 2012 at 15:28:31, Nayak, Rajendra wrote:
>> Some functions like _omap4_disable_module() and _omap4_wait_target_disable()
>> are (will be) used on all OMAPs OMAP4 and beyond which support module level
>> control. Fix the error checks in these functions to return if called on
>> any platform pre OMAP4 (i.e OMAP2 and OMAP3) instead of checking for
>> !cpu_is_omap44xx(). This avoids having to update the error check with a
>> '&&  !cpu_is_omap54xx()' when OMAP5 is introduced and possibly similar updates
>> when further OMAP generations are added.
>>
>
> Let me add some flavor here :)
>
> AM33xx, which has module level control, but falls under OMAP3 family of
> devices. cpu_is_omap34xx() is true for AM33xx device and we have to add
> check in all these functions. And I am sure we will have many of such
> devices in the future.
>
> Can we use some flag based option here, instead of cpu_is_xxx() check?
>

The intent of this patch was to make the error handling uniform across
all modules control functions in hwmod, and it atleast addresses one
problem of having to update these checks every time a new OMAP gets
added.

The problem that you bring up with AM33xx is regardless of this patch
(you would still need to go update every !cpu_is_omap44xx() check)
and IMHO should be handled separately, with a flag like you are
suggesting or by some other means. If you already have patches on how
this can be done, you should go ahead and post them out.

  reply	other threads:[~2012-03-29  6:12 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-27  9:58 [PATCH] ARM: OMAP: hwmod: Fix error handling in functions used OMAP4 onwards Rajendra Nayak
2012-03-27 19:52 ` Jon Hunter
2012-03-28  2:39   ` Paul Walmsley
2012-03-28 16:36     ` Jon Hunter
2012-03-28  6:32 ` Hiremath, Vaibhav
2012-03-29  6:12   ` Rajendra Nayak [this message]
2012-03-29  8:56     ` Hiremath, Vaibhav
2012-03-29  9:02       ` Rajendra Nayak
2012-03-29  9:14         ` Hiremath, Vaibhav
2012-03-29 15:01           ` Jon Hunter
2012-03-29 15:03       ` Jon Hunter
2012-03-30  7:14         ` Hiremath, Vaibhav

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=4F73FD52.60209@ti.com \
    --to=rnayak@ti.com \
    --cc=linux-arm-kernel@lists.infradead.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