All of lore.kernel.org
 help / color / mirror / Atom feed
From: Deepak R Varma <drv@mailo.com>
To: Bob Peterson <rpeterso@redhat.com>,
	Andreas Gruenbacher <agruenba@redhat.com>,
	gfs2@lists.linux.dev, linux-kernel@vger.kernel.org
Cc: linux-kernel-mentees@lists.linuxfoundation.org,
	Dan Carpenter <error27@gmail.com>
Subject: [PATCH] gfs2: No need to be "extern" at the time of definition
Date: Fri, 29 Sep 2023 10:44:16 +0530	[thread overview]
Message-ID: <ZRZdKAmDjrpCQLwE@runicha.com> (raw)

No need to for the extern keyword at the time of function definition.
Remove it to silence the following Smatch warnings:
fs/gfs2/super.c:1579:13: warning: function 'free_local_statfs_inodes' with external linkage has definition
fs/gfs2/super.c:1594:21: warning: function 'find_local_statfs_inode' with external linkage has definition

Signed-off-by: Deepak R Varma <drv@mailo.com>
---
 fs/gfs2/super.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/fs/gfs2/super.c b/fs/gfs2/super.c
index 02d93da21b2b..fad36ed89853 100644
--- a/fs/gfs2/super.c
+++ b/fs/gfs2/super.c
@@ -1576,7 +1576,7 @@ static void gfs2_free_inode(struct inode *inode)
 	kmem_cache_free(gfs2_inode_cachep, GFS2_I(inode));
 }

-extern void free_local_statfs_inodes(struct gfs2_sbd *sdp)
+void free_local_statfs_inodes(struct gfs2_sbd *sdp)
 {
 	struct local_statfs_inode *lsi, *safe;

@@ -1591,8 +1591,7 @@ extern void free_local_statfs_inodes(struct gfs2_sbd *sdp)
 	}
 }

-extern struct inode *find_local_statfs_inode(struct gfs2_sbd *sdp,
-					     unsigned int index)
+struct inode *find_local_statfs_inode(struct gfs2_sbd *sdp, unsigned int index)
 {
 	struct local_statfs_inode *lsi;

--
2.39.2



_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees

WARNING: multiple messages have this Message-ID (diff)
From: Deepak R Varma <drv@mailo.com>
To: Bob Peterson <rpeterso@redhat.com>,
	Andreas Gruenbacher <agruenba@redhat.com>,
	gfs2@lists.linux.dev, linux-kernel@vger.kernel.org
Cc: linux-kernel-mentees@lists.linuxfoundation.org,
	Dan Carpenter <error27@gmail.com>, Deepak R Varma <drv@mailo.com>
Subject: [PATCH] gfs2: No need to be "extern" at the time of definition
Date: Fri, 29 Sep 2023 10:44:16 +0530	[thread overview]
Message-ID: <ZRZdKAmDjrpCQLwE@runicha.com> (raw)

No need to for the extern keyword at the time of function definition.
Remove it to silence the following Smatch warnings:
fs/gfs2/super.c:1579:13: warning: function 'free_local_statfs_inodes' with external linkage has definition
fs/gfs2/super.c:1594:21: warning: function 'find_local_statfs_inode' with external linkage has definition

Signed-off-by: Deepak R Varma <drv@mailo.com>
---
 fs/gfs2/super.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/fs/gfs2/super.c b/fs/gfs2/super.c
index 02d93da21b2b..fad36ed89853 100644
--- a/fs/gfs2/super.c
+++ b/fs/gfs2/super.c
@@ -1576,7 +1576,7 @@ static void gfs2_free_inode(struct inode *inode)
 	kmem_cache_free(gfs2_inode_cachep, GFS2_I(inode));
 }

-extern void free_local_statfs_inodes(struct gfs2_sbd *sdp)
+void free_local_statfs_inodes(struct gfs2_sbd *sdp)
 {
 	struct local_statfs_inode *lsi, *safe;

@@ -1591,8 +1591,7 @@ extern void free_local_statfs_inodes(struct gfs2_sbd *sdp)
 	}
 }

-extern struct inode *find_local_statfs_inode(struct gfs2_sbd *sdp,
-					     unsigned int index)
+struct inode *find_local_statfs_inode(struct gfs2_sbd *sdp, unsigned int index)
 {
 	struct local_statfs_inode *lsi;

--
2.39.2




             reply	other threads:[~2023-09-29  5:14 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-29  5:14 Deepak R Varma [this message]
2023-09-29  5:14 ` [PATCH] gfs2: No need to be "extern" at the time of definition Deepak R Varma

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=ZRZdKAmDjrpCQLwE@runicha.com \
    --to=drv@mailo.com \
    --cc=agruenba@redhat.com \
    --cc=error27@gmail.com \
    --cc=gfs2@lists.linux.dev \
    --cc=linux-kernel-mentees@lists.linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rpeterso@redhat.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 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.