Lines Matching full:sd
214 #define FIRMWARE_VERSION(x, y) (sd->params.version.firmwareVersion == (x) && \
215 sd->params.version.firmwareRevision == (y))
353 struct sd { struct
442 struct sd *sd = (struct sd *) gspca_dev; in do_command() local
480 sd->params.version.firmwareVersion = gspca_dev->usb_buf[0]; in do_command()
481 sd->params.version.firmwareRevision = gspca_dev->usb_buf[1]; in do_command()
482 sd->params.version.vcVersion = gspca_dev->usb_buf[2]; in do_command()
483 sd->params.version.vcRevision = gspca_dev->usb_buf[3]; in do_command()
486 sd->params.pnpID.vendor = in do_command()
488 sd->params.pnpID.product = in do_command()
490 sd->params.pnpID.deviceRevision = in do_command()
494 sd->params.status.systemState = gspca_dev->usb_buf[0]; in do_command()
495 sd->params.status.grabState = gspca_dev->usb_buf[1]; in do_command()
496 sd->params.status.streamState = gspca_dev->usb_buf[2]; in do_command()
497 sd->params.status.fatalError = gspca_dev->usb_buf[3]; in do_command()
498 sd->params.status.cmdError = gspca_dev->usb_buf[4]; in do_command()
499 sd->params.status.debugFlags = gspca_dev->usb_buf[5]; in do_command()
500 sd->params.status.vpStatus = gspca_dev->usb_buf[6]; in do_command()
501 sd->params.status.errorCode = gspca_dev->usb_buf[7]; in do_command()
504 sd->params.vpVersion.vpVersion = gspca_dev->usb_buf[0]; in do_command()
505 sd->params.vpVersion.vpRevision = gspca_dev->usb_buf[1]; in do_command()
506 sd->params.vpVersion.cameraHeadID = in do_command()
510 sd->params.colourParams.brightness = gspca_dev->usb_buf[0]; in do_command()
511 sd->params.colourParams.contrast = gspca_dev->usb_buf[1]; in do_command()
512 sd->params.colourParams.saturation = gspca_dev->usb_buf[2]; in do_command()
515 sd->params.colourBalance.redGain = gspca_dev->usb_buf[0]; in do_command()
516 sd->params.colourBalance.greenGain = gspca_dev->usb_buf[1]; in do_command()
517 sd->params.colourBalance.blueGain = gspca_dev->usb_buf[2]; in do_command()
520 sd->params.exposure.gain = gspca_dev->usb_buf[0]; in do_command()
521 sd->params.exposure.fineExp = gspca_dev->usb_buf[1]; in do_command()
522 sd->params.exposure.coarseExpLo = gspca_dev->usb_buf[2]; in do_command()
523 sd->params.exposure.coarseExpHi = gspca_dev->usb_buf[3]; in do_command()
524 sd->params.exposure.redComp = gspca_dev->usb_buf[4]; in do_command()
525 sd->params.exposure.green1Comp = gspca_dev->usb_buf[5]; in do_command()
526 sd->params.exposure.green2Comp = gspca_dev->usb_buf[6]; in do_command()
527 sd->params.exposure.blueComp = gspca_dev->usb_buf[7]; in do_command()
533 if (a != sd->params.qx3.button) { in do_command()
538 sd->params.qx3.button = a; in do_command()
540 if (sd->params.qx3.button) { in do_command()
553 sd->params.qx3.cradled = ((gspca_dev->usb_buf[2] & 0x40) == 0); in do_command()
619 struct sd *sd = (struct sd *) gspca_dev; in reset_camera_params() local
620 struct cam_params *params = &sd->params; in reset_camera_params()
670 flicker_jumps[sd->mainsFreq] in reset_camera_params()
707 struct sd *sd = (struct sd *) gspca_dev; in goto_low_power() local
718 if (sd->params.status.systemState != LO_POWER_STATE) { in goto_low_power()
719 if (sd->params.status.systemState != WARM_BOOT_STATE) { in goto_low_power()
721 sd->params.status.systemState); in goto_low_power()
722 printstatus(gspca_dev, &sd->params); in goto_low_power()
733 struct sd *sd = (struct sd *) gspca_dev; in goto_high_power() local
749 if (sd->params.status.systemState != HI_POWER_STATE) { in goto_high_power()
751 sd->params.status.systemState); in goto_high_power()
752 printstatus(gspca_dev, &sd->params); in goto_high_power()
786 struct sd *sd = (struct sd *) gspca_dev; in command_setformat() local
790 sd->params.format.videoSize, in command_setformat()
791 sd->params.format.subSample, in command_setformat()
792 sd->params.format.yuvOrder, 0); in command_setformat()
797 sd->params.roi.colStart, sd->params.roi.colEnd, in command_setformat()
798 sd->params.roi.rowStart, sd->params.roi.rowEnd); in command_setformat()
803 struct sd *sd = (struct sd *) gspca_dev; in command_setcolourparams() local
805 sd->params.colourParams.brightness, in command_setcolourparams()
806 sd->params.colourParams.contrast, in command_setcolourparams()
807 sd->params.colourParams.saturation, 0); in command_setcolourparams()
812 struct sd *sd = (struct sd *) gspca_dev; in command_setapcor() local
814 sd->params.apcor.gain1, in command_setapcor()
815 sd->params.apcor.gain2, in command_setapcor()
816 sd->params.apcor.gain4, in command_setapcor()
817 sd->params.apcor.gain8); in command_setapcor()
822 struct sd *sd = (struct sd *) gspca_dev; in command_setvloffset() local
824 sd->params.vlOffset.gain1, in command_setvloffset()
825 sd->params.vlOffset.gain2, in command_setvloffset()
826 sd->params.vlOffset.gain4, in command_setvloffset()
827 sd->params.vlOffset.gain8); in command_setvloffset()
832 struct sd *sd = (struct sd *) gspca_dev; in command_setexposure() local
836 sd->params.exposure.gainMode, in command_setexposure()
838 sd->params.exposure.compMode, in command_setexposure()
839 sd->params.exposure.centreWeight, in command_setexposure()
840 sd->params.exposure.gain, in command_setexposure()
841 sd->params.exposure.fineExp, in command_setexposure()
842 sd->params.exposure.coarseExpLo, in command_setexposure()
843 sd->params.exposure.coarseExpHi, in command_setexposure()
844 sd->params.exposure.redComp, in command_setexposure()
845 sd->params.exposure.green1Comp, in command_setexposure()
846 sd->params.exposure.green2Comp, in command_setexposure()
847 sd->params.exposure.blueComp); in command_setexposure()
851 if (sd->params.exposure.expMode != 1) { in command_setexposure()
854 sd->params.exposure.expMode, in command_setexposure()
856 sd->params.exposure.gain, in command_setexposure()
857 sd->params.exposure.fineExp, in command_setexposure()
858 sd->params.exposure.coarseExpLo, in command_setexposure()
859 sd->params.exposure.coarseExpHi, in command_setexposure()
868 struct sd *sd = (struct sd *) gspca_dev; in command_setcolourbalance() local
870 if (sd->params.colourBalance.balanceMode == 1) { in command_setcolourbalance()
875 sd->params.colourBalance.redGain, in command_setcolourbalance()
876 sd->params.colourBalance.greenGain, in command_setcolourbalance()
877 sd->params.colourBalance.blueGain); in command_setcolourbalance()
884 if (sd->params.colourBalance.balanceMode == 2) { in command_setcolourbalance()
888 if (sd->params.colourBalance.balanceMode == 3) { in command_setcolourbalance()
898 struct sd *sd = (struct sd *) gspca_dev; in command_setcompressiontarget() local
901 sd->params.compressionTarget.frTargeting, in command_setcompressiontarget()
902 sd->params.compressionTarget.targetFR, in command_setcompressiontarget()
903 sd->params.compressionTarget.targetQ, 0); in command_setcompressiontarget()
908 struct sd *sd = (struct sd *) gspca_dev; in command_setyuvtresh() local
911 sd->params.yuvThreshold.yThreshold, in command_setyuvtresh()
912 sd->params.yuvThreshold.uvThreshold, 0, 0); in command_setyuvtresh()
917 struct sd *sd = (struct sd *) gspca_dev; in command_setcompressionparams() local
922 sd->params.compressionParams.hysteresis, in command_setcompressionparams()
923 sd->params.compressionParams.threshMax, in command_setcompressionparams()
924 sd->params.compressionParams.smallStep, in command_setcompressionparams()
925 sd->params.compressionParams.largeStep, in command_setcompressionparams()
926 sd->params.compressionParams.decimationHysteresis, in command_setcompressionparams()
927 sd->params.compressionParams.frDiffStepThresh, in command_setcompressionparams()
928 sd->params.compressionParams.qDiffStepThresh, in command_setcompressionparams()
929 sd->params.compressionParams.decimationThreshMod); in command_setcompressionparams()
934 struct sd *sd = (struct sd *) gspca_dev; in command_setcompression() local
937 sd->params.compression.mode, in command_setcompression()
938 sd->params.compression.decimation, 0, 0); in command_setcompression()
943 struct sd *sd = (struct sd *) gspca_dev; in command_setsensorfps() local
946 sd->params.sensorFps.divisor, in command_setsensorfps()
947 sd->params.sensorFps.baserate, 0, 0); in command_setsensorfps()
952 struct sd *sd = (struct sd *) gspca_dev; in command_setflickerctrl() local
955 sd->params.flickerControl.flickerMode, in command_setflickerctrl()
956 sd->params.flickerControl.coarseJump, in command_setflickerctrl()
957 sd->params.flickerControl.allowableOverExposure, in command_setflickerctrl()
963 struct sd *sd = (struct sd *) gspca_dev; in command_setecptiming() local
966 sd->params.ecpTiming, 0, 0, 0); in command_setecptiming()
976 struct sd *sd = (struct sd *) gspca_dev; in command_resume() local
979 0, sd->params.streamStartLine, 0, 0); in command_resume()
984 struct sd *sd = (struct sd *) gspca_dev; in command_setlights() local
987 p1 = (sd->params.qx3.bottomlight == 0) << 1; in command_setlights()
988 p2 = (sd->params.qx3.toplight == 0) << 3; in command_setlights()
1017 struct sd *sd = (struct sd *) gspca_dev; in set_flicker() local
1018 int currentexp = sd->params.exposure.coarseExpLo + in set_flicker()
1019 sd->params.exposure.coarseExpHi * 256; in set_flicker()
1023 int cj = sd->params.flickerControl.coarseJump; in set_flicker()
1024 sd->params.flickerControl.flickerMode = 1; in set_flicker()
1025 sd->params.flickerControl.disabled = 0; in set_flicker()
1026 if (sd->params.exposure.expMode != 2) { in set_flicker()
1027 sd->params.exposure.expMode = 2; in set_flicker()
1028 sd->exposure_status = EXPOSURE_NORMAL; in set_flicker()
1030 if (sd->params.exposure.gain >= BITS_PER_TYPE(currentexp)) in set_flicker()
1032 currentexp = currentexp << sd->params.exposure.gain; in set_flicker()
1033 sd->params.exposure.gain = 0; in set_flicker()
1045 sd->params.exposure.coarseExpLo = startexp & 0xff; in set_flicker()
1046 sd->params.exposure.coarseExpHi = startexp >> 8; in set_flicker()
1050 sd->params.exposure.redComp = in set_flicker()
1052 sd->params.exposure.green1Comp = in set_flicker()
1054 sd->params.exposure.green2Comp = in set_flicker()
1056 sd->params.exposure.blueComp = in set_flicker()
1059 sd->params.exposure.redComp = COMP_RED; in set_flicker()
1060 sd->params.exposure.green1Comp = COMP_GREEN1; in set_flicker()
1061 sd->params.exposure.green2Comp = COMP_GREEN2; in set_flicker()
1062 sd->params.exposure.blueComp = COMP_BLUE; in set_flicker()
1065 sd->params.exposure.compMode = 0; in set_flicker()
1067 sd->params.exposure.compMode = 1; in set_flicker()
1069 sd->params.apcor.gain1 = 0x18; in set_flicker()
1070 sd->params.apcor.gain2 = 0x18; in set_flicker()
1071 sd->params.apcor.gain4 = 0x16; in set_flicker()
1072 sd->params.apcor.gain8 = 0x14; in set_flicker()
1074 sd->params.flickerControl.flickerMode = 0; in set_flicker()
1075 sd->params.flickerControl.disabled = 1; in set_flicker()
1078 sd->params.exposure.redComp, currentexp); in set_flicker()
1080 sd->params.exposure.green1Comp, currentexp); in set_flicker()
1082 sd->params.exposure.green2Comp, currentexp); in set_flicker()
1084 sd->params.exposure.blueComp, currentexp); in set_flicker()
1086 while (startexp > MAX_EXP && sd->params.exposure.gain < in set_flicker()
1087 sd->params.exposure.gainMode - 1) { in set_flicker()
1089 ++sd->params.exposure.gain; in set_flicker()
1095 sd->params.exposure.coarseExpLo = startexp & 0xff; in set_flicker()
1096 sd->params.exposure.coarseExpHi = startexp >> 8; in set_flicker()
1097 sd->params.exposure.redComp = COMP_RED; in set_flicker()
1098 sd->params.exposure.green1Comp = COMP_GREEN1; in set_flicker()
1099 sd->params.exposure.green2Comp = COMP_GREEN2; in set_flicker()
1100 sd->params.exposure.blueComp = COMP_BLUE; in set_flicker()
1101 sd->params.exposure.compMode = 1; in set_flicker()
1102 sd->params.apcor.gain1 = 0x18; in set_flicker()
1103 sd->params.apcor.gain2 = 0x16; in set_flicker()
1104 sd->params.apcor.gain4 = 0x24; in set_flicker()
1105 sd->params.apcor.gain8 = 0x34; in set_flicker()
1107 sd->params.vlOffset.gain1 = 20; in set_flicker()
1108 sd->params.vlOffset.gain2 = 24; in set_flicker()
1109 sd->params.vlOffset.gain4 = 26; in set_flicker()
1110 sd->params.vlOffset.gain8 = 26; in set_flicker()
1138 struct sd *sd = (struct sd *) gspca_dev; in monitor_exposure() local
1162 light_exp = sd->params.colourParams.brightness + in monitor_exposure()
1166 dark_exp = sd->params.colourParams.brightness + in monitor_exposure()
1172 old_exposure = sd->params.exposure.coarseExpHi * 256 + in monitor_exposure()
1173 sd->params.exposure.coarseExpLo; in monitor_exposure()
1175 if (!sd->params.flickerControl.disabled) { in monitor_exposure()
1184 if (sd->exposure_status == EXPOSURE_VERY_DARK) in monitor_exposure()
1185 ++sd->exposure_count; in monitor_exposure()
1187 sd->exposure_status = in monitor_exposure()
1189 sd->exposure_count = 1; in monitor_exposure()
1193 if (sd->exposure_status == EXPOSURE_DARK) in monitor_exposure()
1194 ++sd->exposure_count; in monitor_exposure()
1196 sd->exposure_status = EXPOSURE_DARK; in monitor_exposure()
1197 sd->exposure_count = 1; in monitor_exposure()
1204 if (sd->exposure_status == EXPOSURE_VERY_LIGHT) in monitor_exposure()
1205 ++sd->exposure_count; in monitor_exposure()
1207 sd->exposure_status = in monitor_exposure()
1209 sd->exposure_count = 1; in monitor_exposure()
1213 if (sd->exposure_status == EXPOSURE_LIGHT) in monitor_exposure()
1214 ++sd->exposure_count; in monitor_exposure()
1216 sd->exposure_status = EXPOSURE_LIGHT; in monitor_exposure()
1217 sd->exposure_count = 1; in monitor_exposure()
1222 sd->exposure_status = EXPOSURE_NORMAL; in monitor_exposure()
1230 if (sd->exposure_status == EXPOSURE_VERY_DARK) in monitor_exposure()
1231 ++sd->exposure_count; in monitor_exposure()
1233 sd->exposure_status = in monitor_exposure()
1235 sd->exposure_count = 1; in monitor_exposure()
1239 if (sd->exposure_status == EXPOSURE_DARK) in monitor_exposure()
1240 ++sd->exposure_count; in monitor_exposure()
1242 sd->exposure_status = EXPOSURE_DARK; in monitor_exposure()
1243 sd->exposure_count = 1; in monitor_exposure()
1250 if (sd->exposure_status == EXPOSURE_VERY_LIGHT) in monitor_exposure()
1251 ++sd->exposure_count; in monitor_exposure()
1253 sd->exposure_status = in monitor_exposure()
1255 sd->exposure_count = 1; in monitor_exposure()
1259 if (sd->exposure_status == EXPOSURE_LIGHT) in monitor_exposure()
1260 ++sd->exposure_count; in monitor_exposure()
1262 sd->exposure_status = EXPOSURE_LIGHT; in monitor_exposure()
1263 sd->exposure_count = 1; in monitor_exposure()
1268 sd->exposure_status = EXPOSURE_NORMAL; in monitor_exposure()
1272 framerate = atomic_read(&sd->fps); in monitor_exposure()
1276 if (!sd->params.flickerControl.disabled) { in monitor_exposure()
1278 if ((sd->exposure_status == EXPOSURE_VERY_DARK || in monitor_exposure()
1279 sd->exposure_status == EXPOSURE_DARK) && in monitor_exposure()
1280 sd->exposure_count >= DARK_TIME * framerate && in monitor_exposure()
1281 sd->params.sensorFps.divisor < 2) { in monitor_exposure()
1284 ++sd->params.sensorFps.divisor; in monitor_exposure()
1287 sd->params.flickerControl.coarseJump = in monitor_exposure()
1288 flicker_jumps[sd->mainsFreq] in monitor_exposure()
1289 [sd->params.sensorFps.baserate] in monitor_exposure()
1290 [sd->params.sensorFps.divisor]; in monitor_exposure()
1293 new_exposure = sd->params.flickerControl.coarseJump-1; in monitor_exposure()
1296 sd->params.flickerControl.coarseJump; in monitor_exposure()
1297 sd->params.exposure.coarseExpLo = new_exposure & 0xff; in monitor_exposure()
1298 sd->params.exposure.coarseExpHi = new_exposure >> 8; in monitor_exposure()
1300 sd->exposure_status = EXPOSURE_NORMAL; in monitor_exposure()
1303 } else if ((sd->exposure_status == EXPOSURE_VERY_LIGHT || in monitor_exposure()
1304 sd->exposure_status == EXPOSURE_LIGHT) && in monitor_exposure()
1305 sd->exposure_count >= LIGHT_TIME * framerate && in monitor_exposure()
1306 sd->params.sensorFps.divisor > 0) { in monitor_exposure()
1311 --sd->params.sensorFps.divisor; in monitor_exposure()
1314 sd->params.flickerControl.coarseJump = in monitor_exposure()
1315 flicker_jumps[sd->mainsFreq] in monitor_exposure()
1316 [sd->params.sensorFps.baserate] in monitor_exposure()
1317 [sd->params.sensorFps.divisor]; in monitor_exposure()
1320 new_exposure = sd->params.flickerControl.coarseJump-1; in monitor_exposure()
1323 sd->params.flickerControl.coarseJump < max_exp) in monitor_exposure()
1325 sd->params.flickerControl.coarseJump; in monitor_exposure()
1326 sd->params.exposure.coarseExpLo = new_exposure & 0xff; in monitor_exposure()
1327 sd->params.exposure.coarseExpHi = new_exposure >> 8; in monitor_exposure()
1329 sd->exposure_status = EXPOSURE_NORMAL; in monitor_exposure()
1334 if ((sd->exposure_status == EXPOSURE_VERY_DARK || in monitor_exposure()
1335 sd->exposure_status == EXPOSURE_DARK) && in monitor_exposure()
1336 sd->exposure_count >= DARK_TIME * framerate && in monitor_exposure()
1337 sd->params.sensorFps.divisor < 2) { in monitor_exposure()
1340 ++sd->params.sensorFps.divisor; in monitor_exposure()
1343 if (sd->params.exposure.gain > 0) { in monitor_exposure()
1344 --sd->params.exposure.gain; in monitor_exposure()
1347 sd->exposure_status = EXPOSURE_NORMAL; in monitor_exposure()
1350 } else if ((sd->exposure_status == EXPOSURE_VERY_LIGHT || in monitor_exposure()
1351 sd->exposure_status == EXPOSURE_LIGHT) && in monitor_exposure()
1352 sd->exposure_count >= LIGHT_TIME * framerate && in monitor_exposure()
1353 sd->params.sensorFps.divisor > 0) { in monitor_exposure()
1356 --sd->params.sensorFps.divisor; in monitor_exposure()
1359 if (sd->params.exposure.gain < in monitor_exposure()
1360 sd->params.exposure.gainMode - 1) { in monitor_exposure()
1361 ++sd->params.exposure.gain; in monitor_exposure()
1364 sd->exposure_status = EXPOSURE_NORMAL; in monitor_exposure()
1389 struct sd *sd = (struct sd *) gspca_dev; in restart_flicker() local
1395 cam_exposure = atomic_read(&sd->cam_exposure); in restart_flicker()
1397 if (sd->params.flickerControl.flickerMode == 0 || in restart_flicker()
1401 old_exp = sd->params.exposure.coarseExpLo + in restart_flicker()
1402 sd->params.exposure.coarseExpHi*256; in restart_flicker()
1407 cam_exposure %= sd->params.flickerControl.coarseJump; in restart_flicker()
1408 if (!sd->params.flickerControl.disabled && in restart_flicker()
1409 cam_exposure <= sd->params.flickerControl.coarseJump - 3) { in restart_flicker()
1411 sd->params.flickerControl.disabled = 1; in restart_flicker()
1414 if (sd->params.flickerControl.disabled && in restart_flicker()
1415 old_exp > sd->params.flickerControl.coarseJump + in restart_flicker()
1427 struct sd *sd = (struct sd *) gspca_dev; in sd_config() local
1430 sd->mainsFreq = FREQ_DEF == V4L2_CID_POWER_LINE_FREQUENCY_60HZ; in sd_config()
1442 sd->params.version.firmwareVersion = 0; in sd_config()
1444 if (sd->params.version.firmwareVersion != 1) { in sd_config()
1446 sd->params.version.firmwareVersion); in sd_config()
1451 if (sd->params.version.firmwareRevision <= 2 && in sd_config()
1452 sd->params.exposure.gainMode > 2) { in sd_config()
1453 sd->params.exposure.gainMode = 2; in sd_config()
1457 sd->params.qx3.qx3_detected = (sd->params.pnpID.vendor == 0x0813 && in sd_config()
1458 sd->params.pnpID.product == 0x0001); in sd_config()
1465 struct sd *sd = (struct sd *) gspca_dev; in sd_start() local
1470 if (sd->params.status.systemState != WARM_BOOT_STATE) { in sd_start()
1472 sd->params.status.systemState); in sd_start()
1473 printstatus(gspca_dev, &sd->params); in sd_start()
1495 sd->params.version.firmwareVersion = 0; in sd_start()
1518 if (sd->params.status.fatalError) { in sd_start()
1520 sd->params.status.fatalError, in sd_start()
1521 sd->params.status.vpStatus); in sd_start()
1532 sd->params.streamStartLine = 120; in sd_start()
1536 sd->params.roi.colStart = 2; in sd_start()
1537 sd->params.roi.rowStart = 6; in sd_start()
1539 sd->params.roi.colStart = 0; in sd_start()
1540 sd->params.roi.rowStart = 0; in sd_start()
1544 sd->params.format.videoSize = VIDEOSIZE_QCIF; in sd_start()
1545 sd->params.roi.colStart /= 2; in sd_start()
1546 sd->params.roi.rowStart /= 2; in sd_start()
1547 sd->params.streamStartLine /= 2; in sd_start()
1549 sd->params.format.videoSize = VIDEOSIZE_CIF; in sd_start()
1551 sd->params.roi.colEnd = sd->params.roi.colStart + in sd_start()
1553 sd->params.roi.rowEnd = sd->params.roi.rowStart + in sd_start()
1612 sd->first_frame = 6; in sd_start()
1613 sd->exposure_status = EXPOSURE_NORMAL; in sd_start()
1614 sd->exposure_count = 0; in sd_start()
1615 atomic_set(&sd->cam_exposure, 0); in sd_start()
1616 atomic_set(&sd->fps, 0); in sd_start()
1623 struct sd *sd __maybe_unused = (struct sd *) gspca_dev; in sd_stopN()
1638 if (sd->params.qx3.button) { in sd_stopN()
1640 the latch, so we do not reset sd->params.qx3.button now, to in sd_stopN()
1651 struct sd *sd = (struct sd *) gspca_dev; in sd_init() local
1663 if (sd->params.qx3.qx3_detected) in sd_init()
1669 sd->params.version.firmwareVersion, in sd_init()
1670 sd->params.version.firmwareRevision, in sd_init()
1671 sd->params.version.vcVersion, in sd_init()
1672 sd->params.version.vcRevision); in sd_init()
1674 sd->params.pnpID.vendor, sd->params.pnpID.product, in sd_init()
1675 sd->params.pnpID.deviceRevision); in sd_init()
1677 sd->params.vpVersion.vpVersion, in sd_init()
1678 sd->params.vpVersion.vpRevision, in sd_init()
1679 sd->params.vpVersion.cameraHeadID); in sd_init()
1688 struct sd *sd = (struct sd *) gspca_dev; in sd_pkt_scan() local
1693 data[16] == sd->params.format.videoSize && in sd_pkt_scan()
1694 data[17] == sd->params.format.subSample && in sd_pkt_scan()
1695 data[18] == sd->params.format.yuvOrder && in sd_pkt_scan()
1696 data[24] == sd->params.roi.colStart && in sd_pkt_scan()
1697 data[25] == sd->params.roi.colEnd && in sd_pkt_scan()
1698 data[26] == sd->params.roi.rowStart && in sd_pkt_scan()
1699 data[27] == sd->params.roi.rowEnd) { in sd_pkt_scan()
1702 atomic_set(&sd->cam_exposure, data[39] * 2); in sd_pkt_scan()
1703 atomic_set(&sd->fps, data[41]); in sd_pkt_scan()
1725 struct sd *sd = (struct sd *) gspca_dev; in sd_dq_callback() local
1729 if (sd->first_frame) { in sd_dq_callback()
1730 sd->first_frame--; in sd_dq_callback()
1731 if (sd->first_frame == 0) in sd_dq_callback()
1740 if (sd->params.exposure.expMode == 2) in sd_dq_callback()
1752 struct sd *sd = (struct sd *)gspca_dev; in sd_s_ctrl() local
1761 sd->params.colourParams.brightness = ctrl->val; in sd_s_ctrl()
1762 sd->params.flickerControl.allowableOverExposure = in sd_s_ctrl()
1763 find_over_exposure(sd->params.colourParams.brightness); in sd_s_ctrl()
1769 sd->params.colourParams.contrast = ctrl->val; in sd_s_ctrl()
1773 sd->params.colourParams.saturation = ctrl->val; in sd_s_ctrl()
1777 sd->mainsFreq = ctrl->val == V4L2_CID_POWER_LINE_FREQUENCY_60HZ; in sd_s_ctrl()
1778 sd->params.flickerControl.coarseJump = in sd_s_ctrl()
1779 flicker_jumps[sd->mainsFreq] in sd_s_ctrl()
1780 [sd->params.sensorFps.baserate] in sd_s_ctrl()
1781 [sd->params.sensorFps.divisor]; in sd_s_ctrl()
1788 sd->params.qx3.bottomlight = ctrl->val; in sd_s_ctrl()
1792 sd->params.qx3.toplight = ctrl->val; in sd_s_ctrl()
1796 sd->params.compressionTarget.frTargeting = ctrl->val; in sd_s_ctrl()
1809 struct sd *sd = (struct sd *)gspca_dev; in sd_init_controls() local
1834 sd->freq = v4l2_ctrl_new_std_menu(hdl, &sd_ctrl_ops, in sd_init_controls()
1838 if (sd->params.qx3.qx3_detected) { in sd_init_controls()
1882 return gspca_dev_probe(intf, id, &sd_desc, sizeof(struct sd), in sd_probe()