diff options
author | Bjorn Helgaas <bjorn.helgaas@hp.com> | 2008-06-27 18:57:01 -0400 |
---|---|---|
committer | Andi Kleen <andi@basil.nowhere.org> | 2008-07-16 17:27:06 -0400 |
commit | 57fd51a8be26921b56747ddd09d1d9e01c11c9e0 (patch) | |
tree | 8b34c3d57867a217cfabf09a73a1af19242bdc7b /include/linux | |
parent | f61ed7e32d2d6a0a8c3c101da513ccedd542e14d (diff) |
PNP: add pnp_possible_config() -- can a device could be configured this way?
As part of a heuristic to identify modem devices, 8250_pnp.c
checks to see whether a device can be configured at any of the
legacy COM port addresses.
This patch moves the code that traverses the PNP "possible resource
options" from 8250_pnp.c to the PNP subsystem. This encapsulation
is important because a future patch will change the implementation
of those resource options.
Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Signed-off-by: Andi Kleen <ak@linux.intel.com>
Acked-by: Rene Herman <rene.herman@gmail.com>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/pnp.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/pnp.h b/include/linux/pnp.h index dfaa567e04a8..e033e1b14c27 100644 --- a/include/linux/pnp.h +++ b/include/linux/pnp.h | |||
@@ -479,6 +479,8 @@ void pnp_unregister_card_driver(struct pnp_card_driver *drv); | |||
479 | extern struct list_head pnp_cards; | 479 | extern struct list_head pnp_cards; |
480 | 480 | ||
481 | /* resource management */ | 481 | /* resource management */ |
482 | int pnp_possible_config(struct pnp_dev *dev, int type, resource_size_t base, | ||
483 | resource_size_t size); | ||
482 | int pnp_auto_config_dev(struct pnp_dev *dev); | 484 | int pnp_auto_config_dev(struct pnp_dev *dev); |
483 | int pnp_start_dev(struct pnp_dev *dev); | 485 | int pnp_start_dev(struct pnp_dev *dev); |
484 | int pnp_stop_dev(struct pnp_dev *dev); | 486 | int pnp_stop_dev(struct pnp_dev *dev); |
@@ -506,6 +508,9 @@ static inline int pnp_register_card_driver(struct pnp_card_driver *drv) { return | |||
506 | static inline void pnp_unregister_card_driver(struct pnp_card_driver *drv) { } | 508 | static inline void pnp_unregister_card_driver(struct pnp_card_driver *drv) { } |
507 | 509 | ||
508 | /* resource management */ | 510 | /* resource management */ |
511 | static inline int pnp_possible_config(struct pnp_dev *dev, int type, | ||
512 | resource_size_t base, | ||
513 | resource_size_t size) { return 0; } | ||
509 | static inline int pnp_auto_config_dev(struct pnp_dev *dev) { return -ENODEV; } | 514 | static inline int pnp_auto_config_dev(struct pnp_dev *dev) { return -ENODEV; } |
510 | static inline int pnp_start_dev(struct pnp_dev *dev) { return -ENODEV; } | 515 | static inline int pnp_start_dev(struct pnp_dev *dev) { return -ENODEV; } |
511 | static inline int pnp_stop_dev(struct pnp_dev *dev) { return -ENODEV; } | 516 | static inline int pnp_stop_dev(struct pnp_dev *dev) { return -ENODEV; } |