From: Mathias Nyman <mathias.nyman@intel.com>
To: Sneeker Yeh <sneeker.yeh@gmail.com>,
Rob Herring <robh+dt@kernel.org>, Pawel Moll <pawel.moll@arm.com>,
Mark Rutland <mark.rutland@arm.com>,
Ian Campbell <ijc+devicetree@hellion.org.uk>,
Kumar Gala <galak@codeaurora.org>, Felipe Balbi <balbi@ti.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Grant Likely <grant.likely@linaro.org>,
Huang Rui <ray.huang@amd.com>,
Kishon Vijay Abraham I <kishon@ti.com>,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-usb@vger.kernel.org, linux-omap@vger.kernel.org
Cc: Andy Green <andy.green@linaro.org>,
Jassi Brar <jaswinder.singh@linaro.org>,
Sneeker Yeh <Sneeker.Yeh@tw.fujitsu.com>
Subject: Re: [PATCH v3 1/5] xhci: add a quirk for device disconnection errata for Synopsis Designware USB3 core
Date: Fri, 13 Feb 2015 11:08:38 +0200 [thread overview]
Message-ID: <54DDBF16.2080807@intel.com> (raw)
In-Reply-To: <1422173608-24355-2-git-send-email-Sneeker.Yeh@tw.fujitsu.com>
On 25.01.2015 10:13, Sneeker Yeh wrote:
Oh, and one more thing:
>
> +static void xhci_try_to_clear_csc(struct usb_hcd *hcd, int dev_port_num)
> +{
> + int max_ports;
> + struct xhci_hcd *xhci = hcd_to_xhci(hcd);
> + __le32 __iomem **port_array;
> + u32 status;
> +
> + /* print debug info */
> + if (hcd->speed == HCD_USB3) {
> + max_ports = xhci->num_usb3_ports;
> + port_array = xhci->usb3_ports;
> + } else {
> + max_ports = xhci->num_usb2_ports;
> + port_array = xhci->usb2_ports;
> + }
> +
> + if (dev_port_num > max_ports) {
> + xhci_err(xhci, "%s() port number invalid", __func__);
> + return;
> + }
> + status = readl(port_array[dev_port_num - 1]);
> +
> + /* write 1 to clear */
> + if (!(status & PORT_CONNECT) && (status & PORT_CSC))
> + writel(status & PORT_CSC, port_array[0]);
We don't want to write back all the bits we read from the PORTSC register.
Use the xhci_put_state_to_neutral(status) helper function to mask out some RW1C bits.
This in addition to writing to the correct PORTSC register as I previously mentioned.
-Mathias
next prev parent reply other threads:[~2015-02-13 9:07 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-25 8:13 [PATCH v3 0/5] Add support for Fujitsu USB host controller Sneeker Yeh
2015-01-25 8:13 ` Sneeker Yeh
[not found] ` <1422173608-24355-1-git-send-email-Sneeker.Yeh-l16TxrwUIHTQFUHtdCDX3A@public.gmane.org>
2015-01-25 8:13 ` [PATCH v3 1/5] xhci: add a quirk for device disconnection errata for Synopsis Designware USB3 core Sneeker Yeh
2015-01-25 8:13 ` Sneeker Yeh
[not found] ` <1422173608-24355-2-git-send-email-Sneeker.Yeh-l16TxrwUIHTQFUHtdCDX3A@public.gmane.org>
2015-02-12 13:50 ` Mathias Nyman
2015-02-12 13:50 ` Mathias Nyman
2015-02-12 15:18 ` Alan Stern
2015-02-12 15:18 ` Alan Stern
2015-02-13 8:54 ` Mathias Nyman
[not found] ` <Pine.LNX.4.44L0.1502121013390.1209-100000-IYeN2dnnYyZXsRXLowluHWD2FQJk+8+b@public.gmane.org>
2015-02-15 15:09 ` Sneeker Yeh
2015-02-15 15:09 ` Sneeker Yeh
2015-02-15 14:29 ` Sneeker Yeh
[not found] ` <CAJ1gpc3fSpVyYx52xk+r+aPJt4YBcP+9wLGo9bUnX-EE1MP-VQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-02-16 9:26 ` Mathias Nyman
2015-02-16 9:26 ` Mathias Nyman
2015-02-13 9:08 ` Mathias Nyman [this message]
2015-01-25 8:13 ` [PATCH v3 2/5] xhci: Platform: Set Synopsis device disconnection quirk based on platform data Sneeker Yeh
2015-01-25 8:13 ` [PATCH v3 3/5] usb: dwc3: add revision number DWC3_REVISION_290A and DWC3_REVISION_300A Sneeker Yeh
2015-01-25 8:13 ` [PATCH v3 4/5] usb: dwc3: Add quirk for Synopsis device disconnection errata Sneeker Yeh
2015-01-25 8:13 ` [PATCH v3 5/5] usb: dwc3: add Fujitsu Specific Glue layer Sneeker Yeh
2015-01-27 15:22 ` [PATCH v3 0/5] Add support for Fujitsu USB host controller Felipe Balbi
2015-01-27 15:22 ` Felipe Balbi
[not found] ` <20150127152250.GB13776-HgARHv6XitJaoMGHk7MhZQC/G2K4zDHf@public.gmane.org>
2015-01-29 16:23 ` Felipe Balbi
2015-01-29 16:23 ` Felipe Balbi
2015-01-30 16:38 ` Felipe Balbi
2015-01-30 16:38 ` Felipe Balbi
2015-02-10 15:43 ` Sneeker Yeh
2015-02-11 11:57 ` Mathias Nyman
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=54DDBF16.2080807@intel.com \
--to=mathias.nyman@intel.com \
--cc=Sneeker.Yeh@tw.fujitsu.com \
--cc=andy.green@linaro.org \
--cc=balbi@ti.com \
--cc=devicetree@vger.kernel.org \
--cc=galak@codeaurora.org \
--cc=grant.likely@linaro.org \
--cc=gregkh@linuxfoundation.org \
--cc=ijc+devicetree@hellion.org.uk \
--cc=jaswinder.singh@linaro.org \
--cc=kishon@ti.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=pawel.moll@arm.com \
--cc=ray.huang@amd.com \
--cc=robh+dt@kernel.org \
--cc=sneeker.yeh@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.