Commit 17cdfaf7 authored by Jorge Machado's avatar Jorge Machado

Software WR-starting-kit changes associated with GW review

parent 1f1c7a22
......@@ -85,7 +85,7 @@ static void __fmc_dio_int_new_pulse(struct fmc_dio *dev, int ch,
map = get_regmap(dev->version);
map += ch;
fmc_dio_int_ts_sub(ts, 8); /* 1 cycle, to account for output latencies */
fmc_dio_int_ts_sub(ts, 16); /* 2 cycles, to account for output latencies */
writel(ts->tv_nsec / 8, base + map->cycle);
writel(GET_HI32(ts->tv_sec), base + map->trig_h);
writel(ts->tv_sec, base + map->trig_l);
......@@ -541,8 +541,9 @@ irqreturn_t fmc_dio_int_interrupt(struct fmc_dio *dev)
SET_HI32(ts->tv_sec, readl(base + map->fifo_tai_h));
ts->tv_sec |= readl(base + map->fifo_tai_l);
ts->tv_nsec = 8 * readl(base + map->fifo_cycle);
/* subtract 5 cycles lost in input sync circuits */
fmc_dio_int_ts_sub(ts, 40);
/* subtract 4 cycles lost in input sync circuits */
fmc_dio_int_ts_sub(ts, 32);
}
writel(chm, base + dio.eic_isr_reg); /* ack */
......
......@@ -329,7 +329,6 @@ static int scan_irq(int argc, char **argv)
} else {
char *s2 = argv[1];
fprintf(stderr,"IRQ Relative time\n");
if (s2[0] == '+') {
cmd->flags |= WR_DIO_F_REL;
s2++;
......@@ -351,7 +350,6 @@ static int scan_irq(int argc, char **argv)
prgname, argv[0], argv[1]);
return -1;
}
fprintf(stderr, "%lu \n", cmd->t[1].tv_nsec);
if(cmd->t[1].tv_nsec < 1000000)
{
fprintf(stderr, "%s: %s: Frequency is greater than 1 kHz \n",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment