1
0
mirror of https://github.com/corundum/corundum.git synced 2025-01-16 08:12:53 +08:00

Read PHC stride

This commit is contained in:
Alex Forencich 2019-12-30 21:02:24 -08:00
parent 8aeea9e110
commit f6da532b97
4 changed files with 4 additions and 0 deletions

View File

@ -148,6 +148,7 @@ int main(int argc, char *argv[])
printf("Board version: %d.%d\n", dev->board_ver >> 16, dev->board_ver & 0xffff);
printf("PHC count: %d\n", dev->phc_count);
printf("PHC offset: 0x%08x\n", dev->phc_offset);
printf("PHC stride: 0x%08x\n", dev->phc_stride);
printf("IF count: %d\n", dev->if_count);
printf("IF stride: 0x%08x\n", dev->if_stride);
printf("IF CSR offset: 0x%08x\n", dev->if_csr_offset);

View File

@ -105,6 +105,7 @@ int main(int argc, char *argv[])
printf("Board version: %d.%d\n", dev->board_ver >> 16, dev->board_ver & 0xffff);
printf("PHC count: %d\n", dev->phc_count);
printf("PHC offset: 0x%08x\n", dev->phc_offset);
printf("PHC stride: 0x%08x\n", dev->phc_stride);
printf("IF count: %d\n", dev->if_count);
printf("IF stride: 0x%08x\n", dev->if_stride);
printf("IF CSR offset: 0x%08x\n", dev->if_csr_offset);

View File

@ -86,6 +86,7 @@ struct mqnic *mqnic_open(const char *dev_name)
dev->phc_count = mqnic_reg_read32(dev->regs, MQNIC_REG_PHC_COUNT);
dev->phc_offset = mqnic_reg_read32(dev->regs, MQNIC_REG_PHC_OFFSET);
dev->phc_stride = mqnic_reg_read32(dev->regs, MQNIC_REG_PHC_STRIDE);
if (dev->phc_count)
{

View File

@ -113,6 +113,7 @@ struct mqnic {
uint32_t phc_count;
uint32_t phc_offset;
uint32_t phc_stride;
uint32_t if_count;
uint32_t if_stride;