* [PATCH] dm ioctl: make dm_open and dm_release release
@ 2017-05-10 9:18 Colin King
2017-05-10 9:19 ` Colin Ian King
0 siblings, 1 reply; 2+ messages in thread
From: Colin King @ 2017-05-10 9:18 UTC (permalink / raw)
To: Alasdair Kergon, Mike Snitzer, dm-devel, Shaohua Li, linux-raid
Cc: kernel-janitors, linux-kernel
From: Colin Ian King <colin.king@canonical.com>
Making dm_open and dm_release static fixes the sparse warnings:
warning: symbol 'dm_open' was not declared. Should it be static?
warning: symbol 'dm_release' was not declared. Should it be static?
Fixes: ab2c6224f4c0c ("dm: a basic support for using the select or poll function")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
drivers/md/dm-ioctl.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/md/dm-ioctl.c b/drivers/md/dm-ioctl.c
index 70dc5db90ef2..d45c68115d4c 100644
--- a/drivers/md/dm-ioctl.c
+++ b/drivers/md/dm-ioctl.c
@@ -1893,7 +1893,7 @@ static long dm_compat_ctl_ioctl(struct file *file, uint command, ulong u)
#define dm_compat_ctl_ioctl NULL
#endif
-int dm_open(struct inode *inode, struct file *filp)
+static int dm_open(struct inode *inode, struct file *filp)
{
int r;
struct dm_file *priv;
@@ -1911,7 +1911,7 @@ int dm_open(struct inode *inode, struct file *filp)
return 0;
}
-int dm_release(struct inode *inode, struct file *filp)
+static int dm_release(struct inode *inode, struct file *filp)
{
kfree(filp->private_data);
return 0;
--
2.11.0
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH] dm ioctl: make dm_open and dm_release release
2017-05-10 9:18 [PATCH] dm ioctl: make dm_open and dm_release release Colin King
@ 2017-05-10 9:19 ` Colin Ian King
0 siblings, 0 replies; 2+ messages in thread
From: Colin Ian King @ 2017-05-10 9:19 UTC (permalink / raw)
To: Alasdair Kergon, Mike Snitzer, dm-devel, Shaohua Li, linux-raid
Cc: kernel-janitors, linux-kernel
On 10/05/17 10:18, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> Making dm_open and dm_release static fixes the sparse warnings:
>
> warning: symbol 'dm_open' was not declared. Should it be static?
> warning: symbol 'dm_release' was not declared. Should it be static?
>
> Fixes: ab2c6224f4c0c ("dm: a basic support for using the select or poll function")
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
> drivers/md/dm-ioctl.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/md/dm-ioctl.c b/drivers/md/dm-ioctl.c
> index 70dc5db90ef2..d45c68115d4c 100644
> --- a/drivers/md/dm-ioctl.c
> +++ b/drivers/md/dm-ioctl.c
> @@ -1893,7 +1893,7 @@ static long dm_compat_ctl_ioctl(struct file *file, uint command, ulong u)
> #define dm_compat_ctl_ioctl NULL
> #endif
>
> -int dm_open(struct inode *inode, struct file *filp)
> +static int dm_open(struct inode *inode, struct file *filp)
> {
> int r;
> struct dm_file *priv;
> @@ -1911,7 +1911,7 @@ int dm_open(struct inode *inode, struct file *filp)
> return 0;
> }
>
> -int dm_release(struct inode *inode, struct file *filp)
> +static int dm_release(struct inode *inode, struct file *filp)
> {
> kfree(filp->private_data);
> return 0;
>
Sorry, ignore this, it had a mistake in the subject line
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-05-10 9:19 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-05-10 9:18 [PATCH] dm ioctl: make dm_open and dm_release release Colin King
2017-05-10 9:19 ` Colin Ian King
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox