---
name: "usb_fill_int_urb"
section: "9"
platform: "linux"
package: "linux-manual-4.9"
version: "4.9.228-1"
release: "Debian 9 (Stretch)"
platforms: ["linux"]
url: "https://new.carta.tech/usb_fill_int_urb"
---

# usb\_fill\_int\_urb(9)

macro to help initialize a interrupt urb

## NAME

usb\_fill\_int\_urb - macro to help initialize a interrupt urb

## SYNOPSIS

**void usb\_fill\_int\_urb(struct urb \*** *urb***, struct usb\_device \*** *dev***, unsigned int** *pipe***, void \*** *transfer\_buffer***, int** *buffer\_length***, usb\_complete\_t** *complete\_fn***, void \*** *context***, int** *interval***);**

## ARGUMENTS

*urb*

pointer to the urb to initialize.

*dev*

pointer to the struct usb\_device for this urb.

*pipe*

the endpoint pipe

*transfer\_buffer*

pointer to the transfer buffer

*buffer\_length*

length of the transfer buffer

*complete\_fn*

pointer to the usb\_complete\_t function

*context*

what to set the urb context to.

*interval*

what to set the urb interval to, encoded like the endpoint descriptor's bInterval value.

## DESCRIPTION

Initializes a interrupt urb with the proper information needed to submit it to a device.

Note that High Speed and SuperSpeed(+) interrupt endpoints use a logarithmic encoding of the endpoint interval, and express polling intervals in microframes (eight per millisecond) rather than in frames (one per millisecond).

Wireless USB also uses the logarithmic encoding, but specifies it in units of 128us instead of 125us. For Wireless USB devices, the interval is passed through to the host controller, rather than being translated into microframe units.

## COPYRIGHT
