mirror of
https://github.com/torvalds/linux.git
synced 2026-05-28 09:04:39 +02:00
media: uvcvideo: Remove nodrop parameter
We announced the deprecation intentions one year ago in the commit
commit 40ed9e9b28 ("media: uvcvideo: Announce the user our deprecation
intentions").
We have not hear any complains, lets remove the nodrop parameter.
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Ricardo Ribalda <ribalda@chromium.org>
Reviewed-by: Hans de Goede <johannes.goede@oss.qualcomm.com>
Signed-off-by: Hans de Goede <johannes.goede@oss.qualcomm.com>
Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
This commit is contained in:
parent
f0487a90b2
commit
27ccc44a51
|
|
@ -32,7 +32,6 @@
|
||||||
|
|
||||||
unsigned int uvc_clock_param = CLOCK_MONOTONIC;
|
unsigned int uvc_clock_param = CLOCK_MONOTONIC;
|
||||||
unsigned int uvc_hw_timestamps_param;
|
unsigned int uvc_hw_timestamps_param;
|
||||||
unsigned int uvc_no_drop_param = 1;
|
|
||||||
static unsigned int uvc_quirks_param = -1;
|
static unsigned int uvc_quirks_param = -1;
|
||||||
unsigned int uvc_dbg_param;
|
unsigned int uvc_dbg_param;
|
||||||
unsigned int uvc_timeout_param = UVC_CTRL_STREAMING_TIMEOUT;
|
unsigned int uvc_timeout_param = UVC_CTRL_STREAMING_TIMEOUT;
|
||||||
|
|
@ -2468,24 +2467,6 @@ MODULE_PARM_DESC(clock, "Video buffers timestamp clock");
|
||||||
module_param_named(hwtimestamps, uvc_hw_timestamps_param, uint, 0644);
|
module_param_named(hwtimestamps, uvc_hw_timestamps_param, uint, 0644);
|
||||||
MODULE_PARM_DESC(hwtimestamps, "Use hardware timestamps");
|
MODULE_PARM_DESC(hwtimestamps, "Use hardware timestamps");
|
||||||
|
|
||||||
static int param_set_nodrop(const char *val, const struct kernel_param *kp)
|
|
||||||
{
|
|
||||||
pr_warn_once("uvcvideo: "
|
|
||||||
DEPRECATED
|
|
||||||
"nodrop parameter will be eventually removed.\n");
|
|
||||||
return param_set_bool(val, kp);
|
|
||||||
}
|
|
||||||
|
|
||||||
static const struct kernel_param_ops param_ops_nodrop = {
|
|
||||||
.set = param_set_nodrop,
|
|
||||||
.get = param_get_uint,
|
|
||||||
};
|
|
||||||
|
|
||||||
param_check_uint(nodrop, &uvc_no_drop_param);
|
|
||||||
module_param_cb(nodrop, ¶m_ops_nodrop, &uvc_no_drop_param, 0644);
|
|
||||||
__MODULE_PARM_TYPE(nodrop, "uint");
|
|
||||||
MODULE_PARM_DESC(nodrop, "Don't drop incomplete frames");
|
|
||||||
|
|
||||||
module_param_named(quirks, uvc_quirks_param, uint, 0644);
|
module_param_named(quirks, uvc_quirks_param, uint, 0644);
|
||||||
MODULE_PARM_DESC(quirks, "Forced device quirks");
|
MODULE_PARM_DESC(quirks, "Forced device quirks");
|
||||||
module_param_named(trace, uvc_dbg_param, uint, 0644);
|
module_param_named(trace, uvc_dbg_param, uint, 0644);
|
||||||
|
|
|
||||||
|
|
@ -331,34 +331,9 @@ struct uvc_buffer *uvc_queue_get_current_buffer(struct uvc_video_queue *queue)
|
||||||
return nextbuf;
|
return nextbuf;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* uvc_queue_buffer_requeue: Requeue a buffer on our internal irqqueue
|
|
||||||
*
|
|
||||||
* Reuse a buffer through our internal queue without the need to 'prepare'.
|
|
||||||
* The buffer will be returned to userspace through the uvc_buffer_queue call if
|
|
||||||
* the device has been disconnected.
|
|
||||||
*/
|
|
||||||
static void uvc_queue_buffer_requeue(struct uvc_video_queue *queue,
|
|
||||||
struct uvc_buffer *buf)
|
|
||||||
{
|
|
||||||
buf->error = 0;
|
|
||||||
buf->state = UVC_BUF_STATE_QUEUED;
|
|
||||||
buf->bytesused = 0;
|
|
||||||
vb2_set_plane_payload(&buf->buf.vb2_buf, 0, 0);
|
|
||||||
|
|
||||||
uvc_buffer_queue(&buf->buf.vb2_buf);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void uvc_queue_buffer_complete(struct kref *ref)
|
static void uvc_queue_buffer_complete(struct kref *ref)
|
||||||
{
|
{
|
||||||
struct uvc_buffer *buf = container_of(ref, struct uvc_buffer, ref);
|
struct uvc_buffer *buf = container_of(ref, struct uvc_buffer, ref);
|
||||||
struct vb2_buffer *vb = &buf->buf.vb2_buf;
|
|
||||||
struct uvc_video_queue *queue = vb2_get_drv_priv(vb->vb2_queue);
|
|
||||||
|
|
||||||
if (buf->error && !uvc_no_drop_param) {
|
|
||||||
uvc_queue_buffer_requeue(queue, buf);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
buf->state = buf->error ? UVC_BUF_STATE_ERROR : UVC_BUF_STATE_DONE;
|
buf->state = buf->error ? UVC_BUF_STATE_ERROR : UVC_BUF_STATE_DONE;
|
||||||
vb2_set_plane_payload(&buf->buf.vb2_buf, 0, buf->bytesused);
|
vb2_set_plane_payload(&buf->buf.vb2_buf, 0, buf->bytesused);
|
||||||
|
|
|
||||||
|
|
@ -659,7 +659,6 @@ static inline struct uvc_fh *to_uvc_fh(struct file *filp)
|
||||||
#define UVC_WARN_XU_GET_RES 2
|
#define UVC_WARN_XU_GET_RES 2
|
||||||
|
|
||||||
extern unsigned int uvc_clock_param;
|
extern unsigned int uvc_clock_param;
|
||||||
extern unsigned int uvc_no_drop_param;
|
|
||||||
extern unsigned int uvc_dbg_param;
|
extern unsigned int uvc_dbg_param;
|
||||||
extern unsigned int uvc_timeout_param;
|
extern unsigned int uvc_timeout_param;
|
||||||
extern unsigned int uvc_hw_timestamps_param;
|
extern unsigned int uvc_hw_timestamps_param;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user