All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Klaus Doth <kdlnx@doth.eu>
Cc: Arnd Bergmann <arnd@arndb.de>,
	helgaas@kernel.org, linux-pci@vger.kernel.org,
	rui_feng@realsil.com.cn
Subject: Re: Possible bug in drivers/misc/cardreader/rtsx_pcr.c
Date: Fri, 22 May 2020 09:33:36 +0200	[thread overview]
Message-ID: <20200522073336.GA929703@kroah.com> (raw)
In-Reply-To: <3ed62141-8060-dcd2-d1e0-d2381f4930dd@doth.eu>

On Thu, May 21, 2020 at 01:50:02PM +0200, Klaus Doth wrote:
> On 5/21/20 10:52 AM, Greg Kroah-Hartman wrote:
> > On Tue, May 19, 2020 at 07:04:06PM +0200, Klaus Doth wrote:
> >> Hi,
> >>
> >>
> >> As per the info from kernelnewbies IRC, I'm sending this also to the PCI
> >> list.
> > <snip>
> >
> > Can you submit a proposed patch in a format that it can be tested and
> > possibly submitted in so that we can review this easier?
> >
> > Also try cc:ing the author of changes in that code, Rui Feng
> > <rui_feng@realsil.com.cn>, as well, as they are the best one to review
> > and comment on your issue.
> >
> > thanks,
> >
> > greg k-h
> 
> 
> DMA transfers to and from the SD card stall for 10 seconds and run into
> timeout on RTS5260 card readers after ASPM was enabled.
> 
> Adding a short msleep after disabling ASPM fixes the issue on several
> Dell Precision 7530/7540 systems I tested.
> 
> This function is only called when waking up after the chip went into
> powersave after not transferring data for a few seconds. The added
> msleep does therefore not change anything in data transfer speed or
> induce any excessive waiting while data transfers are running, or the
> chip is sleeping. Only the transistion from sleep to active is affected.
> 
> 
> Signed-off-by: Klaus Doth <kdlnx@doth.eu>
> 
> ---
>  drivers/misc/cardreader/rtsx_pcr.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/misc/cardreader/rtsx_pcr.c
> b/drivers/misc/cardreader/rtsx_pcr.c
> index 06038b325b02..8b0799cd88c2 100644
> --- a/drivers/misc/cardreader/rtsx_pcr.c
> +++ b/drivers/misc/cardreader/rtsx_pcr.c
> @@ -141,6 +141,7 @@ static void rtsx_comm_pm_full_on(struct rtsx_pcr *pcr)
>      struct rtsx_cr_option *option = &pcr->option;
>  
>      rtsx_disable_aspm(pcr);
> +    msleep(1);
>  
>      if (option->ltr_enabled)
>          rtsx_set_ltr_latency(pcr, option->ltr_active_latency);
> -- 
> 2.26.2

Looks sane, can you resend it in a format I can apply it in (i.e. as a
stand-alone patch with a correct subject line?)

thanks,

greg k-h

  parent reply	other threads:[~2020-05-22  7:33 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-19 17:04 Possible bug in drivers/misc/cardreader/rtsx_pcr.c Klaus Doth
2020-05-21  8:52 ` Greg Kroah-Hartman
2020-05-21 11:50   ` Klaus Doth
2020-05-21 17:59     ` Bjorn Helgaas
2020-05-22  7:33     ` Greg Kroah-Hartman [this message]
2020-05-22  8:23   ` [PATCH] misc: rtsx: Add short delay after exit from ASPM Klaus Doth
2020-05-22  8:33     ` Arnd Bergmann
2020-05-22  9:18       ` [PATCH v2] " Klaus Doth
2020-05-22  9:38         ` Greg Kroah-Hartman
2020-05-22 10:56       ` [PATCH v3] " Klaus Doth
2020-05-22 11:27         ` Greg Kroah-Hartman

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=20200522073336.GA929703@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=arnd@arndb.de \
    --cc=helgaas@kernel.org \
    --cc=kdlnx@doth.eu \
    --cc=linux-pci@vger.kernel.org \
    --cc=rui_feng@realsil.com.cn \
    /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.