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
b924062a
Commit
b924062a
authored
Jul 13, 2003
by
Scott Murray
Browse files
Options
Browse Files
Download
Plain Diff
Merge minion.yyz.somanetworks.com:/ws/scottm/linux-2.5
into minion.yyz.somanetworks.com:/ws/scottm/linux-2.5-cpci-fixes
parents
5fa458f6
4c853b56
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
25 additions
and
48 deletions
+25
-48
drivers/pci/hotplug/Kconfig
drivers/pci/hotplug/Kconfig
+3
-8
drivers/pci/hotplug/cpci_hotplug.h
drivers/pci/hotplug/cpci_hotplug.h
+0
-1
drivers/pci/hotplug/cpci_hotplug_core.c
drivers/pci/hotplug/cpci_hotplug_core.c
+0
-29
drivers/pci/hotplug/cpci_hotplug_pci.c
drivers/pci/hotplug/cpci_hotplug_pci.c
+22
-10
No files found.
drivers/pci/hotplug/Kconfig
View file @
b924062a
...
@@ -99,22 +99,17 @@ config HOTPLUG_PCI_ACPI
...
@@ -99,22 +99,17 @@ config HOTPLUG_PCI_ACPI
When in doubt, say N.
When in doubt, say N.
config HOTPLUG_PCI_CPCI
config HOTPLUG_PCI_CPCI
tristate
"CompactPCI Hotplug driver"
bool
"CompactPCI Hotplug driver"
depends on HOTPLUG_PCI
depends on HOTPLUG_PCI
help
help
Say Y here if you have a CompactPCI system card with CompactPCI
Say Y here if you have a CompactPCI system card with CompactPCI
hotswap support per the PICMG 2.1 specification.
hotswap support per the PICMG 2.1 specification.
This code is also available as a module ( = code which can be
inserted in and removed from the running kernel whenever you want).
The module will be called cpci_hotplug. If you want to compile it
as a module, say M here and read <file:Documentation/modules.txt>.
When in doubt, say N.
When in doubt, say N.
config HOTPLUG_PCI_CPCI_ZT5550
config HOTPLUG_PCI_CPCI_ZT5550
tristate "Ziatech ZT5550 CompactPCI Hotplug driver"
tristate "Ziatech ZT5550 CompactPCI Hotplug driver"
depends on HOTPLUG_PCI_CPCI && X86
depends on HOTPLUG_PCI
&& HOTPLUG_PCI
_CPCI && X86
help
help
Say Y here if you have an Performance Technologies (formerly Intel,
Say Y here if you have an Performance Technologies (formerly Intel,
formerly just Ziatech) Ziatech ZT5550 CompactPCI system card.
formerly just Ziatech) Ziatech ZT5550 CompactPCI system card.
...
@@ -128,7 +123,7 @@ config HOTPLUG_PCI_CPCI_ZT5550
...
@@ -128,7 +123,7 @@ config HOTPLUG_PCI_CPCI_ZT5550
config HOTPLUG_PCI_CPCI_GENERIC
config HOTPLUG_PCI_CPCI_GENERIC
tristate "Generic port I/O CompactPCI Hotplug driver"
tristate "Generic port I/O CompactPCI Hotplug driver"
depends on HOTPLUG_PCI_CPCI && X86
depends on HOTPLUG_PCI
&& HOTPLUG_PCI
_CPCI && X86
help
help
Say Y here if you have a CompactPCI system card that exposes the #ENUM
Say Y here if you have a CompactPCI system card that exposes the #ENUM
hotswap signal as a bit in a system register that can be read through
hotswap signal as a bit in a system register that can be read through
...
...
drivers/pci/hotplug/cpci_hotplug.h
View file @
b924062a
...
@@ -75,7 +75,6 @@ extern int cpci_hp_register_controller(struct cpci_hp_controller *controller);
...
@@ -75,7 +75,6 @@ extern int cpci_hp_register_controller(struct cpci_hp_controller *controller);
extern
int
cpci_hp_unregister_controller
(
struct
cpci_hp_controller
*
controller
);
extern
int
cpci_hp_unregister_controller
(
struct
cpci_hp_controller
*
controller
);
extern
int
cpci_hp_register_bus
(
struct
pci_bus
*
bus
,
u8
first
,
u8
last
);
extern
int
cpci_hp_register_bus
(
struct
pci_bus
*
bus
,
u8
first
,
u8
last
);
extern
int
cpci_hp_unregister_bus
(
struct
pci_bus
*
bus
);
extern
int
cpci_hp_unregister_bus
(
struct
pci_bus
*
bus
);
extern
struct
slot
*
cpci_find_slot
(
struct
pci_bus
*
bus
,
unsigned
int
devfn
);
extern
int
cpci_hp_start
(
void
);
extern
int
cpci_hp_start
(
void
);
extern
int
cpci_hp_stop
(
void
);
extern
int
cpci_hp_stop
(
void
);
...
...
drivers/pci/hotplug/cpci_hotplug_core.c
View file @
b924062a
...
@@ -427,34 +427,6 @@ cpci_hp_unregister_bus(struct pci_bus *bus)
...
@@ -427,34 +427,6 @@ cpci_hp_unregister_bus(struct pci_bus *bus)
return
0
;
return
0
;
}
}
struct
slot
*
cpci_find_slot
(
struct
pci_bus
*
bus
,
unsigned
int
devfn
)
{
struct
slot
*
slot
;
struct
slot
*
found
;
struct
list_head
*
tmp
;
if
(
!
bus
)
{
return
NULL
;
}
spin_lock
(
&
list_lock
);
if
(
!
slots
)
{
spin_unlock
(
&
list_lock
);
return
NULL
;
}
found
=
NULL
;
list_for_each
(
tmp
,
&
slot_list
)
{
slot
=
list_entry
(
tmp
,
struct
slot
,
slot_list
);
if
(
slot
->
bus
==
bus
&&
slot
->
devfn
==
devfn
)
{
found
=
slot
;
break
;
}
}
spin_unlock
(
&
list_lock
);
return
found
;
}
/* This is the interrupt mode interrupt handler */
/* This is the interrupt mode interrupt handler */
irqreturn_t
irqreturn_t
cpci_hp_intr
(
int
irq
,
void
*
data
,
struct
pt_regs
*
regs
)
cpci_hp_intr
(
int
irq
,
void
*
data
,
struct
pt_regs
*
regs
)
...
@@ -924,6 +896,5 @@ EXPORT_SYMBOL_GPL(cpci_hp_register_controller);
...
@@ -924,6 +896,5 @@ EXPORT_SYMBOL_GPL(cpci_hp_register_controller);
EXPORT_SYMBOL_GPL
(
cpci_hp_unregister_controller
);
EXPORT_SYMBOL_GPL
(
cpci_hp_unregister_controller
);
EXPORT_SYMBOL_GPL
(
cpci_hp_register_bus
);
EXPORT_SYMBOL_GPL
(
cpci_hp_register_bus
);
EXPORT_SYMBOL_GPL
(
cpci_hp_unregister_bus
);
EXPORT_SYMBOL_GPL
(
cpci_hp_unregister_bus
);
EXPORT_SYMBOL_GPL
(
cpci_find_slot
);
EXPORT_SYMBOL_GPL
(
cpci_hp_start
);
EXPORT_SYMBOL_GPL
(
cpci_hp_start
);
EXPORT_SYMBOL_GPL
(
cpci_hp_stop
);
EXPORT_SYMBOL_GPL
(
cpci_hp_stop
);
drivers/pci/hotplug/cpci_hotplug_pci.c
View file @
b924062a
...
@@ -461,8 +461,8 @@ static int configure_visit_pci_dev(struct pci_dev_wrapped *wrapped_dev,
...
@@ -461,8 +461,8 @@ static int configure_visit_pci_dev(struct pci_dev_wrapped *wrapped_dev,
* We need to fix up the hotplug representation with the Linux
* We need to fix up the hotplug representation with the Linux
* representation.
* representation.
*/
*/
slot
=
cpci_find_slot
(
dev
->
bus
,
dev
->
devfn
);
if
(
wrapped_dev
->
data
)
{
if
(
slot
)
{
slot
=
(
struct
slot
*
)
wrapped_dev
->
data
;
slot
->
dev
=
dev
;
slot
->
dev
=
dev
;
}
}
...
@@ -494,9 +494,7 @@ static int unconfigure_visit_pci_dev_phase2(struct pci_dev_wrapped *wrapped_dev,
...
@@ -494,9 +494,7 @@ static int unconfigure_visit_pci_dev_phase2(struct pci_dev_wrapped *wrapped_dev,
return
-
ENODEV
;
return
-
ENODEV
;
/* Remove the Linux representation */
/* Remove the Linux representation */
if
(
pci_remove_device_safe
(
dev
)
==
0
)
{
if
(
pci_remove_device_safe
(
dev
))
{
kfree
(
dev
);
}
else
{
err
(
"Could not remove device
\n
"
);
err
(
"Could not remove device
\n
"
);
return
-
1
;
return
-
1
;
}
}
...
@@ -504,8 +502,8 @@ static int unconfigure_visit_pci_dev_phase2(struct pci_dev_wrapped *wrapped_dev,
...
@@ -504,8 +502,8 @@ static int unconfigure_visit_pci_dev_phase2(struct pci_dev_wrapped *wrapped_dev,
/*
/*
* Now remove the hotplug representation.
* Now remove the hotplug representation.
*/
*/
slot
=
cpci_find_slot
(
dev
->
bus
,
dev
->
devfn
);
if
(
wrapped_dev
->
data
)
{
if
(
slot
)
{
slot
=
(
struct
slot
*
)
wrapped_dev
->
data
;
slot
->
dev
=
NULL
;
slot
->
dev
=
NULL
;
}
else
{
}
else
{
dbg
(
"No hotplug representation for %02x:%02x.%x"
,
dbg
(
"No hotplug representation for %02x:%02x.%x"
,
...
@@ -574,13 +572,18 @@ int cpci_configure_slot(struct slot* slot)
...
@@ -574,13 +572,18 @@ int cpci_configure_slot(struct slot* slot)
/* Still NULL? Well then scan for it! */
/* Still NULL? Well then scan for it! */
if
(
slot
->
dev
==
NULL
)
{
if
(
slot
->
dev
==
NULL
)
{
int
n
;
dbg
(
"pci_dev still null"
);
dbg
(
"pci_dev still null"
);
/*
/*
* This will generate pci_dev structures for all functions, but
* This will generate pci_dev structures for all functions, but
* we will only call this case when lookup fails.
* we will only call this case when lookup fails.
*/
*/
slot
->
dev
=
pci_scan_slot
(
slot
->
bus
,
slot
->
devfn
);
n
=
pci_scan_slot
(
slot
->
bus
,
slot
->
devfn
);
dbg
(
"%s: pci_scan_slot returned %d"
,
__FUNCTION__
,
n
);
if
(
n
>
0
)
pci_bus_add_devices
(
slot
->
bus
);
slot
->
dev
=
pci_find_slot
(
slot
->
bus
->
number
,
slot
->
devfn
);
if
(
slot
->
dev
==
NULL
)
{
if
(
slot
->
dev
==
NULL
)
{
err
(
"Could not find PCI device for slot %02x"
,
slot
->
number
);
err
(
"Could not find PCI device for slot %02x"
,
slot
->
number
);
return
0
;
return
0
;
...
@@ -603,6 +606,10 @@ int cpci_configure_slot(struct slot* slot)
...
@@ -603,6 +606,10 @@ int cpci_configure_slot(struct slot* slot)
continue
;
continue
;
wrapped_dev
.
dev
=
dev
;
wrapped_dev
.
dev
=
dev
;
wrapped_bus
.
bus
=
slot
->
dev
->
bus
;
wrapped_bus
.
bus
=
slot
->
dev
->
bus
;
if
(
i
)
wrapped_dev
.
data
=
NULL
;
else
wrapped_dev
.
data
=
(
void
*
)
slot
;
rc
=
pci_visit_dev
(
&
configure_functions
,
&
wrapped_dev
,
&
wrapped_bus
);
rc
=
pci_visit_dev
(
&
configure_functions
,
&
wrapped_dev
,
&
wrapped_bus
);
}
}
}
}
...
@@ -635,9 +642,14 @@ int cpci_unconfigure_slot(struct slot* slot)
...
@@ -635,9 +642,14 @@ int cpci_unconfigure_slot(struct slot* slot)
if
(
dev
)
{
if
(
dev
)
{
wrapped_dev
.
dev
=
dev
;
wrapped_dev
.
dev
=
dev
;
wrapped_bus
.
bus
=
dev
->
bus
;
wrapped_bus
.
bus
=
dev
->
bus
;
if
(
i
)
wrapped_dev
.
data
=
NULL
;
else
wrapped_dev
.
data
=
(
void
*
)
slot
;
dbg
(
"%s - unconfigure phase 2"
,
__FUNCTION__
);
dbg
(
"%s - unconfigure phase 2"
,
__FUNCTION__
);
rc
=
pci_visit_dev
(
&
unconfigure_functions_phase2
,
rc
=
pci_visit_dev
(
&
unconfigure_functions_phase2
,
&
wrapped_dev
,
&
wrapped_bus
);
&
wrapped_dev
,
&
wrapped_bus
);
if
(
rc
)
if
(
rc
)
break
;
break
;
}
}
...
...
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