* [PATCH] fsnotify: make dnotify_fsnotify_ops const
@ 2017-08-30 12:39 Bhumika Goyal
2017-08-30 14:03 ` Jan Kara
0 siblings, 1 reply; 2+ messages in thread
From: Bhumika Goyal @ 2017-08-30 12:39 UTC (permalink / raw)
To: julia.lawall, jack, amir73il, linux-fsdevel, linux-kernel; +Cc: Bhumika Goyal
Make this const as it is never modified.
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
---
fs/notify/dnotify/dnotify.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/notify/dnotify/dnotify.c b/fs/notify/dnotify/dnotify.c
index 2430a04..cba3283 100644
--- a/fs/notify/dnotify/dnotify.c
+++ b/fs/notify/dnotify/dnotify.c
@@ -133,7 +133,7 @@ static void dnotify_free_mark(struct fsnotify_mark *fsn_mark)
kmem_cache_free(dnotify_mark_cache, dn_mark);
}
-static struct fsnotify_ops dnotify_fsnotify_ops = {
+static const struct fsnotify_ops dnotify_fsnotify_ops = {
.handle_event = dnotify_handle_event,
.free_mark = dnotify_free_mark,
};
--
1.9.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] fsnotify: make dnotify_fsnotify_ops const
2017-08-30 12:39 [PATCH] fsnotify: make dnotify_fsnotify_ops const Bhumika Goyal
@ 2017-08-30 14:03 ` Jan Kara
0 siblings, 0 replies; 2+ messages in thread
From: Jan Kara @ 2017-08-30 14:03 UTC (permalink / raw)
To: Bhumika Goyal; +Cc: julia.lawall, jack, amir73il, linux-fsdevel, linux-kernel
On Wed 30-08-17 18:09:02, Bhumika Goyal wrote:
> Make this const as it is never modified.
>
> Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
Thanks. Added to my tree.
Honza
> ---
> fs/notify/dnotify/dnotify.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/notify/dnotify/dnotify.c b/fs/notify/dnotify/dnotify.c
> index 2430a04..cba3283 100644
> --- a/fs/notify/dnotify/dnotify.c
> +++ b/fs/notify/dnotify/dnotify.c
> @@ -133,7 +133,7 @@ static void dnotify_free_mark(struct fsnotify_mark *fsn_mark)
> kmem_cache_free(dnotify_mark_cache, dn_mark);
> }
>
> -static struct fsnotify_ops dnotify_fsnotify_ops = {
> +static const struct fsnotify_ops dnotify_fsnotify_ops = {
> .handle_event = dnotify_handle_event,
> .free_mark = dnotify_free_mark,
> };
> --
> 1.9.1
>
--
Jan Kara <jack@suse.com>
SUSE Labs, CR
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-08-30 14:03 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-08-30 12:39 [PATCH] fsnotify: make dnotify_fsnotify_ops const Bhumika Goyal
2017-08-30 14:03 ` Jan Kara
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).