From: Tejun Heo <tj@kernel.org>
To: Dennis Chen <xschen@tnsoft.com.cn>
Cc: linux-kernel@vger.kernel.org, gregkh@linuxfoundation.org,
xiyou.wangcong@gmail.com
Subject: Re: [PATCH] race condition fixing in sysfs_create_dir
Date: Fri, 26 Jul 2013 09:41:50 -0400 [thread overview]
Message-ID: <20130726134150.GE3013@htj.dyndns.org> (raw)
In-Reply-To: <20130726133856.GD3013@htj.dyndns.org>
On Fri, Jul 26, 2013 at 09:38:56AM -0400, Tejun Heo wrote:
> I don't think sysfs is supposed to handle multiple actors trying to
> populate and destroy the directory at the same time at all, so this
e.g. kobj->sd assignment in sysfs_create_dir() isn't synchronized and
doesn't have memory barrier either. Nothing prevents subdirectory
creation from accessing half-initialized sysfs_dirent on architectures
which require read dependency barriers. The caller is responsible for
synchronizing these operations.
Thanks.
--
tejun
next prev parent reply other threads:[~2013-07-26 13:41 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-26 9:49 Dennis Chen
2013-07-26 9:59 ` Dennis Chen
2013-07-26 13:38 ` Tejun Heo
2013-07-26 13:41 ` Tejun Heo [this message]
2013-07-30 6:34 ` Dennis Chen
2013-07-30 14:10 ` Tejun Heo
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=20130726134150.GE3013@htj.dyndns.org \
--to=tj@kernel.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=xiyou.wangcong@gmail.com \
--cc=xschen@tnsoft.com.cn \
/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