Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
F
FMC ADC 100M 14b 4cha - Software
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
FMC ADC 100M 14b 4cha - Software
Commits
1686e9c9
Commit
1686e9c9
authored
Mar 23, 2013
by
Federico Vaga
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[improve] fa-zio-drv.c: STOP state machine on acquisition error
Signed-off-by:
Federico Vaga
<
federico.vaga@gmail.com
>
parent
82aa23bd
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
fa-zio-drv.c
kernel/fa-zio-drv.c
+5
-4
No files found.
kernel/fa-zio-drv.c
View file @
1686e9c9
...
...
@@ -735,7 +735,7 @@ static void zfat_irq_dma_done(struct zio_cset *cset, int status)
zfa_common_info_get
(
fa
,
ZFA_DMA_STA
,
&
val
);
dev_err
(
fa
->
fmc
->
hwdev
,
"DMA error (status 0x%x). All acquisition lost
\n
"
,
val
);
z
io_trigger_abort_disable
(
cset
,
0
);
z
fad_fsm_command
(
fa
,
ZFA_STOP
);
fa
->
n_dma_err
++
;
}
}
...
...
@@ -772,8 +772,8 @@ static void zfat_irq_trg_fire(struct zio_cset *cset)
dev_dbg
(
fa
->
fmc
->
hwdev
,
"Trigger fire %i/%i
\n
"
,
fa
->
n_fires
+
1
,
fa
->
n_shots
);
if
(
fa
->
n_fires
>=
fa
->
n_shots
)
{
WARN
(
1
,
"Invalid Fire"
);
dev_err
(
fa
->
fmc
->
hwdev
,
"Invalid fire, skip
\n
"
);
WARN
(
1
,
"Invalid Fire
, STOP acquisition
"
);
zfad_fsm_command
(
fa
,
ZFA_STOP
);
return
;
}
...
...
@@ -821,7 +821,7 @@ static void zfat_irq_acq_end(struct zio_cset *cset)
dev_warn
(
fa
->
fmc
->
hwdev
,
"Can't start DMA on the last acquisition, "
"State Machine is not IDLE (status:%d)
\n
"
,
val
);
z
io_trigger_abort_disable
(
cset
,
0
);
z
fad_fsm_command
(
fa
,
ZFA_STOP
);
return
;
}
...
...
@@ -982,6 +982,7 @@ static int zfad_init_cset(struct zio_cset *cset)
/* Initialize channels to use 1V range */
for
(
i
=
0
;
i
<
4
;
++
i
)
zfad_calibration
(
fa
,
&
cset
->
chan
[
i
],
0x11
);
zfad_reset_offset
(
fa
);
/* Enable mezzanine clock */
zfa_common_conf_set
(
fa
,
ZFA_CTL_CLK_EN
,
1
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment