From: Andrzej Pietrasiewicz <andrzej.p@samsung.com>
To: linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: Andrzej Pietrasiewicz <andrzej.p@samsung.com>,
Kyungmin Park <kyungmin.park@samsung.com>,
Felipe Balbi <balbi@ti.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Joel Becker <jlbec@evilplan.org>,
Sebastian Andrzej Siewior <bigeasy@linutronix.de>,
Marek Szyprowski <m.szyprowski@samsung.com>,
Michal Nazarewicz <mina86@mina86.com>
Subject: [RFC][PATCH] fs: configfs: allow other kernel parts to programmatically create config groups
Date: Mon, 26 Nov 2012 09:35:10 +0100 [thread overview]
Message-ID: <1353918910-12381-2-git-send-email-andrzej.p@samsung.com> (raw)
In-Reply-To: <1353918910-12381-1-git-send-email-andrzej.p@samsung.com>
Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
fs/configfs/dir.c | 5 +++--
include/linux/configfs.h | 2 ++
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/fs/configfs/dir.c b/fs/configfs/dir.c
index 7414ae2..42608dc 100644
--- a/fs/configfs/dir.c
+++ b/fs/configfs/dir.c
@@ -656,7 +656,7 @@ static void detach_groups(struct config_group *group)
* We could, perhaps, tweak our parent's ->mkdir for a minute and
* try using vfs_mkdir. Just a thought.
*/
-static int create_default_group(struct config_group *parent_group,
+int create_group(struct config_group *parent_group,
struct config_group *group)
{
int ret;
@@ -690,6 +690,7 @@ static int create_default_group(struct config_group *parent_group,
return ret;
}
+EXPORT_SYMBOL(create_group);
static int populate_groups(struct config_group *group)
{
@@ -701,7 +702,7 @@ static int populate_groups(struct config_group *group)
for (i = 0; group->default_groups[i]; i++) {
new_group = group->default_groups[i];
- ret = create_default_group(group, new_group);
+ ret = create_group(group, new_group);
if (ret) {
detach_groups(group);
break;
diff --git a/include/linux/configfs.h b/include/linux/configfs.h
index 34025df..8bf295f 100644
--- a/include/linux/configfs.h
+++ b/include/linux/configfs.h
@@ -252,6 +252,8 @@ static inline struct configfs_subsystem *to_configfs_subsystem(struct config_gro
int configfs_register_subsystem(struct configfs_subsystem *subsys);
void configfs_unregister_subsystem(struct configfs_subsystem *subsys);
+int create_group(struct config_group *parent_group, struct config_group *group);
+
/* These functions can sleep and can alloc with GFP_KERNEL */
/* WARNING: These cannot be called underneath configfs callbacks!! */
int configfs_depend_item(struct configfs_subsystem *subsys, struct config_item *target);
--
1.7.0.4
next prev parent reply other threads:[~2012-11-26 8:35 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-26 8:35 [RFC][PATCH] fs: configfs: " Andrzej Pietrasiewicz
2012-11-26 8:35 ` Andrzej Pietrasiewicz [this message]
2012-11-26 13:14 ` Michal Nazarewicz
2012-11-26 16:30 ` Sebastian Andrzej Siewior
2012-11-26 16:56 ` Michal Nazarewicz
2012-11-26 17:06 ` Sebastian Andrzej Siewior
2012-11-26 17:54 ` Michal Nazarewicz
2012-11-27 15:20 ` Sebastian Andrzej Siewior
2012-11-28 7:08 ` Nicholas A. Bellinger
2012-11-27 8:57 ` Andrzej Pietrasiewicz
2012-11-27 14:32 ` Michal Nazarewicz
2012-11-27 15:59 ` Sebastian Andrzej Siewior
2012-11-27 16:23 ` Michal Nazarewicz
2012-11-28 8:15 ` Sebastian Andrzej Siewior
2012-11-28 13:05 ` Michal Nazarewicz
2012-11-28 13:50 ` Sebastian Andrzej Siewior
2012-11-28 14:24 ` Michal Nazarewicz
2012-11-28 18:52 ` Sebastian Andrzej Siewior
2012-12-07 23:18 ` Joel Becker
2012-12-10 11:57 ` Andrzej Pietrasiewicz
2012-12-10 14:17 ` Andrzej Pietrasiewicz
2012-12-10 14:34 ` Felipe Balbi
2012-12-10 15:27 ` Andrzej Pietrasiewicz
2012-12-12 1:10 ` Joel Becker
2012-12-11 21:27 ` Joel Becker
2012-12-14 12:18 ` Sebastian Andrzej Siewior
2012-11-28 8:10 ` Andrzej Pietrasiewicz
2012-11-28 8:38 ` Sebastian Andrzej Siewior
2012-11-28 14:09 ` Andrzej Pietrasiewicz
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=1353918910-12381-2-git-send-email-andrzej.p@samsung.com \
--to=andrzej.p@samsung.com \
--cc=balbi@ti.com \
--cc=bigeasy@linutronix.de \
--cc=gregkh@linuxfoundation.org \
--cc=jlbec@evilplan.org \
--cc=kyungmin.park@samsung.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=m.szyprowski@samsung.com \
--cc=mina86@mina86.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®