Lines Matching defs:gspca_dev
20 struct gspca_dev gspca_dev; /* !! must be the first item */
33 static void reg_w(struct gspca_dev *gspca_dev,
36 struct usb_device *dev = gspca_dev->dev;
39 if (gspca_dev->usb_err < 0)
51 gspca_dev->usb_err = ret;
56 static int sd_config(struct gspca_dev *gspca_dev,
59 gspca_dev->cam.cam_mode = vga_mode;
60 gspca_dev->cam.nmodes = ARRAY_SIZE(vga_mode);
61 gspca_dev->cam.no_urb_create = 1;
66 static int sd_init(struct gspca_dev *gspca_dev)
72 static int sd_start(struct gspca_dev *gspca_dev)
87 gspca_dev->urb[n] = urb;
88 urb->transfer_buffer = usb_alloc_coherent(gspca_dev->dev,
97 urb->dev = gspca_dev->dev;
98 urb->context = gspca_dev;
100 urb->pipe = usb_rcvisocpipe(gspca_dev->dev,
113 return gspca_dev->usb_err;
116 static void sd_stopN(struct gspca_dev *gspca_dev)
120 reg_w(gspca_dev, 0x003c, 0x0003);
121 reg_w(gspca_dev, 0x003c, 0x0004);
122 reg_w(gspca_dev, 0x003c, 0x0005);
123 reg_w(gspca_dev, 0x003c, 0x0006);
124 reg_w(gspca_dev, 0x003c, 0x0007);
126 intf = usb_ifnum_to_if(gspca_dev->dev, gspca_dev->iface);
127 usb_set_interface(gspca_dev->dev, gspca_dev->iface,
131 static void sd_pkt_scan(struct gspca_dev *gspca_dev,
141 struct gspca_dev *gspca_dev = (struct gspca_dev *) urb->context;
146 gspca_dbg(gspca_dev, D_PACK, "sd isoc irq\n");
147 if (!gspca_dev->streaming)
153 if (gspca_dev->frozen)
161 if (urb == gspca_dev->urb[0] || urb == gspca_dev->urb[2])
165 if (urb == gspca_dev->urb[1])
166 urb0 = gspca_dev->urb[0];
168 urb0 = gspca_dev->urb[2];
174 gspca_err(gspca_dev, "ISOC bad lengths %d / %d\n",
177 gspca_dev->last_packet_type = DISCARD_PACKET;
186 gspca_dev->last_packet_type = DISCARD_PACKET;
211 gspca_frame_add(gspca_dev, LAST_PACKET,
213 gspca_frame_add(gspca_dev, FIRST_PACKET,
216 gspca_frame_add(gspca_dev, INTER_PACKET,
219 gspca_dev->last_packet_type = DISCARD_PACKET;
224 gspca_frame_add(gspca_dev, INTER_PACKET,