[PATCH v3 06/12] memory-hotplug: unregister memory section on SPARSEMEM_VMEMMAP

2012-11-01 Thread Wen Congyang
From: Yasuaki Ishimatsu isimatu.yasu...@jp.fujitsu.com Currently __remove_section for SPARSEMEM_VMEMMAP does nothing. But even if we use SPARSEMEM_VMEMMAP, we can unregister the memory_section. So the patch add unregister_memory_section() into __remove_section(). CC: David Rientjes

[PATCH v3 03/12] memory-hotplug: remove redundant codes

2012-11-01 Thread Wen Congyang
offlining memory blocks and checking whether memory blocks are offlined are very similar. This patch introduces a new function to remove redundant codes. CC: David Rientjes rient...@google.com CC: Jiang Liu liu...@gmail.com CC: Len Brown len.br...@intel.com CC: Christoph Lameter c...@linux.com

[PATCH v3 01/12] memory-hotplug: try to offline the memory twice to avoid dependence

2012-11-01 Thread Wen Congyang
memory can't be offlined when CONFIG_MEMCG is selected. For example: there is a memory device on node 1. The address range is [1G, 1.5G). You will find 4 new directories memory8, memory9, memory10, and memory11 under the directory /sys/devices/system/memory/. If CONFIG_MEMCG is selected, we will

[PATCH v3 04/12] memory-hotplug: remove /sys/firmware/memmap/X sysfs

2012-11-01 Thread Wen Congyang
From: Yasuaki Ishimatsu isimatu.yasu...@jp.fujitsu.com 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

[PATCH v3 00/12] memory-hotplug: hot-remove physical memory

2012-11-01 Thread Wen Congyang
The patch-set was divided from following thread's patch-set. https://lkml.org/lkml/2012/9/5/201 The last version of this patchset: https://lkml.org/lkml/2012/10/23/213 If you want to know the reason, please read following thread. https://lkml.org/lkml/2012/10/2/83 The patch-set has

[PATCH v3 05/12] memory-hotplug: introduce new function arch_remove_memory() for removing page table depends on architecture

2012-11-01 Thread Wen Congyang
For removing memory, we need to remove page table. But it depends on architecture. So the patch introduce arch_remove_memory() for removing page table. Now it only calls __remove_pages(). Note: __remove_pages() for some archtecuture is not implemented (I don't know how to implement it for

[PATCH v3 02/12] memory-hotplug: check whether all memory blocks are offlined or not when removing memory

2012-11-01 Thread Wen Congyang
From: Yasuaki Ishimatsu isimatu.yasu...@jp.fujitsu.com We remove the memory like this: 1. lock memory hotplug 2. offline a memory block 3. unlock memory hotplug 4. repeat 1-3 to offline all memory blocks 5. lock memory hotplug 6. remove memory(TODO) 7. unlock memory hotplug All memory blocks

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

2012-11-01 Thread Wen Congyang
This patch introduces a new function try_offline_node() to remove sysfs file of node when all memory sections of this node are removed. If some memory sections of this node are not removed, this function does nothing. CC: David Rientjes rient...@google.com CC: Jiang Liu liu...@gmail.com CC: Len

[PATCH v3 09/12] memory-hotplug: remove page table of x86_64 architecture

2012-11-01 Thread Wen Congyang
For hot removing memory, we sholud remove page table about the memory. So the patch searches a page table about the removed memory, and clear page table. CC: David Rientjes rient...@google.com CC: Jiang Liu liu...@gmail.com CC: Len Brown len.br...@intel.com CC: Christoph Lameter c...@linux.com

[PATCH v3 07/12] memory-hotplug: implement register_page_bootmem_info_section of sparse-vmemmap

2012-11-01 Thread Wen Congyang
From: Yasuaki Ishimatsu isimatu.yasu...@jp.fujitsu.com 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

[PATCH v3 08/12] memory-hotplug: remove memmap of sparse-vmemmap

2012-11-01 Thread Wen Congyang
From: Yasuaki Ishimatsu isimatu.yasu...@jp.fujitsu.com All pages of virtual mapping in removed memory cannot be freed, since some pages used as PGD/PUD includes not only removed memory but also other memory. So the patch checks whether page can be freed or not. How to check whether page can be

APM/AMCC Kilauea board broken with 3.5+ kernel

2012-11-01 Thread Robert Berger
Hi, Please correct me if I'm wrong, but I thought that one of the reasons to bring a board to mainline is that if someone breaks it he/she also fixes it (at least this is what I tell to the attendees of my trainings). ... but maybe that's not always the case ... Before the commit[1] it worked,

[PATCH v3 12/12] memory-hotplug: free node_data when a node is offlined

2012-11-01 Thread Wen Congyang
We call hotadd_new_pgdat() to allocate memory to store node_data. So we should free it when removing a node. CC: David Rientjes rient...@google.com CC: Jiang Liu liu...@gmail.com CC: Len Brown len.br...@intel.com CC: Benjamin Herrenschmidt b...@kernel.crashing.org CC: Paul Mackerras

[PATCH v3 10/12] memory-hotplug: memory_hotplug: clear zone when removing the memory

2012-11-01 Thread Wen Congyang
From: Yasuaki Ishimatsu isimatu.yasu...@jp.fujitsu.com When a memory is added, we update zone's and pgdat's start_pfn and spanned_pages in the function __add_zone(). So we should revert them when the memory is removed. The patch adds a new function __remove_zone() to do this. CC: David Rientjes

Re: [linuxppc-release] [PATCH] powerpc/fsl-pci: Add PCI controller ATMU PM support

2012-11-01 Thread Timur Tabi
Jia Hongtao wrote: +#ifdef CONFIG_SUSPEND +static int fsl_pci_resume(struct platform_device *pdev) +{ + struct pci_controller *hose; + struct resource pci_rsrc; + + hose = pci_find_hose_for_OF_device(pdev-dev.of_node); + of_address_to_resource(pdev-dev.of_node, 0,

Re: Deprecating reserve-map in favor of properties

2012-11-01 Thread Grant Likely
On Fri, Sep 21, 2012 at 12:10 AM, Benjamin Herrenschmidt b...@kernel.crashing.org wrote: Hi folks ! The reserve map is, imho, my biggest mistake when coming up with the FDT format. The main problem is that it doesn't survive the transition via a real Open Firmware interface. There is no

Re: Deprecating reserve-map in favor of properties

2012-11-01 Thread Benjamin Herrenschmidt
On Thu, 2012-11-01 at 15:21 +0100, Grant Likely wrote: I think this makes sense. Cyril and I are just talking about what he needs. He wants to set aside per-device reserved regions and would like to have the ability to reference a particular reserved region from a device node, probably with a

[PATCH 1/2] powerpc: Move most of setup.h out of uapi

2012-11-01 Thread Anton Blanchard
Most of setup.h should not be exported to userspace, so move it back. All we are left with is the asm-generic include to pick up the COMMAND_LINE_SIZE define. Signed-off-by: Anton Blanchard an...@samba.org --- Index: b/arch/powerpc/include/asm/setup.h

[PATCH 2/2] powerpc: Remove stale function prototypes from setup.h

2012-11-01 Thread Anton Blanchard
I noticed a couple of function prototypes for functions that no longer exist. Remove them. Signed-off-by: Anton Blanchard an...@samba.org --- Index: b/arch/powerpc/include/asm/setup.h === --- a/arch/powerpc/include/asm/setup.h +++

Re: [PATCH 0/6] powerpc: SMT priority (PPR) save and restore

2012-11-01 Thread Haren Myneni
On 10/31/2012 05:44 PM, Michael Neuling wrote: Haren Myneni ha...@linux.vnet.ibm.com wrote: [PATCH 0/6] powerpc: SMT priority (PPR) save and restore On P7 systems, users can define SMT priority levels 2,3 and 4 for processes so that some can run higher priority than the other ones. In the

Re: [PATCH] powerpc: add finit_module syscall.

2012-11-01 Thread Benjamin Herrenschmidt
On Thu, 2012-11-01 at 11:28 +1030, Rusty Russell wrote: (This is just for Acks: this won't work without the actual syscall patches, sitting in my tree for -next at the moment). Signed-off-by: Rusty Russell ru...@rustcorp.com.au Acked-by: Benjamin Herrenschmidt b...@kernel.crashing.org ---

[PATCH] powerpc: Fix typos in Freescale copyright claims

2012-11-01 Thread Li Yang
There are many cases that Semiconductor is misspelled. The patch fix these typos. Signed-off-by: Li Yang le...@freescale.com --- arch/powerpc/include/asm/dbell.h |2 +- arch/powerpc/include/asm/fsl_gtm.h|2 +- arch/powerpc/include/asm/immap_qe.h |2 +-