From: Leo Yan <leo.yan@linaro.org>
To: Shuai Xue <xueshuai@linux.alibaba.com>
Cc: James Clark <james.clark@arm.com>,
Peter Zijlstra <peterz@infradead.org>,
alexander.shishkin@linux.intel.com, mingo@redhat.com,
baolin.wang@linux.alibaba.com, acme@kernel.org,
mark.rutland@arm.com, jolsa@kernel.org, namhyung@kernel.org,
irogers@google.com, adrian.hunter@intel.com,
linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org,
nathan@kernel.org, bpf@vger.kernel.org
Subject: Re: [PATCH v4 1/2] perf/core: Bail out early if the request AUX area is out of bound
Date: Wed, 6 Sep 2023 15:02:38 +0800 [thread overview]
Message-ID: <20230906070238.GC388456@leoy-huanghe.lan> (raw)
In-Reply-To: <bad0d23d-a66e-0558-469b-a2dd1d5eb497@linux.alibaba.com>
Hi Shuai,
On Wed, Sep 06, 2023 at 11:27:38AM +0800, Shuai Xue wrote:
[...]
> >>> + /* Can't allocate more than MAX_ORDER */
> >>
> >> The comment is confused. I'd like to refine it as:
> >>
> >> /*
> >> * kcalloc_node() is unable to allocate buffer if the size is larger
> >> * than: PAGE_SIZE << MAX_ORDER; directly bail out in this case.
> >> */
> >
> > Hi, Leo,
> >
> > Thank you for your quick feedback. The comment is simplified from Peter's reply in v2
> > version. Your refined comment is more detailed and it makes sense to me, I would like
> > to adopt it if @Peter has no other opinions.
> >
> >> To be honest, I am not sure if perf core maintainers like this kind
> >> thing or not. Please seek their opinion before you move forward.
> >>
> >
> > and hi, all perf core maintainers,
> >
> > I have not received explicit objection from perf core maintainers @Peter or @James so
> > I moved forward to address their comments. It's fine to me to wait for more opinions from
> > perf core maintainers.
> >
> > Best Regards,
> > Shuai
> >
>
> Hi, Leo, and all folks,
>
> Any more comments? Should I move forward to send a new patch?
I am afraid I cannot give a reliable suggestion.
Anyway, I personally think the returned error value in this patch is
better than the kernel oops since the kernel oops is a bit scary for
tool's users ;) Another reason is the perf core layer should report
error earlier rather than relying on the page buddy allocation layer
to detect the memory allocation failure, which is easier for both
developers and users to understand the failure.
IMHO, a good practice is to respin a new patch set and send out for
review. Good luck!
Thanks,
Leo
next prev parent reply other threads:[~2023-09-06 7:02 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-04 7:29 [PATCH v4 0/2] " Shuai Xue
2023-08-04 7:29 ` [PATCH v4 1/2] " Shuai Xue
2023-08-04 8:59 ` Leo Yan
2023-08-04 11:24 ` Shuai Xue
2023-09-06 3:27 ` Shuai Xue
2023-09-06 7:02 ` Leo Yan [this message]
2023-09-06 7:07 ` Shuai Xue
2023-08-04 7:29 ` [PATCH v4 2/2] perf record: Update docs regarding the maximum limitation of AUX area Shuai Xue
2023-08-04 8:46 ` Leo Yan
2023-08-04 11:47 ` Shuai Xue
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=20230906070238.GC388456@leoy-huanghe.lan \
--to=leo.yan@linaro.org \
--cc=acme@kernel.org \
--cc=adrian.hunter@intel.com \
--cc=alexander.shishkin@linux.intel.com \
--cc=baolin.wang@linux.alibaba.com \
--cc=bpf@vger.kernel.org \
--cc=irogers@google.com \
--cc=james.clark@arm.com \
--cc=jolsa@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=nathan@kernel.org \
--cc=peterz@infradead.org \
--cc=xueshuai@linux.alibaba.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
all inboxes | Powered by JetHome®