Commit 427bb692 authored by Federico Vaga's avatar Federico Vaga

fa-zio-drv.c: update seconds on probe

Use the kernel seconds to configure the UTC seconds register of the ADC
Signed-off-by: 's avatarFederico Vaga <federico.vaga@gmail.com>
parent b585991a
......@@ -12,6 +12,7 @@
#include <linux/types.h>
#include <linux/list.h>
#include <linux/moduleparam.h>
#include <linux/time.h>
#include <linux/delay.h>
#include <linux/zio.h>
......@@ -433,6 +434,8 @@ static int zfad_init_cset(struct zio_cset *cset)
/* Select external trigger (index 0) */
zfa_common_conf_set(fa, &zfad_regs[ZFAT_CFG_INT_SEL], 1);
cset->ti->zattr_set.ext_zattr[0].value = 1;
/* Set UTC seconds from the kernel seconds */
zfa_common_conf_set(fa, &zfad_regs[ZFA_UTC_SECONDS], get_seconds());
return 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