Commit 50fa6cff authored by Alessandro Rubini's avatar Alessandro Rubini

wr-servo (and wr): remove _t from name of structures

Signed-off-by: Alessandro Rubini's avatarAlessandro Rubini <rubini@gnudd.com>
parent 2ab718f3
......@@ -53,7 +53,7 @@ static DSCurrent currentDS;
static DSParent parentDS;
static DSTimeProperties timePropertiesDS;
static struct pp_servo servo;
static struct wr_servo_state_t servo_state;
static struct wr_servo_state servo_state;
static struct wr_dsport wr_dsport = {
.ops = &wrpc_wr_operations,
......
......@@ -161,7 +161,7 @@ int main(int argc, char **argv)
ppg->max_links = PP_MAX_LINKS;
ppg->global_ext_data = alloc_fn(ppsi_head,
sizeof(struct wr_servo_state_t));
sizeof(struct wr_servo_state));
/* NOTE: arch_data is not in shmem */
ppg->arch_data = malloc( sizeof(struct unix_arch_data));
ppg->pp_instances = alloc_fn(ppsi_head,
......
......@@ -132,7 +132,7 @@ int wr_servo_got_sync(struct pp_instance *ppi, TimeInternal *t1,
int wr_servo_got_delay(struct pp_instance *ppi, Integer32 cf);
int wr_servo_update(struct pp_instance *ppi);
struct wr_servo_state_t {
struct wr_servo_state {
char if_name[16]; /* Informative, for wr_mon through shmem */
int state;
int next_state;
......@@ -164,8 +164,8 @@ struct wr_servo_state_t {
};
/* All data used as extension ppsi-wr must be put here */
struct wr_data_t {
struct wr_servo_state_t servo_state;
struct wr_data {
struct wr_servo_state servo_state;
};
#endif /* __WREXT_WR_API_H__ */
......@@ -26,7 +26,7 @@ static const char *servo_name[] = {
static int tracking_enabled = 1; /* FIXME: why? */
extern struct wrs_shm_head *ppsi_head;
static struct wr_servo_state_t *saved_servo_pointer; /* required for
static struct wr_servo_state *saved_servo_pointer; /* required for
* wr_servo_reset, which doesn't
* have ppi context. */
......@@ -158,8 +158,8 @@ static inline int32_t delta_to_ps(struct FixedDelta d)
int wr_servo_init(struct pp_instance *ppi)
{
struct wr_dsport *wrp = WR_DSPOR(ppi);
struct wr_servo_state_t *s =
&((struct wr_data_t *)ppi->ext_data)->servo_state;
struct wr_servo_state *s =
&((struct wr_data *)ppi->ext_data)->servo_state;
/* shmem lock */
wrs_shm_write(ppsi_head, WRS_SHM_WRITE_BEGIN);
/* Determine the alpha coefficient */
......@@ -203,8 +203,8 @@ int wr_servo_man_adjust_phase(int phase)
int wr_servo_got_sync(struct pp_instance *ppi, TimeInternal *t1,
TimeInternal *t2)
{
struct wr_servo_state_t *s =
&((struct wr_data_t *)ppi->ext_data)->servo_state;
struct wr_servo_state *s =
&((struct wr_data *)ppi->ext_data)->servo_state;
s->t1 = *t1;
s->t1.correct = 1;
......@@ -217,8 +217,8 @@ int wr_servo_got_sync(struct pp_instance *ppi, TimeInternal *t1,
int wr_servo_got_delay(struct pp_instance *ppi, Integer32 cf)
{
struct wr_servo_state_t *s =
&((struct wr_data_t *)ppi->ext_data)->servo_state;
struct wr_servo_state *s =
&((struct wr_data *)ppi->ext_data)->servo_state;
s->t3 = ppi->t3;
/* s->t3.phase = 0; */
......@@ -233,8 +233,8 @@ int wr_servo_got_delay(struct pp_instance *ppi, Integer32 cf)
int wr_servo_update(struct pp_instance *ppi)
{
struct wr_dsport *wrp = WR_DSPOR(ppi);
struct wr_servo_state_t *s =
&((struct wr_data_t *)ppi->ext_data)->servo_state;
struct wr_servo_state *s =
&((struct wr_data *)ppi->ext_data)->servo_state;
uint64_t big_delta_fix;
uint64_t delay_ms_fix;
......
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