Home
last modified time | relevance | path

Searched full:eeprom (Results 1 – 25 of 1190) sorted by relevance

12345678910>>...48

/linux/drivers/misc/eeprom/
H A Deeprom_93cx6.c7 * Abstract: EEPROM reader routines for 93cx6 chipsets.
19 MODULE_DESCRIPTION("EEPROM 93cx6 chip driver");
22 static inline void eeprom_93cx6_pulse_high(struct eeprom_93cx6 *eeprom) in eeprom_93cx6_pulse_high() argument
24 eeprom->reg_data_clock = 1; in eeprom_93cx6_pulse_high()
25 eeprom->register_write(eeprom); in eeprom_93cx6_pulse_high()
35 static inline void eeprom_93cx6_pulse_low(struct eeprom_93cx6 *eeprom) in eeprom_93cx6_pulse_low() argument
37 eeprom->reg_data_clock = 0; in eeprom_93cx6_pulse_low()
38 eeprom->register_write(eeprom); in eeprom_93cx6_pulse_low()
48 static void eeprom_93cx6_startup(struct eeprom_93cx6 *eeprom) in eeprom_93cx6_startup() argument
53 eeprom->register_read(eeprom); in eeprom_93cx6_startup()
[all …]
H A Didt_89hpesx.c12 * This driver primarily is developed to have an access to EEPROM device of
14 * operations from/to EEPROM, which is located at private (so called Master)
17 * /sys/bus/i2c/devices/<bus>-<devaddr>/eeprom
19 * User-space applications won't be able to write to the EEPROM sysfs-node.
70 * @eesize: Size of EEPROM in bytes (calculated from "idt,eecompatible")
71 * @eero: EEPROM Read-only flag
72 * @eeaddr: EEPROM custom address
74 * @inieecmd: Initial cmd value for EEPROM read/write operations
86 * @ee_file: EEPROM read/write sysfs-file
123 * struct idt_eeprom_seq - sequence of data to be read/written from/to EEPROM
[all...]
H A Dmax6875.c7 * Based on eeprom.c
9 * The MAX6875 has a bank of registers and two banks of EEPROM.
12 * * 0x8000 - 0x8046 = configuration EEPROM
13 * * 0x8100 - 0x82FF = user EEPROM
15 * This driver makes the user EEPROM available for read.
17 * The registers & config EEPROM should be accessed via i2c-dev.
23 * address, so this driver is destructive if loaded for the wrong EEPROM chip.
36 /* USER EEPROM is at addresses 0x8100 - 0x82FF */
76 /* select the eeprom address */ in max6875_update_slice()
126 .name = "eeprom",
[all...]
/linux/drivers/nvmem/
H A Dlpc18xx_eeprom.c3 * NXP LPC18xx/LPC43xx EEPROM memory NVMEM driver
38 /* EEPROM device requires a ~1500 kHz clock (min 800 kHz, max 1600 kHz) */
41 /* EEPROM requires 3 ms of erase/program time between each writing */
54 static inline void lpc18xx_eeprom_writel(struct lpc18xx_eeprom_dev *eeprom, in lpc18xx_eeprom_writel() argument
57 writel(val, eeprom->reg_base + reg); in lpc18xx_eeprom_writel()
60 static inline u32 lpc18xx_eeprom_readl(struct lpc18xx_eeprom_dev *eeprom, in lpc18xx_eeprom_readl() argument
63 return readl(eeprom->reg_base + reg); in lpc18xx_eeprom_readl()
66 static int lpc18xx_eeprom_busywait_until_prog(struct lpc18xx_eeprom_dev *eeprom) in lpc18xx_eeprom_busywait_until_prog() argument
71 /* Wait until EEPROM program operation has finished */ in lpc18xx_eeprom_busywait_until_prog()
75 val = lpc18xx_eeprom_readl(eeprom, LPC18XX_EEPROM_INTSTAT); in lpc18xx_eeprom_busywait_until_prog()
[all …]
H A Drave-sp-eeprom.c4 * EEPROM driver for RAVE SP
18 * enum rave_sp_eeprom_access_type - Supported types of EEPROM access
20 * @RAVE_SP_EEPROM_WRITE: EEPROM write
21 * @RAVE_SP_EEPROM_READ: EEPROM read
29 * enum rave_sp_eeprom_header_size - EEPROM command header sizes
31 * @RAVE_SP_EEPROM_HEADER_SMALL: EEPROM header size for "small" devices (< 8K)
32 * @RAVE_SP_EEPROM_HEADER_BIG: EEPROM header size for "big" devices (> 8K)
43 * struct rave_sp_eeprom_page - RAVE SP EEPROM page
59 * struct rave_sp_eeprom - RAVE SP EEPROM device
62 * @mutex: Lock protecting access to EEPROM
[all …]
/linux/drivers/net/wireless/mediatek/mt7601u/
H A Deeprom.c13 #include "eeprom.h"
51 /* Parts of eeprom not in the usage map (0x80-0xc0,0xf0) in mt7601u_efuse_read()
90 …dev_err(dev->dev, "Error: your device needs default EEPROM file and this driver doesn't support it… in mt7601u_efuse_physical_size_check()
98 mt7601u_has_tssi(struct mt7601u_dev *dev, u8 *eeprom) in mt7601u_has_tssi() argument
100 u16 nic_conf1 = get_unaligned_le16(eeprom + MT_EE_NIC_CONF_1); in mt7601u_has_tssi()
106 mt7601u_set_chip_cap(struct mt7601u_dev *dev, u8 *eeprom) in mt7601u_set_chip_cap() argument
108 u16 nic_conf0 = get_unaligned_le16(eeprom + MT_EE_NIC_CONF_0); in mt7601u_set_chip_cap()
109 u16 nic_conf1 = get_unaligned_le16(eeprom + MT_EE_NIC_CONF_1); in mt7601u_set_chip_cap()
114 dev->ee->tssi_enabled = mt7601u_has_tssi(dev, eeprom) && in mt7601u_set_chip_cap()
131 u8 *eeprom, u8 max_pwr) in mt7601u_set_channel_target_power() argument
[all …]
/linux/drivers/media/usb/pvrusb2/
H A Dpvrusb2-eeprom.c9 #include "pvrusb2-eeprom.h"
19 Read and analyze data in the eeprom. Use tveeprom to figure out
27 /* We seem to only be interested in the last 128 bytes of the EEPROM */
30 /* Grab EEPROM contents, needed for direct method. */
34 u8 *eeprom; in pvr2_eeprom_fetch() local
42 eeprom = kzalloc(EEPROM_SIZE, GFP_KERNEL); in pvr2_eeprom_fetch()
43 if (!eeprom) { in pvr2_eeprom_fetch()
45 "Failed to allocate memory required to read eeprom"); in pvr2_eeprom_fetch()
49 trace_eeprom("Value for eeprom addr from controller was 0x%x", in pvr2_eeprom_fetch()
52 /* Seems that if the high bit is set, then the *real* eeprom in pvr2_eeprom_fetch()
[all …]
/linux/include/linux/
H A Deeprom_93cx6.h10 Abstract: EEPROM reader datastructures for 93cx6 chipsets.
17 * EEPROM operation defines.
32 * for reading the eeprom data.
34 * @register_read(struct eeprom_93cx6 *eeprom): handler to
35 * read the eeprom register, this function should set all reg_* fields.
36 * @register_write(struct eeprom_93cx6 *eeprom): handler to
37 * write to the eeprom register by using all reg_* fields.
38 * @width: eeprom width, should be one of the PCI_EEPROM_WIDTH_* defines
39 * @quirks: eeprom or controller quirks
47 * and the eeprom_93cx6 handlers for reading the eeprom.
[all …]
/linux/drivers/net/ethernet/intel/e1000e/
H A Dnvm.c7 * e1000_raise_eec_clk - Raise EEPROM clock
9 * @eecd: pointer to the EEPROM
11 * Enable/Raise the EEPROM clock bit.
22 * e1000_lower_eec_clk - Lower EEPROM clock
24 * @eecd: pointer to the EEPROM
26 * Clear/Lower the EEPROM clock bit.
37 * e1000_shift_out_eec_bits - Shift data bits our to the EEPROM
39 * @data: data to send to the EEPROM
42 * We need to shift 'count' bits out to the EEPROM. So, the value in the
43 * "data" parameter will be shifted out to the EEPROM one bit at a time.
[all …]
/linux/drivers/net/ethernet/intel/igb/
H A De1000_nvm.c11 * igb_raise_eec_clk - Raise EEPROM clock
13 * @eecd: pointer to the EEPROM
15 * Enable/Raise the EEPROM clock bit.
26 * igb_lower_eec_clk - Lower EEPROM clock
28 * @eecd: pointer to the EEPROM
30 * Clear/Lower the EEPROM clock bit.
41 * igb_shift_out_eec_bits - Shift data bits our to the EEPROM
43 * @data: data to send to the EEPROM
46 * We need to shift 'count' bits out to the EEPROM. So, the value in the
47 * "data" parameter will be shifted out to the EEPROM one bit at a time.
[all …]
/linux/Documentation/devicetree/bindings/nvmem/
H A Dlpc1857-eeprom.txt1 * NXP LPC18xx EEPROM memory NVMEM driver
4 - compatible: Should be "nxp,lpc1857-eeprom"
8 - reg: EEPROM registers.
9 - mem: EEPROM address space.
12 - eeprom: EEPROM operating clock.
14 the EEPROM in reset.
15 - interrupts: Should contain EEPROM interrupt.
19 eeprom: eeprom@4000e000 {
20 compatible = "nxp,lpc1857-eeprom";
25 clock-names = "eeprom";
/linux/drivers/net/wireless/ralink/rt2x00/
H A Drt2800pci.c79 static void rt2800pci_eepromregister_read(struct eeprom_93cx6 *eeprom) in rt2800pci_eepromregister_read() argument
81 struct rt2x00_dev *rt2x00dev = eeprom->data; in rt2800pci_eepromregister_read()
86 eeprom->reg_data_in = !!rt2x00_get_field32(reg, E2PROM_CSR_DATA_IN); in rt2800pci_eepromregister_read()
87 eeprom->reg_data_out = !!rt2x00_get_field32(reg, E2PROM_CSR_DATA_OUT); in rt2800pci_eepromregister_read()
88 eeprom->reg_data_clock = in rt2800pci_eepromregister_read()
90 eeprom->reg_chip_select = in rt2800pci_eepromregister_read()
94 static void rt2800pci_eepromregister_write(struct eeprom_93cx6 *eeprom) in rt2800pci_eepromregister_write() argument
96 struct rt2x00_dev *rt2x00dev = eeprom->data; in rt2800pci_eepromregister_write()
99 rt2x00_set_field32(&reg, E2PROM_CSR_DATA_IN, !!eeprom->reg_data_in); in rt2800pci_eepromregister_write()
100 rt2x00_set_field32(&reg, E2PROM_CSR_DATA_OUT, !!eeprom->reg_data_out); in rt2800pci_eepromregister_write()
[all …]
/linux/drivers/net/wireless/mediatek/mt76/mt7615/
H A Deeprom.c10 #include "eeprom.h"
89 u16 val = get_unaligned_le16(dev->eeprom.data); in mt7615_check_eeprom()
104 u8 val, *eeprom = dev->mt76.eeprom.data; in mt7615_eeprom_parse_hw_band_cap() local
126 eeprom[MT_EE_WIFI_CONF]); in mt7615_eeprom_parse_hw_band_cap()
146 u8 *eeprom = dev->mt76.eeprom.data; in mt7615_eeprom_parse_hw_cap() local
154 eeprom[MT7663_EE_HW_CONF1]); in mt7615_eeprom_parse_hw_cap()
158 /* read tx-rx mask from eeprom */ in mt7615_eeprom_parse_hw_cap()
163 eeprom[MT_EE_NIC_CONF_0]); in mt7615_eeprom_parse_hw_cap()
277 u8 *eeprom = dev->mt76.eeprom.data; in mt7615_apply_cal_free_data() local
289 eeprom[ical[i]] = otp[ical[i]]; in mt7615_apply_cal_free_data()
[all …]
/linux/drivers/net/wireless/mediatek/mt76/mt7603/
H A Deeprom.c5 #include "eeprom.h"
105 u8 *eeprom = dev->mt76.eeprom.data; in mt7603_apply_cal_free_data() local
109 if (!np || !of_property_read_bool(np, "mediatek,eeprom-merge-otp")) in mt7603_apply_cal_free_data()
121 eeprom[offset] = efuse[offset]; in mt7603_apply_cal_free_data()
139 u16 val = get_unaligned_le16(dev->eeprom.data); in mt7603_check_eeprom()
158 u8 *eeprom; in mt7603_eeprom_init() local
169 memcpy(dev->mt76.eeprom.data, dev->mt76.otp.data, in mt7603_eeprom_init()
173 eeprom = (u8 *)dev->mt76.eeprom.data; in mt7603_eeprom_init()
175 memcpy(dev->mphy.macaddr, eeprom + MT_EE_MAC_ADDR, ETH_ALEN); in mt7603_eeprom_init()
179 if (FIELD_GET(MT_EE_NIC_CONF_0_RX_PATH, eeprom[MT_EE_NIC_CONF_0]) == 1 || in mt7603_eeprom_init()
[all …]
/linux/drivers/net/ethernet/atheros/atl1e/
H A Datl1e_ethtool.c205 struct ethtool_eeprom *eeprom, u8 *bytes) in atl1e_get_eeprom() argument
214 if (eeprom->len == 0) in atl1e_get_eeprom()
220 eeprom->magic = hw->vendor_id | (hw->device_id << 16); in atl1e_get_eeprom()
222 first_dword = eeprom->offset >> 2; in atl1e_get_eeprom()
223 last_dword = (eeprom->offset + eeprom->len - 1) >> 2; in atl1e_get_eeprom()
237 memcpy(bytes, (u8 *)eeprom_buff + (eeprom->offset & 3), in atl1e_get_eeprom()
238 eeprom->len); in atl1e_get_eeprom()
245 struct ethtool_eeprom *eeprom, u8 *bytes) in atl1e_set_eeprom() argument
255 if (eeprom->len == 0) in atl1e_set_eeprom()
258 if (eeprom->magic != (hw->vendor_id | (hw->device_id << 16))) in atl1e_set_eeprom()
[all …]
/linux/Documentation/devicetree/bindings/eeprom/
H A Dmicrochip,93lc46b.yaml4 $id: http://devicetree.org/schemas/eeprom/microchip,93lc46b.yaml#
7 title: Microchip 93xx46 SPI compatible EEPROM family
19 - eeprom-93xx46
28 description: chip select of EEPROM
33 parameter-less property which disables writes to the EEPROM
39 of EEPROM (e.g. for SPI bus multiplexing)
62 eeprom@0 {
63 compatible = "eeprom-93xx46";
H A Dat25.yaml4 $id: http://devicetree.org/schemas/eeprom/at25.yaml#
15 - pattern: "^eeprom@[0-9a-f]{1,2}$"
18 # There are multiple known vendors who manufacture EEPROM chips compatible
53 Size of the eeprom page. FRAMs don't have pages.
58 Total eeprom size in bytes.
74 Disable writes to the eeprom.
86 Total eeprom size in bytes. Deprecated, use "size" property instead.
92 Addr-mode flags, as defined in include/linux/spi/eeprom.h.
99 Size of the eeprom page. Deprecated, use "pagesize" property instead.
131 eeprom@0 {
/linux/drivers/net/usb/
H A Dasix_common.c635 int asix_get_eeprom(struct net_device *net, struct ethtool_eeprom *eeprom, in asix_get_eeprom() argument
643 if (eeprom->len == 0) in asix_get_eeprom()
646 eeprom->magic = AX_EEPROM_MAGIC; in asix_get_eeprom()
648 first_word = eeprom->offset >> 1; in asix_get_eeprom()
649 last_word = (eeprom->offset + eeprom->len - 1) >> 1; in asix_get_eeprom()
656 /* ax8817x returns 2 bytes from eeprom on read */ in asix_get_eeprom()
665 memcpy(data, (u8 *)eeprom_buff + (eeprom->offset & 1), eeprom->len); in asix_get_eeprom()
670 int asix_set_eeprom(struct net_device *net, struct ethtool_eeprom *eeprom, in asix_set_eeprom() argument
679 netdev_dbg(net, "write EEPROM len %d, offset %d, magic 0x%x\n", in asix_set_eeprom()
680 eeprom->len, eeprom->offset, eeprom->magic); in asix_set_eeprom()
[all …]
/linux/drivers/gpu/drm/panel/
H A Dpanel-olimex-lcd-olinuxino.c70 struct lcd_olinuxino_eeprom eeprom; member
106 struct lcd_olinuxino_info *lcd_info = &lcd->eeprom.info; in lcd_olinuxino_get_modes()
111 for (i = 0; i < lcd->eeprom.num_modes; i++) { in lcd_olinuxino_get_modes()
113 &lcd->eeprom.reserved[i * sizeof(*lcd_mode)]; in lcd_olinuxino_get_modes()
194 (u8 *)&lcd->eeprom + i); in lcd_olinuxino_probe()
203 checksum = ~crc32(~0, (u8 *)&lcd->eeprom, 252); in lcd_olinuxino_probe()
204 if (checksum != lcd->eeprom.checksum) { in lcd_olinuxino_probe()
210 if (lcd->eeprom.header != LCD_OLINUXINO_HEADER_MAGIC) { in lcd_olinuxino_probe()
216 lcd->eeprom.info.name, in lcd_olinuxino_probe()
217 lcd->eeprom.revision, in lcd_olinuxino_probe()
[all …]
/linux/drivers/w1/slaves/
H A DKconfig70 tristate "112-byte EEPROM support (DS28E05)"
73 is a 112-byte user-programmable EEPROM is
78 tristate "256b EEPROM family support (DS2430)"
80 Say Y here if you want to use a 1-wire 256bit EEPROM
82 This EEPROM is organized as one page of 32 bytes for random
86 tristate "1kb EEPROM family support (DS2431)"
89 1kb EEPROM family device (DS2431)
92 tristate "4kb EEPROM family support (DS2433)"
95 4kb EEPROM family device (DS2433).
144 tristate "4096-Bit Addressable 1-Wire EEPROM with PIO (DS28E04-100)"
[all …]
/linux/drivers/net/ethernet/intel/e1000/
H A De1000_hw.c449 /* After MAC reset, force reload of EEPROM to restore power-on settings in e1000_reset_hw()
450 * to device. Later controllers reload the EEPROM automatically, so in e1000_reset_hw()
464 /* Wait for EEPROM reload */ in e1000_reset_hw()
471 /* Wait for EEPROM reload */ in e1000_reset_hw()
640 * e1000_adjust_serdes_amplitude - Adjust SERDES output amplitude based on EEPROM setting.
692 /* Read and store word 0x0F of the EEPROM. This word contains bits in e1000_setup_link()
698 * be initialized based on a value in the EEPROM. in e1000_setup_link()
704 e_dbg("EEPROM Read Error\n"); in e1000_setup_link()
730 /* Take the 4 bits from EEPROM word 0x0F that determine the initial in e1000_setup_link()
741 e_dbg("EEPROM Read Error\n"); in e1000_setup_link()
[all …]
/linux/drivers/net/wireless/marvell/libertas/
H A Dethtool.c28 * All 8388 parts have 16KiB EEPROM size at the time of writing.
39 struct ethtool_eeprom *eeprom, u8 * bytes) in lbs_ethtool_get_eeprom() argument
45 if (eeprom->offset + eeprom->len > LBS_EEPROM_LEN || in lbs_ethtool_get_eeprom()
46 eeprom->len > LBS_EEPROM_READ_LEN) in lbs_ethtool_get_eeprom()
50 LBS_EEPROM_READ_LEN + eeprom->len); in lbs_ethtool_get_eeprom()
52 cmd.offset = cpu_to_le16(eeprom->offset); in lbs_ethtool_get_eeprom()
53 cmd.len = cpu_to_le16(eeprom->len); in lbs_ethtool_get_eeprom()
56 memcpy(bytes, cmd.value, eeprom->len); in lbs_ethtool_get_eeprom()
/linux/drivers/net/wireless/mediatek/mt76/mt76x2/
H A Deeprom.c10 #include "eeprom.h"
17 void *src = dev->mt76.eeprom.data + MT_EE_MAC_ADDR; in mt76x2_eeprom_get_macaddr()
81 u8 *eeprom = dev->mt76.eeprom.data; in mt76x2_apply_cal_free_data() local
83 eeprom[MT_EE_TX_POWER_0_START_5G], in mt76x2_apply_cal_free_data()
84 eeprom[MT_EE_TX_POWER_0_START_5G + 1], in mt76x2_apply_cal_free_data()
85 eeprom[MT_EE_TX_POWER_1_START_5G], in mt76x2_apply_cal_free_data()
86 eeprom[MT_EE_TX_POWER_1_START_5G + 1] in mt76x2_apply_cal_free_data()
91 if (!np || !of_property_read_bool(np, "mediatek,eeprom-merge-otp")) in mt76x2_apply_cal_free_data()
100 eeprom[offset] = efuse[offset]; in mt76x2_apply_cal_free_data()
105 memcpy(eeprom + MT_EE_TX_POWER_0_START_5G, prev_grp0, 2); in mt76x2_apply_cal_free_data()
[all …]
/linux/drivers/gpu/drm/amd/amdgpu/
H A Damdgpu_ras_eeprom.c36 /* These are memory addresses as would be seen by one or more EEPROM
38 * set of EEPROM devices. They form a continuous memory space.
41 * which is a reserved value and indicates that this is an I2C EEPROM
42 * device. It also includes the top 3 bits of the 19 bit EEPROM memory
51 * Depending on the size of the I2C EEPROM device(s), bits 18:16 may
55 * The RAS table lives either at address 0 or address 40000h of EEPROM.
62 * those entities occupy in the EEPROM memory.
76 * EEPROM Table structure v1
79 * | EEPROM TABLE HEADER |
89 /* Assume 2-Mbit size EEPROM and take up the whole space. */
[all …]
/linux/Documentation/misc-devices/
H A Dmax6875.rst21 The Maxim MAX6875 is an EEPROM-programmable power-supply sequencer/supervisor.
23 It also provides 512 bytes of user EEPROM.
25 At reset, the MAX6875 reads the configuration EEPROM into its configuration
45 eeprom - 512 bytes of user-defined EEPROM space.
93 The configuration EEPROM is at addresses 0x8000 - 0x8045.
95 The user EEPROM is at addresses 0x8100 - 0x82ff.
97 Use i2c_smbus_write_word_data() to write a byte to EEPROM.
112 Reading data from the EEPROM is a little more complicated.

12345678910>>...48