xhci: remove unused parameter 'xhci' in function xhci_handshake().

Parameter 'xhci' is no longer be used in function xhci_handshake(),
just remove it.

Signed-off-by: Lin Wang <lin.x.wang@intel.com>
Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Lin Wang 2015-01-09 16:06:28 +02:00 committed by Greg Kroah-Hartman
parent 92c9691bf3
commit dc0b177cf8
3 changed files with 11 additions and 13 deletions

View File

@ -299,7 +299,7 @@ static int xhci_abort_cmd_ring(struct xhci_hcd *xhci)
* seconds), then it should assume that the there are * seconds), then it should assume that the there are
* larger problems with the xHC and assert HCRST. * larger problems with the xHC and assert HCRST.
*/ */
ret = xhci_handshake(xhci, &xhci->op_regs->cmd_ring, ret = xhci_handshake(&xhci->op_regs->cmd_ring,
CMD_RING_RUNNING, 0, 5 * 1000 * 1000); CMD_RING_RUNNING, 0, 5 * 1000 * 1000);
if (ret < 0) { if (ret < 0) {
xhci_err(xhci, "Stopped the command ring failed, " xhci_err(xhci, "Stopped the command ring failed, "

View File

@ -60,8 +60,7 @@ MODULE_PARM_DESC(quirks, "Bit flags for quirks to be enabled as default");
* handshake done). There are two failure modes: "usec" have passed (major * handshake done). There are two failure modes: "usec" have passed (major
* hardware flakeout), or the register reads as all-ones (hardware removed). * hardware flakeout), or the register reads as all-ones (hardware removed).
*/ */
int xhci_handshake(struct xhci_hcd *xhci, void __iomem *ptr, int xhci_handshake(void __iomem *ptr, u32 mask, u32 done, int usec)
u32 mask, u32 done, int usec)
{ {
u32 result; u32 result;
@ -111,7 +110,7 @@ int xhci_halt(struct xhci_hcd *xhci)
xhci_dbg_trace(xhci, trace_xhci_dbg_init, "// Halt the HC"); xhci_dbg_trace(xhci, trace_xhci_dbg_init, "// Halt the HC");
xhci_quiesce(xhci); xhci_quiesce(xhci);
ret = xhci_handshake(xhci, &xhci->op_regs->status, ret = xhci_handshake(&xhci->op_regs->status,
STS_HALT, STS_HALT, XHCI_MAX_HALT_USEC); STS_HALT, STS_HALT, XHCI_MAX_HALT_USEC);
if (!ret) { if (!ret) {
xhci->xhc_state |= XHCI_STATE_HALTED; xhci->xhc_state |= XHCI_STATE_HALTED;
@ -140,7 +139,7 @@ static int xhci_start(struct xhci_hcd *xhci)
* Wait for the HCHalted Status bit to be 0 to indicate the host is * Wait for the HCHalted Status bit to be 0 to indicate the host is
* running. * running.
*/ */
ret = xhci_handshake(xhci, &xhci->op_regs->status, ret = xhci_handshake(&xhci->op_regs->status,
STS_HALT, 0, XHCI_MAX_HALT_USEC); STS_HALT, 0, XHCI_MAX_HALT_USEC);
if (ret == -ETIMEDOUT) if (ret == -ETIMEDOUT)
xhci_err(xhci, "Host took too long to start, " xhci_err(xhci, "Host took too long to start, "
@ -175,7 +174,7 @@ int xhci_reset(struct xhci_hcd *xhci)
command |= CMD_RESET; command |= CMD_RESET;
writel(command, &xhci->op_regs->command); writel(command, &xhci->op_regs->command);
ret = xhci_handshake(xhci, &xhci->op_regs->command, ret = xhci_handshake(&xhci->op_regs->command,
CMD_RESET, 0, 10 * 1000 * 1000); CMD_RESET, 0, 10 * 1000 * 1000);
if (ret) if (ret)
return ret; return ret;
@ -186,7 +185,7 @@ int xhci_reset(struct xhci_hcd *xhci)
* xHCI cannot write to any doorbells or operational registers other * xHCI cannot write to any doorbells or operational registers other
* than status until the "Controller Not Ready" flag is cleared. * than status until the "Controller Not Ready" flag is cleared.
*/ */
ret = xhci_handshake(xhci, &xhci->op_regs->status, ret = xhci_handshake(&xhci->op_regs->status,
STS_CNR, 0, 10 * 1000 * 1000); STS_CNR, 0, 10 * 1000 * 1000);
for (i = 0; i < 2; ++i) { for (i = 0; i < 2; ++i) {
@ -929,7 +928,7 @@ int xhci_suspend(struct xhci_hcd *xhci, bool do_wakeup)
/* Some chips from Fresco Logic need an extraordinary delay */ /* Some chips from Fresco Logic need an extraordinary delay */
delay *= (xhci->quirks & XHCI_SLOW_SUSPEND) ? 10 : 1; delay *= (xhci->quirks & XHCI_SLOW_SUSPEND) ? 10 : 1;
if (xhci_handshake(xhci, &xhci->op_regs->status, if (xhci_handshake(&xhci->op_regs->status,
STS_HALT, STS_HALT, delay)) { STS_HALT, STS_HALT, delay)) {
xhci_warn(xhci, "WARN: xHC CMD_RUN timeout\n"); xhci_warn(xhci, "WARN: xHC CMD_RUN timeout\n");
spin_unlock_irq(&xhci->lock); spin_unlock_irq(&xhci->lock);
@ -944,7 +943,7 @@ int xhci_suspend(struct xhci_hcd *xhci, bool do_wakeup)
command = readl(&xhci->op_regs->command); command = readl(&xhci->op_regs->command);
command |= CMD_CSS; command |= CMD_CSS;
writel(command, &xhci->op_regs->command); writel(command, &xhci->op_regs->command);
if (xhci_handshake(xhci, &xhci->op_regs->status, if (xhci_handshake(&xhci->op_regs->status,
STS_SAVE, 0, 10 * 1000)) { STS_SAVE, 0, 10 * 1000)) {
xhci_warn(xhci, "WARN: xHC save state timeout\n"); xhci_warn(xhci, "WARN: xHC save state timeout\n");
spin_unlock_irq(&xhci->lock); spin_unlock_irq(&xhci->lock);
@ -1011,7 +1010,7 @@ int xhci_resume(struct xhci_hcd *xhci, bool hibernated)
command = readl(&xhci->op_regs->command); command = readl(&xhci->op_regs->command);
command |= CMD_CRS; command |= CMD_CRS;
writel(command, &xhci->op_regs->command); writel(command, &xhci->op_regs->command);
if (xhci_handshake(xhci, &xhci->op_regs->status, if (xhci_handshake(&xhci->op_regs->status,
STS_RESTORE, 0, 10 * 1000)) { STS_RESTORE, 0, 10 * 1000)) {
xhci_warn(xhci, "WARN: xHC restore state timeout\n"); xhci_warn(xhci, "WARN: xHC restore state timeout\n");
spin_unlock_irq(&xhci->lock); spin_unlock_irq(&xhci->lock);
@ -1082,7 +1081,7 @@ int xhci_resume(struct xhci_hcd *xhci, bool hibernated)
command = readl(&xhci->op_regs->command); command = readl(&xhci->op_regs->command);
command |= CMD_RUN; command |= CMD_RUN;
writel(command, &xhci->op_regs->command); writel(command, &xhci->op_regs->command);
xhci_handshake(xhci, &xhci->op_regs->status, STS_HALT, xhci_handshake(&xhci->op_regs->status, STS_HALT,
0, 250 * 1000); 0, 250 * 1000);
/* step 5: walk topology and initialize portsc, /* step 5: walk topology and initialize portsc,

View File

@ -1733,8 +1733,7 @@ void xhci_free_command(struct xhci_hcd *xhci,
/* xHCI host controller glue */ /* xHCI host controller glue */
typedef void (*xhci_get_quirks_t)(struct device *, struct xhci_hcd *); typedef void (*xhci_get_quirks_t)(struct device *, struct xhci_hcd *);
int xhci_handshake(struct xhci_hcd *xhci, void __iomem *ptr, int xhci_handshake(void __iomem *ptr, u32 mask, u32 done, int usec);
u32 mask, u32 done, int usec);
void xhci_quiesce(struct xhci_hcd *xhci); void xhci_quiesce(struct xhci_hcd *xhci);
int xhci_halt(struct xhci_hcd *xhci); int xhci_halt(struct xhci_hcd *xhci);
int xhci_reset(struct xhci_hcd *xhci); int xhci_reset(struct xhci_hcd *xhci);