diff mbox

[05/12] blk-mq-debugfs: Declare a local symbol static

Message ID 20170817232311.25948-6-bart.vanassche@wdc.com (mailing list archive)
State New, archived
Headers show

Commit Message

Bart Van Assche Aug. 17, 2017, 11:23 p.m. UTC
This was detected by sparse.

Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com>
Cc: Omar Sandoval <osandov@fb.com>
---
 block/blk-mq-debugfs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Omar Sandoval Aug. 18, 2017, 6:52 a.m. UTC | #1
On Thu, Aug 17, 2017 at 04:23:04PM -0700, Bart Van Assche wrote:
> This was detected by sparse.

Reviewed-by: Omar Sandoval <osandov@fb.com>

> Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com>
> Cc: Omar Sandoval <osandov@fb.com>
> ---
>  block/blk-mq-debugfs.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/block/blk-mq-debugfs.c b/block/blk-mq-debugfs.c
> index 55940ddacd96..e53b6129ca5a 100644
> --- a/block/blk-mq-debugfs.c
> +++ b/block/blk-mq-debugfs.c
> @@ -739,7 +739,7 @@ static int blk_mq_debugfs_release(struct inode *inode, struct file *file)
>  		return seq_release(inode, file);
>  }
>  
> -const struct file_operations blk_mq_debugfs_fops = {
> +static const struct file_operations blk_mq_debugfs_fops = {
>  	.open		= blk_mq_debugfs_open,
>  	.read		= seq_read,
>  	.write		= blk_mq_debugfs_write,
> -- 
> 2.14.0
>
Hannes Reinecke Aug. 18, 2017, 7:33 a.m. UTC | #2
On 08/18/2017 01:23 AM, Bart Van Assche wrote:
> This was detected by sparse.
> 
> Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com>
> Cc: Omar Sandoval <osandov@fb.com>
> ---
>  block/blk-mq-debugfs.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/block/blk-mq-debugfs.c b/block/blk-mq-debugfs.c
> index 55940ddacd96..e53b6129ca5a 100644
> --- a/block/blk-mq-debugfs.c
> +++ b/block/blk-mq-debugfs.c
> @@ -739,7 +739,7 @@ static int blk_mq_debugfs_release(struct inode *inode, struct file *file)
>  		return seq_release(inode, file);
>  }
>  
> -const struct file_operations blk_mq_debugfs_fops = {
> +static const struct file_operations blk_mq_debugfs_fops = {
>  	.open		= blk_mq_debugfs_open,
>  	.read		= seq_read,
>  	.write		= blk_mq_debugfs_write,
> 
Reviewed-by: Hannes Reinecke <hare@suse.com>

Cheers,

Hannes
diff mbox

Patch

diff --git a/block/blk-mq-debugfs.c b/block/blk-mq-debugfs.c
index 55940ddacd96..e53b6129ca5a 100644
--- a/block/blk-mq-debugfs.c
+++ b/block/blk-mq-debugfs.c
@@ -739,7 +739,7 @@  static int blk_mq_debugfs_release(struct inode *inode, struct file *file)
 		return seq_release(inode, file);
 }
 
-const struct file_operations blk_mq_debugfs_fops = {
+static const struct file_operations blk_mq_debugfs_fops = {
 	.open		= blk_mq_debugfs_open,
 	.read		= seq_read,
 	.write		= blk_mq_debugfs_write,