#include <linux/netdevice.h>
#include <linux/suspend.h>
#include <linux/slab.h>
+#include <linux/delay.h>
#include <linux/usb.h>
#include <linux/crc32.h>
#include <net/irda/irda.h>
REQ_WRITE_SINGLE,
USB_DIR_OUT|USB_TYPE_VENDOR|USB_RECIP_DEVICE,
value, reg, NULL, 0,
- MSECS_TO_JIFFIES(CTRL_TIMEOUT));
+ msecs_to_jiffies(CTRL_TIMEOUT));
}
/* Send control message to read multiple registers */
REQ_READ_REG,
USB_DIR_IN | USB_TYPE_VENDOR | USB_RECIP_DEVICE,
0, reg, data, count,
- MSECS_TO_JIFFIES(CTRL_TIMEOUT));
+ msecs_to_jiffies(CTRL_TIMEOUT));
}
static inline int isfir(u32 speed)
return 0;
/* estimate transfer time for remaining chars */
- wait_ms((count * 8000) / stir->speed);
+ msleep((count * 8000) / stir->speed);
}
err = write_reg(stir, REG_FIFOCTL, FIFOCTL_CLR);
if (usb_bulk_msg(stir->usbdev, usb_sndbulkpipe(stir->usbdev, 1),
stir->io_buf, wraplen,
- NULL, MSECS_TO_JIFFIES(TRANSMIT_TIMEOUT)))
+ NULL, msecs_to_jiffies(TRANSMIT_TIMEOUT)))
stir->stats.tx_errors++;
}
info("%s: receive usb submit failed",
stir->netdev->name);
stir->receiving = 0;
- wait_ms(10);
+ msleep(10);
continue;
}
}