summaryrefslogtreecommitdiff
path: root/linux/drivers/media/dvb
diff options
context:
space:
mode:
authorSteven Toth <stoth@linuxtv.org>2008-10-06 19:44:04 -0400
committerSteven Toth <stoth@linuxtv.org>2008-10-06 19:44:04 -0400
commitb42ee9569d2b79420ffc6f113c7cb94bd335b2aa (patch)
treedd0f4da244e3ad363e6a0c05bf329c899cd93ddd /linux/drivers/media/dvb
parent2def42f61166d6585adf788cd75b81052ae4b1c4 (diff)
downloadmediapointer-dvb-s2-b42ee9569d2b79420ffc6f113c7cb94bd335b2aa.tar.gz
mediapointer-dvb-s2-b42ee9569d2b79420ffc6f113c7cb94bd335b2aa.tar.bz2
S2API: Remove the hardcoded command limit during validation
From: Steven Toth <stoth@linuxtv.org> This means that when developers add new commands then they'll be see the DTV_MAX_COMMAND define and will be more likely to modify it, without having to modify the command validation code. Priority: normal Signed-off-by: Steven Toth <stoth@linuxtv.org>
Diffstat (limited to 'linux/drivers/media/dvb')
-rw-r--r--linux/drivers/media/dvb/dvb-core/dvb_frontend.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/linux/drivers/media/dvb/dvb-core/dvb_frontend.c b/linux/drivers/media/dvb/dvb-core/dvb_frontend.c
index ad479f3e1..98cb675e2 100644
--- a/linux/drivers/media/dvb/dvb-core/dvb_frontend.c
+++ b/linux/drivers/media/dvb/dvb-core/dvb_frontend.c
@@ -918,8 +918,7 @@ void dtv_property_dump(struct dtv_property *tvp)
{
int i;
- if( (tvp->cmd <= 0 || tvp->cmd > DTV_DELIVERY_SYSTEM) &&
- tvp->cmd != DTV_API_VERSION) {
+ if (tvp->cmd <= 0 || tvp->cmd > DTV_MAX_COMMAND) {
printk("%s: tvp.cmd = 0x%08x (undefined/unknown/invalid)\n",
__func__, tvp->cmd);
return;