[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-id: <000001ce42f2$96128cc0$c237a640$@samsung.com>
Date: Sat, 27 Apr 2013 11:54:50 +0900
From: Jingoo Han <jg1.han@...sung.com>
To: 'Andrew Morton' <akpm@...ux-foundation.org>
Cc: linux-kernel@...r.kernel.org, 'Len Brown' <len.brown@...el.com>,
'Pavel Machek' <pavel@....cz>,
"'Rafael J. Wysocki'" <rjw@...k.pl>, linux-pm@...r.kernel.org,
Jingoo Han <jg1.han@...sung.com>
Subject: [PATCH] PM: Add pm_ops_ptr() macro
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@...sung.com>
---
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 {
--
1.7.2.5
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists