Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
60c7e915
Commit
60c7e915
authored
Jun 03, 2003
by
David S. Miller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[NET]: Convert ia64 simeth.c away from init_etherdev().
parent
4e956a78
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
15 deletions
+16
-15
arch/ia64/hp/sim/simeth.c
arch/ia64/hp/sim/simeth.c
+16
-15
No files found.
arch/ia64/hp/sim/simeth.c
View file @
60c7e915
...
...
@@ -191,7 +191,7 @@ simeth_probe1(void)
unsigned
char
mac_addr
[
ETH_ALEN
];
struct
simeth_local
*
local
;
struct
net_device
*
dev
;
int
fd
,
i
;
int
fd
,
i
,
err
;
/*
* XXX Fix me
...
...
@@ -207,22 +207,12 @@ simeth_probe1(void)
if
(
fd
==
-
1
)
return
-
ENODEV
;
dev
=
init_etherdev
(
NULL
,
sizeof
(
struct
simeth_local
));
dev
=
alloc_etherdev
(
sizeof
(
struct
simeth_local
));
if
(
!
dev
)
return
-
ENOMEM
;
memcpy
(
dev
->
dev_addr
,
mac_addr
,
sizeof
(
mac_addr
));
dev
->
irq
=
ia64_alloc_vector
();
/*
* attach the interrupt in the simulator, this does enable interrupts
* until a netdev_attach() is called
*/
netdev_connect
(
dev
->
irq
);
memset
(
dev
->
priv
,
0
,
sizeof
(
struct
simeth_local
));
local
=
dev
->
priv
;
local
->
simfd
=
fd
;
/* keep track of underlying file descriptor */
...
...
@@ -232,8 +222,19 @@ simeth_probe1(void)
dev
->
get_stats
=
simeth_get_stats
;
dev
->
set_multicast_list
=
set_multicast_list
;
/* no yet used */
/* Fill in the fields of the device structure with ethernet-generic values. */
ether_setup
(
dev
);
err
=
register_netdev
(
dev
);
if
(
dev
)
{
kfree
(
dev
);
return
err
;
}
dev
->
irq
=
ia64_alloc_vector
();
/*
* attach the interrupt in the simulator, this does enable interrupts
* until a netdev_attach() is called
*/
netdev_connect
(
dev
->
irq
);
printk
(
KERN_INFO
"%s: hosteth=%s simfd=%d, HwAddr"
,
dev
->
name
,
simeth_device
,
local
->
simfd
);
...
...
@@ -242,7 +243,7 @@ simeth_probe1(void)
}
printk
(
", IRQ %d
\n
"
,
dev
->
irq
);
return
0
;
return
0
;
}
/*
...
...
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