Home
last modified time | relevance | path

Searched refs:vpd (Results 1 – 25 of 58) sorted by relevance

123

/kernel/linux/linux-5.10/drivers/pci/
Dvpd.c42 if (!dev->vpd || !dev->vpd->ops) in pci_read_vpd()
44 return dev->vpd->ops->read(dev, pos, count, buf); in pci_read_vpd()
57 if (!dev->vpd || !dev->vpd->ops) in pci_write_vpd()
59 return dev->vpd->ops->write(dev, pos, count, buf); in pci_write_vpd()
70 if (!dev->vpd || !dev->vpd->ops) in pci_set_vpd_size()
72 return dev->vpd->ops->set_size(dev, len); in pci_set_vpd_size()
140 struct pci_vpd *vpd = dev->vpd; in pci_vpd_wait() local
146 if (!vpd->busy) in pci_vpd_wait()
150 ret = pci_user_read_config_word(dev, vpd->cap + PCI_VPD_ADDR, in pci_vpd_wait()
155 if ((status & PCI_VPD_ADDR_F) == vpd->flag) { in pci_vpd_wait()
[all …]
DMakefile7 pci-sysfs.o rom.o setup-res.o irq.o vpd.o \
/kernel/linux/linux-5.10/drivers/firmware/google/
DMakefile10 vpd-sysfs-y := vpd.o vpd_decode.o
11 obj-$(CONFIG_GOOGLE_VPD) += vpd-sysfs.o
DKconfig75 under /sys/firmware/vpd.
/kernel/linux/linux-5.10/drivers/hwmon/
Ddrivetemp.c328 struct scsi_vpd *vpd; in drivetemp_identify_sata() local
341 vpd = rcu_dereference(sdev->vpd_pg89); in drivetemp_identify_sata()
347 if (!vpd || vpd->len < 572 || vpd->data[56] != ATA_CMD_ID_ATA || in drivetemp_identify_sata()
348 vpd->data[36] != 0x34) { in drivetemp_identify_sata()
352 ata_id = (u16 *)&vpd->data[60]; in drivetemp_identify_sata()
/kernel/linux/linux-5.10/drivers/target/
Dtarget_core_transport.c987 struct t10_vpd *vpd, in transport_dump_vpd_proto_id() argument
997 switch (vpd->protocol_identifier) { in transport_dump_vpd_proto_id()
1029 vpd->protocol_identifier); in transport_dump_vpd_proto_id()
1040 transport_set_vpd_proto_id(struct t10_vpd *vpd, unsigned char *page_83) in transport_set_vpd_proto_id() argument
1048 vpd->protocol_identifier = (page_83[0] & 0xf0); in transport_set_vpd_proto_id()
1049 vpd->protocol_identifier_set = 1; in transport_set_vpd_proto_id()
1050 transport_dump_vpd_proto_id(vpd, NULL, 0); in transport_set_vpd_proto_id()
1056 struct t10_vpd *vpd, in transport_dump_vpd_assoc() argument
1067 switch (vpd->association) { in transport_dump_vpd_assoc()
1078 sprintf(buf+len, "Unknown 0x%02x\n", vpd->association); in transport_dump_vpd_assoc()
[all …]
Dtarget_core_pscsi.c224 struct t10_vpd *vpd; in pscsi_get_inquiry_vpd_device_ident() local
254 vpd = kzalloc(sizeof(struct t10_vpd), GFP_KERNEL); in pscsi_get_inquiry_vpd_device_ident()
255 if (!vpd) { in pscsi_get_inquiry_vpd_device_ident()
260 INIT_LIST_HEAD(&vpd->vpd_list); in pscsi_get_inquiry_vpd_device_ident()
262 transport_set_vpd_proto_id(vpd, page_83); in pscsi_get_inquiry_vpd_device_ident()
263 transport_set_vpd_assoc(vpd, page_83); in pscsi_get_inquiry_vpd_device_ident()
265 if (transport_set_vpd_ident_type(vpd, page_83) < 0) { in pscsi_get_inquiry_vpd_device_ident()
268 kfree(vpd); in pscsi_get_inquiry_vpd_device_ident()
271 if (transport_set_vpd_ident(vpd, page_83) < 0) { in pscsi_get_inquiry_vpd_device_ident()
274 kfree(vpd); in pscsi_get_inquiry_vpd_device_ident()
[all …]
Dtarget_core_device.c519 struct t10_vpd *vpd, *vpd_tmp; in se_release_vpd_for_dev() local
522 list_for_each_entry_safe(vpd, vpd_tmp, in se_release_vpd_for_dev()
524 list_del(&vpd->vpd_list); in se_release_vpd_for_dev()
525 kfree(vpd); in se_release_vpd_for_dev()
Dtarget_core_configfs.c1566 struct t10_vpd *vpd; in target_wwn_vpd_protocol_identifier_show() local
1573 list_for_each_entry(vpd, &t10_wwn->t10_vpd_list, vpd_list) { in target_wwn_vpd_protocol_identifier_show()
1574 if (!vpd->protocol_identifier_set) in target_wwn_vpd_protocol_identifier_show()
1577 transport_dump_vpd_proto_id(vpd, buf, VPD_TMP_BUF_SIZE); in target_wwn_vpd_protocol_identifier_show()
1597 struct t10_vpd *vpd; \
1602 list_for_each_entry(vpd, &t10_wwn->t10_vpd_list, vpd_list) { \
1603 if (vpd->association != _assoc) \
1607 transport_dump_vpd_assoc(vpd, buf, VPD_TMP_BUF_SIZE); \
1613 transport_dump_vpd_ident_type(vpd, buf, VPD_TMP_BUF_SIZE); \
1619 transport_dump_vpd_ident(vpd, buf, VPD_TMP_BUF_SIZE); \
/kernel/linux/linux-5.10/drivers/net/ethernet/chelsio/cxgb3/
Dt3_hw.c198 u32 clkdiv = adap->params.vpd.cclk / (2 * adap->params.vpd.mdc) - 1; in mi1_init()
712 struct t3_vpd vpd; in get_vpd_params() local
718 ret = t3_seeprom_read(adapter, VPD_BASE, (__le32 *)&vpd); in get_vpd_params()
721 addr = vpd.id_tag == 0x82 ? VPD_BASE : 0; in get_vpd_params()
723 for (i = 0; i < sizeof(vpd); i += 4) { in get_vpd_params()
725 (__le32 *)((u8 *)&vpd + i)); in get_vpd_params()
730 ret = vpdstrtouint(vpd.cclk_data, vpd.cclk_len, 10, &p->cclk); in get_vpd_params()
733 ret = vpdstrtouint(vpd.mclk_data, vpd.mclk_len, 10, &p->mclk); in get_vpd_params()
736 ret = vpdstrtouint(vpd.uclk_data, vpd.uclk_len, 10, &p->uclk); in get_vpd_params()
739 ret = vpdstrtouint(vpd.mdc_data, vpd.mdc_len, 10, &p->mdc); in get_vpd_params()
[all …]
Dcommon.h385 struct vpd_params vpd; member
634 return adap->params.vpd.cclk / 1000; in core_ticks_per_usec()
/kernel/linux/linux-5.10/drivers/net/ethernet/chelsio/cxgb4vf/
Dt4vf_common.h263 struct vpd_params vpd; /* Vital Product Data */ member
311 return adapter->params.vpd.cclk / 1000; in core_ticks_per_usec()
317 return (us * adapter->params.vpd.cclk) / 1000; in us_to_core_ticks()
323 return (ticks * 1000) / adapter->params.vpd.cclk; in core_ticks_to_us()
/kernel/linux/linux-5.10/drivers/misc/cxl/
Dof.c113 char vpd[256]; in read_vpd() local
115 size_t len = sizeof(vpd); in read_vpd()
117 memset(vpd, 0, len); in read_vpd()
120 rc = cxl_guest_read_adapter_vpd(adapter, vpd, len); in read_vpd()
122 rc = cxl_guest_read_afu_vpd(afu, vpd, len); in read_vpd()
125 cxl_dump_debug_buffer(vpd, rc); in read_vpd()
/kernel/linux/linux-5.10/drivers/net/ethernet/ibm/
Dibmvnic.c672 if (!adapter->vpd) in release_vpd_data()
675 kfree(adapter->vpd->buff); in release_vpd_data()
676 kfree(adapter->vpd); in release_vpd_data()
678 adapter->vpd = NULL; in release_vpd_data()
1027 if (adapter->vpd->buff) in ibmvnic_get_vpd()
1028 len = adapter->vpd->len; in ibmvnic_get_vpd()
1050 if (!adapter->vpd->len) in ibmvnic_get_vpd()
1053 if (!adapter->vpd->buff) in ibmvnic_get_vpd()
1054 adapter->vpd->buff = kzalloc(adapter->vpd->len, GFP_KERNEL); in ibmvnic_get_vpd()
1055 else if (adapter->vpd->len != len) in ibmvnic_get_vpd()
[all …]
/kernel/linux/linux-5.10/drivers/scsi/csiostor/
Dcsio_hw.h510 struct csio_vpd vpd; member
582 return (ticks * 1000 + hw->vpd.cclk/2) / hw->vpd.cclk; in csio_core_ticks_to_us()
588 return (us * hw->vpd.cclk) / 1000; in csio_us_to_core_ticks()
Dcsio_hw.c306 uint8_t *vpd, csum; in csio_hw_get_vpd_params() local
319 vpd = kzalloc(VPD_LEN, GFP_ATOMIC); in csio_hw_get_vpd_params()
320 if (vpd == NULL) in csio_hw_get_vpd_params()
327 ret = csio_hw_seeprom_read(hw, VPD_BASE, (uint32_t *)(vpd)); in csio_hw_get_vpd_params()
328 addr = *vpd == 0x82 ? VPD_BASE : VPD_BASE_OLD; in csio_hw_get_vpd_params()
331 ret = csio_hw_seeprom_read(hw, addr + i, (uint32_t *)(vpd + i)); in csio_hw_get_vpd_params()
333 kfree(vpd); in csio_hw_get_vpd_params()
341 v = (const struct t4_vpd_hdr *)vpd; in csio_hw_get_vpd_params()
347 kfree(vpd); \ in csio_hw_get_vpd_params()
354 csum += vpd[i]; in csio_hw_get_vpd_params()
[all …]
/kernel/linux/linux-5.10/drivers/net/ethernet/chelsio/cxgb/
Dsubr.c587 static int t1_eeprom_vpd_get(adapter_t *adapter, struct chelsio_vpd_t *vpd) in t1_eeprom_vpd_get() argument
591 for (addr = 0; !ret && addr < sizeof(*vpd); addr += sizeof(u32)) in t1_eeprom_vpd_get()
593 (__le32 *)((u8 *)vpd + addr)); in t1_eeprom_vpd_get()
603 struct chelsio_vpd_t vpd; in vpd_macaddress_get() local
605 if (t1_eeprom_vpd_get(adapter, &vpd)) in vpd_macaddress_get()
607 memcpy(mac_addr, vpd.mac_base_address, 5); in vpd_macaddress_get()
608 mac_addr[5] = vpd.mac_base_address[5] + index; in vpd_macaddress_get()
/kernel/linux/linux-5.10/drivers/net/ethernet/sun/
Dniu.c6781 struct niu_vpd *vpd = &np->vpd; in niu_get_drvinfo() local
6786 vpd->fcode_major, vpd->fcode_minor); in niu_get_drvinfo()
8044 struct niu_vpd *vpd = &np->vpd; in niu_vpd_parse_version() local
8045 int len = strlen(vpd->version) + 1; in niu_vpd_parse_version()
8046 const char *s = vpd->version; in niu_vpd_parse_version()
8057 sscanf(s, "%d.%d", &vpd->fcode_major, &vpd->fcode_minor); in niu_vpd_parse_version()
8061 vpd->fcode_major, vpd->fcode_minor); in niu_vpd_parse_version()
8062 if (vpd->fcode_major > NIU_VPD_MIN_MAJOR || in niu_vpd_parse_version()
8063 (vpd->fcode_major == NIU_VPD_MIN_MAJOR && in niu_vpd_parse_version()
8064 vpd->fcode_minor >= NIU_VPD_MIN_MINOR)) in niu_vpd_parse_version()
[all …]
/kernel/linux/linux-5.10/drivers/scsi/aic7xxx/
Daic79xx_pci.c508 struct vpd_config vpd; in ahd_check_extport() local
528 + (sizeof(vpd) * (ahd->channel - 'A'))) / 2; in ahd_check_extport()
530 error = ahd_read_seeprom(ahd, (uint16_t *)&vpd, in ahd_check_extport()
531 start_addr, sizeof(vpd)/2, in ahd_check_extport()
534 error = ahd_parse_vpddata(ahd, &vpd); in ahd_check_extport()
/kernel/linux/linux-5.10/drivers/scsi/
Dipr.h349 struct ipr_vpd vpd; member
354 struct ipr_vpd vpd; member
859 struct ipr_vpd vpd; member
868 struct ipr_ext_vpd vpd; member
878 struct ipr_ext_vpd vpd; member
888 struct ipr_vpd vpd; member
894 struct ipr_ext_vpd vpd; member
901 struct ipr_ext_vpd vpd; member
1016 struct ipr_vpd vpd; member
1022 struct ipr_ext_vpd vpd; member
Dipr.c1548 struct ipr_vpd *vpd) in ipr_log_vpd_compact() argument
1553 memcpy(buffer, vpd->vpids.vendor_id, IPR_VENDOR_ID_LEN); in ipr_log_vpd_compact()
1556 memcpy(&buffer[i], vpd->vpids.product_id, IPR_PROD_ID_LEN); in ipr_log_vpd_compact()
1559 memcpy(&buffer[i], vpd->sn, IPR_SERIAL_NUM_LEN); in ipr_log_vpd_compact()
1572 static void ipr_log_vpd(struct ipr_vpd *vpd) in ipr_log_vpd() argument
1577 memcpy(buffer, vpd->vpids.vendor_id, IPR_VENDOR_ID_LEN); in ipr_log_vpd()
1578 memcpy(buffer + IPR_VENDOR_ID_LEN, vpd->vpids.product_id, in ipr_log_vpd()
1583 memcpy(buffer, vpd->sn, IPR_SERIAL_NUM_LEN); in ipr_log_vpd()
1598 struct ipr_ext_vpd *vpd) in ipr_log_ext_vpd_compact() argument
1600 ipr_log_vpd_compact(prefix, hostrcb, &vpd->vpd); in ipr_log_ext_vpd_compact()
[all …]
/kernel/linux/linux-5.10/drivers/net/ethernet/chelsio/cxgb4/
Dt4_hw.c2749 u8 *vpd, csum; in t4_get_raw_vpd_params() local
2752 vpd = vmalloc(VPD_LEN); in t4_get_raw_vpd_params()
2753 if (!vpd) in t4_get_raw_vpd_params()
2759 ret = pci_read_vpd(adapter->pdev, VPD_BASE, sizeof(u32), vpd); in t4_get_raw_vpd_params()
2769 addr = *vpd == CHELSIO_VPD_UNIQUE_ID ? VPD_BASE : VPD_BASE_OLD; in t4_get_raw_vpd_params()
2771 ret = pci_read_vpd(adapter->pdev, addr, VPD_LEN, vpd); in t4_get_raw_vpd_params()
2775 if (vpd[0] != PCI_VPD_LRDT_ID_STRING) { in t4_get_raw_vpd_params()
2781 id_len = pci_vpd_lrdt_size(vpd); in t4_get_raw_vpd_params()
2785 i = pci_vpd_find_tag(vpd, 0, VPD_LEN, PCI_VPD_LRDT_RO_DATA); in t4_get_raw_vpd_params()
2792 vpdr_len = pci_vpd_lrdt_size(&vpd[i]); in t4_get_raw_vpd_params()
[all …]
Dcxgb4.h441 struct vpd_params vpd; member
1687 return adap->params.vpd.cclk / 1000; in core_ticks_per_usec()
1693 return (us * adap->params.vpd.cclk) / 1000; in us_to_core_ticks()
1700 return ((ticks * 1000 + adapter->params.vpd.cclk/2) / in core_ticks_to_us()
1701 adapter->params.vpd.cclk); in core_ticks_to_us()
/kernel/linux/linux-5.10/drivers/net/ethernet/brocade/bna/
Dbfa_defs.h48 struct bfa_mfg_vpd vpd; member
/kernel/linux/linux-5.10/drivers/scsi/lpfc/
Dlpfc_init.c119 lpfc_vpd_t *vp = &phba->vpd; in lpfc_config_port_prep()
2169 lpfc_parse_vpd(struct lpfc_hba *phba, uint8_t *vpd, int len) in lpfc_parse_vpd() argument
2177 if (!vpd) in lpfc_parse_vpd()
2183 (uint32_t) vpd[0], (uint32_t) vpd[1], (uint32_t) vpd[2], in lpfc_parse_vpd()
2184 (uint32_t) vpd[3]); in lpfc_parse_vpd()
2186 switch (vpd[index]) { in lpfc_parse_vpd()
2190 lenlo = vpd[index]; in lpfc_parse_vpd()
2192 lenhi = vpd[index]; in lpfc_parse_vpd()
2199 lenlo = vpd[index]; in lpfc_parse_vpd()
2201 lenhi = vpd[index]; in lpfc_parse_vpd()
[all …]

123