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
01f38644
Commit
01f38644
authored
Jun 10, 2003
by
Andy Grover
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ACPI: Add ACPI PCI Subdriver. This enables acpiphp to work again. (Matthew Wilcox)
parent
556fa9fd
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
62 additions
and
5 deletions
+62
-5
drivers/acpi/acpi_ksyms.c
drivers/acpi/acpi_ksyms.c
+2
-0
drivers/acpi/pci_root.c
drivers/acpi/pci_root.c
+51
-5
include/linux/acpi.h
include/linux/acpi.h
+9
-0
No files found.
drivers/acpi/acpi_ksyms.c
View file @
01f38644
...
@@ -146,6 +146,8 @@ extern int acpi_pci_irq_enable(struct pci_dev *dev);
...
@@ -146,6 +146,8 @@ extern int acpi_pci_irq_enable(struct pci_dev *dev);
EXPORT_SYMBOL
(
acpi_pci_irq_enable
);
EXPORT_SYMBOL
(
acpi_pci_irq_enable
);
extern
int
acpi_pci_irq_lookup
(
int
segment
,
int
bus
,
int
device
,
int
pin
);
extern
int
acpi_pci_irq_lookup
(
int
segment
,
int
bus
,
int
device
,
int
pin
);
EXPORT_SYMBOL
(
acpi_pci_irq_lookup
);
EXPORT_SYMBOL
(
acpi_pci_irq_lookup
);
EXPORT_SYMBOL
(
acpi_pci_register_driver
);
EXPORT_SYMBOL
(
acpi_pci_unregister_driver
);
#endif
/*CONFIG_ACPI_PCI */
#endif
/*CONFIG_ACPI_PCI */
#ifdef CONFIG_ACPI_EC
#ifdef CONFIG_ACPI_EC
...
...
drivers/acpi/pci_root.c
View file @
01f38644
...
@@ -59,17 +59,63 @@ static struct acpi_driver acpi_pci_root_driver = {
...
@@ -59,17 +59,63 @@ static struct acpi_driver acpi_pci_root_driver = {
},
},
};
};
struct
acpi_pci_root
{
struct
acpi_pci_root
{
struct
list_head
node
;
struct
list_head
node
;
acpi_handle
handle
;
acpi_handle
handle
;
struct
acpi_pci_id
id
;
struct
acpi_pci_id
id
;
struct
pci_bus
*
bus
;
struct
pci_bus
*
bus
;
u64
mem_tra
;
u64
mem_tra
;
u64
io_tra
;
u64
io_tra
;
};
};
struct
list_head
acpi_pci_roots
;
struct
list_head
acpi_pci_roots
;
static
struct
acpi_pci_driver
*
sub_driver
;
int
acpi_pci_register_driver
(
struct
acpi_pci_driver
*
driver
)
{
int
n
=
0
;
struct
list_head
*
entry
;
struct
acpi_pci_driver
**
pptr
=
&
sub_driver
;
while
(
*
pptr
)
pptr
=
&
(
*
pptr
)
->
next
;
*
pptr
=
driver
;
if
(
!
driver
->
add
)
return
0
;
list_for_each
(
entry
,
&
acpi_pci_roots
)
{
struct
acpi_pci_root
*
root
;
root
=
list_entry
(
entry
,
struct
acpi_pci_root
,
node
);
driver
->
add
(
root
->
handle
);
n
++
;
}
return
n
;
}
void
acpi_pci_unregister_driver
(
struct
acpi_pci_driver
*
driver
)
{
struct
list_head
*
entry
;
struct
acpi_pci_driver
**
pptr
=
&
sub_driver
;
while
(
*
pptr
)
{
if
(
*
pptr
!=
driver
)
continue
;
*
pptr
=
(
*
pptr
)
->
next
;
break
;
}
if
(
!
driver
->
remove
)
return
;
list_for_each
(
entry
,
&
acpi_pci_roots
)
{
struct
acpi_pci_root
*
root
;
root
=
list_entry
(
entry
,
struct
acpi_pci_root
,
node
);
driver
->
remove
(
root
->
handle
);
}
}
void
void
acpi_pci_get_translations
(
acpi_pci_get_translations
(
...
...
include/linux/acpi.h
View file @
01f38644
...
@@ -401,6 +401,15 @@ struct pci_dev;
...
@@ -401,6 +401,15 @@ struct pci_dev;
int
acpi_pci_irq_enable
(
struct
pci_dev
*
dev
);
int
acpi_pci_irq_enable
(
struct
pci_dev
*
dev
);
int
acpi_pci_irq_init
(
void
);
int
acpi_pci_irq_init
(
void
);
struct
acpi_pci_driver
{
struct
acpi_pci_driver
*
next
;
int
(
*
add
)(
acpi_handle
*
handle
);
void
(
*
remove
)(
acpi_handle
*
handle
);
};
int
acpi_pci_register_driver
(
struct
acpi_pci_driver
*
driver
);
void
acpi_pci_unregister_driver
(
struct
acpi_pci_driver
*
driver
);
#endif
/*CONFIG_ACPI_PCI*/
#endif
/*CONFIG_ACPI_PCI*/
#ifdef CONFIG_ACPI_EC
#ifdef CONFIG_ACPI_EC
...
...
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