Re: [mmotm:master 212/319] fs/nilfs2/sysfs.c:256:1: sparse: symbol 'nilfs_sysfs_create_mounted_snapshots_group' was not declared. Should it be static?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 06/26/2014 12:38 PM, kbuild test robot wrote:
tree:   git://git.cmpxchg.org/linux-mmotm.git master
head:   9477ec75947f2cf0fc47e8ab781a5e9171099be2
commit: c4d5ec2ba1ab268de64dcad7c6544d99a2218999 [212/319] nilfs2: integrate sysfs support into driver
reproduce: make C=1 CF=-D__CHECK_ENDIAN__


sparse warnings: (new ones prefixed by >>)

fs/nilfs2/sysfs.c:256:1: sparse: symbol 'nilfs_sysfs_create_mounted_snapshots_group' was not declared. Should it be static?
fs/nilfs2/sysfs.c:369:1: sparse: symbol 'nilfs_sysfs_create_checkpoints_group' was not declared. Should it be static?
fs/nilfs2/sysfs.c:458:1: sparse: symbol 'nilfs_sysfs_create_segments_group' was not declared. Should it be static?
fs/nilfs2/sysfs.c:720:1: sparse: symbol 'nilfs_sysfs_create_segctor_group' was not declared. Should it be static?
fs/nilfs2/sysfs.c:846:1: sparse: symbol 'nilfs_sysfs_create_superblock_group' was not declared. Should it be static?
Please consider folding the attached diff :-)

The diff looks good for me. But what about to fix the issue in the source?
Please, find my vision of the patch in the attachment.

Thanks,
Vyacheslav Dubeyko.

From: Fengguang Wu <fengguang.wu@xxxxxxxxx>
Subject: [PATCH mmotm] nilfs2: nilfs_sysfs_create_mounted_snapshots_group can be static
TO: Vyacheslav Dubeyko <Vyacheslav.Dubeyko@xxxxxxxx>
CC: Johannes Weiner <hannes@xxxxxxxxxxx>
CC: linux-nilfs@xxxxxxxxxxxxxxx
CC: linux-kernel@xxxxxxxxxxxxxxx

CC: Vyacheslav Dubeyko <Vyacheslav.Dubeyko@xxxxxxxx>
CC: Johannes Weiner <hannes@xxxxxxxxxxx>
Signed-off-by: Fengguang Wu <fengguang.wu@xxxxxxxxx>
---
 fs/nilfs2/sysfs.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/nilfs2/sysfs.c b/fs/nilfs2/sysfs.c
index 0f6148c..bbb0dcc 100644
--- a/fs/nilfs2/sysfs.c
+++ b/fs/nilfs2/sysfs.c
@@ -87,7 +87,7 @@ static struct kobj_type nilfs_##name##_ktype = { \
 };
 
 #define NILFS_DEV_INT_GROUP_FNS(name, parent_name) \
-int nilfs_sysfs_create_##name##_group(struct the_nilfs *nilfs) \
+static int nilfs_sysfs_create_##name##_group(struct the_nilfs *nilfs) \
 { \
 	struct kobject *parent; \
 	struct kobject *kobj; \
@@ -106,7 +106,7 @@ int nilfs_sysfs_create_##name##_group(struct the_nilfs *nilfs) \
 		return err; \
 	return 0; \
 } \
-void nilfs_sysfs_delete_##name##_group(struct the_nilfs *nilfs) \
+static void nilfs_sysfs_delete_##name##_group(struct the_nilfs *nilfs) \
 { \
 	kobject_del(&nilfs->ns_##parent_name##_subgroups->sg_##name##_kobj); \
 }
-- 
1.7.9.5


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]