#include <linux/list.h>
#include <linux/kobject.h>
#include <linux/platform_device.h>
-
-#include <asm/io.h>
+#include <linux/io.h>
#ifdef CONFIG_ARM
#include <asm/arch/hardware.h>
index += len & ~0x03;
}
if (len & 0x02) {
- musb_writew(fifo, 0, *(u16*)&src[index]);
+ musb_writew(fifo, 0, *(u16 *)&src[index]);
index += 2;
}
} else {
index = len & ~0x03;
}
if (len & 0x02) {
- *(u16*)&dst[index] = musb_readw(fifo, 0);
+ *(u16 *)&dst[index] = musb_readw(fifo, 0);
index += 2;
}
} else {
#define STAGE0_MASK (MUSB_INTR_RESUME | MUSB_INTR_SESSREQ \
| MUSB_INTR_VBUSERROR | MUSB_INTR_CONNECT \
- | MUSB_INTR_RESET )
+ | MUSB_INTR_RESET)
-static irqreturn_t musb_stage0_irq(struct musb * musb, u8 int_usb,
+static irqreturn_t musb_stage0_irq(struct musb *musb, u8 int_usb,
u8 devctl, u8 power)
{
irqreturn_t handled = IRQ_NONE;
* @param devctl
* @param power
*/
-static irqreturn_t musb_stage2_irq(struct musb * musb, u8 int_usb,
+static irqreturn_t musb_stage2_irq(struct musb *musb, u8 int_usb,
u8 devctl, u8 power)
{
irqreturn_t handled = IRQ_NONE;
u8 epn = cfg->hw_ep_num;
if (epn >= MUSB_C_NUM_EPS) {
- pr_debug( "%s: invalid ep %d\n",
+ pr_debug("%s: invalid ep %d\n",
musb_driver_name, epn);
continue;
}
offset = fifo_setup(musb, hw_ep + epn, cfg++, offset);
if (offset < 0) {
- pr_debug( "%s: mem overrun, ep %d\n",
+ pr_debug("%s: mem overrun, ep %d\n",
musb_driver_name, epn);
return -EINVAL;
}
#ifdef CONFIG_USB_MUSB_HDRC_HCD
if (!musb->bulk_ep) {
- pr_debug( "%s: missing bulk\n", musb_driver_name);
+ pr_debug("%s: missing bulk\n", musb_driver_name);
return -EINVAL;
}
#endif
#ifdef CONFIG_USB_MUSB_HDRC_HCD
if (!musb->bulk_ep) {
- pr_debug( "%s: missing bulk\n", musb_driver_name);
+ pr_debug("%s: missing bulk\n", musb_driver_name);
return -EINVAL;
}
#endif
reg = musb_readb(mbase, 0x10 + MUSB_CONFIGDATA);
strcpy(aInfo, (reg & MUSB_CONFIGDATA_UTMIDW) ? "UTMI-16" : "UTMI-8");
- if (reg & MUSB_CONFIGDATA_DYNFIFO) {
+ if (reg & MUSB_CONFIGDATA_DYNFIFO)
strcat(aInfo, ", dyn FIFOs");
- }
if (reg & MUSB_CONFIGDATA_MPRXE) {
strcat(aInfo, ", bulk combine");
#ifdef C_MP_RX
strcat(aInfo, ", HB-ISO Tx");
strcat(aInfo, " (X)"); /* no driver support */
}
- if (reg & MUSB_CONFIGDATA_SOFTCONE) {
+ if (reg & MUSB_CONFIGDATA_SOFTCONE)
strcat(aInfo, ", SoftConn");
- }
printk(KERN_DEBUG "%s: ConfigData=0x%02x (%s)\n",
musb_driver_name, reg, aInfo);
musb_srp_store(struct device *dev, struct device_attribute *attr,
const char *buf, size_t n)
{
- struct musb *musb=dev_to_musb(dev);
+ struct musb *musb = dev_to_musb(dev);
unsigned short srp;
if (sscanf(buf, "%hu", &srp) != 1
|| (srp != 1)) {
- printk (KERN_ERR "SRP: Value must be 1\n");
+ printk(KERN_ERR "SRP: Value must be 1\n");
return -EINVAL;
}
#ifdef CONFIG_USB_MUSB_OTG
break;
#else
- bad_config:
+bad_config:
#endif
default:
dev_err(dev, "incompatible Kconfig role setting\n");
INIT_WORK(&musb->irq_work, musb_irq_work);
/* attach to the IRQ */
- if (request_irq (nIrq, musb->isr, 0, dev->bus_id, musb)) {
+ if (request_irq(nIrq, musb->isr, 0, dev->bus_id, musb)) {
dev_err(dev, "request_irq %d failed!\n", nIrq);
status = -ENODEV;
goto fail2;