All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tony Lindgren <tony@atomide.com>
To: Felipe Balbi <felipe.balbi@nokia.com>
Cc: linux-omap@vger.kernel.org, "Jouni Högander" <jouni.hogander@nokia.com>
Subject: Re: [PATCH] USB: MUSB: Better sysconf reg settings on PM point of view
Date: Fri, 2 May 2008 15:57:00 -0700	[thread overview]
Message-ID: <20080502225659.GU8981@atomide.com> (raw)
In-Reply-To: <1209467151-24972-1-git-send-email-felipe.balbi@nokia.com>

* Felipe Balbi <felipe.balbi@nokia.com> [080429 04:08]:
> The following patch is needed because usb is preventing core
> powerdomain to enter sleep state.
> 
> Thanks to Jouni Högander for pointing this

Pushing today.

FYI, I'm putting together patches to get rid of the __REG32 and
__REG16 macros in order to get multi-omap booting working between
926, arm11, and cortex using the same kernel.

The __REG macros won't work for multi-omap when the IO
bases are different as these macros cannot be replaced by
functions in io.c.

Tony


> Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
> Signed-off-by: Jouni Högander <jouni.hogander@nokia.com>
> ---
>  drivers/usb/musb/omap2430.c |   23 ++++++++++++-----------
>  1 files changed, 12 insertions(+), 11 deletions(-)
> 
> diff --git a/drivers/usb/musb/omap2430.c b/drivers/usb/musb/omap2430.c
> index e092393..36f1739 100644
> --- a/drivers/usb/musb/omap2430.c
> +++ b/drivers/usb/musb/omap2430.c
> @@ -224,6 +224,14 @@ int __init musb_platform_init(struct musb *musb)
>  	musb->xceiv = *xceiv;
>  	musb_platform_resume(musb);
>  
> +	OTG_SYSCONFIG_REG &= ~ENABLEWAKEUP;	/* disable wakeup */
> +	OTG_SYSCONFIG_REG &= ~NOSTDBY;		/* remove possible nostdby */
> +	OTG_SYSCONFIG_REG |= SMARTSTDBY;	/* enable smart standby */
> +	OTG_SYSCONFIG_REG &= ~AUTOIDLE;		/* disable auto idle */
> +	OTG_SYSCONFIG_REG &= ~NOIDLE;		/* remove possible noidle */
> +	OTG_SYSCONFIG_REG |= SMARTIDLE;		/* enable smart idle */
> +	OTG_SYSCONFIG_REG |= AUTOIDLE;		/* enable auto idle */
> +
>  	OTG_INTERFSEL_REG |= ULPI_12PIN;
>  
>  	pr_debug("HS USB OTG: revision 0x%x, sysconfig 0x%02x, "
> @@ -250,12 +258,8 @@ int musb_platform_suspend(struct musb *musb)
>  		return 0;
>  
>  	/* in any role */
> -	OTG_FORCESTDBY_REG &= ~ENABLEFORCE; /* disable MSTANDBY */
> -	OTG_SYSCONFIG_REG &= FORCESTDBY;	/* enable force standby */
> -	OTG_SYSCONFIG_REG &= ~AUTOIDLE;		/* disable auto idle */
> -	OTG_SYSCONFIG_REG |= SMARTIDLE;		/* enable smart idle */
> -	OTG_FORCESTDBY_REG |= ENABLEFORCE; /* enable MSTANDBY */
> -	OTG_SYSCONFIG_REG |= AUTOIDLE;		/* enable auto idle */
> +	OTG_FORCESTDBY_REG |= ENABLEFORCE;	/* enable MSTANDBY */
> +	OTG_SYSCONFIG_REG |= ENABLEWAKEUP;	/* enable wakeup */
>  
>  	if (musb->xceiv.set_suspend)
>  		musb->xceiv.set_suspend(&musb->xceiv, 1);
> @@ -281,11 +285,8 @@ int musb_platform_resume(struct musb *musb)
>  	else
>  		clk_enable(musb->clock);
>  
> -	OTG_FORCESTDBY_REG &= ~ENABLEFORCE; /* disable MSTANDBY */
> -	OTG_SYSCONFIG_REG |= SMARTSTDBY;	/* enable smart standby */
> -	OTG_SYSCONFIG_REG &= ~AUTOIDLE;		/* disable auto idle */
> -	OTG_SYSCONFIG_REG |= SMARTIDLE;		/* enable smart idle */
> -	OTG_SYSCONFIG_REG |= AUTOIDLE;		/* enable auto idle */
> +	OTG_SYSCONFIG_REG &= ~ENABLEWAKEUP;	/* disable wakeup */
> +	OTG_FORCESTDBY_REG &= ~ENABLEFORCE;	/* disable MSTANDBY */
>  
>  	return 0;
>  }
> -- 
> 1.5.5.1.99.gf0ec4
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

      reply	other threads:[~2008-05-02 22:57 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-04-29 11:05 [PATCH] USB: MUSB: Better sysconf reg settings on PM point of view Felipe Balbi
2008-05-02 22:57 ` Tony Lindgren [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=20080502225659.GU8981@atomide.com \
    --to=tony@atomide.com \
    --cc=felipe.balbi@nokia.com \
    --cc=jouni.hogander@nokia.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 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.