aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/media/video/pvrusb2/pvrusb2-dvb.c6
-rw-r--r--drivers/media/video/pvrusb2/pvrusb2-dvb.h1
2 files changed, 1 insertions, 6 deletions
diff --git a/drivers/media/video/pvrusb2/pvrusb2-dvb.c b/drivers/media/video/pvrusb2/pvrusb2-dvb.c
index d82fceae4689..c20eef0f077e 100644
--- a/drivers/media/video/pvrusb2/pvrusb2-dvb.c
+++ b/drivers/media/video/pvrusb2/pvrusb2-dvb.c
@@ -41,7 +41,6 @@ static int pvr2_dvb_feed_func(struct pvr2_dvb_adapter *adap)
41 stream = adap->channel.stream->stream; 41 stream = adap->channel.stream->stream;
42 42
43 for (;;) { 43 for (;;) {
44 if (adap->feed_thread_stop) break;
45 if (kthread_should_stop()) break; 44 if (kthread_should_stop()) break;
46 45
47 /* Not sure about this... */ 46 /* Not sure about this... */
@@ -76,7 +75,7 @@ static int pvr2_dvb_feed_func(struct pvr2_dvb_adapter *adap)
76 ret = wait_event_interruptible( 75 ret = wait_event_interruptible(
77 adap->buffer_wait_data, 76 adap->buffer_wait_data,
78 (pvr2_stream_get_ready_count(stream) > 0) || 77 (pvr2_stream_get_ready_count(stream) > 0) ||
79 adap->feed_thread_stop); 78 kthread_should_stop());
80 if (ret < 0) break; 79 if (ret < 0) break;
81 } 80 }
82 81
@@ -110,8 +109,6 @@ static void pvr2_dvb_stream_end(struct pvr2_dvb_adapter *adap)
110 struct pvr2_stream *stream; 109 struct pvr2_stream *stream;
111 110
112 if (adap->thread) { 111 if (adap->thread) {
113 adap->feed_thread_stop = !0;
114 pvr2_dvb_notify(adap);
115 kthread_stop(adap->thread); 112 kthread_stop(adap->thread);
116 adap->thread = NULL; 113 adap->thread = NULL;
117 } 114 }
@@ -182,7 +179,6 @@ static int pvr2_dvb_stream_do_start(struct pvr2_dvb_adapter *adap)
182 if (ret < 0) return ret; 179 if (ret < 0) return ret;
183 } 180 }
184 181
185 adap->feed_thread_stop = 0;
186 adap->thread = kthread_run(pvr2_dvb_feed_thread, adap, "pvrusb2-dvb"); 182 adap->thread = kthread_run(pvr2_dvb_feed_thread, adap, "pvrusb2-dvb");
187 183
188 if (IS_ERR(adap->thread)) { 184 if (IS_ERR(adap->thread)) {
diff --git a/drivers/media/video/pvrusb2/pvrusb2-dvb.h b/drivers/media/video/pvrusb2/pvrusb2-dvb.h
index 2dd0d4ef22a2..884ff916a352 100644
--- a/drivers/media/video/pvrusb2/pvrusb2-dvb.h
+++ b/drivers/media/video/pvrusb2/pvrusb2-dvb.h
@@ -28,7 +28,6 @@ struct pvr2_dvb_adapter {
28 unsigned int stream_run:1; 28 unsigned int stream_run:1;
29 29
30 wait_queue_head_t buffer_wait_data; 30 wait_queue_head_t buffer_wait_data;
31 int feed_thread_stop;
32 char *buffer_storage[PVR2_DVB_BUFFER_COUNT]; 31 char *buffer_storage[PVR2_DVB_BUFFER_COUNT];
33}; 32};
34 33