lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20100422193148.GG5805@quack.suse.cz>
Date:	Thu, 22 Apr 2010 21:31:49 +0200
From:	Jan Kara <jack@...e.cz>
To:	Sergey Senozhatsky <sergey.senozhatsky@...il.com>
Cc:	Jan Kara <jack@...e.cz>, Christoph Hellwig <hch@....de>,
	linux-kernel@...r.kernel.org
Subject: Re: suppress warning: ‘quotatypes’ defined but not used

On Thu 22-04-10 11:05:40, Sergey Senozhatsky wrote:
> Hello,
> There is unused (in some cases) pointer in dquot.c
> fs/quota/dquot.c:135: warning: ‘quotatypes’ defined but not used
> 
> which is referenced only when 
> #ifdef CONFIG_QUOTA_DEBUG or #ifdef CONFIG_PRINT_QUOTA_WARNING
> 
> My proposal is to wrap declaration in "if defined(CONFIG_QUOTA_DEBUG) || defined(CONFIG_PRINT_QUOTA_WARNING) ..."?
  The patch is fine. Could you please add your Signed-off-by to the patch
(see Documentation/SubmittingPatches in case you don't know what it is).
Thanks.

								Honza
> 
> 
> diff --git a/fs/quota/dquot.c b/fs/quota/dquot.c
> index 788b580..ab0a08a 100644
> --- a/fs/quota/dquot.c
> +++ b/fs/quota/dquot.c
> @@ -132,7 +132,10 @@ static __cacheline_aligned_in_smp DEFINE_SPINLOCK(dq_state_lock);
>  __cacheline_aligned_in_smp DEFINE_SPINLOCK(dq_data_lock);
>  EXPORT_SYMBOL(dq_data_lock);
> 
> -static char *quotatypes[] = INITQFNAMES;
> +#if defined(CONFIG_QUOTA_DEBUG) || defined(CONFIG_PRINT_QUOTA_WARNING)
> +	static char *quotatypes[] = INITQFNAMES;
> +#endif
> +
>  static struct quota_format_type *quota_formats;        /* List of registered formats */
>  static struct quota_module_name module_names[] = INIT_QUOTA_MODULE_NAMES;
> 


-- 
Jan Kara <jack@...e.cz>
SUSE Labs, CR
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ