mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Marc Kleine-Budde <mkl@pengutronix.de>
To: Chris Ruehl <chris.ruehl@gtsys.com.hk>
Cc: peter.chen@freescale.com, gregkh@linuxfoundation.org,
	linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/3 v4] usb: chipidea: Reallocate regmap only if lpm is detected
Date: Tue, 03 Dec 2013 12:12:01 +0100	[thread overview]
Message-ID: <529DBC81.5030805@pengutronix.de> (raw)
In-Reply-To: <1386057710-3848-1-git-send-email-chris.ruehl@gtsys.com.hk>

[-- Attachment #1: Type: text/plain, Size: 1758 bytes --]

On 12/03/2013 09:01 AM, Chris Ruehl wrote:
> usb: chipidea: Reallocate regmap only if lpm is detected
> 
> The regmap only needs to reallocate if the hw_read on the CAP register shows
> lpm is used. Therefore the if() statement check the change.
> 
> Signed-off-by: Chris Ruehl <chris.ruehl@gtsys.com.hk>
> Acked-by: Peter Chen <peter.chen@freescale.com>
> ---
>  drivers/usb/chipidea/core.c |    7 ++++++-
>  1 file changed, 6 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/usb/chipidea/core.c b/drivers/usb/chipidea/core.c
> index 5d8981c..9a5ef20 100644
> --- a/drivers/usb/chipidea/core.c
> +++ b/drivers/usb/chipidea/core.c
> @@ -208,7 +208,8 @@ static int hw_device_init(struct ci_hdrc *ci, void __iomem *base)
>  	reg = hw_read(ci, CAP_HCCPARAMS, HCCPARAMS_LEN) >>
>  		__ffs(HCCPARAMS_LEN);
>  	ci->hw_bank.lpm  = reg;
> -	hw_alloc_regmap(ci, !!reg);
> +	if (reg)
> +		hw_alloc_regmap(ci, !!reg);
>  	ci->hw_bank.size = ci->hw_bank.op - ci->hw_bank.abs;
>  	ci->hw_bank.size += OP_LAST;
>  	ci->hw_bank.size /= sizeof(u32);
> @@ -642,6 +643,10 @@ static int ci_hdrc_probe(struct platform_device *pdev)
>  			: CI_ROLE_GADGET;
>  	}
>  
> +	/* only update vbus status for peripheral */
> +	if (ci->role == CI_ROLE_GADGET)
> +		ci_handle_vbus_change(ci);
> +

This change seems unrelated to me.

Marc

>  	ret = ci_role_start(ci, ci->role);
>  	if (ret) {
>  		dev_err(dev, "can't start %s role\n", ci_role(ci)->name);
> 


-- 
Pengutronix e.K.                  | Marc Kleine-Budde           |
Industrial Linux Solutions        | Phone: +49-231-2826-924     |
Vertretung West/Dortmund          | Fax:   +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686  | http://www.pengutronix.de   |


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 259 bytes --]

  parent reply	other threads:[~2013-12-03 11:12 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-03  8:01 Chris Ruehl
2013-12-03  8:01 ` [PATCH 2/3 v4] Fix Internal error: : 808 [#1] ARM related to STS flag Chris Ruehl
2013-12-03  8:01 ` [PATCH 3/3 v4] usb: chipidea: hw_phymode_configure moved before ci_usb_phy_init Chris Ruehl
2013-12-03 14:27   ` Peter Chen
2014-01-22  9:49   ` Regression on next-20140116 [Was: [PATCH 3/3 v4] usb: chipidea: hw_phymode_configure moved before ci_usb_phy_init] Uwe Kleine-König
2014-01-22 21:41     ` Uwe Kleine-König
2014-01-23  1:22       ` Peter Chen
2014-01-23  4:59         ` Chris Ruehl
2014-01-24 10:18         ` Uwe Kleine-König
2013-12-03 11:12 ` Marc Kleine-Budde [this message]
2013-12-03 13:57   ` [PATCH 1/3 v4] usb: chipidea: Reallocate regmap only if lpm is detected Peter Chen
2013-12-04  1:37   ` Chris Ruehl

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=529DBC81.5030805@pengutronix.de \
    --to=mkl@pengutronix.de \
    --cc=chris.ruehl@gtsys.com.hk \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=peter.chen@freescale.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome