Skip to content

Commit 1692b27

Browse files
Bjorn Helgaaslenb
authored andcommitted
PNP: make pnp_add_id() internal to PNP core
pnp_add_id() doesn't need to be exposed outside the PNP core, so move the declaration to an internal header file. Signed-off-by: Bjorn Helgaas <[email protected]> Acked-By: Rene Herman <[email protected]> Signed-off-by: Len Brown <[email protected]>
1 parent 4a49049 commit 1692b27

File tree

4 files changed

+3
-2
lines changed

4 files changed

+3
-2
lines changed

drivers/pnp/base.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
extern spinlock_t pnp_lock;
22
void *pnp_alloc(long size);
3+
int pnp_add_id(struct pnp_id *id, struct pnp_dev *dev);
34
int pnp_interface_attach_device(struct pnp_dev *dev);
45
void pnp_fixup_device(struct pnp_dev *dev);
56
void pnp_free_option(struct pnp_option *option);

drivers/pnp/pnpacpi/core.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
#include <acpi/acpi_bus.h>
2626
#include <acpi/actypes.h>
2727

28+
#include "../base.h"
2829
#include "pnpacpi.h"
2930

3031
static int num = 0;

drivers/pnp/pnpbios/core.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@
6969
#include <asm/system.h>
7070
#include <asm/byteorder.h>
7171

72+
#include "../base.h"
7273
#include "pnpbios.h"
7374

7475
/*

include/linux/pnp.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,6 @@ void pnp_resource_change(struct resource *resource, resource_size_t start,
403403
/* protocol helpers */
404404
int pnp_is_active(struct pnp_dev *dev);
405405
int compare_pnp_id(struct pnp_id *pos, const char *id);
406-
int pnp_add_id(struct pnp_id *id, struct pnp_dev *dev);
407406
int pnp_register_driver(struct pnp_driver *drv);
408407
void pnp_unregister_driver(struct pnp_driver *drv);
409408

@@ -450,7 +449,6 @@ static inline void pnp_resource_change(struct resource *resource, resource_size_
450449
/* protocol helpers */
451450
static inline int pnp_is_active(struct pnp_dev *dev) { return 0; }
452451
static inline int compare_pnp_id(struct pnp_id *pos, const char *id) { return -ENODEV; }
453-
static inline int pnp_add_id(struct pnp_id *id, struct pnp_dev *dev) { return -ENODEV; }
454452
static inline int pnp_register_driver(struct pnp_driver *drv) { return -ENODEV; }
455453
static inline void pnp_unregister_driver(struct pnp_driver *drv) { }
456454

0 commit comments

Comments
 (0)