From: "Hillf Danton" <hillf.zj@alibaba-inc.com>
To: "'Wang Nan'" <wangnan0@huawei.com>
Cc: <linux@arm.linux.org.uk>, "'Ingo Molnar'" <mingo@redhat.com>,
<masami.hiramatsu.pt@hitachi.com>,
<anil.s.keshavamurthy@intel.com>, <davem@davemloft.net>,
<ananth@in.ibm.com>, <dave.long@linaro.org>, <tixy@linaro.org>,
<lizefan@huawei.com>,
"'linux-kernel'" <linux-kernel@vger.kernel.org>
Subject: RE: [RFC PATCH 09/11] kprobes: core logic of eraly kprobes
Date: Thu, 08 Jan 2015 10:32:14 +0800 [thread overview]
Message-ID: <04d401d02aeb$50c519c0$f24f4d40$@alibaba-inc.com> (raw)
In-Reply-To: <54AD0B98.5050103@huawei.com>
>
> This macro defines an array and a bitmap, not only declare them. In addition,
> the functions defined by it are used only in this specific .c file.
>
> If there are not only one .c files use it, I think patch 7 can be improved:
>
> #define DEFINE_EKPROBE_AREA(__t, __static) \
> __static __t __ek_##__name##_slots[NR_EARLY_KPROBES_SLOTS]; \
> __static unsigned long __ek_##__name##_bitmap[EARLY_KPROBES_BITMAP_SZ];
>
> #define DEFINE_EKPROBE_ALLOC_OPS(__t, __name, __static) \
> DEFINE_EKPROBE_AREA(__t, __static) \
> __DEFINE_EKPROBE_ALLOC_OPS(__t, __name) \
> static inline __t *ek_alloc_##__name(void) \
> { \
> ...
>
> In .h file(s):
> DEFINE_EKPROBE_ALLOC_OPS(struct early_kprobe_slot, early_kprobe, extern)
>
> In .c file:
> DEFINE_EKPROBE_AREA(__t, )
>
> What do you think?
>
Looks like rocket science;-)
next prev parent reply other threads:[~2015-01-08 2:33 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-07 9:21 Hillf Danton
2015-01-07 9:43 ` Wang Nan
2015-01-07 10:02 ` Hillf Danton
2015-01-07 10:34 ` Wang Nan
2015-01-08 2:32 ` Hillf Danton [this message]
-- strict thread matches above, loose matches on Subject: below --
2015-01-07 7:34 [RFC PATCH 00/11] Early kprobe: enable kprobes at very early Wang Nan
2015-01-07 7:36 ` [RFC PATCH 09/11] kprobes: core logic of eraly kprobes Wang Nan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='04d401d02aeb$50c519c0$f24f4d40$@alibaba-inc.com' \
--to=hillf.zj@alibaba-inc.com \
--cc=ananth@in.ibm.com \
--cc=anil.s.keshavamurthy@intel.com \
--cc=dave.long@linaro.org \
--cc=davem@davemloft.net \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
--cc=lizefan@huawei.com \
--cc=masami.hiramatsu.pt@hitachi.com \
--cc=mingo@redhat.com \
--cc=tixy@linaro.org \
--cc=wangnan0@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome