summaryrefslogtreecommitdiff
path: root/linux/drivers
diff options
context:
space:
mode:
authorKenneth Aafloy <devnull@localhost>2005-03-09 22:35:19 +0000
committerKenneth Aafloy <devnull@localhost>2005-03-09 22:35:19 +0000
commitfd2c130cffc2b9bcc69ee0797fa879f559654f90 (patch)
tree114215fba030e0879e2bb950994a7849171c5a09 /linux/drivers
parent56e2d9cc1275025eb00aeea373d2210647126274 (diff)
downloadmediapointer-dvb-s2-fd2c130cffc2b9bcc69ee0797fa879f559654f90.tar.gz
mediapointer-dvb-s2-fd2c130cffc2b9bcc69ee0797fa879f559654f90.tar.bz2
- clear up confusion between ids and adapters
Diffstat (limited to 'linux/drivers')
-rw-r--r--linux/drivers/media/dvb/dvb-core/dvbdev.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/linux/drivers/media/dvb/dvb-core/dvbdev.c b/linux/drivers/media/dvb/dvb-core/dvbdev.c
index 73fd74fcf..94b3bfb51 100644
--- a/linux/drivers/media/dvb/dvb-core/dvbdev.c
+++ b/linux/drivers/media/dvb/dvb-core/dvbdev.c
@@ -51,9 +51,10 @@ static const char * const dnames[] = {
"net", "osd"
};
-#define DVB_MAX_IDS 6
-#define nums2minor(num,type,id) ((num << 6) | (id << 4) | type)
-#define MAX_DVB_MINORS (DVB_MAX_IDS*64)
+#define DVB_MAX_ADAPTERS 8
+#define DVB_MAX_IDS 4
+#define nums2minor(num,type,id) ((num << 6) | (id << 4) | type)
+#define MAX_DVB_MINORS (DVB_MAX_ADAPTERS*64)
static struct class_simple *dvb_class;
@@ -267,7 +268,7 @@ static int dvbdev_get_free_adapter_num (void)
{
int num = 0;
- while (1) {
+ while (num < DVB_MAX_ADAPTERS) {
struct list_head *entry;
list_for_each (entry, &dvb_adapter_list) {
struct dvb_adapter *adap;