From: Torin Carey <torin@tcarey.uk>
To: Hao Lee <haolee.swjtu@gmail.com>
Cc: akpm@linux-foundation.org, christian.brauner@ubuntu.com,
keescook@chromium.org, adobriyan@gmail.com,
jamorris@linux.microsoft.com, linux-fsdevel@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] proc: use kmalloc instead of __get_free_page() to alloc path buffer
Date: Tue, 25 Jan 2022 14:03:16 +0000 [thread overview]
Message-ID: <YfADJHY7Fy8S9Tl4@kappa> (raw)
In-Reply-To: <20220123100837.GA1491@haolee.io>
On Sun, Jan 23, 2022 at 10:08:37AM +0000, Hao Lee wrote:
> It's not a standard approach that use __get_free_page() to alloc path
> buffer directly. We'd better use kmalloc and PATH_MAX.
If we're allocating PATH_MAX sized buffers for names, wouldn't it be
suitable to use the name slab names_cachep declared in
include/linux/fs.h using __getname() and __putname()?
Best,
Torin
prev parent reply other threads:[~2022-01-25 14:14 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-23 10:08 [PATCH] proc: use kmalloc instead of __get_free_page() to alloc path buffer Hao Lee
2022-01-23 13:55 ` Alexey Dobriyan
2022-01-23 13:58 ` [PATCH v2] proc: alloc PATH_MAX bytes for /proc/${pid}/fd/ symlinks Alexey Dobriyan
2022-01-23 14:23 ` Hao Lee
2022-01-25 14:03 ` Torin Carey [this message]
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=YfADJHY7Fy8S9Tl4@kappa \
--to=torin@tcarey.uk \
--cc=adobriyan@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=christian.brauner@ubuntu.com \
--cc=haolee.swjtu@gmail.com \
--cc=jamorris@linux.microsoft.com \
--cc=keescook@chromium.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.