<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic VIDIOC_DQBUF failed in i.MX Processors</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/VIDIOC-DQBUF-failed/m-p/711324#M110596</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Recently, I modified the driver of tvp5150 according to the driver of adc7180 for imx6q.&lt;/P&gt;&lt;P&gt;Amend as follows：&lt;/P&gt;&lt;P&gt;1、In tvp5150_probe fuction, I added like this :&lt;/P&gt;&lt;P&gt;tvin_plat = c-&amp;gt;dev.platform_data;&lt;BR /&gt; if (tvin_plat-&amp;gt;dvddio_reg) {&lt;BR /&gt; dvddio_regulator =&lt;BR /&gt; regulator_get(&amp;amp;c-&amp;gt;dev, tvin_plat-&amp;gt;dvddio_reg);&lt;BR /&gt; if (!IS_ERR_VALUE((unsigned long)dvddio_regulator)) {&lt;BR /&gt; regulator_set_voltage(dvddio_regulator, 3300000, 3300000);&lt;BR /&gt; if (regulator_enable(dvddio_regulator) != 0)&lt;BR /&gt; return -ENODEV;&lt;BR /&gt; }&lt;BR /&gt; }&lt;/P&gt;&lt;P&gt;if (tvin_plat-&amp;gt;dvdd_reg) {&lt;BR /&gt; dvdd_regulator =&lt;BR /&gt; regulator_get(&amp;amp;c-&amp;gt;dev, tvin_plat-&amp;gt;dvdd_reg);&lt;BR /&gt; if (!IS_ERR_VALUE((unsigned long)dvdd_regulator)) {&lt;BR /&gt; regulator_set_voltage(dvdd_regulator, 1800000, 1800000);&lt;BR /&gt; if (regulator_enable(dvdd_regulator) != 0)&lt;BR /&gt; return -ENODEV;&lt;BR /&gt; }&lt;BR /&gt; }&lt;/P&gt;&lt;P&gt;if (tvin_plat-&amp;gt;avdd_reg) {&lt;BR /&gt; avdd_regulator =&lt;BR /&gt; regulator_get(&amp;amp;c-&amp;gt;dev, tvin_plat-&amp;gt;avdd_reg);&lt;BR /&gt; if (!IS_ERR_VALUE((unsigned long)avdd_regulator)) {&lt;BR /&gt; regulator_set_voltage(avdd_regulator, 1800000, 1800000);&lt;BR /&gt; if (regulator_enable(avdd_regulator) != 0)&lt;BR /&gt; return -ENODEV;&lt;BR /&gt; }&lt;BR /&gt; }&lt;/P&gt;&lt;P&gt;if (tvin_plat-&amp;gt;pvdd_reg) {&lt;BR /&gt; pvdd_regulator =&lt;BR /&gt; regulator_get(&amp;amp;c-&amp;gt;dev, tvin_plat-&amp;gt;pvdd_reg);&lt;BR /&gt; if (!IS_ERR_VALUE((unsigned long)pvdd_regulator)) {&lt;BR /&gt; regulator_set_voltage(pvdd_regulator, 1800000, 1800000);&lt;BR /&gt; if (regulator_enable(pvdd_regulator) != 0)&lt;BR /&gt; return -ENODEV;&lt;BR /&gt; }&lt;BR /&gt; }&lt;/P&gt;&lt;P&gt;if (tvin_plat-&amp;gt;io_init)&lt;BR /&gt; tvin_plat-&amp;gt;io_init();&lt;BR /&gt; msleep(1);&lt;BR /&gt; /* Set initial values for the sensor struct. */&lt;BR /&gt; memset(&amp;amp;tvp5150_data, 0, sizeof(tvp5150_data));&lt;BR /&gt; tvp5150_data.sen.i2c_client = c;&lt;BR /&gt; tvp5150_data.sen.streamcap.timeperframe.denominator = 30;&lt;BR /&gt; tvp5150_data.sen.streamcap.timeperframe.numerator = 1;&lt;BR /&gt; tvp5150_data.std_id = V4L2_STD_ALL;&lt;BR /&gt; video_idx = TVP5150_NOT_LOCKED;&lt;BR /&gt; tvp5150_data.sen.pix.width = video_fmts[video_idx].raw_width;&lt;BR /&gt; tvp5150_data.sen.pix.height = video_fmts[video_idx].raw_height;&lt;BR /&gt; tvp5150_data.sen.pix.pixelformat = V4L2_PIX_FMT_UYVY; /* YUV422 */&lt;BR /&gt; tvp5150_data.sen.pix.priv = 1; /* 1 is used to indicate TV in */&lt;BR /&gt; tvp5150_data.sen.on = true;&lt;BR /&gt; tvp5150_data.sen.csi = 0;&lt;BR /&gt; tvp5150_data.sen.mclk = 0;&lt;BR /&gt; tvp5150_data.sen.mclk_source = 0;&lt;/P&gt;&lt;P&gt;gpio_sensor_active();&lt;BR /&gt; tvp5150_int_device.priv = &amp;amp;tvp5150_data;&lt;BR /&gt; v4l2_int_device_register(&amp;amp;tvp5150_int_device);&lt;/P&gt;&lt;P&gt;2、&lt;/P&gt;&lt;P&gt;static struct v4l2_int_ioctl_desc tvp5150_ioctl_desc[] = {&lt;/P&gt;&lt;P&gt;{vidioc_int_dev_init_num, (v4l2_int_ioctl_func*)ioctl_dev_init},&lt;/P&gt;&lt;P&gt;{vidioc_int_g_ifparm_num, (v4l2_int_ioctl_func*)ioctl_g_ifparm},&lt;BR /&gt;{vidioc_int_init_num, (v4l2_int_ioctl_func*)ioctl_init},&lt;/P&gt;&lt;P&gt;{vidioc_int_g_fmt_cap_num, (v4l2_int_ioctl_func*)ioctl_g_fmt_cap},&lt;/P&gt;&lt;P&gt;{vidioc_int_g_fmt_cap_num, (v4l2_int_ioctl_func*)ioctl_g_fmt_cap},&lt;/P&gt;&lt;P&gt;{vidioc_int_enum_framesizes_num,&amp;nbsp;(v4l2_int_ioctl_func *) ioctl_enum_framesizes},&lt;BR /&gt; {vidioc_int_g_chip_ident_num,&amp;nbsp;(v4l2_int_ioctl_func *)ioctl_g_chip_ident},&lt;BR /&gt;};&lt;/P&gt;&lt;P&gt;Every fuction is same as adv7180 driver!&lt;/P&gt;&lt;P&gt;3、&lt;/P&gt;&lt;P&gt;static struct v4l2_int_slave tvp5150_slave = {&lt;BR /&gt; .ioctls = tvp5150_ioctl_desc,&lt;BR /&gt; .num_ioctls = ARRAY_SIZE(tvp5150_ioctl_desc),&lt;BR /&gt;};&lt;/P&gt;&lt;P&gt;static struct v4l2_int_device tvp5150_int_device = {&lt;BR /&gt; .module = THIS_MODULE,&lt;BR /&gt; .name = "tvp5150",&lt;BR /&gt; .type = v4l2_int_type_slave,&lt;BR /&gt; .u = {&lt;BR /&gt; .slave = &amp;amp;tvp5150_slave,&lt;BR /&gt; },&lt;BR /&gt;};&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am sure the tvp5150 chip is configured to output BT656 data.&lt;/P&gt;&lt;P&gt;As result, I run my image capture procedure, the print information as follow:&lt;/P&gt;&lt;P&gt;ERROR: v4l2 capture: mxc_v4l_dqueue timeout enc_counter 0&lt;BR /&gt;VIDIOC_DQBUF failed&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 21 Oct 2017 06:41:22 GMT</pubDate>
    <dc:creator>yanglv</dc:creator>
    <dc:date>2017-10-21T06:41:22Z</dc:date>
    <item>
      <title>VIDIOC_DQBUF failed</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/VIDIOC-DQBUF-failed/m-p/711324#M110596</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Recently, I modified the driver of tvp5150 according to the driver of adc7180 for imx6q.&lt;/P&gt;&lt;P&gt;Amend as follows：&lt;/P&gt;&lt;P&gt;1、In tvp5150_probe fuction, I added like this :&lt;/P&gt;&lt;P&gt;tvin_plat = c-&amp;gt;dev.platform_data;&lt;BR /&gt; if (tvin_plat-&amp;gt;dvddio_reg) {&lt;BR /&gt; dvddio_regulator =&lt;BR /&gt; regulator_get(&amp;amp;c-&amp;gt;dev, tvin_plat-&amp;gt;dvddio_reg);&lt;BR /&gt; if (!IS_ERR_VALUE((unsigned long)dvddio_regulator)) {&lt;BR /&gt; regulator_set_voltage(dvddio_regulator, 3300000, 3300000);&lt;BR /&gt; if (regulator_enable(dvddio_regulator) != 0)&lt;BR /&gt; return -ENODEV;&lt;BR /&gt; }&lt;BR /&gt; }&lt;/P&gt;&lt;P&gt;if (tvin_plat-&amp;gt;dvdd_reg) {&lt;BR /&gt; dvdd_regulator =&lt;BR /&gt; regulator_get(&amp;amp;c-&amp;gt;dev, tvin_plat-&amp;gt;dvdd_reg);&lt;BR /&gt; if (!IS_ERR_VALUE((unsigned long)dvdd_regulator)) {&lt;BR /&gt; regulator_set_voltage(dvdd_regulator, 1800000, 1800000);&lt;BR /&gt; if (regulator_enable(dvdd_regulator) != 0)&lt;BR /&gt; return -ENODEV;&lt;BR /&gt; }&lt;BR /&gt; }&lt;/P&gt;&lt;P&gt;if (tvin_plat-&amp;gt;avdd_reg) {&lt;BR /&gt; avdd_regulator =&lt;BR /&gt; regulator_get(&amp;amp;c-&amp;gt;dev, tvin_plat-&amp;gt;avdd_reg);&lt;BR /&gt; if (!IS_ERR_VALUE((unsigned long)avdd_regulator)) {&lt;BR /&gt; regulator_set_voltage(avdd_regulator, 1800000, 1800000);&lt;BR /&gt; if (regulator_enable(avdd_regulator) != 0)&lt;BR /&gt; return -ENODEV;&lt;BR /&gt; }&lt;BR /&gt; }&lt;/P&gt;&lt;P&gt;if (tvin_plat-&amp;gt;pvdd_reg) {&lt;BR /&gt; pvdd_regulator =&lt;BR /&gt; regulator_get(&amp;amp;c-&amp;gt;dev, tvin_plat-&amp;gt;pvdd_reg);&lt;BR /&gt; if (!IS_ERR_VALUE((unsigned long)pvdd_regulator)) {&lt;BR /&gt; regulator_set_voltage(pvdd_regulator, 1800000, 1800000);&lt;BR /&gt; if (regulator_enable(pvdd_regulator) != 0)&lt;BR /&gt; return -ENODEV;&lt;BR /&gt; }&lt;BR /&gt; }&lt;/P&gt;&lt;P&gt;if (tvin_plat-&amp;gt;io_init)&lt;BR /&gt; tvin_plat-&amp;gt;io_init();&lt;BR /&gt; msleep(1);&lt;BR /&gt; /* Set initial values for the sensor struct. */&lt;BR /&gt; memset(&amp;amp;tvp5150_data, 0, sizeof(tvp5150_data));&lt;BR /&gt; tvp5150_data.sen.i2c_client = c;&lt;BR /&gt; tvp5150_data.sen.streamcap.timeperframe.denominator = 30;&lt;BR /&gt; tvp5150_data.sen.streamcap.timeperframe.numerator = 1;&lt;BR /&gt; tvp5150_data.std_id = V4L2_STD_ALL;&lt;BR /&gt; video_idx = TVP5150_NOT_LOCKED;&lt;BR /&gt; tvp5150_data.sen.pix.width = video_fmts[video_idx].raw_width;&lt;BR /&gt; tvp5150_data.sen.pix.height = video_fmts[video_idx].raw_height;&lt;BR /&gt; tvp5150_data.sen.pix.pixelformat = V4L2_PIX_FMT_UYVY; /* YUV422 */&lt;BR /&gt; tvp5150_data.sen.pix.priv = 1; /* 1 is used to indicate TV in */&lt;BR /&gt; tvp5150_data.sen.on = true;&lt;BR /&gt; tvp5150_data.sen.csi = 0;&lt;BR /&gt; tvp5150_data.sen.mclk = 0;&lt;BR /&gt; tvp5150_data.sen.mclk_source = 0;&lt;/P&gt;&lt;P&gt;gpio_sensor_active();&lt;BR /&gt; tvp5150_int_device.priv = &amp;amp;tvp5150_data;&lt;BR /&gt; v4l2_int_device_register(&amp;amp;tvp5150_int_device);&lt;/P&gt;&lt;P&gt;2、&lt;/P&gt;&lt;P&gt;static struct v4l2_int_ioctl_desc tvp5150_ioctl_desc[] = {&lt;/P&gt;&lt;P&gt;{vidioc_int_dev_init_num, (v4l2_int_ioctl_func*)ioctl_dev_init},&lt;/P&gt;&lt;P&gt;{vidioc_int_g_ifparm_num, (v4l2_int_ioctl_func*)ioctl_g_ifparm},&lt;BR /&gt;{vidioc_int_init_num, (v4l2_int_ioctl_func*)ioctl_init},&lt;/P&gt;&lt;P&gt;{vidioc_int_g_fmt_cap_num, (v4l2_int_ioctl_func*)ioctl_g_fmt_cap},&lt;/P&gt;&lt;P&gt;{vidioc_int_g_fmt_cap_num, (v4l2_int_ioctl_func*)ioctl_g_fmt_cap},&lt;/P&gt;&lt;P&gt;{vidioc_int_enum_framesizes_num,&amp;nbsp;(v4l2_int_ioctl_func *) ioctl_enum_framesizes},&lt;BR /&gt; {vidioc_int_g_chip_ident_num,&amp;nbsp;(v4l2_int_ioctl_func *)ioctl_g_chip_ident},&lt;BR /&gt;};&lt;/P&gt;&lt;P&gt;Every fuction is same as adv7180 driver!&lt;/P&gt;&lt;P&gt;3、&lt;/P&gt;&lt;P&gt;static struct v4l2_int_slave tvp5150_slave = {&lt;BR /&gt; .ioctls = tvp5150_ioctl_desc,&lt;BR /&gt; .num_ioctls = ARRAY_SIZE(tvp5150_ioctl_desc),&lt;BR /&gt;};&lt;/P&gt;&lt;P&gt;static struct v4l2_int_device tvp5150_int_device = {&lt;BR /&gt; .module = THIS_MODULE,&lt;BR /&gt; .name = "tvp5150",&lt;BR /&gt; .type = v4l2_int_type_slave,&lt;BR /&gt; .u = {&lt;BR /&gt; .slave = &amp;amp;tvp5150_slave,&lt;BR /&gt; },&lt;BR /&gt;};&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am sure the tvp5150 chip is configured to output BT656 data.&lt;/P&gt;&lt;P&gt;As result, I run my image capture procedure, the print information as follow:&lt;/P&gt;&lt;P&gt;ERROR: v4l2 capture: mxc_v4l_dqueue timeout enc_counter 0&lt;BR /&gt;VIDIOC_DQBUF failed&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 21 Oct 2017 06:41:22 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/VIDIOC-DQBUF-failed/m-p/711324#M110596</guid>
      <dc:creator>yanglv</dc:creator>
      <dc:date>2017-10-21T06:41:22Z</dc:date>
    </item>
    <item>
      <title>Re: VIDIOC_DQBUF failed</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/VIDIOC-DQBUF-failed/m-p/711325#M110597</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Yang&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for sensors with BT656 format there is special unit test program: mxc_v4l2_tvin,&lt;/P&gt;&lt;P&gt;first please try with it :&lt;/P&gt;&lt;P&gt;imx-test&lt;BR /&gt;&lt;A href="https://community.nxp.com/www.nxp.com/lgfiles/NMG/MAD/YOCTO/imx-test-5.7.tar.gz" target="test_blank"&gt;www.nxp.com/lgfiles/NMG/MAD/YOCTO/imx-test-5.7.tar.gz&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards&lt;BR /&gt;igor&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 Oct 2017 07:47:02 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/VIDIOC-DQBUF-failed/m-p/711325#M110597</guid>
      <dc:creator>igorpadykov</dc:creator>
      <dc:date>2017-10-26T07:47:02Z</dc:date>
    </item>
    <item>
      <title>Re: VIDIOC_DQBUF failed</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/VIDIOC-DQBUF-failed/m-p/711326#M110598</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Yang,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Did you find a solution for:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[ 231.524060] ERROR: v4l2 capture: mxc_v4l_dqueue timeout enc_counter 0&lt;BR /&gt;VIDIOC_DQBUF failed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Umit&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Oct 2019 06:55:28 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/VIDIOC-DQBUF-failed/m-p/711326#M110598</guid>
      <dc:creator>umit_kayacik</dc:creator>
      <dc:date>2019-10-08T06:55:28Z</dc:date>
    </item>
    <item>
      <title>Re: VIDIOC_DQBUF failed</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/VIDIOC-DQBUF-failed/m-p/711327#M110599</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm also facing same issue. Could any one suggest any solution.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Oct 2019 16:52:14 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/VIDIOC-DQBUF-failed/m-p/711327#M110599</guid>
      <dc:creator>vinodkumart</dc:creator>
      <dc:date>2019-10-23T16:52:14Z</dc:date>
    </item>
    <item>
      <title>Re: VIDIOC_DQBUF failed</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/VIDIOC-DQBUF-failed/m-p/711328#M110600</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I fixed this issue by removing all other pins(Like Data_En etc) except the 8-parallel lines from dts file and it worked.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Nov 2019 11:26:56 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/VIDIOC-DQBUF-failed/m-p/711328#M110600</guid>
      <dc:creator>vinodkumart</dc:creator>
      <dc:date>2019-11-22T11:26:56Z</dc:date>
    </item>
  </channel>
</rss>

