Blame view
include/media/tveeprom.h
3.29 KB
b24413180 License cleanup: ... |
1 |
/* SPDX-License-Identifier: GPL-2.0 */ |
326ab27bb [media] DocBook: ... |
2 |
|
ac19ecc6f [PATCH] v4l: upda... |
3 |
/* |
326ab27bb [media] DocBook: ... |
4 5 |
* tveeprom - Contains structures and functions to work with Hauppauge * eeproms. |
ac19ecc6f [PATCH] v4l: upda... |
6 |
*/ |
326ab27bb [media] DocBook: ... |
7 8 9 10 11 12 13 14 15 16 17 18 |
#include <linux/if_ether.h> /** * enum tveeprom_audio_processor - Specifies the type of audio processor * used on a Hauppauge device. * * @TVEEPROM_AUDPROC_NONE: No audio processor present * @TVEEPROM_AUDPROC_INTERNAL: The audio processor is internal to the * video processor * @TVEEPROM_AUDPROC_MSP: The audio processor is a MSPXXXX device * @TVEEPROM_AUDPROC_OTHER: The audio processor is another device */ |
330010100 [media] tveeprom:... |
19 |
enum tveeprom_audio_processor { |
330010100 [media] tveeprom:... |
20 |
TVEEPROM_AUDPROC_NONE, |
330010100 [media] tveeprom:... |
21 |
TVEEPROM_AUDPROC_INTERNAL, |
330010100 [media] tveeprom:... |
22 |
TVEEPROM_AUDPROC_MSP, |
330010100 [media] tveeprom:... |
23 24 |
TVEEPROM_AUDPROC_OTHER, }; |
326ab27bb [media] DocBook: ... |
25 26 27 28 |
/** * struct tveeprom - Contains the fields parsed from Hauppauge eeproms * * @has_radio: 1 if the device has radio; 0 otherwise. |
89cb3ddbe [media] doc-rst: ... |
29 |
* |
326ab27bb [media] DocBook: ... |
30 31 |
* @has_ir: If has_ir == 0, then it is unknown what the IR * capabilities are. Otherwise: |
89cb3ddbe [media] doc-rst: ... |
32 33 34 35 |
* bit 0) 1 (= IR capabilities are known); * bit 1) IR receiver present; * bit 2) IR transmitter (blaster) present. * |
326ab27bb [media] DocBook: ... |
36 37 38 |
* @has_MAC_address: 0: no MAC, 1: MAC present, 2: unknown. * @tuner_type: type of the tuner (TUNER_*, as defined at * include/media/tuner.h). |
89cb3ddbe [media] doc-rst: ... |
39 |
* |
326ab27bb [media] DocBook: ... |
40 41 42 43 |
* @tuner_formats: Supported analog TV standards (V4L2_STD_*). * @tuner_hauppauge_model: Hauppauge's code for the device model number. * @tuner2_type: type of the second tuner (TUNER_*, as defined * at include/media/tuner.h). |
89cb3ddbe [media] doc-rst: ... |
44 |
* |
326ab27bb [media] DocBook: ... |
45 46 |
* @tuner2_formats: Tuner 2 supported analog TV standards * (V4L2_STD_*). |
89cb3ddbe [media] doc-rst: ... |
47 |
* |
326ab27bb [media] DocBook: ... |
48 49 |
* @tuner2_hauppauge_model: tuner 2 Hauppauge's code for the device model * number. |
89cb3ddbe [media] doc-rst: ... |
50 |
* |
326ab27bb [media] DocBook: ... |
51 52 |
* @audio_processor: analog audio decoder, as defined by enum * tveeprom_audio_processor. |
89cb3ddbe [media] doc-rst: ... |
53 |
* |
326ab27bb [media] DocBook: ... |
54 55 56 |
* @decoder_processor: Hauppauge's code for the decoder chipset. * Unused by the drivers, as they probe the * decoder based on the PCI or USB ID. |
89cb3ddbe [media] doc-rst: ... |
57 |
* |
326ab27bb [media] DocBook: ... |
58 |
* @model: Hauppauge's model number |
89cb3ddbe [media] doc-rst: ... |
59 |
* |
326ab27bb [media] DocBook: ... |
60 |
* @revision: Card revision number |
89cb3ddbe [media] doc-rst: ... |
61 |
* |
326ab27bb [media] DocBook: ... |
62 |
* @serial_number: Card's serial number |
89cb3ddbe [media] doc-rst: ... |
63 |
* |
326ab27bb [media] DocBook: ... |
64 |
* @rev_str: Card revision converted to number |
89cb3ddbe [media] doc-rst: ... |
65 |
* |
326ab27bb [media] DocBook: ... |
66 67 |
* @MAC_address: MAC address for the network interface */ |
1da177e4c Linux-2.6.12-rc2 |
68 69 |
struct tveeprom { u32 has_radio; |
b654fcdc0 V4L/DVB (8479): t... |
70 |
u32 has_ir; |
326ab27bb [media] DocBook: ... |
71 |
u32 has_MAC_address; |
1da177e4c Linux-2.6.12-rc2 |
72 73 74 |
u32 tuner_type; u32 tuner_formats; |
f95006f89 [PATCH] V4L: Add ... |
75 |
u32 tuner_hauppauge_model; |
1da177e4c Linux-2.6.12-rc2 |
76 |
|
0f97a931b [PATCH] v4l: tvee... |
77 78 |
u32 tuner2_type; u32 tuner2_formats; |
f95006f89 [PATCH] V4L: Add ... |
79 |
u32 tuner2_hauppauge_model; |
0f97a931b [PATCH] v4l: tvee... |
80 |
|
1da177e4c Linux-2.6.12-rc2 |
81 |
u32 audio_processor; |
0f97a931b [PATCH] v4l: tvee... |
82 |
u32 decoder_processor; |
1da177e4c Linux-2.6.12-rc2 |
83 84 85 86 87 |
u32 model; u32 revision; u32 serial_number; char rev_str[5]; |
574e2af7c include: Convert ... |
88 |
u8 MAC_address[ETH_ALEN]; |
1da177e4c Linux-2.6.12-rc2 |
89 |
}; |
326ab27bb [media] DocBook: ... |
90 91 92 93 94 |
/** * tveeprom_hauppauge_analog - Fill struct tveeprom using the contents * of the eeprom previously filled at * @eeprom_data field. * |
326ab27bb [media] DocBook: ... |
95 96 97 98 99 |
* @tvee: Struct to where the eeprom parsed data will be filled; * @eeprom_data: Array with the contents of the eeprom_data. It should * contain 256 bytes filled with the contents of the * eeprom read from the Hauppauge device. */ |
446aba663 [media] tveeprom:... |
100 |
void tveeprom_hauppauge_analog(struct tveeprom *tvee, |
1da177e4c Linux-2.6.12-rc2 |
101 |
unsigned char *eeprom_data); |
326ab27bb [media] DocBook: ... |
102 103 104 105 106 107 108 109 110 111 |
/** * tveeprom_read - Reads the contents of the eeprom found at the Hauppauge * devices. * * @c: I2C client struct * @eedata: Array where the eeprom content will be stored. * @len: Size of @eedata array. If the eeprom content will be latter * be parsed by tveeprom_hauppauge_analog(), len should be, at * least, 256. */ |
1da177e4c Linux-2.6.12-rc2 |
112 |
int tveeprom_read(struct i2c_client *c, unsigned char *eedata, int len); |