mirror of
https://github.com/corundum/corundum.git
synced 2025-01-16 08:12:53 +08:00
Read timeslot count
This commit is contained in:
parent
f53a6b20e8
commit
abdb714fd9
@ -197,6 +197,8 @@ int main(int argc, char *argv[])
|
|||||||
printf("Sched stride: 0x%08x\n", dev_port->sched_stride);
|
printf("Sched stride: 0x%08x\n", dev_port->sched_stride);
|
||||||
printf("Sched type: 0x%08x\n", dev_port->sched_type);
|
printf("Sched type: 0x%08x\n", dev_port->sched_type);
|
||||||
|
|
||||||
|
printf("Timeslot count: %d\n", dev_port->tdma_timeslot_count);
|
||||||
|
|
||||||
if (period_nsec > 0)
|
if (period_nsec > 0)
|
||||||
{
|
{
|
||||||
printf("Configure port TDMA schedule\n");
|
printf("Configure port TDMA schedule\n");
|
||||||
|
@ -142,6 +142,8 @@ struct mqnic *mqnic_open(const char *dev_name)
|
|||||||
port->sched_offset = mqnic_reg_read32(port->regs, MQNIC_PORT_REG_SCHED_OFFSET);
|
port->sched_offset = mqnic_reg_read32(port->regs, MQNIC_PORT_REG_SCHED_OFFSET);
|
||||||
port->sched_stride = mqnic_reg_read32(port->regs, MQNIC_PORT_REG_SCHED_STRIDE);
|
port->sched_stride = mqnic_reg_read32(port->regs, MQNIC_PORT_REG_SCHED_STRIDE);
|
||||||
port->sched_type = mqnic_reg_read32(port->regs, MQNIC_PORT_REG_SCHED_TYPE);
|
port->sched_type = mqnic_reg_read32(port->regs, MQNIC_PORT_REG_SCHED_TYPE);
|
||||||
|
|
||||||
|
port->tdma_timeslot_count = mqnic_reg_read32(port->regs, MQNIC_PORT_REG_TDMA_TIMESLOT_COUNT);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -58,6 +58,8 @@ struct mqnic_port {
|
|||||||
uint32_t sched_offset;
|
uint32_t sched_offset;
|
||||||
uint32_t sched_stride;
|
uint32_t sched_stride;
|
||||||
uint32_t sched_type;
|
uint32_t sched_type;
|
||||||
|
|
||||||
|
uint32_t tdma_timeslot_count;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct mqnic_if {
|
struct mqnic_if {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user