diff options
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/dvb/firewire/firedtv-fw.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/drivers/media/dvb/firewire/firedtv-fw.c b/drivers/media/dvb/firewire/firedtv-fw.c index fe44789ab037..6223bf01efe9 100644 --- a/drivers/media/dvb/firewire/firedtv-fw.c +++ b/drivers/media/dvb/firewire/firedtv-fw.c | |||
@@ -202,14 +202,8 @@ static void handle_fcp(struct fw_card *card, struct fw_request *request, | |||
202 | unsigned long flags; | 202 | unsigned long flags; |
203 | int su; | 203 | int su; |
204 | 204 | ||
205 | if ((tcode != TCODE_WRITE_QUADLET_REQUEST && | 205 | if (length < 2 || (((u8 *)payload)[0] & 0xf0) != 0) |
206 | tcode != TCODE_WRITE_BLOCK_REQUEST) || | ||
207 | offset != CSR_REGISTER_BASE + CSR_FCP_RESPONSE || | ||
208 | length == 0 || | ||
209 | (((u8 *)payload)[0] & 0xf0) != 0) { | ||
210 | fw_send_response(card, request, RCODE_TYPE_ERROR); | ||
211 | return; | 206 | return; |
212 | } | ||
213 | 207 | ||
214 | su = ((u8 *)payload)[1] & 0x7; | 208 | su = ((u8 *)payload)[1] & 0x7; |
215 | 209 | ||
@@ -230,10 +224,8 @@ static void handle_fcp(struct fw_card *card, struct fw_request *request, | |||
230 | } | 224 | } |
231 | spin_unlock_irqrestore(&node_list_lock, flags); | 225 | spin_unlock_irqrestore(&node_list_lock, flags); |
232 | 226 | ||
233 | if (fdtv) { | 227 | if (fdtv) |
234 | avc_recv(fdtv, payload, length); | 228 | avc_recv(fdtv, payload, length); |
235 | fw_send_response(card, request, RCODE_COMPLETE); | ||
236 | } | ||
237 | } | 229 | } |
238 | 230 | ||
239 | static struct fw_address_handler fcp_handler = { | 231 | static struct fw_address_handler fcp_handler = { |