diff mbox

PM: Add pm_ops_ptr() macro

Message ID 000001ce42f2$96128cc0$c237a640$@samsung.com (mailing list archive)
State Rejected, archived
Headers show

Commit Message

Jingoo Han April 27, 2013, 2:54 a.m. UTC
Add pm_ops_ptr() macro that allows the .pm entry in the driver structures
to be assigned without having an #define xxx NULL for the case that PM is
not enabled.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
---
 include/linux/pm.h |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

Comments

Rafael Wysocki April 27, 2013, 2:40 p.m. UTC | #1
On Saturday, April 27, 2013 11:54:50 AM Jingoo Han wrote:
> Add pm_ops_ptr() macro that allows the .pm entry in the driver structures
> to be assigned without having an #define xxx NULL for the case that PM is
> not enabled.
> 
> Signed-off-by: Jingoo Han <jg1.han@samsung.com>

First, I'm not taking any more PM patches for v3.10 (that don't fix recent
regressions).

Second, please add that macro along with a user.

Thanks,
Rafael


> ---
>  include/linux/pm.h |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
> 
> diff --git a/include/linux/pm.h b/include/linux/pm.h
> index a224c7f..bd50d15 100644
> --- a/include/linux/pm.h
> +++ b/include/linux/pm.h
> @@ -55,8 +55,10 @@ struct device;
>  
>  #ifdef CONFIG_PM
>  extern const char power_group_name[];		/* = "power" */
> +#define pm_ops_ptr(_ptr)	(_ptr)
>  #else
>  #define power_group_name	NULL
> +#define pm_ops_ptr(_ptr)	NULL
>  #endif
>  
>  typedef struct pm_message {
>
diff mbox

Patch

diff --git a/include/linux/pm.h b/include/linux/pm.h
index a224c7f..bd50d15 100644
--- a/include/linux/pm.h
+++ b/include/linux/pm.h
@@ -55,8 +55,10 @@  struct device;
 
 #ifdef CONFIG_PM
 extern const char power_group_name[];		/* = "power" */
+#define pm_ops_ptr(_ptr)	(_ptr)
 #else
 #define power_group_name	NULL
+#define pm_ops_ptr(_ptr)	NULL
 #endif
 
 typedef struct pm_message {