Add interface revision field to pci_register_lkm parameter list.pci.c pcibus.h
This parameter is intended to allow new kernels to work with old LKM binaries, provided the revision ID is incremented whenever the PCI LKM interface is changed. The revision ID does not at all protect against changes in data structures accesses by the driver.
This commit is contained in:
parent
f2071a9cf6
commit
cfc23ad40c
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=22260
@ -953,10 +953,14 @@ static void pci_rescan()
|
||||
**========================================================
|
||||
*/
|
||||
|
||||
int pci_register_lkm (struct pci_device *dvp)
|
||||
int pci_register_lkm (struct pci_device *dvp, int if_revision)
|
||||
{
|
||||
struct pci_lkm *lkm;
|
||||
|
||||
if (if_version != 0) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (!dvp || !dvp->pd_probe || !dvp->pd_attach) {
|
||||
return -1;
|
||||
}
|
||||
|
@ -953,10 +953,14 @@ static void pci_rescan()
|
||||
**========================================================
|
||||
*/
|
||||
|
||||
int pci_register_lkm (struct pci_device *dvp)
|
||||
int pci_register_lkm (struct pci_device *dvp, int if_revision)
|
||||
{
|
||||
struct pci_lkm *lkm;
|
||||
|
||||
if (if_version != 0) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (!dvp || !dvp->pd_probe || !dvp->pd_attach) {
|
||||
return -1;
|
||||
}
|
||||
|
@ -94,6 +94,6 @@ struct pcibus {
|
||||
|
||||
extern struct linker_set pcibus_set;
|
||||
|
||||
int pci_register_lkm (struct pci_device *dvp);
|
||||
int pci_register_lkm (struct pci_device *dvp, int if_revision);
|
||||
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user