~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/include/media/tveeprom.h

Version: ~ [ linux-6.12-rc7 ] ~ [ linux-6.11.7 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.60 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.116 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.171 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.229 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.285 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.323 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.12 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

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

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php