aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSubbaraya Sundeep Bhatta <subbaraya.sundeep.bhatta@xilinx.com>2015-05-21 06:16:46 -0400
committerFelipe Balbi <balbi@ti.com>2015-05-26 10:44:55 -0400
commit459e210c4fd034d20077bcec31fec9472a700fe9 (patch)
treea4de968f24a7925ced42b71c88f257cd1fc5db20
parenta81df9eedf7d29d747c86fed2402bd416bacd7a3 (diff)
usb: dwc3: gadget: Fix incorrect DEPCMD and DGCMD status macros
Fixed the incorrect macro definitions correctly as per databook. Signed-off-by: Subbaraya Sundeep Bhatta <sbhatta@xilinx.com> Fixes: b09bb64239c8 (usb: dwc3: gadget: implement Global Command support) Cc: <stable@vger.kernel.org> #v3.5+ Signed-off-by: Felipe Balbi <balbi@ti.com>
-rw-r--r--drivers/usb/dwc3/core.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/dwc3/core.h b/drivers/usb/dwc3/core.h
index fdab715a0631..c0eafa6fd403 100644
--- a/drivers/usb/dwc3/core.h
+++ b/drivers/usb/dwc3/core.h
@@ -339,7 +339,7 @@
339#define DWC3_DGCMD_SET_ENDPOINT_NRDY 0x0c 339#define DWC3_DGCMD_SET_ENDPOINT_NRDY 0x0c
340#define DWC3_DGCMD_RUN_SOC_BUS_LOOPBACK 0x10 340#define DWC3_DGCMD_RUN_SOC_BUS_LOOPBACK 0x10
341 341
342#define DWC3_DGCMD_STATUS(n) (((n) >> 15) & 1) 342#define DWC3_DGCMD_STATUS(n) (((n) >> 12) & 0x0F)
343#define DWC3_DGCMD_CMDACT (1 << 10) 343#define DWC3_DGCMD_CMDACT (1 << 10)
344#define DWC3_DGCMD_CMDIOC (1 << 8) 344#define DWC3_DGCMD_CMDIOC (1 << 8)
345 345
@@ -355,7 +355,7 @@
355#define DWC3_DEPCMD_PARAM_SHIFT 16 355#define DWC3_DEPCMD_PARAM_SHIFT 16
356#define DWC3_DEPCMD_PARAM(x) ((x) << DWC3_DEPCMD_PARAM_SHIFT) 356#define DWC3_DEPCMD_PARAM(x) ((x) << DWC3_DEPCMD_PARAM_SHIFT)
357#define DWC3_DEPCMD_GET_RSC_IDX(x) (((x) >> DWC3_DEPCMD_PARAM_SHIFT) & 0x7f) 357#define DWC3_DEPCMD_GET_RSC_IDX(x) (((x) >> DWC3_DEPCMD_PARAM_SHIFT) & 0x7f)
358#define DWC3_DEPCMD_STATUS(x) (((x) >> 15) & 1) 358#define DWC3_DEPCMD_STATUS(x) (((x) >> 12) & 0x0F)
359#define DWC3_DEPCMD_HIPRI_FORCERM (1 << 11) 359#define DWC3_DEPCMD_HIPRI_FORCERM (1 << 11)
360#define DWC3_DEPCMD_CMDACT (1 << 10) 360#define DWC3_DEPCMD_CMDACT (1 << 10)
361#define DWC3_DEPCMD_CMDIOC (1 << 8) 361#define DWC3_DEPCMD_CMDIOC (1 << 8)