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]
Date:	Wed, 16 Jul 2008 01:07:31 +0200
From:	Dominik Brodowski <linux@...inikbrodowski.net>
To:	Jason Baron <jbaron@...hat.com>
Cc:	linux-kernel@...r.kernel.org, akpm@...ux-foundation.org,
	joe@...ches.com, greg@...ah.com, nick@...k-andrew.net,
	randy.dunlap@...cle.com
Subject: Re: [PATCH 6/7] dynamic debug v2 - convert cpufreq

Hi,

On Tue, Jul 15, 2008 at 05:36:13PM -0400, Jason Baron wrote:
> +#include <linux/dynamic_debug_cpufreq.h>

what's contained in this file (couldn't find it in this or one of the other
diffs, but may have missed it).

> -#define dprintk(msg...) cpufreq_debug_printk(CPUFREQ_DEBUG_DRIVER, "cpufreq-nforce2", msg)
> +#define dprintk(msg...) do { \
> +	if (dynamic_dbg_enabled(TYPE_FLAG, CPUFREQ_DEBUG_DRIVER, cpufreq_debug)) \
> +		cpufreq_debug_printk(CPUFREQ_DEBUG_DRIVER, "cpufreq-nforce2", msg); \
> +	} while (0)

Hm.... What about leaving this as it is, renaming the
drivers/cpufreq/cpufreq.c function to __cpufreq_debug_printk(), and then
adding to include/linux/cpufreq.h

#define cpufreq_debug_printk(type, prefix, msg...) do { \
	if (dynamic_dbg_enabled(TYPE_FLAG, type, cpufreq_debug))
		cpufreq_debug_printk(type, prefix, msg); \
	} while (0)

> +#if defined(CONFIG_CPU_FREQ_DEBUG) || defined (CONFIG_DYNAMIC_PRINTK_DEBUG)
...
> +#if defined(CONFIG_CPU_FREQ_DEBUG) || defined (CONFIG_DYNAMIC_PRINTK_DEBUG)

can't we just depend on thing on another?

> -module_param(debug, uint, 0644);
> -MODULE_PARM_DESC(debug, "CPUfreq debugging: add 1 to debug core,"
> +module_param(cpufreq_debug, uint, 0644);
> +MODULE_PARM_DESC(cpufreq_debug, "CPUfreq debugging: add 1 to debug core,"
>  			" 2 to debug drivers, and 4 to debug governors.");

cpufreq.cpufreq_debug is ugly and not backwards compatible... what about 

module_param_named(debug, cpufreq_debug, uint, 0644) [or the other way
around, I always forget...])

Best,
	Dominik
--
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