Home
last modified time | relevance | path

Searched refs:prom (Results 1 – 9 of 9) sorted by relevance

/drivers/iio/common/ms_sensors/
Dms_sensors_i2c.c499 static u8 ms_sensors_tp_crc4(u16 *prom) in ms_sensors_tp_crc4() argument
506 n_rem ^= prom[cnt >> 1] & 0x00FF; in ms_sensors_tp_crc4()
508 n_rem ^= prom[cnt >> 1] >> 8; in ms_sensors_tp_crc4()
530 static bool ms_sensors_tp_crc_valid_112(u16 *prom) in ms_sensors_tp_crc_valid_112() argument
532 u16 w0 = prom[0], crc_read = (w0 & 0xF000) >> 12; in ms_sensors_tp_crc_valid_112()
535 prom[0] &= 0x0FFF; /* Clear the CRC computation part */ in ms_sensors_tp_crc_valid_112()
536 prom[MS_SENSORS_TP_PROM_WORDS_NB - 1] = 0; in ms_sensors_tp_crc_valid_112()
538 crc = ms_sensors_tp_crc4(prom); in ms_sensors_tp_crc_valid_112()
540 prom[0] = w0; in ms_sensors_tp_crc_valid_112()
554 static bool ms_sensors_tp_crc_valid_128(u16 *prom) in ms_sensors_tp_crc_valid_128() argument
[all …]
Dms_sensors_i2c.h50 u16 prom[MS_SENSORS_TP_PROM_WORDS_NB]; member
/drivers/iio/pressure/
Dms5611_core.c56 static bool ms5611_prom_is_valid(u16 *prom, size_t len) in ms5611_prom_is_valid() argument
59 uint16_t crc = 0, crc_orig = prom[7] & 0x000F; in ms5611_prom_is_valid()
61 prom[7] &= 0xFF00; in ms5611_prom_is_valid()
65 crc ^= prom[i >> 1] & 0x00FF; in ms5611_prom_is_valid()
67 crc ^= prom[i >> 1] >> 8; in ms5611_prom_is_valid()
88 ret = st->read_prom_word(st, i, &st->prom[i]); in ms5611_read_prom()
96 if (!ms5611_prom_is_valid(st->prom, MS5611_PROM_WORDS_NB)) { in ms5611_read_prom()
126 dt = t - (st->prom[5] << 8); in ms5611_temp_and_pressure_compensate()
127 off = ((s64)st->prom[2] << 16) + ((st->prom[4] * dt) >> 7); in ms5611_temp_and_pressure_compensate()
128 sens = ((s64)st->prom[1] << 15) + ((st->prom[3] * dt) >> 8); in ms5611_temp_and_pressure_compensate()
[all …]
Dms5611.h46 u16 prom[MS5611_PROM_WORDS_NB]; member
/drivers/iio/temperature/
Dtsys01.c39 u16 prom[TSYS01_PROM_WORDS_NB]; member
67 (s64)dev_data->prom[5 - i]; in tsys01_read_temperature()
72 temp += coeff_mul[0] * (s64)dev_data->prom[5]; in tsys01_read_temperature()
137 &dev_data->prom[i]); in tsys01_read_prom()
141 ret = sprintf(ptr, "0x%04x ", dev_data->prom[i]); in tsys01_read_prom()
145 if (!tsys01_crc_valid(dev_data->prom)) { in tsys01_read_prom()
/drivers/atm/
Dfore200e.c554 fore200e_pca_prom_read(struct fore200e* fore200e, struct prom_data* prom) in fore200e_pca_prom_read() argument
567 prom_dma = dma_map_single(fore200e->dev, prom, sizeof(struct prom_data), in fore200e_pca_prom_read()
594 swap_here(&prom->mac_addr[0]); in fore200e_pca_prom_read()
595 swap_here(&prom->mac_addr[4]); in fore200e_pca_prom_read()
712 static int __init fore200e_sba_prom_read(struct fore200e *fore200e, struct prom_data *prom) in fore200e_sba_prom_read() argument
721 memcpy(&prom->mac_addr[4], prop, 4); in fore200e_sba_prom_read()
726 memcpy(&prom->mac_addr[2], prop, 4); in fore200e_sba_prom_read()
728 prom->serial_number = of_getintprop_default(op->dev.of_node, in fore200e_sba_prom_read()
730 prom->hw_revision = of_getintprop_default(op->dev.of_node, in fore200e_sba_prom_read()
1955 struct prom_data* prom = kzalloc(sizeof(struct prom_data), GFP_KERNEL); in fore200e_get_esi() local
[all …]
/drivers/net/ethernet/8390/
Dpcnet_cs.c327 u_char prom[32]; in get_prom() local
356 prom[i] = inb(ioaddr + PCNET_DATAPORT); in get_prom()
358 if ((prom[0] == hw_info[i].a0) && in get_prom()
359 (prom[2] == hw_info[i].a1) && in get_prom()
360 (prom[4] == hw_info[i].a2)) in get_prom()
363 if ((i < NR_INFO) || ((prom[28] == 0x57) && (prom[30] == 0x57))) { in get_prom()
365 dev->dev_addr[j] = prom[j<<1]; in get_prom()
/drivers/net/ethernet/sgi/
Dioc3-eth.c200 u8 prom[16]; in ioc3eth_get_mac_addr() local
211 ret = nvmem_device_read(nvmem, 0, 16, prom); in ioc3eth_get_mac_addr()
217 if (prom[0] != 0x0a || in ioc3eth_get_mac_addr()
218 crc16(CRC16_INIT, prom, 13) != CRC16_VALID) in ioc3eth_get_mac_addr()
222 mac_addr[i] = prom[10 - i]; in ioc3eth_get_mac_addr()
/drivers/net/ethernet/micrel/
Dksz884x.c4145 static void hw_set_promiscuous(struct ksz_hw *hw, u8 prom) in hw_set_promiscuous() argument
4150 if (prom) in hw_set_promiscuous()