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] [day] [month] [year] [list]
Message-ID: <1393425796.407.19.camel@joe-AO722>
Date:	Wed, 26 Feb 2014 06:43:16 -0800
From:	Joe Perches <joe@...ches.com>
To:	John Johansen <john.johansen@...onical.com>
Cc:	linux-kernel@...r.kernel.org,
	James Morris <james.l.morris@...cle.com>,
	linux-security-module@...r.kernel.org
Subject: Re: [PATCH 2/8] security: apparmor: Use a more current logging style

On Tue, 2014-02-25 at 23:31 -0800, John Johansen wrote:
> On 02/24/2014 01:59 PM, Joe Perches wrote:
> > Convert printks to pr_<level>.
> > Add pr_fmt.
> > Coalesce formats.
> > Remove embedded prefixes from logging.
> > 
> 
> you missed one place,

No, not really.

pr_debug differs from printk(KERN_DEBUG in that
pr_debug is only enabled with a #define DEBUG
or CONFIG_DYNAMIC_DEBUG setting.

I did not want to convert any of the printks
with KERN_DEBUG in this pass as that would
change the message logging by requiring
dynamic debugging be included in the CONFIG.

A subsequent pass converting these uses will
be done if or after these initial patches are
applied.

thanks, Joe

> --- a/security/apparmor/include/apparmor.h
> +++ b/security/apparmor/include/apparmor.h
> @@ -50,7 +50,7 @@ extern unsigned int aa_g_path_max;
>  #define AA_DEBUG(fmt, args...)                                         \
>         do {                                                            \
>                 if (aa_g_debug && printk_ratelimit())                   \
> -                       printk(KERN_DEBUG "AppArmor: " fmt, ##args);    \
> +                       pr_debug(fmt, ##args);                          \
>         } while (0)
>  
>  #define AA_ERROR(fmt, args...)                                         \
> 
> other than that looks good.
> 
> > Signed-off-by: Joe Perches <joe@...ches.com>
> Acked-by: John Johansen <john.johansen@...onical.com>


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