Re: [RFC PATCH 2/12] memory-hogplug : check memory offline in offline_pages

2012-06-27 Thread Yasuaki Ishimatsu
Hi Kosaki-san, 2012/06/28 14:26, KOSAKI Motohiro wrote: On Wed, Jun 27, 2012 at 1:44 AM, Yasuaki Ishimatsu wrote: When offline_pages() is called to offlined memory, the function fails since all memory has been offlined. In this case, the function should succeed. The patch adds the check functi

Re: [RFC PATCH 4/12] memory-hotplug : remove /sys/firmware/memmap/X sysfs

2012-06-27 Thread Wen Congyang
At 06/27/2012 01:47 PM, Yasuaki Ishimatsu Wrote: > When (hot)adding memory into system, /sys/firmware/memmap/X/{end, start, type} > sysfs files are created. But there is no code to remove these files. The patch > implements the function to remove them. > > Note : The code does not free firmware_ma

Re: [RFC PATCH 2/12] memory-hogplug : check memory offline in offline_pages

2012-06-27 Thread Yasuaki Ishimatsu
Hi Kosaki-san, 2012/06/28 14:27, KOSAKI Motohiro wrote: On Thu, Jun 28, 2012 at 1:06 AM, Yasuaki Ishimatsu wrote: Hi Wen, 2012/06/27 17:49, Wen Congyang wrote: At 06/27/2012 01:44 PM, Yasuaki Ishimatsu Wrote: When offline_pages() is called to offlined memory, the function fails since all me

Re: [RFC PATCH 2/12] memory-hogplug : check memory offline in offline_pages

2012-06-27 Thread KOSAKI Motohiro
On Thu, Jun 28, 2012 at 1:06 AM, Yasuaki Ishimatsu wrote: > Hi Wen, > > 2012/06/27 17:49, Wen Congyang wrote: >> At 06/27/2012 01:44 PM, Yasuaki Ishimatsu Wrote: >>> When offline_pages() is called to offlined memory, the function fails since >>> all memory has been offlined. In this case, the func

Re: [RFC PATCH 2/12] memory-hogplug : check memory offline in offline_pages

2012-06-27 Thread KOSAKI Motohiro
On Wed, Jun 27, 2012 at 1:44 AM, Yasuaki Ishimatsu wrote: > When offline_pages() is called to offlined memory, the function fails since > all memory has been offlined. In this case, the function should succeed. > The patch adds the check function into offline_pages(). I don't understand your poin

Re: [RFC PATCH 2/12] memory-hogplug : check memory offline in offline_pages

2012-06-27 Thread Yasuaki Ishimatsu
Hi Wen, 2012/06/27 17:49, Wen Congyang wrote: > At 06/27/2012 01:44 PM, Yasuaki Ishimatsu Wrote: >> When offline_pages() is called to offlined memory, the function fails since >> all memory has been offlined. In this case, the function should succeed. >> The patch adds the check function into offl

Re: [RFC PATCH 1/12] memory-hotplug : rename remove_memory to offline_memory

2012-06-27 Thread Yasuaki Ishimatsu
Hi Wen, 2012/06/28 12:25, Wen Congyang wrote: > At 06/28/2012 11:01 AM, Yasuaki Ishimatsu Wrote: >> Hi David and Wen, >> >> Thank you for reviewing my patch. >> >> 2012/06/27 17:47, Wen Congyang wrote: >>> At 06/27/2012 03:14 PM, Wen Congyang Wrote: At 06/27/2012 01:42 PM, Yasuaki Ishimatsu W

Re: [PATCH V4 2/2] PCI: minimal alignment for bars of P2P bridges

2012-06-27 Thread Ram Pai
On Wed, Jun 27, 2012 at 10:48:45PM +0800, Gavin Shan wrote: > On some powerpc platforms, device BARs need to be assigned to separate > "segments" of the address space in order for the error isolation and HW > virtualization mechanisms (EEH) to work properly. Those "segments" have > a minimum size t

RE: [PATCH 0/3] powerpc/fsl: PCI refactoring and QEMU paravirt platform

2012-06-27 Thread Jia Hongtao-B38951
> -Original Message- > From: Wood Scott-B07421 > Sent: Thursday, June 28, 2012 7:49 AM > To: ga...@kernel.crashing.org > Cc: ag...@suse.de; linuxppc-dev@lists.ozlabs.org; Jia Hongtao-B38951 > Subject: [PATCH 0/3] powerpc/fsl: PCI refactoring and QEMU paravirt > platform > > The QEMU stuf

Re: [PATCH V4 1/2] PCI: pcibus address to resource converting take bus directly

2012-06-27 Thread Gavin Shan
>> For allocating resource under bus path, we do have dev pass along, >> and we could just use bus instead. Also, we'd like to make function >> find_pci_host_bridge() global so that some platforms (e.g. PPC) can >> access the pci host bridge directly. > >This patch appears to have multiple unrelate

Re: [PATCH v6 1/5] powerpc/85xx: implement hardware timebase sync

2012-06-27 Thread Zhao Chenhui
On Wed, Jun 27, 2012 at 09:48:52PM +1000, Benjamin Herrenschmidt wrote: > On Wed, 2012-06-27 at 18:21 +0800, Zhao Chenhui wrote: > > > What's that CONFIG option for ? > > > > > > Cheers, > > > Ben. > > > > This option is to guard the timebase sync routines. It is selected > > when KEXEC or HOTPLU

Re: [RFC PATCH 1/12] memory-hotplug : rename remove_memory to offline_memory

2012-06-27 Thread Wen Congyang
At 06/28/2012 11:01 AM, Yasuaki Ishimatsu Wrote: > Hi David and Wen, > > Thank you for reviewing my patch. > > 2012/06/27 17:47, Wen Congyang wrote: >> At 06/27/2012 03:14 PM, Wen Congyang Wrote: >>> At 06/27/2012 01:42 PM, Yasuaki Ishimatsu Wrote: remove_memory() does not remove memory but

Re: [RFC PATCH 1/12] memory-hotplug : rename remove_memory to offline_memory

2012-06-27 Thread Yasuaki Ishimatsu
Hi David and Wen, Thank you for reviewing my patch. 2012/06/27 17:47, Wen Congyang wrote: > At 06/27/2012 03:14 PM, Wen Congyang Wrote: >> At 06/27/2012 01:42 PM, Yasuaki Ishimatsu Wrote: >>> remove_memory() does not remove memory but just offlines memory. The patch >>> changes name of it to offl

Re: [PATCH 03/21] ppc/eeh: more logs for EEH initialization

2012-06-27 Thread Gavin Shan
>On Thu, 2012-06-28 at 00:01 +0800, Gavin Shan wrote: >> The patch adds more logs to EEH initialization functions for >> debugging purpose. Also, the machine type ("pSeries") is checked >> in the platform initialization to assure it's the correct platform >> to invoke it. > >Hi Gavin, > >Our boot l

[PATCH 3/3] powerpc/mpc85xx_ds: convert to unified PCI init

2012-06-27 Thread Scott Wood
Similar to how the primary PCI bridge is identified by looking for an isa subnode, we determine whether to apply uli exclusions by looking for a uli subnode. Signed-off-by: Scott Wood --- Besides being an example of a real-hardware board to use the new PCI init (probably one of the more complicat

[PATCH 2/3] powerpc/e500: add paravirt QEMU platform

2012-06-27 Thread Scott Wood
This gives the kernel a paravirtualized machine to target, without requiring both sides to pretend to be targeting a specific board that likely has little to do with the host in KVM scenarios. This avoids the need to add new boards to QEMU just to be able to run KVM on new CPUs. As this is the fi

[PATCH 1/3] powerpc/fsl-pci: provide common PCI init

2012-06-27 Thread Scott Wood
As an alternative incremental starting point to Jia Hongtao's patchset, get the FSL PCI init out of the board files, but do not yet convert to a platform driver. Rather than having each board supply a magic register offset for determining the "primary" bus, we look for which PCI host bridge contai

[PATCH 0/3] powerpc/fsl: PCI refactoring and QEMU paravirt platform

2012-06-27 Thread Scott Wood
The QEMU stuff is related to the PCI refactoring because currently we have a hard time selecting a primary bus under QEMU, and also because the generic qemu e500 platform wants a full list of FSL PCI compatibles to check. Scott Wood (3): powerpc/fsl-pci: get PCI init out of board files powerpc

Re: [PATCH 03/21] ppc/eeh: more logs for EEH initialization

2012-06-27 Thread Michael Ellerman
On Thu, 2012-06-28 at 00:01 +0800, Gavin Shan wrote: > The patch adds more logs to EEH initialization functions for > debugging purpose. Also, the machine type ("pSeries") is checked > in the platform initialization to assure it's the correct platform > to invoke it. Hi Gavin, Our boot logs are f

[PATCH] powerpc: check_and_cede_processor never cedes

2012-06-27 Thread Anton Blanchard
Hi, > I'd rather add a helper, something like lazy_irq_pending() > and hide the actual check for the bits in irq_happened, in > case we change the scheme again. Good idea. Look ok? -- Commit f948501b36c6 ("Make hard_irq_disable() actually hard-disable interrupts") caused check_and_cede_process

Re: [PATCH] powerpc: check_and_cede_processor never cedes

2012-06-27 Thread Benjamin Herrenschmidt
On Thu, 2012-06-28 at 08:45 +1000, Anton Blanchard wrote: > hard_irq_disable(); > - if (get_paca()->irq_happened == 0) > + if (get_paca()->irq_happened == PACA_IRQ_HARD_DIS) > cede_processor(); I'd rather add a helper, something like lazy_irq_pending() and hide the actu

[PATCH] powerpc: check_and_cede_processor never cedes

2012-06-27 Thread Anton Blanchard
Commit f948501b36c6 ("Make hard_irq_disable() actually hard-disable interrupts") caused check_and_cede_processor to stop working. ->irq_happened will never be zero right after a hard_irq_disable so the compiler removes the call to cede_processor completely. The bug was introduced back in the lazy

Re: [PATCH V4 2/2] PCI: minimal alignment for bars of P2P bridges

2012-06-27 Thread Benjamin Herrenschmidt
On Wed, 2012-06-27 at 12:48 -0600, Bjorn Helgaas wrote: > On Wed, Jun 27, 2012 at 8:48 AM, Gavin Shan wrote: > > On some powerpc platforms, device BARs need to be assigned to separate > > "segments" of the address space in order for the error isolation and HW > > virtualization mechanisms (EEH) to

Re: [PATCH] Using alloc_coherent for caam job rings

2012-06-27 Thread Kim Phillips
On Wed, 27 Jun 2012 10:58:32 +0530 Bharat Bhushan wrote: > This resolves the Linux boot crash issue when "swiotlb=force" is set > in bootargs on systems which have memory more than 4G. Acked-by: Kim Phillips Thanks Bharat, Kim ___ Linuxppc-dev mail

Re: [PATCH V4 2/2] PCI: minimal alignment for bars of P2P bridges

2012-06-27 Thread Bjorn Helgaas
On Wed, Jun 27, 2012 at 8:48 AM, Gavin Shan wrote: > On some powerpc platforms, device BARs need to be assigned to separate > "segments" of the address space in order for the error isolation and HW > virtualization mechanisms (EEH) to work properly. Those "segments" have > a minimum size that can

Re: [PATCH V4 1/2] PCI: pcibus address to resource converting take bus directly

2012-06-27 Thread Bjorn Helgaas
On Wed, Jun 27, 2012 at 8:48 AM, Gavin Shan wrote: > For allocating resource under bus path, we do have dev pass along, > and we could just use bus instead. Also, we'd like to make function > find_pci_host_bridge() global so that some platforms (e.g. PPC) can > access the pci host bridge directly.

[PATCH 12/21] ppc/eeh: trace error based on PE from beginning

2012-06-27 Thread Gavin Shan
There're 2 conditions to trigger EEH error detection: invalid value returned from reading I/O or config space. On each case, the function eeh_dn_check_failure will be called to initialize EEH event and put it into the poll for further processing. The patch changes the function for a little bit so

[PATCH 18/21] ppc/eeh: handle EEH error based on PE

2012-06-27 Thread Gavin Shan
The patch reworks the current implementation so that the eeh errors will be handled basing on PE instead of eeh device. Signed-off-by: Gavin Shan --- arch/powerpc/include/asm/eeh.h |1 + arch/powerpc/include/asm/eeh_event.h|2 +- arch/powerpc/platforms/pseries/eeh_dr

[PATCH 13/21] ppc/eeh: eeh options based on PE

2012-06-27 Thread Gavin Shan
Originally, all the EEH options were implemented based on OF node. Actually, it explicitly breaks the rules that the operation target is PE instead of device. Therefore, the patch makes all the operations based on PE instead of device. Unfortunately, the backend for config space has to be kept as

[PATCH V2 00/16] powerpc/eeh: PE support

2012-06-27 Thread Gavin Shan
The series of patches address explicit PE support as well as probe type support. For explicit PE support, struct eeh_pe has been introduced. While designing the struct, following factors have been taken into account. * For one particular PE, it might be composed of single PCI device, or mu

[PATCH 17/21] ppc/eeh: make EEH handler PE sensitive

2012-06-27 Thread Gavin Shan
Once eeh error is found, eeh event will be created and put it into the global linked list. At the mean while, kernel thread will be started to process it. The handler for the kernel thread originally was eeh device sensitive. The patch reworks the handler of the kernel thread so that it's PE sensi

[PATCH 05/21] ppc/eeh: introduce global mutex

2012-06-27 Thread Gavin Shan
The patch introduces global mutex for EEH so that the core data structures can be protected by that. Also, 2 inline functions are exported for that: eeh_lock() and eeh_unlock(). Signed-off-by: Gavin Shan --- arch/powerpc/include/asm/eeh.h | 15 +++ arch/powerpc/platforms/pser

[PATCH 06/21] ppc/eeh: Create PEs for PHBs

2012-06-27 Thread Gavin Shan
For one particular PE, it's only meaningful in the ancestor PHB domain. Therefore, each PHB should have its own PE hierarchy tree to trace those PEs created against the PHB. The patch creates PEs for the PHBs and put those PEs into the global link list traced by "eeh_phb_pe". The link list of PEs

[PATCH 02/21] ppc/eeh: use slab to allocate eeh devices

2012-06-27 Thread Gavin Shan
The EEH initialization functions have been postponed until slab/slub are ready. So we use slab/slub to allocate the memory chunks for newly creatd EEH devices. That would save lots of memory. The patch also does cleanup to replace "kmalloc" with "kzalloc" so that we needn't clear the allocated mem

[PATCH 15/21] ppc/eeh: I/O enable and log retrival based on PE

2012-06-27 Thread Gavin Shan
The patch refactors the original implementation in order to enable I/O and do log retrieval based on PE. Signed-off-by: Gavin Shan --- arch/powerpc/include/asm/ppc-pci.h |4 ++-- arch/powerpc/platforms/pseries/eeh.c | 44 +++--- 2 files changed, 21 insertions(

[PATCH 21/21] ppc/eeh: trace eeh device from I/O cache

2012-06-27 Thread Gavin Shan
The idea comes from Benjamin Herrenschmidt. The eeh cache helps fetching the pci device according to the given I/O address. Since the eeh cache is serving for eeh, it's reasonable for eeh cache to trace eeh device except pci device. The patch make eeh cache to trace eeh device. Also, the major eeh

[PATCH 16/21] ppc/eeh: do reset based on PE

2012-06-27 Thread Gavin Shan
The patch implements reset based on PE instead of eeh device. Also, The functions used to retrieve the reset type, either hot or fundamental reset, have been reworked for a little bit. More specificly, it's implemented based the the eeh device traverse function. Signed-off-by: Gavin Shan --- arc

[PATCH 03/21] ppc/eeh: more logs for EEH initialization

2012-06-27 Thread Gavin Shan
The patch adds more logs to EEH initialization functions for debugging purpose. Also, the machine type ("pSeries") is checked in the platform initialization to assure it's the correct platform to invoke it. Signed-off-by: Gavin Shan --- arch/powerpc/platforms/pseries/eeh_dev.c |2 ++ arc

[PATCH 07/21] ppc/eeh: Search PE based on requirement

2012-06-27 Thread Gavin Shan
The patch implements searching PE based on the following requirements: * Search PE according to PE address, which is traditional PE address that is composed of PCI bus/device/function number, or unified PE address assigned by firmware or platform. * Search parent PE according to the giv

[PATCH 01/21] ppc/eeh: move EEH initialization around

2012-06-27 Thread Gavin Shan
Currently, we have 3 phases for EEH initialization on pSeries platform using builtin functions: platform initialization, EEH device creation, and EEH subsystem enablement. All of them are done no later than ppc_md.setup_arch. That means that the slab/slub isn't ready yet, so we have to allocate mem

Re: [PATCH V2 00/16] powerpc/eeh: PE support

2012-06-27 Thread Gavin Shan
I'm sorry that the subject should be: [PATCH V2 00/21] powerpc/eeh: PE support I forgot got change that when pulling it from V1 :-) Thanks, Gavin >The series of patches address explicit PE support as well as probe type >support. For explicit PE support, struct eeh_pe has been introduced. >While

[PATCH 04/21] ppc/eeh: Introduce eeh_pe struct

2012-06-27 Thread Gavin Shan
As defined in PAPR 2.4, Partitionable Endpoint (PE) is an I/O subtree that can be treated as a unit for the purposes of partitioning and error recovery. Therefore, eeh core should be aware of PE. With eeh_pe struct, we can support PE explicitly. Further more, it makes all the staff as data centrali

[PATCH 08/21] ppc/eeh: create PEs duing EEH initialization

2012-06-27 Thread Gavin Shan
The patch creates PEs and associated the newly created PEs with it parent/silbing as well as EEH devices. It would become more straight to trace EEH errors and recover them accordingly. Once the EEH functionality on one PCI IOA has been enabled, we tries to create PE against it. If there's existin

[PATCH 19/21] ppc/eeh: move stats to PE

2012-06-27 Thread Gavin Shan
The patch removes the eeh related statistics for eeh device since they have been maintained by the corresponding eeh PE. Also, the flags used to trace the state of eeh device and PE have been reworked for a little bit. Signed-off-by: Gavin Shan --- arch/powerpc/include/asm/eeh.h |

[PATCH 20/21] ppc/eeh: probe mode support

2012-06-27 Thread Gavin Shan
While EEH module is installed, PCI devices is checked one by one to see if it supports eeh. That is done based on OF nodes or PCI device referred by "struct pci_dev". In order to distinguish the case, global variable "eeh_probe_mode" is introduced. The patch implements the support to eeh probe mod

[PATCH V4 1/2] PCI: pcibus address to resource converting take bus directly

2012-06-27 Thread Gavin Shan
For allocating resource under bus path, we do have dev pass along, and we could just use bus instead. Also, we'd like to make function find_pci_host_bridge() global so that some platforms (e.g. PPC) can access the pci host bridge directly. Signed-off-by: Yinghai Lu --- drivers/pci/host-bridge.c

[PATCH 14/21] ppc/eeh: device bars restore based on PE

2012-06-27 Thread Gavin Shan
The patch introduces the function to traverse the devices of the specified PE and its child PEs. Also, the restore on device bars is implemented based on the traverse function. Signed-off-by: Gavin Shan --- arch/powerpc/include/asm/eeh.h |3 + arch/powerpc/include/asm/ppc-pci.h

[PATCH 09/21] ppc/eeh: remove PE at appropriate time

2012-06-27 Thread Gavin Shan
During PCI hotplug and EEH recovery, the PE hierarchy PE might be changed due to the PCI topology changes. At later point when the PCI device is added, the PE will be created dynamically again. The patch introduces new function to remove EEH devices from the associated PE. That also can cause that

[PATCH 10/21] ppc/eeh: build EEH event based on PE

2012-06-27 Thread Gavin Shan
The original implementation builds EEH event based on EEH device. We already had dedicated struct to depict PE. It's reasonable to build EEH event based on PE. Signed-off-by: Gavin Shan --- arch/powerpc/include/asm/eeh_event.h |4 ++-- arch/powerpc/platforms/pseries/eeh_event.c | 29

[PATCH 11/21] ppc/eeh: trace EEH state based on PE

2012-06-27 Thread Gavin Shan
Since we've introduced dedicated struct to trace individual PEs, it's reasonable to trace its state through the dedicated struct instead of using "eeh_dev" any more. The patches implements the state tracing based on PE. It's notable that the PE state will be applied to the specified PE as well as

Re: [RFC PATCH 03/17] KVM: PPC64: booke: Add EPCR support in sregs

2012-06-27 Thread Scott Wood
On 06/27/2012 06:41 AM, Caraman Mihai Claudiu-B02008 wrote: >> -Original Message- >> From: Wood Scott-B07421 >> Sent: Wednesday, June 27, 2012 1:35 AM >> To: Caraman Mihai Claudiu-B02008 >> Cc: kvm-...@vger.kernel.org; k...@vger.kernel.org; linuxppc- >> d...@lists.ozlabs.org; qemu-...@nongn

Re: [PATCH 4/4] powerpc/perf: Use perf_instruction_pointer in callchains

2012-06-27 Thread Scott Wood
On 06/26/2012 10:59 PM, Anton Blanchard wrote: > > Hi Scott, > >> Won't this break core-fsl-emb, which doesn't define >> perf_instruction_pointer()? > > It links ok for me. You should get the default version: > > #ifndef perf_misc_flags > # define perf_misc_flags(regs) \ > (user

[PATCH V4 2/2] PCI: minimal alignment for bars of P2P bridges

2012-06-27 Thread Gavin Shan
On some powerpc platforms, device BARs need to be assigned to separate "segments" of the address space in order for the error isolation and HW virtualization mechanisms (EEH) to work properly. Those "segments" have a minimum size that can be fairly large (16M). In order to be able to use the generi

Re: [PATCH 3/3] serial/8250: delete WR SBC850 UART quirk handling

2012-06-27 Thread Alan Cox
> I will, once Alpha is removed from the tree. At the moment, > it still uses it. Ok I hadn't realised that. Alan ___ Linuxppc-dev mailing list Linuxppc-dev@lists.ozlabs.org https://lists.ozlabs.org/listinfo/linuxppc-dev

Re: [PATCH 3/3] serial/8250: delete WR SBC850 UART quirk handling

2012-06-27 Thread Paul Gortmaker
On 12-06-27 07:52 AM, Alan Cox wrote: > On Tue, 26 Jun 2012 15:54:29 -0400 > Paul Gortmaker wrote: > >> We've are dropping the support for the EOL SBC8560, so we can >> also delete this variant of the Alpha quirk support. >> >> Cc: Alan Cox >> Cc: Greg Kroah-Hartman >> Cc: linux-ser...@vger.ker

Re: [PATCH 3/3] serial/8250: delete WR SBC850 UART quirk handling

2012-06-27 Thread Alan Cox
On Tue, 26 Jun 2012 15:54:29 -0400 Paul Gortmaker wrote: > We've are dropping the support for the EOL SBC8560, so we can > also delete this variant of the Alpha quirk support. > > Cc: Alan Cox > Cc: Greg Kroah-Hartman > Cc: linux-ser...@vger.kernel.org > Signed-off-by: Paul Gortmaker > --- >

RE: [RFC PATCH 10/17] PowerPC: booke64: Refactor exception prolog for save/restore regs

2012-06-27 Thread Caraman Mihai Claudiu-B02008
> -Original Message- > From: Benjamin Herrenschmidt [mailto:b...@kernel.crashing.org] > Sent: Wednesday, June 27, 2012 1:13 AM > To: Caraman Mihai Claudiu-B02008 > Cc: kvm-...@vger.kernel.org; k...@vger.kernel.org; linuxppc- > d...@lists.ozlabs.org; qemu-...@nongnu.org > Subject: Re: [RFC P

Re: [PATCH v6 1/5] powerpc/85xx: implement hardware timebase sync

2012-06-27 Thread Benjamin Herrenschmidt
On Wed, 2012-06-27 at 18:21 +0800, Zhao Chenhui wrote: > > What's that CONFIG option for ? > > > > Cheers, > > Ben. > > This option is to guard the timebase sync routines. It is selected > when KEXEC or HOTPLUG_CPU is enabled on Freescale Book-E platforms. Any reason not to just make it uncondit

Re: [PATCH -v4 6/6] fault-injection: add notifier error injection testing scripts

2012-06-27 Thread Akinobu Mita
2012/6/27 Andrew Morton : > On Sat, 23 Jun 2012 23:58:22 +0900 > Akinobu Mita wrote: > >> This adds two testing scripts with notifier error injection > > Can we move these into tools/testing/selftests/, so that a "make > run_tests" runs these tests? > > Also, I don't think it's appropriate that "f

RE: [RFC PATCH 03/17] KVM: PPC64: booke: Add EPCR support in sregs

2012-06-27 Thread Caraman Mihai Claudiu-B02008
> -Original Message- > From: Wood Scott-B07421 > Sent: Wednesday, June 27, 2012 1:35 AM > To: Caraman Mihai Claudiu-B02008 > Cc: kvm-...@vger.kernel.org; k...@vger.kernel.org; linuxppc- > d...@lists.ozlabs.org; qemu-...@nongnu.org > Subject: Re: [RFC PATCH 03/17] KVM: PPC64: booke: Add EPCR

Re: [PATCH v6 1/5] powerpc/85xx: implement hardware timebase sync

2012-06-27 Thread Zhao Chenhui
On Wed, Jun 27, 2012 at 08:10:34AM +1000, Benjamin Herrenschmidt wrote: > On Tue, 2012-06-26 at 18:25 +0800, Zhao Chenhui wrote: > > Do hardware timebase sync. Firstly, stop all timebases, and transfer > > the timebase value of the boot core to the other core. Finally, > > start all timebases. > >

Re: [PATCH v6 1/5] powerpc/85xx: implement hardware timebase sync

2012-06-27 Thread Zhao Chenhui
On Tue, Jun 26, 2012 at 09:03:42AM -0500, Kumar Gala wrote: > > On Jun 26, 2012, at 5:25 AM, Zhao Chenhui wrote: > > > Do hardware timebase sync. Firstly, stop all timebases, and transfer > > the timebase value of the boot core to the other core. Finally, > > start all timebases. > > > > Only ap

Re: [RFC PATCH 2/12] memory-hogplug : check memory offline in offline_pages

2012-06-27 Thread Wen Congyang
At 06/27/2012 01:44 PM, Yasuaki Ishimatsu Wrote: > When offline_pages() is called to offlined memory, the function fails since > all memory has been offlined. In this case, the function should succeed. > The patch adds the check function into offline_pages(). You miss such case: some pages are onl

Re: [RFC PATCH 1/12] memory-hotplug : rename remove_memory to offline_memory

2012-06-27 Thread Wen Congyang
At 06/27/2012 03:14 PM, Wen Congyang Wrote: > At 06/27/2012 01:42 PM, Yasuaki Ishimatsu Wrote: >> remove_memory() does not remove memory but just offlines memory. The patch >> changes name of it to offline_memory(). > > There are 3 functions in the kernel: > 1. add_memory() > 2. online_pages() > 3

[PATCH SLUB 1/2 v2] duplicate the cache name in saved_alias list

2012-06-27 Thread Li Zhong
SLUB duplicates the cache name string passed into kmem_cache_create(). However if the cache could be merged to others during early boot, the name pointer is saved in saved_alias list, and the string needs to be kept valid before slab_sysfs_init() is finished. With this patch, the name string (if km

[PATCH] powerpc/pseries: fix software invalidate TCE

2012-06-27 Thread Michael Neuling
The following added support for powernv but broke pseries/BML: 1f1616e powerpc/powernv: Add TCE SW invalidation support TCE_PCI_SW_INVAL was split into FREE and CREATE flags but the tests in the pseries code were not updated to reflect this. Signed-off-by: Michael Neuling cc: sta...@kernel.org

Re: [PATCH 1/2] drivers: crypto: move nx build to driver/crypto Makefile

2012-06-27 Thread Herbert Xu
On Wed, Jun 13, 2012 at 01:22:42PM -0500, Seth Jennings wrote: > When the nx driver was pulled, the Makefile that actually > builds it is arch/powerpc/Makefile. This is unnatural. > > This patch moves the line that builds the nx driver from > arch/powerpc/Makefile to drivers/crypto/Makefile where

Re: [RFC PATCH 1/12] memory-hotplug : rename remove_memory to offline_memory

2012-06-27 Thread Wen Congyang
At 06/27/2012 01:42 PM, Yasuaki Ishimatsu Wrote: > remove_memory() does not remove memory but just offlines memory. The patch > changes name of it to offline_memory(). There are 3 functions in the kernel: 1. add_memory() 2. online_pages() 3. remove_memory() So I think offline_pages() is better th

Re: Build regressions/improvements in v3.5-rc4

2012-06-27 Thread Michael Ellerman
On Tue, 2012-06-26 at 22:06 +0200, Geert Uytterhoeven wrote: > On Tue, Jun 26, 2012 at 9:59 PM, Geert Uytterhoeven > wrote: > > JFYI, when comparing v3.5-rc4 to v3.5-rc3[3], the summaries are: > > - build errors: +11/-219 > powerpc-randconfig > > + include/asm-generic/pgtable.h: error: implic

Re: [PATCH] powerpc: fix whitespace in eeh

2012-06-27 Thread Gavin Shan
>Signed-off-by: Michael Neuling > Acked-by: Gavin Shan >diff --git a/arch/powerpc/platforms/pseries/eeh_pseries.c >b/arch/powerpc/platforms/pseries/eeh_pseries.c >index 8752f79..c33360ec 100644 >--- a/arch/powerpc/platforms/pseries/eeh_pseries.c >+++ b/arch/powerpc/platforms/pseries/eeh_pserie

[RFC PATCH 12/12] memory-hotplug : remove sysfs file of node

2012-06-27 Thread Yasuaki Ishimatsu
The patch adds node_set_offline() and unregister_one_node() to remove_memory() for removing sysfs file of node. CC: Len Brown CC: Benjamin Herrenschmidt CC: Paul Mackerras CC: Christoph Lameter Cc: Minchan Kim CC: Andrew Morton CC: KOSAKI Motohiro CC: Wen Congyang Signed-off-by: Yasuaki Is

[RFC PATCH 11/12] memory-hotplug : add node_device_release

2012-06-27 Thread Yasuaki Ishimatsu
When calling unregister_node(), the function shows following message at device_release(). Device 'node2' does not have a release() function, it is broken and must be fixed. So the patch implements node_device_release() CC: Len Brown CC: Benjamin Herrenschmidt CC: Paul Mackerras CC: Christoph

[RFC PATCH 10/12] memory-hotplug : free memmap of sparse-vmemmap

2012-06-27 Thread Yasuaki Ishimatsu
I don't think that all pages of virtual mapping in removed memory can be freed, since page which type is MIX_SECTION_INFO is difficult to free. So, the patch only frees page which type is SECTION_INFO at first. CC: Len Brown CC: Benjamin Herrenschmidt CC: Paul Mackerras CC: Christoph Lameter C

[RFC PATCH 9/12] memory-hotplug : implement register_page_bootmem_info_section of sparse-vmemmap

2012-06-27 Thread Yasuaki Ishimatsu
For removing memmap region of sparse-vmemmap which is allocated bootmem, memmap region of sparse-vmemmap needs to be registered by get_page_bootmem(). So the patch searches pages of virtual mapping and registers the pages by get_page_bootmem(). CC: Len Brown CC: Benjamin Herrenschmidt CC: Paul M

[RFC PATCH 8/12] memory-hotplug : move register_page_bootmem_info_node and put_page_bootmem for sparse-vmemmap

2012-06-27 Thread Yasuaki Ishimatsu
For implementing register_page_bootmem_info_node of sparse-vmemmap, register_page_bootmem_info_node and put_page_bootmem are moved to memory_hotplug.c CC: Len Brown CC: Benjamin Herrenschmidt CC: Paul Mackerras CC: Christoph Lameter Cc: Minchan Kim CC: Andrew Morton CC: KOSAKI Motohiro CC:

[RFC PATCH 7/12] memory-hotplug : check page type in get_page_bootmem

2012-06-27 Thread Yasuaki Ishimatsu
There is a possibility that get_page_bootmem() is called to the same page many times. So when get_page_bootmem is called to the same page, the function only increments page->_count. CC: Len Brown CC: Benjamin Herrenschmidt CC: Paul Mackerras CC: Christoph Lameter Cc: Minchan Kim CC: Andrew Mo

[RFC PATCH 6/12] memory-hotplug : remove_memory calls __remove_pages

2012-06-27 Thread Yasuaki Ishimatsu
The patch adds __remove_pages() to remove_memory(). Then the range of phys_start_pfn argument and nr_pages argument in __remove_pagse() may have different zone. So zone argument is removed from __remove_pages() and __remove_pages() caluculates zone in each section. When CONFIG_SPARSEMEM_VMEMMAP is

[RFC PATCH 2/12] memory-hogplug : check memory offline in offline_pages

2012-06-27 Thread Yasuaki Ishimatsu
When offline_pages() is called to offlined memory, the function fails since all memory has been offlined. In this case, the function should succeed. The patch adds the check function into offline_pages(). CC: Len Brown CC: Benjamin Herrenschmidt CC: Paul Mackerras CC: Christoph Lameter Cc: Min

[RFC PATCH 1/12] memory-hotplug : rename remove_memory to offline_memory

2012-06-27 Thread Yasuaki Ishimatsu
remove_memory() does not remove memory but just offlines memory. The patch changes name of it to offline_memory(). CC: Len Brown CC: Benjamin Herrenschmidt CC: Paul Mackerras CC: Christoph Lameter Cc: Minchan Kim CC: Andrew Morton CC: KOSAKI Motohiro CC: Wen Congyang Signed-off-by: Yasuaki

[RFC PATCH 0/12] memory-hotplug : hot-remove physical memory

2012-06-27 Thread Yasuaki Ishimatsu
This patch series aims to support physical memory hot-remove. [RFC PATCH 1/12] memory-hotplug : rename remove_memory to offline_memory [RFC PATCH 2/12] memory-hogplug : check memory offline in offline_pages [RFC PATCH 3/12] memory-hotplug : add physical memory hotplug code to acpi_memory_de

[RFC PATCH 5/12] memory-hotplug : does not release memory region in PAGES_PER_SECTION chunks

2012-06-27 Thread Yasuaki Ishimatsu
Since applying a patch(de7f0cba96786c), release_mem_region() has been changed as called in PAGES_PER_SECTION chunks because register_memory_resource() is called in PAGES_PER_SECTION chunks by add_memory(). But it seems firmware dependency. If CRS are written in the PAGES_PER_SECTION chunks in ACPI

[RFC PATCH 4/12] memory-hotplug : remove /sys/firmware/memmap/X sysfs

2012-06-27 Thread Yasuaki Ishimatsu
When (hot)adding memory into system, /sys/firmware/memmap/X/{end, start, type} sysfs files are created. But there is no code to remove these files. The patch implements the function to remove them. Note : The code does not free firmware_map_entry since there is no way to free memory which i

[RFC PATCH 3/12] memory-hotplug : add physical memory hotplug code to acpi_memory_device_remove

2012-06-27 Thread Yasuaki Ishimatsu
acpi_memory_device_remove() has been prepared to remove physical memory. But, the function only frees acpi_memory_device currentlry. The patch adds following functions into acpi_memory_device_remove(): - offline memory - remove physical memory (only return -EBUSY) - free acpi_memory_device