Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
F
FMC TDC 1ns 5cha - Software
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
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 TDC 1ns 5cha - Software
Commits
ba2ccc42
Commit
ba2ccc42
authored
Apr 08, 2015
by
Federico Vaga
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel: fix reset procedure
Signed-off-by:
Federico Vaga
<
federico.vaga@cern.ch
>
parent
96dd7d9f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
6 deletions
+8
-6
ft-svec.c
kernel/ft-svec.c
+7
-5
tdc_regs.h
kernel/hw/tdc_regs.h
+1
-1
No files found.
kernel/ft-svec.c
View file @
ba2ccc42
...
...
@@ -26,15 +26,17 @@ static int ft_svec_reset(struct fmctdc_dev *ft)
dev_dbg
(
&
ft
->
fmc
->
dev
,
"Un-resetting FMCs...
\n
"
);
/* Reset */
fmc_writel
(
ft
->
fmc
,
~
(
1
<<
ft
->
fmc
->
slot_id
),
/* Reset
- reset bits are shifted by 1
*/
fmc_writel
(
ft
->
fmc
,
~
(
1
<<
(
ft
->
fmc
->
slot_id
+
1
)
),
TDC_SVEC_CARRIER_BASE
+
TDC_REG_CARRIER_RST
);
udelay
(
1000
);
udelay
(
5000
);
val
=
fmc_readl
(
ft
->
fmc
,
TDC_SVEC_CARRIER_BASE
+
TDC_REG_CARRIER_RST
);
val
|=
(
1
<<
(
ft
->
fmc
->
slot_id
+
1
));
/* Un-Reset */
fmc_writel
(
ft
->
fmc
,
val
|
(
1
<<
ft
->
fmc
->
slot_id
),
TDC_SVEC_CARRIER_BASE
+
TDC_REG_CARRIER_RST
);
fmc_writel
(
ft
->
fmc
,
val
,
TDC_SVEC_CARRIER_BASE
+
TDC_REG_CARRIER_RST
);
return
0
;
}
...
...
kernel/hw/tdc_regs.h
View file @
ba2ccc42
...
...
@@ -97,7 +97,7 @@
#define TDC_DMA_STAT_DONE 0x1
#define TDC_DMA_STAT_ERROR 0x3
#define TDC_SVEC_CARRIER_BASE 0x
20
000
#define TDC_SVEC_CARRIER_BASE 0x
1
000
/* TDC core submodule offsets (wrs to the TDC control registers block) */
...
...
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