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: <36ca99e90804081236ifa3eecfue3dd211f9cdcb32a@mail.gmail.com>
Date:	Tue, 8 Apr 2008 21:36:49 +0200
From:	"Bert Wesarg" <bert.wesarg@...glemail.com>
To:	"Mike Travis" <travis@....com>
Cc:	"Ingo Molnar" <mingo@...e.hu>, "Paul Jackson" <pj@....com>,
	"Thomas Gleixner" <tglx@...utronix.de>,
	"H. Peter Anvin" <hpa@...or.com>,
	"Andrew Morton" <akpm@...ux-foundation.org>,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/3] x86: modify show_shared_cpu_map in intel_cacheinfo v3

On Tue, Apr 8, 2008 at 8:43 PM, Mike Travis <travis@....com> wrote:
>  --- linux-2.6.x86.sched.orig/arch/x86/kernel/cpu/intel_cacheinfo.c
>  +++ linux-2.6.x86.sched/arch/x86/kernel/cpu/intel_cacheinfo.c
>  @@ -591,20 +591,34 @@ static ssize_t show_size(struct _cpuid4_
>         return sprintf (buf, "%luK\n", this_leaf->size / 1024);
>   }
>
>  -static ssize_t show_shared_cpu_map(struct _cpuid4_info *this_leaf, char *buf)
>  +static ssize_t show_shared_cpu_map_func(struct _cpuid4_info *this_leaf,
>  +                                       int type, char *buf)
I don't know if this is more efficient or better or cleaner, but how
about to pass the function pointer (ie. cpulist_scnprintf or
cpumap_scnprintf)? You safe at least one condition.

>  +               n = type?
>  +                       cpulist_scnprintf(buf, len-2, *mask):
>  +                       cpumask_scnprintf(buf, len-2, *mask);

Thanks.
Bert
--
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