This macro is used by some media drivers and was added to the kernel in commit 95c0fd457. Signed-off-by: Hauke Mehrtens <hauke@xxxxxxxxxx> --- backport/backport-include/linux/pnp.h | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 backport/backport-include/linux/pnp.h diff --git a/backport/backport-include/linux/pnp.h b/backport/backport-include/linux/pnp.h new file mode 100644 index 0000000..0a88455 --- /dev/null +++ b/backport/backport-include/linux/pnp.h @@ -0,0 +1,19 @@ +#ifndef __BACKPORT_LINUX_PNP_H +#define __BACKPORT_LINUX_PNP_H +#include_next <linux/pnp.h> + +#ifndef module_pnp_driver +/** + * module_pnp_driver() - Helper macro for registering a PnP driver + * @__pnp_driver: pnp_driver struct + * + * Helper macro for PnP drivers which do not do anything special in module + * init/exit. This eliminates a lot of boilerplate. Each module may only + * use this macro once, and calling it replaces module_init() and module_exit() + */ +#define module_pnp_driver(__pnp_driver) \ + module_driver(__pnp_driver, pnp_register_driver, \ + pnp_unregister_driver) +#endif + +#endif /* __BACKPORT_LINUX_PNP_H */ -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe backports" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html