linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] fs: replace int param with size_t for seq_open_private()
@ 2014-09-01 13:17 Rob Jones
  2014-09-01 15:36 ` Al Viro
  0 siblings, 1 reply; 14+ messages in thread
From: Rob Jones @ 2014-09-01 13:17 UTC (permalink / raw)
  To: linux-kernel; +Cc: linux-fsdevel, viro, akpm, linux-kernel, rob.jones

also for __seq_open_private()

Resubmitted due to email address typo.

Signed-off-by: Rob Jones <rob.jones@codethink.co.uk>
---
 fs/seq_file.c            |    4 ++--
 include/linux/seq_file.h |    4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/fs/seq_file.c b/fs/seq_file.c
index 1d641bb..dc2dfec 100644
--- a/fs/seq_file.c
+++ b/fs/seq_file.c
@@ -640,7 +640,7 @@ int seq_release_private(struct inode *inode, struct file *file)
 EXPORT_SYMBOL(seq_release_private);
 
 void *__seq_open_private(struct file *f, const struct seq_operations *ops,
-		int psize)
+		size_t psize)
 {
 	int rc;
 	void *private;
@@ -666,7 +666,7 @@ out:
 EXPORT_SYMBOL(__seq_open_private);
 
 int seq_open_private(struct file *filp, const struct seq_operations *ops,
-		int psize)
+		size_t psize)
 {
 	return __seq_open_private(filp, ops, psize) ? 0 : -ENOMEM;
 }
diff --git a/include/linux/seq_file.h b/include/linux/seq_file.h
index 52e0097..9382339 100644
--- a/include/linux/seq_file.h
+++ b/include/linux/seq_file.h
@@ -140,8 +140,8 @@ static inline int seq_nodemask_list(struct seq_file *m, nodemask_t *mask)
 int single_open(struct file *, int (*)(struct seq_file *, void *), void *);
 int single_open_size(struct file *, int (*)(struct seq_file *, void *), void *, size_t);
 int single_release(struct inode *, struct file *);
-void *__seq_open_private(struct file *, const struct seq_operations *, int);
-int seq_open_private(struct file *, const struct seq_operations *, int);
+void *__seq_open_private(struct file *, const struct seq_operations *, size_t);
+int seq_open_private(struct file *, const struct seq_operations *, size_t);
 int seq_release_private(struct inode *, struct file *);
 int seq_put_decimal_ull(struct seq_file *m, char delimiter,
 			unsigned long long num);
-- 
1.7.10.4


^ permalink raw reply related	[flat|nested] 14+ messages in thread
* Re: [PATCH] fs: replace int param with size_t for seq_open_private()
@ 2014-09-01 13:43 Alexey Dobriyan
  2014-09-01 13:54 ` Rob Jones
  0 siblings, 1 reply; 14+ messages in thread
From: Alexey Dobriyan @ 2014-09-01 13:43 UTC (permalink / raw)
  To: Rob Jones; +Cc: Linux Kernel

>  void *__seq_open_private(struct file *f, const struct seq_operations *ops,
> - int psize)
> + size_t psize)

It should be "unsigned int" at most.
As almost all in-kernel lengths.

    Alexey

^ permalink raw reply	[flat|nested] 14+ messages in thread
* [PATCH] fs: replace int param with size_t for seq_open_private()
@ 2014-09-01 13:13 Rob Jones
  2014-09-01 13:15 ` Rob Jones
  0 siblings, 1 reply; 14+ messages in thread
From: Rob Jones @ 2014-09-01 13:13 UTC (permalink / raw)
  To: linux-kernel; +Cc: linux-fsdevel, viro, akpm, linux-kernel, rob.jones

also for __seq_open_private()

Signed-off-by: Rob Jones <rob.jones@codethink.co.uk>
---
 fs/seq_file.c            |    4 ++--
 include/linux/seq_file.h |    4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/fs/seq_file.c b/fs/seq_file.c
index 1d641bb..dc2dfec 100644
--- a/fs/seq_file.c
+++ b/fs/seq_file.c
@@ -640,7 +640,7 @@ int seq_release_private(struct inode *inode, struct file *file)
 EXPORT_SYMBOL(seq_release_private);
 
 void *__seq_open_private(struct file *f, const struct seq_operations *ops,
-		int psize)
+		size_t psize)
 {
 	int rc;
 	void *private;
@@ -666,7 +666,7 @@ out:
 EXPORT_SYMBOL(__seq_open_private);
 
 int seq_open_private(struct file *filp, const struct seq_operations *ops,
-		int psize)
+		size_t psize)
 {
 	return __seq_open_private(filp, ops, psize) ? 0 : -ENOMEM;
 }
diff --git a/include/linux/seq_file.h b/include/linux/seq_file.h
index 52e0097..9382339 100644
--- a/include/linux/seq_file.h
+++ b/include/linux/seq_file.h
@@ -140,8 +140,8 @@ static inline int seq_nodemask_list(struct seq_file *m, nodemask_t *mask)
 int single_open(struct file *, int (*)(struct seq_file *, void *), void *);
 int single_open_size(struct file *, int (*)(struct seq_file *, void *), void *, size_t);
 int single_release(struct inode *, struct file *);
-void *__seq_open_private(struct file *, const struct seq_operations *, int);
-int seq_open_private(struct file *, const struct seq_operations *, int);
+void *__seq_open_private(struct file *, const struct seq_operations *, size_t);
+int seq_open_private(struct file *, const struct seq_operations *, size_t);
 int seq_release_private(struct inode *, struct file *);
 int seq_put_decimal_ull(struct seq_file *m, char delimiter,
 			unsigned long long num);
-- 
1.7.10.4


^ permalink raw reply related	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2014-09-12 14:43 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-01 13:17 [PATCH] fs: replace int param with size_t for seq_open_private() Rob Jones
2014-09-01 15:36 ` Al Viro
2014-09-01 15:53   ` Rob Jones
2014-09-11 16:25   ` Rob Jones
2014-09-12 14:16     ` Richard Weinberger
2014-09-12 14:43       ` Rob Jones
  -- strict thread matches above, loose matches on Subject: below --
2014-09-01 13:43 Alexey Dobriyan
2014-09-01 13:54 ` Rob Jones
2014-09-01 14:13   ` Alexey Dobriyan
2014-09-01 14:38     ` Rob Jones
2014-09-01 21:22       ` Al Viro
2014-09-02  8:29         ` Rob Jones
2014-09-01 13:13 Rob Jones
2014-09-01 13:15 ` Rob Jones

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).