diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2009-09-06 06:54:00 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-09-18 23:19:34 -0400 |
commit | 6b5270d21202fcf6ae16a6266fed83a30ccece7a (patch) | |
tree | 54036a74de819e7d6a63f7572ecf37b0a00ac94c /include | |
parent | 5062cb70c828bd7b2a8223390ae836c5baa250b9 (diff) |
V4L/DVB (12725): v4l: warn when desired devnodenr is in use & add _no_warn function
Warn when the desired device node number is already in use, except when
the new video_register_device_no_warn function is called since in some
use-cases that warning is not relevant.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/media/v4l2-dev.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/media/v4l2-dev.h b/include/media/v4l2-dev.h index 255f6442b635..73c9867d744c 100644 --- a/include/media/v4l2-dev.h +++ b/include/media/v4l2-dev.h | |||
@@ -101,6 +101,10 @@ struct video_device | |||
101 | Also note that vdev->minor is set to -1 if the registration failed. */ | 101 | Also note that vdev->minor is set to -1 if the registration failed. */ |
102 | int __must_check video_register_device(struct video_device *vdev, int type, int nr); | 102 | int __must_check video_register_device(struct video_device *vdev, int type, int nr); |
103 | 103 | ||
104 | /* Same as video_register_device, but no warning is issued if the desired | ||
105 | device node number was already in use. */ | ||
106 | int __must_check video_register_device_no_warn(struct video_device *vdev, int type, int nr); | ||
107 | |||
104 | /* Unregister video devices. Will do nothing if vdev == NULL or | 108 | /* Unregister video devices. Will do nothing if vdev == NULL or |
105 | vdev->minor < 0. */ | 109 | vdev->minor < 0. */ |
106 | void video_unregister_device(struct video_device *vdev); | 110 | void video_unregister_device(struct video_device *vdev); |