Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
F
FMC DEL 1ns 4cha - 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 DEL 1ns 4cha - Software
Commits
9d862ec4
Commit
9d862ec4
authored
Dec 16, 2012
by
Alessandro Rubini
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
trivial: fd-core: use a shortcut variable we already have
Signed-off-by:
Alessandro Rubini
<
rubini@gnudd.com
>
parent
4ff78a28
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
fd-core.c
kernel/fd-core.c
+7
-7
No files found.
kernel/fd-core.c
View file @
9d862ec4
...
...
@@ -148,21 +148,21 @@ int fd_probe(struct fmc_device *fmc)
fd
=
kzalloc
(
sizeof
(
*
fd
),
GFP_KERNEL
);
if
(
!
fd
)
{
dev_err
(
fmc
->
hw
dev
,
"can't allocate device
\n
"
);
dev_err
(
dev
,
"can't allocate device
\n
"
);
return
-
ENOMEM
;
}
if
(
strcmp
(
fmc
->
carrier_name
,
"SPEC"
))
{
dev_err
(
fmc
->
hw
dev
,
"driver
\"
%s
\"
only works on SPEC card
\n
"
,
dev_err
(
dev
,
"driver
\"
%s
\"
only works on SPEC card
\n
"
,
KBUILD_MODNAME
);
dev_err
(
fmc
->
hw
dev
,
"support for carrier
\"
%s
\"
is missing
\n
"
,
dev_err
(
dev
,
"support for carrier
\"
%s
\"
is missing
\n
"
,
fmc
->
carrier_name
);
return
-
ENODEV
;
}
index
=
fmc
->
op
->
validate
(
fmc
,
&
fd_drv
);
if
(
index
<
0
)
{
dev_info
(
fmc
->
hw
dev
,
"not using
\"
%s
\"
according to "
dev_info
(
dev
,
"not using
\"
%s
\"
according to "
"modparam
\n
"
,
KBUILD_MODNAME
);
return
-
ENODEV
;
}
...
...
@@ -173,7 +173,7 @@ int fd_probe(struct fmc_device *fmc)
ret
=
fmc
->
op
->
reprogram
(
fmc
,
&
fd_drv
,
fwname
);
if
(
ret
<
0
)
{
if
(
ret
==
-
ESRCH
)
{
dev_info
(
fmc
->
hw
dev
,
"%s: no gateware at index %i
\n
"
,
dev_info
(
dev
,
"%s: no gateware at index %i
\n
"
,
KBUILD_MODNAME
,
index
);
return
-
ENODEV
;
}
...
...
@@ -205,10 +205,10 @@ int fd_probe(struct fmc_device *fmc)
/* Check the binary is there */
if
(
fd_readl
(
fd
,
FD_REG_IDR
)
!=
FD_MAGIC_FPGA
)
{
dev_err
(
fmc
->
hw
dev
,
"wrong gateware
\n
"
);
dev_err
(
dev
,
"wrong gateware
\n
"
);
return
-
ENODEV
;
}
else
{
dev_info
(
fmc
->
hw
dev
,
"%s: initializing
\n
"
,
KBUILD_MODNAME
);
dev_info
(
dev
,
"%s: initializing
\n
"
,
KBUILD_MODNAME
);
}
/* First, hardware reset */
...
...
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