All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Koul, Vinod" <vinod.koul@intel.com>
To: Viresh Kumar <viresh.kumar@st.com>
Cc: dan.j.williams@intel.com, linus.walleij@linaro.org,
	armando.visconti@st.com, shiraz.hashim@st.com,
	viresh.linux@gmail.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] dw_dmac: Replace subsys_init() with arch_initcall()
Date: Mon, 16 May 2011 21:36:33 +0530	[thread overview]
Message-ID: <1305561993.28926.73.camel@vkoul-udesk3> (raw)
In-Reply-To: <f06f05e982c6182565a7fee1f7d6396cae895133.1305521318.git.viresh.kumar@st.com>

On Mon, 2011-05-16 at 10:20 +0530, Viresh Kumar wrote:
> In some cases users of dw_dmac, amba-pl022, are initialized before dw_dmac, and
> if they try to use dw_dmac, they simply fail. So its better we register init()
> routine of driver using arch_initcall() instead of subsys_init(), so that dma
> driver is available at the earliest possible.
> 
> Signed-off-by: Viresh Kumar <viresh.kumar@st.com>
> ---
>  drivers/dma/dw_dmac.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/dma/dw_dmac.c b/drivers/dma/dw_dmac.c
> index 54d72a8..4b580e7 100644
> --- a/drivers/dma/dw_dmac.c
> +++ b/drivers/dma/dw_dmac.c
> @@ -1566,7 +1566,7 @@ static int __init dw_init(void)
>  {
>  	return platform_driver_probe(&dw_driver, dw_probe);
>  }
> -subsys_initcall(dw_init);
> +arch_initcall(dw_init);
arch_init is usually kept for subystem initialization.
Why cant you move the amba-pl022 init to module_init, that should take
care of this.

-- 
~Vinod


  reply	other threads:[~2011-05-16 16:39 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-16  4:50 [PATCH] dw_dmac: Replace subsys_init() with arch_initcall() Viresh Kumar
2011-05-16 16:06 ` Koul, Vinod [this message]
2011-05-17  4:06   ` viresh kumar
2011-05-17  3:43     ` Koul, Vinod
2011-05-17  5:54       ` viresh kumar
2011-05-18 12:21         ` Linus Walleij
2011-05-19  5:21           ` viresh kumar
2011-05-19 11:23             ` Koul, Vinod
2011-05-20  3:44               ` viresh kumar

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=1305561993.28926.73.camel@vkoul-udesk3 \
    --to=vinod.koul@intel.com \
    --cc=armando.visconti@st.com \
    --cc=dan.j.williams@intel.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=shiraz.hashim@st.com \
    --cc=viresh.kumar@st.com \
    --cc=viresh.linux@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 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.