diff options
author | Rene Herman <rene.herman@keyaccess.nl> | 2008-05-14 19:05:34 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-05-14 22:11:13 -0400 |
commit | bc033c9b5fd261855278f4ed82c3713cc549afbe (patch) | |
tree | 04bc4aef7c213e409780206be229ecc903e48b70 /drivers/pnp | |
parent | 726a7a3d17f183bd0f93daff4d56953c6af78c57 (diff) |
pnp: add pnp_build_option() to the API
The subsequent AD181x quirk patch would like this as part of the API.
pnp_register_dependent_option() adds to the same dependent chain the quirk is
walking which is fairly unclean. This enables a private option chain build
which it can then just add onto the end when done.
Signed-off-by: Rene Herman <rene.herman@gmail.com>
Tested-by: Uwe Bugla <uwe.bugla@gmx.de>
Acked-by: Uwe Bugla <uwe.bugla@gmx.de>
Acked-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Takashi Iwai <tiwai@suse.de>
Cc: Len Brown <len.brown@intel.com
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/pnp')
-rw-r--r-- | drivers/pnp/base.h | 1 | ||||
-rw-r--r-- | drivers/pnp/resource.c | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/drivers/pnp/base.h b/drivers/pnp/base.h index 4fe7c58f57e9..886dac823ed6 100644 --- a/drivers/pnp/base.h +++ b/drivers/pnp/base.h | |||
@@ -19,6 +19,7 @@ void pnp_remove_card(struct pnp_card *card); | |||
19 | int pnp_add_card_device(struct pnp_card *card, struct pnp_dev *dev); | 19 | int pnp_add_card_device(struct pnp_card *card, struct pnp_dev *dev); |
20 | void pnp_remove_card_device(struct pnp_dev *dev); | 20 | void pnp_remove_card_device(struct pnp_dev *dev); |
21 | 21 | ||
22 | struct pnp_option *pnp_build_option(int priority); | ||
22 | struct pnp_option *pnp_register_independent_option(struct pnp_dev *dev); | 23 | struct pnp_option *pnp_register_independent_option(struct pnp_dev *dev); |
23 | struct pnp_option *pnp_register_dependent_option(struct pnp_dev *dev, | 24 | struct pnp_option *pnp_register_dependent_option(struct pnp_dev *dev, |
24 | int priority); | 25 | int priority); |
diff --git a/drivers/pnp/resource.c b/drivers/pnp/resource.c index 2041620d5682..390b50096e30 100644 --- a/drivers/pnp/resource.c +++ b/drivers/pnp/resource.c | |||
@@ -28,7 +28,7 @@ static int pnp_reserve_mem[16] = {[0 ... 15] = -1 }; /* reserve (don't use) some | |||
28 | * option registration | 28 | * option registration |
29 | */ | 29 | */ |
30 | 30 | ||
31 | static struct pnp_option *pnp_build_option(int priority) | 31 | struct pnp_option *pnp_build_option(int priority) |
32 | { | 32 | { |
33 | struct pnp_option *option = pnp_alloc(sizeof(struct pnp_option)); | 33 | struct pnp_option *option = pnp_alloc(sizeof(struct pnp_option)); |
34 | 34 | ||