Lines Matching refs:desc

105 				     struct xilinx_board_description *desc)  in xilinx_read_eeprom_legacy()  argument
139 strcpy(desc->name, eeprom_content->board_name); in xilinx_read_eeprom_legacy()
140 strcpy(desc->revision, eeprom_content->board_revision); in xilinx_read_eeprom_legacy()
141 strcpy(desc->serial, eeprom_content->board_sn); in xilinx_read_eeprom_legacy()
143 memcpy(desc->mac_addr[0], eeprom_content->eth_mac, ETH_ALEN); in xilinx_read_eeprom_legacy()
145 desc->header = EEPROM_HEADER_MAGIC; in xilinx_read_eeprom_legacy()
168 struct xilinx_board_description *desc) in xilinx_read_eeprom_fru() argument
199 if (desc->header == EEPROM_HEADER_MAGIC) { in xilinx_read_eeprom_fru()
205 strncpy(desc->manufacturer, (char *)fru_data.brd.manufacturer_name, in xilinx_read_eeprom_fru()
206 sizeof(desc->manufacturer)); in xilinx_read_eeprom_fru()
207 strncpy(desc->name, (char *)fru_data.brd.product_name, in xilinx_read_eeprom_fru()
208 sizeof(desc->name)); in xilinx_read_eeprom_fru()
209 strncpy(desc->revision, (char *)fru_data.brd.rev, in xilinx_read_eeprom_fru()
210 sizeof(desc->revision)); in xilinx_read_eeprom_fru()
211 strncpy(desc->serial, (char *)fru_data.brd.serial_number, in xilinx_read_eeprom_fru()
212 sizeof(desc->serial)); in xilinx_read_eeprom_fru()
213 desc->header = EEPROM_HEADER_MAGIC; in xilinx_read_eeprom_fru()
244 struct xilinx_board_description *desc) in xilinx_read_eeprom_single() argument
268 return xilinx_read_eeprom_fru(dev, name, desc); in xilinx_read_eeprom_single()
271 return xilinx_read_eeprom_legacy(dev, name, desc); in xilinx_read_eeprom_single()
280 struct xilinx_board_description *desc; in xilinx_read_eeprom() local
287 board_info = calloc(1, sizeof(desc) * highest_id); in xilinx_read_eeprom()
298 desc = board_info[id]; in xilinx_read_eeprom()
299 if (!desc) { in xilinx_read_eeprom()
300 desc = calloc(1, sizeof(*desc)); in xilinx_read_eeprom()
301 if (!desc) in xilinx_read_eeprom()
304 board_info[id] = desc; in xilinx_read_eeprom()
308 ret = xilinx_read_eeprom_single(name_buf, desc); in xilinx_read_eeprom()
310 free(desc); in xilinx_read_eeprom()
379 struct xilinx_board_description *desc; in board_late_init_xilinx() local
400 desc = board_info[id]; in board_late_init_xilinx()
401 if (desc && desc->header == EEPROM_HEADER_MAGIC) { in board_late_init_xilinx()
402 if (desc->manufacturer[0]) in board_late_init_xilinx()
404 desc->manufacturer); in board_late_init_xilinx()
405 if (desc->name[0]) in board_late_init_xilinx()
407 desc->name); in board_late_init_xilinx()
408 if (desc->revision[0]) in board_late_init_xilinx()
410 desc->revision); in board_late_init_xilinx()
411 if (desc->serial[0]) in board_late_init_xilinx()
413 desc->serial); in board_late_init_xilinx()
419 if (!desc->mac_addr[i]) in board_late_init_xilinx()
422 if (is_valid_ethaddr((const u8 *)desc->mac_addr[i])) in board_late_init_xilinx()
424 macid++, desc->mac_addr[i]); in board_late_init_xilinx()