Re: [PATCH] : Fix compilation warnings when CONFIG_FILE_LOCKING is not defined.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jan 16, 2009 at 3:51 PM, Manish Katiyar <mkatiyar@xxxxxxxxx> wrote:
> Below patch removes the following compilation warnings.
>
> fs/lockd/svclock.c:719: warning: unused variable 'file'
> fs/nfsd/nfsxdr.c:154: warning: unused variable 'dentry'

Hi,

Any feedback on this ?

Thanks -
Manish

>
>
> Signed-off-by: Manish Katiyar <mkatiyar@xxxxxxxxx>
> diff --git a/fs/lockd/svclock.c b/fs/lockd/svclock.c
> index 6063a8e..c4a08e2 100644
> --- a/fs/lockd/svclock.c
> +++ b/fs/lockd/svclock.c
> @@ -716,7 +716,9 @@ struct lock_manager_operations nlmsvc_lock_operations = {
>  static void
>  nlmsvc_grant_blocked(struct nlm_block *block)
>  {
> +#ifdef CONFIG_FILE_LOCKING
>        struct nlm_file         *file = block->b_file;
> +#endif
>        struct nlm_lock         *lock = &block->b_call->a_args.lock;
>        int                     error;
>
> diff --git a/fs/nfsd/nfsxdr.c b/fs/nfsd/nfsxdr.c
> index afd08e2..70219c9 100644
> --- a/fs/nfsd/nfsxdr.c
> +++ b/fs/nfsd/nfsxdr.c
> @@ -151,7 +151,9 @@ static __be32 *
>  encode_fattr(struct svc_rqst *rqstp, __be32 *p, struct svc_fh *fhp,
>             struct kstat *stat)
>  {
> +#ifdef CONFIG_FILE_LOCKING
>        struct dentry   *dentry = fhp->fh_dentry;
> +#endif
>        int type;
>        struct timespec time;
>        u32 f;
>
>
> Thanks -
> Manish
>
--
To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux