All of lore.kernel.org
 help / color / mirror / Atom feed
From: Heikki Krogerus <heikki.krogerus@linux.intel.com>
To: Li Jun <jun.li@nxp.com>
Cc: linux@roeck-us.net, gregkh@linuxfoundation.org,
	linux-usb@vger.kernel.org
Subject: Re: [PATCH 2/3] usb: typec: tcpm: cancel frs hrtimer when unregister tcpm port
Date: Mon, 7 Jun 2021 12:17:01 +0300	[thread overview]
Message-ID: <YL3kDTrlENicPuov@kuha.fi.intel.com> (raw)
In-Reply-To: <1622627829-11070-2-git-send-email-jun.li@nxp.com>

On Wed, Jun 02, 2021 at 05:57:08PM +0800, Li Jun wrote:
> Like the state_machine_timer, we should also cancel possible pending
> frs hrtimer when unregister tcpm port.
> 
> Fixes: 8dc4bd073663 ("usb: typec: tcpm: Add support for Sink Fast Role SWAP(FRS)")
> Signed-off-by: Li Jun <jun.li@nxp.com>

Acked-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>

> ---
>  drivers/usb/typec/tcpm/tcpm.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/usb/typec/tcpm/tcpm.c b/drivers/usb/typec/tcpm/tcpm.c
> index f47685e7923d..c7460df2119d 100644
> --- a/drivers/usb/typec/tcpm/tcpm.c
> +++ b/drivers/usb/typec/tcpm/tcpm.c
> @@ -6328,6 +6328,7 @@ void tcpm_unregister_port(struct tcpm_port *port)
>  {
>  	int i;
>  
> +	hrtimer_cancel(&port->enable_frs_timer);
>  	hrtimer_cancel(&port->vdm_state_machine_timer);
>  	hrtimer_cancel(&port->state_machine_timer);
>  
> -- 
> 2.25.1

-- 
heikki

  parent reply	other threads:[~2021-06-07  9:17 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-02  9:57 [PATCH 1/3] usb: typec: tcpm: cancel vdm and state machine hrtimer when unregister tcpm port Li Jun
2021-06-02  9:57 ` [PATCH 2/3] usb: typec: tcpm: cancel frs " Li Jun
2021-06-02 10:59   ` Guenter Roeck
2021-06-07  9:17   ` Heikki Krogerus [this message]
2021-06-02  9:57 ` [PATCH 3/3] usb: typec: tcpm: cancel send discover " Li Jun
2021-06-02 11:00   ` Guenter Roeck
2021-06-07  9:18   ` Heikki Krogerus
2021-06-02 10:59 ` [PATCH 1/3] usb: typec: tcpm: cancel vdm and state machine " Guenter Roeck
2021-06-07  9:16 ` Heikki Krogerus

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=YL3kDTrlENicPuov@kuha.fi.intel.com \
    --to=heikki.krogerus@linux.intel.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=jun.li@nxp.com \
    --cc=linux-usb@vger.kernel.org \
    --cc=linux@roeck-us.net \
    /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.