Lines Matching refs:ven_req

145 	struct VENDOR_REQUEST_IN ven_req;  in cx231xx_send_usb_command()  local
163 ven_req.wValue = (req_data->dev_addr << 9 | _i2c_period << 4 | in cx231xx_send_usb_command()
170 ven_req.bRequest = i2c_bus->nr + 4; in cx231xx_send_usb_command()
172 ven_req.bRequest = i2c_bus->nr; /* channel number, */ in cx231xx_send_usb_command()
177 ven_req.wIndex = 0; /* need check */ in cx231xx_send_usb_command()
180 ven_req.wIndex = (req_data->saddr_dat & 0xff); in cx231xx_send_usb_command()
183 ven_req.wIndex = req_data->saddr_dat; in cx231xx_send_usb_command()
188 ven_req.wLength = req_data->buf_size; in cx231xx_send_usb_command()
191 ven_req.bData = 0; in cx231xx_send_usb_command()
195 ven_req.direction = USB_DIR_IN; in cx231xx_send_usb_command()
196 memset(req_data->p_buffer, 0x00, ven_req.wLength); in cx231xx_send_usb_command()
198 ven_req.direction = USB_DIR_OUT; in cx231xx_send_usb_command()
201 ven_req.pBuff = req_data->p_buffer; in cx231xx_send_usb_command()
205 status = cx231xx_send_vendor_cmd(dev, &ven_req); in cx231xx_send_usb_command()
318 struct VENDOR_REQUEST_IN *ven_req) in cx231xx_send_vendor_cmd() argument
328 if ((ven_req->wLength > URB_MAX_CTRL_SIZE)) in cx231xx_send_vendor_cmd()
331 if (ven_req->direction) in cx231xx_send_vendor_cmd()
340 if ((ven_req->wLength > 4) && ((ven_req->bRequest == 0x4) || in cx231xx_send_vendor_cmd()
341 (ven_req->bRequest == 0x5) || in cx231xx_send_vendor_cmd()
342 (ven_req->bRequest == 0x6) || in cx231xx_send_vendor_cmd()
347 (ven_req->bRequest == 0x2))) { in cx231xx_send_vendor_cmd()
349 pdata = ven_req->pBuff; in cx231xx_send_vendor_cmd()
352 unsend_size = ven_req->wLength; in cx231xx_send_vendor_cmd()
355 ven_req->wValue = ven_req->wValue & 0xFFFB; in cx231xx_send_vendor_cmd()
356 ven_req->wValue = (ven_req->wValue & 0xFFBD) | 0x2; in cx231xx_send_vendor_cmd()
357 ret = __usb_control_msg(dev, pipe, ven_req->bRequest, in cx231xx_send_vendor_cmd()
358 ven_req->direction | USB_TYPE_VENDOR | USB_RECIP_DEVICE, in cx231xx_send_vendor_cmd()
359 ven_req->wValue, ven_req->wIndex, pdata, in cx231xx_send_vendor_cmd()
364 ven_req->wValue = (ven_req->wValue & 0xFFBD) | 0x42; in cx231xx_send_vendor_cmd()
368 ven_req->bRequest, in cx231xx_send_vendor_cmd()
369 ven_req->direction | USB_TYPE_VENDOR | USB_RECIP_DEVICE, in cx231xx_send_vendor_cmd()
370 ven_req->wValue, ven_req->wIndex, pdata, in cx231xx_send_vendor_cmd()
376 ven_req->wValue = (ven_req->wValue & 0xFFBD) | 0x40; in cx231xx_send_vendor_cmd()
378 ret = __usb_control_msg(dev, pipe, ven_req->bRequest, in cx231xx_send_vendor_cmd()
379 ven_req->direction | USB_TYPE_VENDOR | USB_RECIP_DEVICE, in cx231xx_send_vendor_cmd()
380 ven_req->wValue, ven_req->wIndex, pdata, in cx231xx_send_vendor_cmd()
383 ret = __usb_control_msg(dev, pipe, ven_req->bRequest, in cx231xx_send_vendor_cmd()
384 ven_req->direction | USB_TYPE_VENDOR | USB_RECIP_DEVICE, in cx231xx_send_vendor_cmd()
385 ven_req->wValue, ven_req->wIndex, in cx231xx_send_vendor_cmd()
386 ven_req->pBuff, ven_req->wLength, HZ); in cx231xx_send_vendor_cmd()
1474 struct VENDOR_REQUEST_IN ven_req; in cx231xx_send_gpio_cmd() local
1477 ven_req.wValue = (u16) (gpio_bit >> 16 & 0xffff); in cx231xx_send_gpio_cmd()
1482 ven_req.bRequest = VRT_GET_GPIO; /* 0x9 gpio */ in cx231xx_send_gpio_cmd()
1484 ven_req.bRequest = VRT_SET_GPIO; /* 0x8 gpio */ in cx231xx_send_gpio_cmd()
1487 ven_req.bRequest = VRT_GET_GPIE; /* 0xb gpie */ in cx231xx_send_gpio_cmd()
1489 ven_req.bRequest = VRT_SET_GPIE; /* 0xa gpie */ in cx231xx_send_gpio_cmd()
1493 ven_req.wIndex = (u16) (gpio_bit & 0xffff); in cx231xx_send_gpio_cmd()
1496 ven_req.wLength = len; in cx231xx_send_gpio_cmd()
1499 ven_req.bData = 0; in cx231xx_send_gpio_cmd()
1502 ven_req.pBuff = gpio_val; in cx231xx_send_gpio_cmd()
1506 ven_req.direction = USB_DIR_IN; in cx231xx_send_gpio_cmd()
1507 memset(ven_req.pBuff, 0x00, ven_req.wLength); in cx231xx_send_gpio_cmd()
1509 ven_req.direction = USB_DIR_OUT; in cx231xx_send_gpio_cmd()
1513 status = cx231xx_send_vendor_cmd(dev, &ven_req); in cx231xx_send_gpio_cmd()