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
9805701f
Commit
9805701f
authored
Mar 06, 2014
by
Alessandro Rubini
Committed by
Federico Vaga
Apr 07, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel: use PARAM_GATEWARE and official fmc names
Signed-off-by:
Alessandro Rubini
<
rubini@gnudd.com
>
parent
97d81951
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
7 deletions
+9
-7
fa-core.c
kernel/fa-core.c
+9
-7
No files found.
kernel/fa-core.c
View file @
9805701f
...
...
@@ -19,10 +19,6 @@ static struct fmc_driver fa_dev_drv;
FMC_PARAM_BUSID
(
fa_dev_drv
);
FMC_PARAM_GATEWARE
(
fa_dev_drv
);
static
char
*
fa_binary
=
FA_GATEWARE_DEFAULT_NAME
;
module_param_named
(
file
,
fa_binary
,
charp
,
0444
);
static
const
int
zfad_hw_range
[]
=
{
[
ZFA_RANGE_10V
]
=
0x45
,
[
ZFA_RANGE_1V
]
=
0x11
,
...
...
@@ -264,6 +260,7 @@ int fa_probe(struct fmc_device *fmc)
struct
fa_modlist
*
m
=
NULL
;
struct
fa_dev
*
fa
;
int
err
,
i
=
0
;
char
*
fwname
;
/* Validate the new FMC device */
i
=
fmc
->
op
->
validate
(
fmc
,
&
fa_dev_drv
);
...
...
@@ -273,7 +270,6 @@ int fa_probe(struct fmc_device *fmc)
return
-
ENODEV
;
}
pr_info
(
"%s:%d
\n
"
,
__func__
,
__LINE__
);
/* Driver data */
fa
=
devm_kzalloc
(
&
fmc
->
dev
,
sizeof
(
struct
fa_dev
),
GFP_KERNEL
);
if
(
!
fa
)
...
...
@@ -281,13 +277,19 @@ int fa_probe(struct fmc_device *fmc)
fmc_set_drvdata
(
fmc
,
fa
);
fa
->
fmc
=
fmc
;
if
(
fa_dev_drv
.
gw_n
)
fwname
=
""
;
/* reprogram will pick from module parameter */
else
fwname
=
FA_GATEWARE_DEFAULT_NAME
;
dev_info
(
fmc
->
hwdev
,
"Gateware (%s)
\n
"
,
fwname
);
/* We first write a new binary (and lm32) within the carrier */
err
=
fmc
->
op
->
reprogram
(
fmc
,
&
fa_dev_drv
,
f
a_binary
);
err
=
fmc
->
op
->
reprogram
(
fmc
,
&
fa_dev_drv
,
f
wname
);
if
(
err
)
{
dev_err
(
fmc
->
hwdev
,
"write firmware
\"
%s
\"
: error %i
\n
"
,
f
a_binary
,
err
);
f
wname
,
err
);
goto
out
;
}
dev_info
(
fmc
->
hwdev
,
"Gateware successfully loaded
\n
"
);
/* init all subsystems */
for
(
i
=
0
,
m
=
mods
;
i
<
ARRAY_SIZE
(
mods
);
i
++
,
m
++
)
{
...
...
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