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
36be8435
Commit
36be8435
authored
Oct 03, 2002
by
Greg Kroah-Hartman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
PCI: removed pcibios_present()
parent
4a66ae82
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
15 additions
and
24 deletions
+15
-24
drivers/net/hp100.c
drivers/net/hp100.c
+2
-2
drivers/net/tulip/de4x5.c
drivers/net/tulip/de4x5.c
+2
-2
drivers/pci/compat.c
drivers/pci/compat.c
+0
-8
drivers/pci/syscall.c
drivers/pci/syscall.c
+1
-1
include/linux/pci.h
include/linux/pci.h
+10
-11
No files found.
drivers/net/hp100.c
View file @
36be8435
...
@@ -412,7 +412,7 @@ int __init hp100_probe(struct net_device *dev)
...
@@ -412,7 +412,7 @@ int __init hp100_probe(struct net_device *dev)
/* First: scan PCI bus(es) */
/* First: scan PCI bus(es) */
#ifdef CONFIG_PCI
#ifdef CONFIG_PCI
if
(
pci
bios
_present
())
{
if
(
pci_present
())
{
int
pci_index
;
int
pci_index
;
struct
pci_dev
*
pci_dev
=
NULL
;
struct
pci_dev
*
pci_dev
=
NULL
;
int
pci_id_index
;
int
pci_id_index
;
...
@@ -2960,7 +2960,7 @@ static int __init hp100_module_init(void)
...
@@ -2960,7 +2960,7 @@ static int __init hp100_module_init(void)
{
{
int
i
,
cards
;
int
i
,
cards
;
if
(
hp100_port
==
0
&&
!
EISA_bus
&&
!
pci
bios
_present
())
if
(
hp100_port
==
0
&&
!
EISA_bus
&&
!
pci_present
())
printk
(
"hp100: You should not use auto-probing with insmod!
\n
"
);
printk
(
"hp100: You should not use auto-probing with insmod!
\n
"
);
/* Loop on all possible base addresses */
/* Loop on all possible base addresses */
...
...
drivers/net/tulip/de4x5.c
View file @
36be8435
...
@@ -2190,7 +2190,7 @@ pci_probe(struct net_device *dev, u_long ioaddr)
...
@@ -2190,7 +2190,7 @@ pci_probe(struct net_device *dev, u_long ioaddr)
if
(
lastPCI
==
NO_MORE_PCI
)
return
;
if
(
lastPCI
==
NO_MORE_PCI
)
return
;
if
(
!
pci
bios
_present
())
{
if
(
!
pci_present
())
{
lastPCI
=
NO_MORE_PCI
;
lastPCI
=
NO_MORE_PCI
;
return
;
/* No PCI bus in this machine! */
return
;
/* No PCI bus in this machine! */
}
}
...
@@ -5872,7 +5872,7 @@ count_adapters(void)
...
@@ -5872,7 +5872,7 @@ count_adapters(void)
if
(
EISA_signature
(
name
,
EISA_ID
))
j
++
;
if
(
EISA_signature
(
name
,
EISA_ID
))
j
++
;
}
}
#endif
#endif
if
(
!
pci
bios
_present
())
return
j
;
if
(
!
pci_present
())
return
j
;
for
(
i
=
0
;
(
pdev
=
pci_find_class
(
class
,
pdev
))
!=
NULL
;
i
++
)
{
for
(
i
=
0
;
(
pdev
=
pci_find_class
(
class
,
pdev
))
!=
NULL
;
i
++
)
{
vendor
=
pdev
->
vendor
;
vendor
=
pdev
->
vendor
;
...
...
drivers/pci/compat.c
View file @
36be8435
...
@@ -13,12 +13,6 @@
...
@@ -13,12 +13,6 @@
/* Obsolete functions, these will be going away... */
/* Obsolete functions, these will be going away... */
int
pcibios_present
(
void
)
{
return
!
list_empty
(
&
pci_devices
);
}
#define PCI_OP(rw,size,type) \
#define PCI_OP(rw,size,type) \
int pcibios_##rw##_config_##size (unsigned char bus, unsigned char dev_fn, \
int pcibios_##rw##_config_##size (unsigned char bus, unsigned char dev_fn, \
unsigned char where, unsigned type val) \
unsigned char where, unsigned type val) \
...
@@ -35,8 +29,6 @@ PCI_OP(write, byte, char)
...
@@ -35,8 +29,6 @@ PCI_OP(write, byte, char)
PCI_OP
(
write
,
word
,
short
)
PCI_OP
(
write
,
word
,
short
)
PCI_OP
(
write
,
dword
,
int
)
PCI_OP
(
write
,
dword
,
int
)
EXPORT_SYMBOL
(
pcibios_present
);
EXPORT_SYMBOL
(
pcibios_read_config_byte
);
EXPORT_SYMBOL
(
pcibios_read_config_byte
);
EXPORT_SYMBOL
(
pcibios_read_config_word
);
EXPORT_SYMBOL
(
pcibios_read_config_word
);
EXPORT_SYMBOL
(
pcibios_read_config_dword
);
EXPORT_SYMBOL
(
pcibios_read_config_dword
);
...
...
drivers/pci/syscall.c
View file @
36be8435
...
@@ -98,7 +98,7 @@ sys_pciconfig_write(unsigned long bus, unsigned long dfn,
...
@@ -98,7 +98,7 @@ sys_pciconfig_write(unsigned long bus, unsigned long dfn,
if
(
!
capable
(
CAP_SYS_ADMIN
))
if
(
!
capable
(
CAP_SYS_ADMIN
))
return
-
EPERM
;
return
-
EPERM
;
if
(
!
pci
bios
_present
())
if
(
!
pci_present
())
return
-
ENOSYS
;
return
-
ENOSYS
;
dev
=
pci_find_slot
(
bus
,
dfn
);
dev
=
pci_find_slot
(
bus
,
dfn
);
...
...
include/linux/pci.h
View file @
36be8435
...
@@ -322,15 +322,6 @@ enum pci_mmap_state {
...
@@ -322,15 +322,6 @@ enum pci_mmap_state {
#define PCI_ANY_ID (~0)
#define PCI_ANY_ID (~0)
#define pci_present pcibios_present
#define pci_for_each_dev_reverse(dev) \
for(dev = pci_dev_g(pci_devices.prev); dev != pci_dev_g(&pci_devices); dev = pci_dev_g(dev->global_list.prev))
#define pci_for_each_bus(bus) \
for(bus = pci_bus_b(pci_root_buses.next); bus != pci_bus_b(&pci_root_buses); bus = pci_bus_b(bus->node.next))
/*
/*
* The pci_dev structure is used to describe both PCI and ISAPnP devices.
* The pci_dev structure is used to describe both PCI and ISAPnP devices.
*/
*/
...
@@ -503,8 +494,17 @@ struct pci_driver {
...
@@ -503,8 +494,17 @@ struct pci_driver {
/* these external functions are only available when PCI support is enabled */
/* these external functions are only available when PCI support is enabled */
#ifdef CONFIG_PCI
#ifdef CONFIG_PCI
static
inline
int
pci_present
(
void
)
{
return
!
list_empty
(
&
pci_devices
);
}
#define pci_for_each_dev(dev) \
#define pci_for_each_dev(dev) \
for(dev = pci_dev_g(pci_devices.next); dev != pci_dev_g(&pci_devices); dev = pci_dev_g(dev->global_list.next))
for(dev = pci_dev_g(pci_devices.next); dev != pci_dev_g(&pci_devices); dev = pci_dev_g(dev->global_list.next))
#define pci_for_each_dev_reverse(dev) \
for(dev = pci_dev_g(pci_devices.prev); dev != pci_dev_g(&pci_devices); dev = pci_dev_g(dev->global_list.prev))
#define pci_for_each_bus(bus) \
for(bus = pci_bus_b(pci_root_buses.next); bus != pci_bus_b(&pci_root_buses); bus = pci_bus_b(bus->node.next))
void
pcibios_fixup_bus
(
struct
pci_bus
*
);
void
pcibios_fixup_bus
(
struct
pci_bus
*
);
int
pcibios_enable_device
(
struct
pci_dev
*
,
int
mask
);
int
pcibios_enable_device
(
struct
pci_dev
*
,
int
mask
);
...
@@ -520,7 +520,6 @@ void pcibios_fixup_pbus_ranges(struct pci_bus *, struct pbus_set_ranges_data *);
...
@@ -520,7 +520,6 @@ void pcibios_fixup_pbus_ranges(struct pci_bus *, struct pbus_set_ranges_data *);
/* Backward compatibility, don't use in new code! */
/* Backward compatibility, don't use in new code! */
int
pcibios_present
(
void
);
int
pcibios_read_config_byte
(
unsigned
char
bus
,
unsigned
char
dev_fn
,
int
pcibios_read_config_byte
(
unsigned
char
bus
,
unsigned
char
dev_fn
,
unsigned
char
where
,
unsigned
char
*
val
);
unsigned
char
where
,
unsigned
char
*
val
);
int
pcibios_read_config_word
(
unsigned
char
bus
,
unsigned
char
dev_fn
,
int
pcibios_read_config_word
(
unsigned
char
bus
,
unsigned
char
dev_fn
,
...
@@ -656,7 +655,7 @@ void pci_pool_free (struct pci_pool *pool, void *vaddr, dma_addr_t addr);
...
@@ -656,7 +655,7 @@ void pci_pool_free (struct pci_pool *pool, void *vaddr, dma_addr_t addr);
*/
*/
#ifndef CONFIG_PCI
#ifndef CONFIG_PCI
static
inline
int
pci
bios
_present
(
void
)
{
return
0
;
}
static
inline
int
pci_present
(
void
)
{
return
0
;
}
#define _PCI_NOP(o,s,t) \
#define _PCI_NOP(o,s,t) \
static inline int pcibios_##o##_config_##s (u8 bus, u8 dfn, u8 where, t val) \
static inline int pcibios_##o##_config_##s (u8 bus, u8 dfn, u8 where, t val) \
...
...
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