Commit 3cee67f7 authored by Stephen Rothwell's avatar Stephen Rothwell Committed by Benjamin Herrenschmidt

powerpc/pseries: Fix CMO sysdev attribute API change fallout

Noticed due to these wanings:

arch/powerpc/platforms/pseries/cmm.c:298: warning: initialization from incompatible pointer type
arch/powerpc/platforms/pseries/cmm.c:299: warning: initialization from incompatible pointer type
arch/powerpc/platforms/pseries/cmm.c:320: warning: initialization from incompatible pointer type
arch/powerpc/platforms/pseries/cmm.c:320: warning: initialization from incompatible pointer type
Signed-off-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
parent dec2b0d0
...@@ -289,7 +289,9 @@ static int cmm_thread(void *dummy) ...@@ -289,7 +289,9 @@ static int cmm_thread(void *dummy)
} }
#define CMM_SHOW(name, format, args...) \ #define CMM_SHOW(name, format, args...) \
static ssize_t show_##name(struct sys_device *dev, char *buf) \ static ssize_t show_##name(struct sys_device *dev, \
struct sysdev_attribute *attr, \
char *buf) \
{ \ { \
return sprintf(buf, format, ##args); \ return sprintf(buf, format, ##args); \
} \ } \
...@@ -298,12 +300,14 @@ static int cmm_thread(void *dummy) ...@@ -298,12 +300,14 @@ static int cmm_thread(void *dummy)
CMM_SHOW(loaned_kb, "%lu\n", PAGES2KB(loaned_pages)); CMM_SHOW(loaned_kb, "%lu\n", PAGES2KB(loaned_pages));
CMM_SHOW(loaned_target_kb, "%lu\n", PAGES2KB(loaned_pages_target)); CMM_SHOW(loaned_target_kb, "%lu\n", PAGES2KB(loaned_pages_target));
static ssize_t show_oom_pages(struct sys_device *dev, char *buf) static ssize_t show_oom_pages(struct sys_device *dev,
struct sysdev_attribute *attr, char *buf)
{ {
return sprintf(buf, "%lu\n", PAGES2KB(oom_freed_pages)); return sprintf(buf, "%lu\n", PAGES2KB(oom_freed_pages));
} }
static ssize_t store_oom_pages(struct sys_device *dev, static ssize_t store_oom_pages(struct sys_device *dev,
struct sysdev_attribute *attr,
const char *buf, size_t count) const char *buf, size_t count)
{ {
unsigned long val = simple_strtoul (buf, NULL, 10); unsigned long val = simple_strtoul (buf, NULL, 10);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment