aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2010-06-03 15:31:20 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2010-08-02 13:05:52 -0400
commit39e1256bc4b85145b9db392e49a71cad43f6903b (patch)
tree26859d818584ff840d9574957abad2caf2056e7f /drivers
parent54b78608c6f4a30b4d64ec17bc36636c2a081506 (diff)
V4L/DVB: tm6000: Use an enum for extension type
In order to better document and be sure that the values are used at the proper places, convert extension type into an enum and name it as "type", instead of "id". Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/staging/tm6000/tm6000-alsa.c2
-rw-r--r--drivers/staging/tm6000/tm6000-dvb.c2
-rw-r--r--drivers/staging/tm6000/tm6000.h8
3 files changed, 7 insertions, 5 deletions
diff --git a/drivers/staging/tm6000/tm6000-alsa.c b/drivers/staging/tm6000/tm6000-alsa.c
index 745f8de9ff91..de5e78d4b54a 100644
--- a/drivers/staging/tm6000/tm6000-alsa.c
+++ b/drivers/staging/tm6000/tm6000-alsa.c
@@ -392,7 +392,7 @@ static int tm6000_audio_fini(struct tm6000_core *dev)
392} 392}
393 393
394struct tm6000_ops audio_ops = { 394struct tm6000_ops audio_ops = {
395 .id = TM6000_AUDIO, 395 .type = TM6000_AUDIO,
396 .name = "TM6000 Audio Extension", 396 .name = "TM6000 Audio Extension",
397 .init = tm6000_audio_init, 397 .init = tm6000_audio_init,
398 .fini = tm6000_audio_fini, 398 .fini = tm6000_audio_fini,
diff --git a/drivers/staging/tm6000/tm6000-dvb.c b/drivers/staging/tm6000/tm6000-dvb.c
index d3529ae73e2f..f501edccf9c4 100644
--- a/drivers/staging/tm6000/tm6000-dvb.c
+++ b/drivers/staging/tm6000/tm6000-dvb.c
@@ -432,7 +432,7 @@ static int dvb_fini(struct tm6000_core *dev)
432} 432}
433 433
434static struct tm6000_ops dvb_ops = { 434static struct tm6000_ops dvb_ops = {
435 .id = TM6000_DVB, 435 .type = TM6000_DVB,
436 .name = "TM6000 dvb Extension", 436 .name = "TM6000 dvb Extension",
437 .init = dvb_init, 437 .init = dvb_init,
438 .fini = dvb_fini, 438 .fini = dvb_fini,
diff --git a/drivers/staging/tm6000/tm6000.h b/drivers/staging/tm6000/tm6000.h
index a1d96d619734..8fccf3e4d8f6 100644
--- a/drivers/staging/tm6000/tm6000.h
+++ b/drivers/staging/tm6000/tm6000.h
@@ -218,13 +218,15 @@ struct tm6000_core {
218 spinlock_t slock; 218 spinlock_t slock;
219}; 219};
220 220
221#define TM6000_AUDIO 0x10 221enum tm6000_ops_type {
222#define TM6000_DVB 0x20 222 TM6000_AUDIO = 0x10,
223 TM6000_DVB = 0x20,
224};
223 225
224struct tm6000_ops { 226struct tm6000_ops {
225 struct list_head next; 227 struct list_head next;
226 char *name; 228 char *name;
227 int id; 229 enum tm6000_ops_type type;
228 int (*init)(struct tm6000_core *); 230 int (*init)(struct tm6000_core *);
229 int (*fini)(struct tm6000_core *); 231 int (*fini)(struct tm6000_core *);
230}; 232};