Commit 7ffdfdd3 authored by Federico Vaga's avatar Federico Vaga

wrtd:rt:*: fix white-spaces

Signed-off-by: Federico Vaga's avatarFederico Vaga <federico.vaga@cern.ch>


NOTE
This commit has been created by `git subtree` on the Mock Turtle repository
on tag mock-turtle-2.0

This commit will not compile
parent 28ccad4b
...@@ -163,7 +163,7 @@ static int wrtd_out_hash_table_find(struct wrtd_trig_id *tid) ...@@ -163,7 +163,7 @@ static int wrtd_out_hash_table_find(struct wrtd_trig_id *tid)
return hidx; return hidx;
} }
return -1; return -1;
} }
...@@ -282,9 +282,9 @@ static inline int pulse_queue_empty(struct lrt_pulse_queue *p) ...@@ -282,9 +282,9 @@ static inline int pulse_queue_empty(struct lrt_pulse_queue *p)
*/ */
static struct pulse_queue_entry* pulse_queue_front(struct lrt_pulse_queue *p) static struct pulse_queue_entry* pulse_queue_front(struct lrt_pulse_queue *p)
{ {
if (!p->count) if (!p->count)
return NULL; return NULL;
return &p->data[p->tail]; return &p->data[p->tail];
} }
...@@ -462,7 +462,7 @@ static void do_output (struct wrtd_out_channel *out) ...@@ -462,7 +462,7 @@ static void do_output (struct wrtd_out_channel *out)
/* Output is idle: check if there's something in the queue to execute */ /* Output is idle: check if there's something in the queue to execute */
if (pulse_queue_empty(q)) if (pulse_queue_empty(q))
return; return;
pq_ent = pulse_queue_front(q); pq_ent = pulse_queue_front(q);
ts = &pq_ent->trig.ts; ts = &pq_ent->trig.ts;
...@@ -636,7 +636,7 @@ static void filter_trigger(struct wrtd_trigger_entry *trig) ...@@ -636,7 +636,7 @@ static void filter_trigger(struct wrtd_trigger_entry *trig)
void do_rx(void) void do_rx(void)
{ {
volatile struct wrtd_trigger_entry *ent; volatile struct wrtd_trigger_entry *ent;
struct wrtd_trigger_entry trig; struct wrtd_trigger_entry trig;
struct wrtd_trigger_message *msg; struct wrtd_trigger_message *msg;
int i; int i;
...@@ -737,7 +737,7 @@ static int wrtd_out_hash_table_free(struct wrtd_trig_id *tid) ...@@ -737,7 +737,7 @@ static int wrtd_out_hash_table_free(struct wrtd_trig_id *tid)
if (trig_eq(tid, &ht[hidx]->id)) if (trig_eq(tid, &ht[hidx]->id))
break; break;
} }
return -1; return -1;
} }
...@@ -818,7 +818,7 @@ static int wrtd_out_trigger_index(struct trtl_proto_header *hin, void *pin, ...@@ -818,7 +818,7 @@ static int wrtd_out_trigger_index(struct trtl_proto_header *hin, void *pin,
if (hin->len * 4 != sizeof(struct wrtd_trig_id)) { if (hin->len * 4 != sizeof(struct wrtd_trig_id)) {
pp_printf("%s: wrong incoming message size %d (expected %d)\n", pp_printf("%s: wrong incoming message size %d (expected %d)\n",
__func__, hin->len * 4, sizeof(struct wrtd_trig_id)); __func__, hin->len * 4, sizeof(struct wrtd_trig_id));
goto err; goto err;
} }
if (!pout) { if (!pout) {
pp_printf("%s: missing payload)\n", __func__); pp_printf("%s: missing payload)\n", __func__);
...@@ -967,14 +967,14 @@ void init(void) ...@@ -967,14 +967,14 @@ void init(void)
for (i = 0; i < FD_NUM_CHANNELS; i++) { for (i = 0; i < FD_NUM_CHANNELS; i++) {
memset(&wrtd_out_channels[i], 0, memset(&wrtd_out_channels[i], 0,
sizeof(struct wrtd_out_channel)); sizeof(struct wrtd_out_channel));
wrtd_out_channels[i].base_addr = 0x100 + i * 0x100; wrtd_out_channels[i].base_addr = 0x100 + i * 0x100;
wrtd_out_channels[i].n = i; wrtd_out_channels[i].n = i;
wrtd_out_channels[i].config.mode = WRTD_TRIGGER_MODE_AUTO; wrtd_out_channels[i].config.mode = WRTD_TRIGGER_MODE_AUTO;
wrtd_out_channels[i].priv.pending_trig = NULL; wrtd_out_channels[i].priv.pending_trig = NULL;
wrtd_out_channels[i].config.state = OUT_ST_IDLE; wrtd_out_channels[i].config.state = OUT_ST_IDLE;
wrtd_out_channels[i].priv.idle = 1; wrtd_out_channels[i].priv.idle = 1;
wrtd_out_channels[i].config.dead_time = 80000 / 8; // 80 us wrtd_out_channels[i].config.dead_time = 80000 / 8; // 80 us
wrtd_out_channels[i].config.width_cycles = 1250; // 1us wrtd_out_channels[i].config.width_cycles = 1250; // 1us
pp_printf("mode %d %d\n", i , wrtd_out_channels[i].config.mode); pp_printf("mode %d %d\n", i , wrtd_out_channels[i].config.mode);
} }
......
...@@ -278,7 +278,7 @@ static int wrtd_in_trigger_sw(struct trtl_proto_header *hin, void *pin, ...@@ -278,7 +278,7 @@ static int wrtd_in_trigger_sw(struct trtl_proto_header *hin, void *pin,
So add to it the current time */ So add to it the current time */
struct wr_timestamp ts_orig; struct wr_timestamp ts_orig;
ts_orig.seconds = lr_readl(WRN_CPU_LR_REG_TAI_SEC); ts_orig.seconds = lr_readl(WRN_CPU_LR_REG_TAI_SEC);
ts_orig.ticks = lr_readl(WRN_CPU_LR_REG_TAI_CYCLES); ts_orig.ticks = lr_readl(WRN_CPU_LR_REG_TAI_CYCLES);
...@@ -349,7 +349,7 @@ void wr_update_link(void) ...@@ -349,7 +349,7 @@ void wr_update_link(void)
} }
if ( wr_state != WR_LINK_OFFLINE && !wr_link_up() ) { if ( wr_state != WR_LINK_OFFLINE && !wr_link_up() ) {
pp_printf("rt-tdc: WR sync lost\n"); pp_printf("rt-tdc: WR sync lost\n");
wr_state = WR_LINK_OFFLINE; wr_state = WR_LINK_OFFLINE;
wr_enable_lock(0); wr_enable_lock(0);
} }
......
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