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
Kirill Smelkov
linux
Commits
bbbd317e
Commit
bbbd317e
authored
Sep 20, 2004
by
Pavel Machek
Committed by
Jeff Garzik
Sep 20, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] swsuspend for ne2k-pci cards
Author: Ãric Brunet <Eric.Brunet@lps.ens.fr>
parent
980b00f6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
31 additions
and
0 deletions
+31
-0
drivers/net/ne2k-pci.c
drivers/net/ne2k-pci.c
+31
-0
No files found.
drivers/net/ne2k-pci.c
View file @
bbbd317e
...
...
@@ -653,12 +653,43 @@ static void __devexit ne2k_pci_remove_one (struct pci_dev *pdev)
pci_set_drvdata
(
pdev
,
NULL
);
}
#ifdef CONFIG_PM
static
int
ne2k_pci_suspend
(
struct
pci_dev
*
pdev
,
u32
state
)
{
struct
net_device
*
dev
=
pci_get_drvdata
(
pdev
);
netif_device_detach
(
dev
);
pci_save_state
(
pdev
,
pdev
->
saved_config_space
);
pci_set_power_state
(
pdev
,
state
);
return
0
;
}
static
int
ne2k_pci_resume
(
struct
pci_dev
*
pdev
)
{
struct
net_device
*
dev
=
pci_get_drvdata
(
pdev
);
pci_set_power_state
(
pdev
,
0
);
pci_restore_state
(
pdev
,
pdev
->
saved_config_space
);
NS8390_init
(
dev
,
1
);
netif_device_attach
(
dev
);
return
0
;
}
#endif
/* CONFIG_PM */
static
struct
pci_driver
ne2k_driver
=
{
.
name
=
DRV_NAME
,
.
probe
=
ne2k_pci_init_one
,
.
remove
=
__devexit_p
(
ne2k_pci_remove_one
),
.
id_table
=
ne2k_pci_tbl
,
#ifdef CONFIG_PM
.
suspend
=
ne2k_pci_suspend
,
.
resume
=
ne2k_pci_resume
,
#endif
/* CONFIG_PM */
};
...
...
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