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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 11 May 2012 09:54:27 +0800
From:	"Yan, Zheng" <zheng.z.yan@...el.com>
To:	Peter Zijlstra <a.p.zijlstra@...llo.nl>
CC:	mingo@...e.hu, andi@...stfloor.org, eranian@...gle.com,
	jolsa@...hat.com, ming.m.lin@...el.com,
	linux-kernel@...r.kernel.org, hpa <hpa@...or.com>
Subject: Re: [PATCH 4/9] perf: Generic intel uncore support

On 05/10/2012 06:05 PM, Peter Zijlstra wrote:
> On Thu, 2012-05-10 at 15:34 +0800, Yan, Zheng wrote:
>>
>> This code doesn't work for PCI uncore device if there are offline CPUs,
>> because topology_physical_package_id() always return 0 for offline CPUs.
> 
> Hmm, that sounds wrong.. one would expect something like BAD_APICID, -1
> or the correct number. hpa should we fix that?
> 
> Anyway,
> 
>> So besides the per CPU variable, we still need another data structure
>> to track the uncore boxes. Do you still want to use per CPU variable?
> 
> Well you don't really need the value for offline CPUs, until they're
> online right? 
Yes

> So all you need to do is iterate all the box muck in a
> hotplug handler and set the right pointer, no? (I suspect this would
> need to be done in CPU_STARTING).
The problem is that CPUs on a particular socket can all be offline. So
we need an extra data structure to track the uncore boxes. This means
that the memory addresses of uncore boxes are stored in two places.
It's a little tricky to keep the two places in sync. For example, In the
case of hot-plugging CPU, the per CPU pointers can only be set after the
PCI uncore devices are probed. How to handle the case that cpu hotplug
handler is executed before PCI uncore devices are probed? For the reason
listed above I still prefer not to use per CPU pointer.

Regards
Yan, Zheng
--
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