[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-11-09 Thread Russell Neches
Confirmed that with v4l2loopback-dkms 0.12.3-1ubuntu0.1, configured
devices are not correctly advertised. This breaks Zoom, Cheese, etc.
Compiling v4l2loopback from upstream source works correctly.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-11-03 Thread Stefan Bader
Right now, the only app that appears to work with the new module is
Chromium. Which was where I was testing because that seemed more
demanding. Will be working on the regression on bug 1901491.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-11-02 Thread emptythevoid
Can confirm, this change prevents Zoom from listing my v4l2lsink from
OBS.  I had to downgrade to the "base" package so that my co-workers can
continue to see my stupid effects and overlays.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-11-02 Thread Stefan Bader
No, looking quickly at the code that should be set in the capabilities
returned by the query capabilities call. But not in the static
device_caps. And if that is added back, one cannot drop that flag for
exclusive_caps functionality without triggering repeated kernel
warnings.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-11-02 Thread Stefan Bader
Would loading the new module with exclusive_caps=1 work as a quick work-
around. I guess I missed adding the caps explicitly in the query
function. So that relies on thing being set as device caps.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-11-02 Thread Raphaël
The last fix also broke v4l2loopback for me. Most applications seem to
check the V4L2_CAP_VIDEO_CAPTURE flag (eg Firefox:
https://hg.mozilla.org/releases/mozilla-
release/file/aac9479c6a32ce3b95556da24f3b00c00e145506/media/webrtc/trunk/webrtc/modules/video_capture/linux/device_info_linux.cc#l386),
which is now unset by the fix. This means apps such as Firefox do not
detect virtual cameras created by v4l2loopback with this patch.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-10-31 Thread bx
This fix has rendered v4l2loopback obsolete. Indeed, the device is no longer 
detected by any applications (e.g. VLC, Firefox, etc.).
I had to revert to the previous version to be able to use it again.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-10-29 Thread Launchpad Bug Tracker
This bug was fixed in the package v4l2loopback - 0.12.3-1ubuntu0.1

---
v4l2loopback (0.12.3-1ubuntu0.1) focal; urgency=medium

  * Fix kernel warnings triggered by vidioc_querycap (LP: #1899633).

 -- Stefan Bader   Tue, 13 Oct 2020 15:07:55
+0200

** Changed in: v4l2loopback (Ubuntu Focal)
   Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-10-21 Thread Stefan Bader
$ dpkg -l|grep v4l2loop
ii  v4l2loopback-dkms   0.12.3-1ubuntu0.1   
all  Source for the v4l2loopback driver (DKMS)
ii  v4l2loopback-utils  0.12.3-1ubuntu0.1   
all  Commandline utilities for the for the v4l2-loopback module

$ dkms status|grep v4l2
v4l2loopback, 0.12.3, 5.4.0-51-generic, x86_64: installed
v4l2loopback, 0.12.3, 5.4.0-52-generic, x86_64: installed

$ modprobe v4l2loopback exclusive_caps=1
$ dmesg|grep v4l2-ioctl


I already was using the updated code, so I repeated the steps in a VM
with the current version of the driver and got the following in dmesg:

[  471.604470] WARNING: CPU: 1 PID: 18911 at 
drivers/media/v4l2-core/v4l2-ioctl.c:1064 v4l_querycap+0x8b/0xa0 [videodev]
[  471.604602] WARNING: CPU: 1 PID: 18911 at 
drivers/media/v4l2-core/v4l2-ioctl.c:1069 v4l_querycap+0x8f/0xa0 [videodev]

** Tags removed: verification-needed verification-needed-focal
** Tags added: verification-done verification-done-focal

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-10-20 Thread Brian Murray
Hello Stefan, or anyone else affected,

Accepted v4l2loopback into focal-proposed. The package will build now
and be available at
https://launchpad.net/ubuntu/+source/v4l2loopback/0.12.3-1ubuntu0.1 in a
few hours, and then in the -proposed repository.

Please help us by testing this new package.  See
https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how
to enable and use -proposed.  Your feedback will aid us getting this
update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug,
mentioning the version of the package you tested, what testing has been
performed on the package and change the tag from verification-needed-
focal to verification-done-focal. If it does not fix the bug for you,
please add a comment stating that, and change the tag to verification-
failed-focal. In either case, without details of your testing we will
not be able to proceed.

Further information regarding the verification process can be found at
https://wiki.ubuntu.com/QATeam/PerformingSRUVerification .  Thank you in
advance for helping!

N.B. The updated package will be released to -updates after the bug(s)
fixed by this package have been verified and the package has been in
-proposed for a minimum of 7 days.

** Changed in: v4l2loopback (Ubuntu Focal)
   Status: In Progress => Fix Committed

** Tags added: verification-needed verification-needed-focal

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-10-19 Thread Christian Ehrhardt 
Thanks for the updated debdiff as requested, LGTM now.
Some minor cleanup 0.12.3-1ubuntu1 -> 0.12.3-1ubuntu0.1

Further I think we should add DKMS rebuild with the Focal kernel as
test-step explicitly (it will be done on install of the upgrade anyway,
but to be formally correct)

** Description changed:

  Release: 20.04/Focal Fossa
  
  [SRU Justification]
  
  Impact: Starting with kernel version 5.4 the v4l2-core started to add
  sanity checking on drivers when querying capabilities. First drivers are
  not supposed to modify an initially set device_caps attribute. And
  second, the returned set of capabilities must be a superset of those in
  device_caps. The v4l2loopback module fails on both checks which results
  in repeated warnings (with additional stack trace) starting with:
  
  - WARNING: CPU: 2 PID: 7234 at drivers/media/v4l2-core/v4l2-ioctl.c:1064 
v4l_querycap+0x8f/0xa0 [videodev]
  - WARNING: CPU: 2 PID: 7234 at drivers/media/v4l2-core/v4l2-ioctl.c:1069 
v4l_querycap+0x8f/0xa0 [videodev]
  
- Fix: The proposed fix adds compat code which stops modifying device_caps
- after initial setup for kernel versions 5.4 and later. Also for those
- versions the initial setup excludes V4L2_CAP_VIDEO_CAPTURE and
- V4L2_CAP_VIDEO_OUTPUT as those capabilities might be optionally set when
- calling v4l_querycap() to indicate readyness.
+ Fix:
+ The proposed fix adds compat code which stops modifying device_caps after 
initial setup for kernel versions 5.4 and later. Also for those versions the 
initial setup excludes V4L2_CAP_VIDEO_CAPTURE and V4L2_CAP_VIDEO_OUTPUT as 
those capabilities might be optionally set when calling v4l_querycap() to 
indicate readyness.
  
- Testcase: Inserting the DKMS module the following way should start showing 
the above warnings:
-   sudo modprobe v4l2loopback exclusive_caps=1
- Once the fixed version is used, there should no longer be any warnings.
+ Testcase:
+ #1
+DKMS build the updated version (should be implicitly done on an
+upgrade of v4l2loopback)
+But one can try to rebuild explicitly and check if any warnings are 
+given. This would be extra useful if a pre 5.4 kernel could be used as 
+well (not officially part of focal, therefore optional)
  
- Regression Potential: The change affects the internal device_caps
- variable only. If that is unexpectedly used by anything external (the
- kernel code should be assumed to expect the modified form) the loopback
- device might become unusable for recording/playback. I have been using
- the modified driver for a while now as v4l2sink in obs-studio and saw
- now issues.
+ #2
+Inserting the DKMS module the following way should start showing the 
+above warnings:
+      $ sudo modprobe v4l2loopback exclusive_caps=1
+Once the fixed version is used, there should no longer be any warnings.
+ 
+ Regression Potential:
+ The change affects the internal device_caps variable only. If that is 
unexpectedly used by anything external (the kernel code should be assumed to 
expect the modified form) the loopback device might become unusable for 
recording/playback. I have been using the modified driver for a while now as 
v4l2sink in obs-studio and saw now issues.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-10-19 Thread Christian Ehrhardt 
FYI: I was on the receiving end of a video call using this updated
driver - I can confirm it works.

Reviewed, made some minor fixups (version as mentioned), extended the
SRU template n the description and sponsored into Focal-proposed

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-10-19 Thread Stefan Bader
The kernel check was added in [1] v5.4-rc1 by:

Author: Hans Verkuil 
Date:   Tue Jul 23 04:21:25 2019 -0400

media: v4l2-dev/ioctl: require non-zero device_caps, verify sane querycap 
results

Now that all V4L2 drivers set device_caps in struct video_device, we can add
a check for this to ensure all future drivers fill this in.

Also verify that when the querycap ioctl is called the driver didn't mess
with the device_caps value and that capabilities is a superset of 
device_caps.

Signed-off-by: Hans Verkuil 
Reviewed-by: Sakari Ailus 
[hverkuil-ci...@xs4all.nl: fix too-long line]
Signed-off-by: Mauro Carvalho Chehab 


[1] 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=3c1350501c21db8e3b1a38d9e97db29694305c3b

** Patch added: "v2: clarify why upstreaming is not needed"
   
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+attachment/5424119/+files/focal-proposed-fix.debdiff

** Patch removed: "focal-proposed-fix.debdiff"
   
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+attachment/5421730/+files/focal-proposed-fix.debdiff

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-10-13 Thread Stefan Bader
Test build uploaded to:
https://launchpad.net/~smb/+archive/ubuntu/focal/+packages

The attached debdiff contains the proposed adjustments to the DKMS
package.

** Patch added: "focal-proposed-fix.debdiff"
   
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+attachment/5421730/+files/focal-proposed-fix.debdiff

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1899633] Re: Repeated kernel warnings/stacktraces with kernel 5.4 and newer

2020-10-13 Thread Stefan Bader
The 20.10 version (0.12.5-1) was reworked considerably and I was told by
someone else that it would not exhibit those warnings.

** Changed in: v4l2loopback (Ubuntu)
   Status: In Progress => Fix Released

** Changed in: v4l2loopback (Ubuntu)
 Assignee: Stefan Bader (smb) => (unassigned)

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1899633

Title:
  Repeated kernel warnings/stacktraces with kernel 5.4 and newer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/v4l2loopback/+bug/1899633/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs