* [PATCH 2/2] relay: move FIX_SIZE macro into relay.c
@ 2013-03-18 2:51 zhangwei(Jovi)
2013-03-18 20:19 ` Andrew Morton
0 siblings, 1 reply; 3+ messages in thread
From: zhangwei(Jovi) @ 2013-03-18 2:51 UTC (permalink / raw)
To: linux-kernel, Andrew Morton, Eric Dumazet
It's better to place FIX_SIZE macro in relay.c, instead of relay.h
Signed-off-by: zhangwei(Jovi) <jovi.zhangwei@huawei.com>
---
include/linux/relay.h | 3 ---
kernel/relay.c | 3 +++
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/include/linux/relay.h b/include/linux/relay.h
index 91cacc3..d7c8359 100644
--- a/include/linux/relay.h
+++ b/include/linux/relay.h
@@ -20,9 +20,6 @@
#include <linux/poll.h>
#include <linux/kref.h>
-/* Needs a _much_ better name... */
-#define FIX_SIZE(x) ((((x) - 1) & PAGE_MASK) + PAGE_SIZE)
-
/*
* Tracks changes to rchan/rchan_buf structs
*/
diff --git a/kernel/relay.c b/kernel/relay.c
index d21006c..4c2959b 100644
--- a/kernel/relay.c
+++ b/kernel/relay.c
@@ -550,6 +550,9 @@ static int __cpuinit relay_hotcpu_callback(struct notifier_block *nb,
return NOTIFY_OK;
}
+/* Needs a _much_ better name... */
+#define FIX_SIZE(x) ((((x) - 1) & PAGE_MASK) + PAGE_SIZE)
+
/**
* relay_open - create a new relay channel
* @base_filename: base name of files to create, %NULL for buffering only
--
1.7.9.7
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 2/2] relay: move FIX_SIZE macro into relay.c
2013-03-18 2:51 [PATCH 2/2] relay: move FIX_SIZE macro into relay.c zhangwei(Jovi)
@ 2013-03-18 20:19 ` Andrew Morton
2013-03-20 9:24 ` zhangwei(Jovi)
0 siblings, 1 reply; 3+ messages in thread
From: Andrew Morton @ 2013-03-18 20:19 UTC (permalink / raw)
To: zhangwei(Jovi); +Cc: linux-kernel, Eric Dumazet
On Mon, 18 Mar 2013 10:51:54 +0800 "zhangwei(Jovi)" <jovi.zhangwei@huawei.com> wrote:
> +/* Needs a _much_ better name... */
> +#define FIX_SIZE(x) ((((x) - 1) & PAGE_MASK) + PAGE_SIZE)
> +
Gad. That's the same as PAGE_ALIGN(), is it not?
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH 2/2] relay: move FIX_SIZE macro into relay.c
2013-03-18 20:19 ` Andrew Morton
@ 2013-03-20 9:24 ` zhangwei(Jovi)
0 siblings, 0 replies; 3+ messages in thread
From: zhangwei(Jovi) @ 2013-03-20 9:24 UTC (permalink / raw)
To: Andrew Morton; +Cc: linux-kernel, Eric Dumazet
On 2013/3/19 4:19, Andrew Morton wrote:
> On Mon, 18 Mar 2013 10:51:54 +0800 "zhangwei(Jovi)" <jovi.zhangwei@huawei.com> wrote:
>
>> +/* Needs a _much_ better name... */
>> +#define FIX_SIZE(x) ((((x) - 1) & PAGE_MASK) + PAGE_SIZE)
>> +
>
> Gad. That's the same as PAGE_ALIGN(), is it not?
>
Indeed, I will post another patch to change this, base on -mm.
Thanks.
.jovi
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-03-20 9:24 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-03-18 2:51 [PATCH 2/2] relay: move FIX_SIZE macro into relay.c zhangwei(Jovi)
2013-03-18 20:19 ` Andrew Morton
2013-03-20 9:24 ` zhangwei(Jovi)
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).