Re: [PATCH V3 2/6] crypto/nx: Create nx842_configure_crb function

2017-08-03 Thread Herbert Xu
On Fri, Jul 21, 2017 at 09:57:39PM -0700, Haren Myneni wrote: > > Configure CRB is moved to nx842_configure_crb() so that it can > be used for icswx and VAS exec functions. VAS function will be > added later with P9 support. > > Signed-off-by: Haren Myneni Your patch does not

Re: [PATCH] powerpc/mm: Invalidate partition table cache on host proc tbl base update

2017-08-03 Thread Michael Ellerman
Suraj Jitindar Singh writes: > The host process table base is stored in the partition table by calling > the function native_register_process_table(). Currently this just sets > the entry in memory and is missing a proceeding cache invalidation > instruction. Any update

Re: [PATCH] powerpc/xive: fix the fuzz value in xive_pick_irq_target()

2017-08-03 Thread Benjamin Herrenschmidt
On Thu, 2017-08-03 at 09:45 +0200, Cédric Le Goater wrote: > On 08/02/2017 11:57 PM, Benjamin Herrenschmidt wrote: > > On Wed, 2017-08-02 at 18:43 +0200, Cédric Le Goater wrote: > > > If xive_find_target_in_mask() fails to find a cpu, the fuzz value used > > > in xive_pick_irq_target() is

Re: [PATCH v3 0/5] powerpc/mm: Fix kernel protection and implement STRICT_KERNEL_RWX on PPC32

2017-08-03 Thread Balbir Singh
On Wed, Aug 2, 2017 at 11:50 PM, Christophe Leroy wrote: > This patch set implements STRICT_KERNEL_RWX on Powerpc32 > after fixing a few issues related to kernel code page protection. > > At the end we take the opportunity to get rid of some unneccessary/outdated > fixmap

Re: [PATCH] powerpc/xive: fix the fuzz value in xive_pick_irq_target()

2017-08-03 Thread Cédric Le Goater
On 08/02/2017 11:57 PM, Benjamin Herrenschmidt wrote: > On Wed, 2017-08-02 at 18:43 +0200, Cédric Le Goater wrote: >> If xive_find_target_in_mask() fails to find a cpu, the fuzz value used >> in xive_pick_irq_target() is decremented and reused in the last >> returning call to

Re: [PATCH v3 2/3] cxl: Mark context requiring global TLBIs

2017-08-03 Thread Balbir Singh
On Thu, Aug 3, 2017 at 6:29 AM, Frederic Barrat wrote: > The PSL and XSL need to see all TLBIs pertinent to the memory contexts > used on the adapter. For the hash memory model, it is done by making > all TLBIs global as soon as the cxl driver is in use. For radix, we

Re: [PATCH v3 1/3] powerpc/mm: Add marker for contexts requiring global TLB invalidations

2017-08-03 Thread Balbir Singh
On Thu, Aug 3, 2017 at 6:29 AM, Frederic Barrat wrote: > Introduce a new 'flags' attribute per context and define its first bit > to be a marker requiring all TLBIs for that context to be broadcasted > globally. Once that marker is set on a context, it cannot be

Re: [PATCH] powerpc/mm: Invalidate partition table cache on host proc tbl base update

2017-08-03 Thread Benjamin Herrenschmidt
On Thu, 2017-08-03 at 16:30 +1000, Michael Ellerman wrote: > Suraj Jitindar Singh writes: > > > The host process table base is stored in the partition table by calling > > the function native_register_process_table(). Currently this just sets > > the entry in memory and

Re: [PATCH V3 2/6] crypto/nx: Create nx842_configure_crb function

2017-08-03 Thread Michael Ellerman
Herbert Xu writes: > On Fri, Jul 21, 2017 at 09:57:39PM -0700, Haren Myneni wrote: >> >> Configure CRB is moved to nx842_configure_crb() so that it can >> be used for icswx and VAS exec functions. VAS function will be >> added later with P9 support. >> >>

Re: POWER9 PMU stops after idle workaround

2017-08-03 Thread Michael Ellerman
On Thu, 2017-07-20 at 01:53:22 UTC, Nicholas Piggin wrote: > POWER9 DD2 PMU can stop after a state-loss idle in some conditions. > > A solution is to set then clear MMCRA[60] after wake from state-loss > idle. > > Signed-off-by: Nicholas Piggin > Acked-by: Madhavan Srinivasan

Re: powerpc/64: Fix __check_irq_replay missing decrementer interrupt

2017-08-03 Thread Michael Ellerman
On Tue, 2017-08-01 at 13:59:28 UTC, Nicholas Piggin wrote: > If the decrementer wraps and de-asserts the decrementer exception while > hard-disabled, __check_irq_replay has a test to notice the wrap when > interrupts are re-enabled. > > The decrementer check must be done when clearing the

Re: powerpc/64s: watchdog fix stack setup

2017-08-03 Thread Michael Ellerman
On Sat, 2017-07-29 at 12:50:27 UTC, Nicholas Piggin wrote: > The watchdog soft-NMI exception stack setup loads a stack pointer > twice, which is an obvious error. It ends up using the system reset > interrupt (true-NMI) stack, which is also a bug because the watchdog > could be preempted by a

[PATCH 1/4] powerpc/prom: avoid endian conversions for linux, memory-limit node

2017-08-03 Thread Hari Bathini
As linux,memory-limit node is set and also later used by the kernel, avoid endian conversions for this property. Fixes: 493adffcb43f ("powerpc: Make prom_init.c endian safe") Cc: sta...@vger.kernel.org # 3.12+ Cc: Anton Blanchard Cc: Benjamin Herrenschmidt

[PATCH 3/4] powerpc/prom: fix early parsing of 'mem=' parameter

2017-08-03 Thread Hari Bathini
Early cmdline parser looks for "mem=" substring in the cmdline string but it could also succeed when cmdline string contains parameters like 'fadump_reserve_mem=' or such leading to undesired results. Add support to skip proceeding in such case. Fixes: cf68787b68a2 ("powerpc/prom_init: Evaluate

[PATCH 4/4] powerpc/prom: fix early parsing of 'disable_radix' parameter

2017-08-03 Thread Hari Bathini
Early cmdline parser looks for "disable_radix" substring in the cmdline string but it could also succeed when cmdline string contains parameters like 'x_disable_radix' or disable_radix_type=' or such causing undesired actions. Add support to skip proceeding in such cases. Fixes: 014d02cbf16b

[PATCH 2/4] powerpc/prom: fix early parsing of parameters

2017-08-03 Thread Hari Bathini
Parameters 'mem=', 'iommu=' and the like, which affect the iommu are parsed early in the boot process. This parser looks for a parameter substring like 'iommu=' in the cmdline string but it could also succeed when cmdline string contains parameters like 'x_iommu=' or such leading to undesired

Re: [PATCH] powerpc/xive: fix the fuzz value in xive_pick_irq_target()

2017-08-03 Thread Michael Ellerman
Benjamin Herrenschmidt writes: > On Thu, 2017-08-03 at 09:45 +0200, Cédric Le Goater wrote: >> On 08/02/2017 11:57 PM, Benjamin Herrenschmidt wrote: >> > On Wed, 2017-08-02 at 18:43 +0200, Cédric Le Goater wrote: >> > > If xive_find_target_in_mask() fails to find a cpu,

Re: [PATCH V3 2/6] crypto/nx: Create nx842_configure_crb function

2017-08-03 Thread Herbert Xu
On Thu, Aug 03, 2017 at 07:53:16PM +1000, Michael Ellerman wrote: > Herbert Xu writes: > > > On Fri, Jul 21, 2017 at 09:57:39PM -0700, Haren Myneni wrote: > >> > >> Configure CRB is moved to nx842_configure_crb() so that it can > >> be used for icswx and VAS exec

Re: mpc832x_rdb: fix of_irq_to_resource() error check

2017-08-03 Thread Michael Ellerman
On Sat, 2017-07-29 at 19:52:09 UTC, Sergei Shtylyov wrote: > of_irq_to_resource() has recently been fixed to return negative error #'s > along with 0 in case of failure, however the Freescale MPC832x RDB board > code still only regards 0 as as failure indication -- fix it up. > > Fixes:

Re: [PATCH v3 7/7] ima: Support module-style appended signatures for appraisal

2017-08-03 Thread Mimi Zohar
On Wed, 2017-08-02 at 18:52 -0400, Mimi Zohar wrote: > On Wed, 2017-08-02 at 14:42 -0300, Thiago Jung Bauermann wrote: > > Mimi Zohar writes: > > >> @@ -229,8 +251,24 @@ int ima_appraise_measurement(enum ima_hooks func, > > >> goto out; > > >>

Re: [PATCH] powerpc/xive: fix the fuzz value in xive_pick_irq_target()

2017-08-03 Thread Cédric Le Goater
On 08/03/2017 01:52 PM, Benjamin Herrenschmidt wrote: > On Thu, 2017-08-03 at 19:52 +1000, Michael Ellerman wrote: >> What if num is 0? >> >> Which it would be in the fallback case, if the affinity mask is empty, >> AFAICS. > > How can the mask be empty though ? But yes, as I noted there is a >

Re: [PATCH v9 14/14] powerpc: rewrite local_t using soft_irq

2017-08-03 Thread Nicholas Piggin
On Thu, 3 Aug 2017 09:19:18 +0530 Madhavan Srinivasan wrote: > @@ -14,6 +17,202 @@ typedef struct > #define local_read(l)atomic_long_read(&(l)->a) > #define local_set(l,i) atomic_long_set(&(l)->a, (i)) > > +#ifdef CONFIG_PPC64 > + > +static __inline__

[PATCH 0/4] axonram: Adjustments for axon_ram_probe()

2017-08-03 Thread SF Markus Elfring
From: Markus Elfring Date: Thu, 3 Aug 2017 21:02:02 +0200 A few update suggestions were taken into account from static source code analysis. Markus Elfring (4): Delete an error message for a failed memory allocation Improve a size determination in

[PATCH 3/4] axonram: Return directly after a failed kzalloc() in axon_ram_probe()

2017-08-03 Thread SF Markus Elfring
From: Markus Elfring Date: Thu, 3 Aug 2017 20:23:57 +0200 * Return directly after a call of the function "kzalloc" failed at the beginning. * Delete a repeated check for the local variable "bank" which became unnecessary with this refactoring. Signed-off-by:

[PATCH 2/4] axonram: Improve a size determination in axon_ram_probe()

2017-08-03 Thread SF Markus Elfring
From: Markus Elfring Date: Thu, 3 Aug 2017 20:00:16 +0200 Replace the specification of a data structure by a pointer dereference as the parameter for the operator "sizeof" to make the corresponding size determination a bit safer according to the Linux coding style

[v5 06/15] sparc64: simplify vmemmap_populate

2017-08-03 Thread Pavel Tatashin
Remove duplicating code by using common functions vmemmap_pud_populate and vmemmap_pgd_populate. Signed-off-by: Pavel Tatashin Reviewed-by: Steven Sistare Reviewed-by: Daniel Jordan Reviewed-by: Bob Picco

[v5 02/15] x86/mm: setting fields in deferred pages

2017-08-03 Thread Pavel Tatashin
Without deferred struct page feature (CONFIG_DEFERRED_STRUCT_PAGE_INIT), flags and other fields in "struct page"es are never changed prior to first initializing struct pages by going through __init_single_page(). With deferred struct page feature enabled there is a case where we set some fields

[v5 08/15] mm: zero struct pages during initialization

2017-08-03 Thread Pavel Tatashin
Add struct page zeroing as a part of initialization of other fields in __init_single_page(). Signed-off-by: Pavel Tatashin Reviewed-by: Steven Sistare Reviewed-by: Daniel Jordan Reviewed-by: Bob Picco

Re: [PATCH 1/3] PCI: dwc: Handle host_init failures

2017-08-03 Thread Bjorn Helgaas
On Sat, Jul 15, 2017 at 11:39:45PM -0700, Bjorn Andersson wrote: > In several dwc based drivers host_init can fail, so make sure to > propagate and handle this to avoid continuing operation of a driver or > hardware in an invalid state. > > Signed-off-by: Bjorn Andersson

[v5 05/15] mm: don't accessed uninitialized struct pages

2017-08-03 Thread Pavel Tatashin
In deferred_init_memmap() where all deferred struct pages are initialized we have a check like this: if (page->flags) { VM_BUG_ON(page_zone(page) != zone); goto free_range; } This way we are checking if the current deferred page has already been initialized. It

[PATCH 1/4] axonram: Delete an error message for a failed memory allocation in axon_ram_probe()

2017-08-03 Thread SF Markus Elfring
From: Markus Elfring Date: Thu, 3 Aug 2017 19:49:18 +0200 Omit an extra message for a memory allocation failure in this function. This issue was detected by using the Coccinelle software. Link:

[PATCH 4/4] axonram: Delete an unnecessary variable initialisation in axon_ram_probe()

2017-08-03 Thread SF Markus Elfring
From: Markus Elfring Date: Thu, 3 Aug 2017 20:34:00 +0200 The local variable "rc" will eventually be set only to an error code. Thus omit the explicit initialisation at the beginning. Signed-off-by: Markus Elfring ---

Re: [PATCH v3 7/7] ima: Support module-style appended signatures for appraisal

2017-08-03 Thread Thiago Jung Bauermann
Mimi Zohar writes: > On Wed, 2017-08-02 at 18:52 -0400, Mimi Zohar wrote: >> On Wed, 2017-08-02 at 14:42 -0300, Thiago Jung Bauermann wrote: >> > Mimi Zohar writes: > >> > >> @@ -229,8 +251,24 @@ int ima_appraise_measurement(enum ima_hooks

[v5 10/15] x86/kasan: explicitly zero kasan shadow memory

2017-08-03 Thread Pavel Tatashin
To optimize the performance of struct page initialization, vmemmap_populate() will no longer zero memory. We must explicitly zero the memory that is allocated by vmemmap_populate() for kasan, as this memory does not go through struct page initialization path. Signed-off-by: Pavel Tatashin

[v5 14/15] mm: optimize early system hash allocations

2017-08-03 Thread Pavel Tatashin
Clients can call alloc_large_system_hash() with flag: HASH_ZERO to specify that memory that was allocated for system hash needs to be zeroed, otherwise the memory does not need to be zeroed, and client will initialize it. If memory does not need to be zero'd, call the new

Re: [PATCH] powerpc/mm: Invalidate partition table cache on host proc tbl base update

2017-08-03 Thread Benjamin Herrenschmidt
On Fri, 2017-08-04 at 11:02 +1000, Suraj Jitindar Singh wrote: > > I guess there's the possibility of: > [x] randomly crash > > This is required to run a powernv kernel as a guest because we need to > know when it's updated its process table location. You mean in qemu full emu ? powernv kernels

Re: [v5 2/2] raid6/altivec: Add vpermxor implementation for raid6 Q syndrome

2017-08-03 Thread Matt Brown
On Wed, Aug 2, 2017 at 10:20 AM, Daniel Axtens wrote: > Oh, one final thing - I just realised there's a .gitignore file in > lib/raid6/.gitignore that needs to be updated to include the vpermxor > generated files. That should be part of this patch. > Oh, I managed to miss that!

Re: [PATCH] powerpc/mm: Invalidate partition table cache on host proc tbl base update

2017-08-03 Thread Michael Ellerman
Suraj Jitindar Singh writes: > On Thu, 2017-08-03 at 17:35 +1000, Benjamin Herrenschmidt wrote: >> On Thu, 2017-08-03 at 16:30 +1000, Michael Ellerman wrote: >> > Suraj Jitindar Singh writes: >> > >> > > The host process table base is stored

[v6 2/2] lib/raid6: Build proper raid6test files on powerpc

2017-08-03 Thread Matt Brown
Previously the raid6 test Makefile did not build the POWER specific files (altivec and vpermxor). This patch fixes the bug, so that all appropriate files for powerpc are built. This patch also fixes the missing and mismatched ifdef statements to allow the altivec.uc file to be built correctly.

Re: [PATCH v1 1/3] arch/powerpc/set_memory: Implement set_memory_xx routines

2017-08-03 Thread Balbir Singh
On Fri, Aug 4, 2017 at 1:38 PM, Aneesh Kumar K.V wrote: > Balbir Singh writes: > >> On Wed, Aug 2, 2017 at 8:09 PM, Aneesh Kumar K.V >> wrote: >>> Balbir Singh writes: >>> Add

Re: [PATCH 1/4] powerpc/prom: avoid endian conversions for linux, memory-limit node

2017-08-03 Thread Michael Ellerman
Hari Bathini writes: > As linux,memory-limit node is set and also later used by the kernel, > avoid endian conversions for this property. > > Fixes: 493adffcb43f ("powerpc: Make prom_init.c endian safe") > Cc: sta...@vger.kernel.org # 3.12+ > Cc: Anton Blanchard

[v5 00/15] complete deferred page initialization

2017-08-03 Thread Pavel Tatashin
Changelog: v5 - v4 - Fixed build issues reported by kbuild on various configurations v4 - v3 - Rewrote code to zero sturct pages in __init_single_page() as suggested by Michal Hocko - Added code to handle issues related to accessing struct page memory before they are initialized. v3 - v2 -

[v5 03/15] sparc64/mm: setting fields in deferred pages

2017-08-03 Thread Pavel Tatashin
Without deferred struct page feature (CONFIG_DEFERRED_STRUCT_PAGE_INIT), flags and other fields in "struct page"es are never changed prior to first initializing struct pages by going through __init_single_page(). With deferred struct page feature enabled there is a case where we set some fields

Re: [PATCH 1/4] powerpc/prom: avoid endian conversions for linux, memory-limit node

2017-08-03 Thread Benjamin Herrenschmidt
On Thu, 2017-08-03 at 14:54 +0530, Hari Bathini wrote: > As linux,memory-limit node is set and also later used by the kernel, > avoid endian conversions for this property. > > Fixes: 493adffcb43f ("powerpc: Make prom_init.c endian safe") > Cc: sta...@vger.kernel.org # 3.12+ > Cc: Anton Blanchard

Re: [PATCH 1/4] powerpc/prom: avoid endian conversions for linux, memory-limit node

2017-08-03 Thread Benjamin Herrenschmidt
On Fri, 2017-08-04 at 11:37 +1000, Benjamin Herrenschmidt wrote: > On Thu, 2017-08-03 at 14:54 +0530, Hari Bathini wrote: > > As linux,memory-limit node is set and also later used by the kernel, > > avoid endian conversions for this property. > > > > Fixes: 493adffcb43f ("powerpc: Make

Re: [PATCH v1 1/3] arch/powerpc/set_memory: Implement set_memory_xx routines

2017-08-03 Thread Aneesh Kumar K.V
Balbir Singh writes: > On Wed, Aug 2, 2017 at 8:09 PM, Aneesh Kumar K.V > wrote: >> Balbir Singh writes: >> >>> Add support for set_memory_xx routines. With the STRICT_KERNEL_RWX >>> feature support we got support

Re: [v5 1/2] lib/raid6: Build proper files on corresponding arch

2017-08-03 Thread Matt Brown
On Wed, Aug 2, 2017 at 12:00 PM, Michael Ellerman wrote: > Daniel Axtens writes: > >> Hi Matt, >> >>> --- a/lib/raid6/test/Makefile >>> +++ b/lib/raid6/test/Makefile >>> @@ -44,10 +44,12 @@ else ifeq ($(HAS_NEON),yes) >>> CFLAGS +=

Re: [PATCH v9 14/14] powerpc: rewrite local_t using soft_irq

2017-08-03 Thread Benjamin Herrenschmidt
On Fri, 2017-08-04 at 03:50 +1000, Nicholas Piggin wrote: > Hey, so... why are any of these implemented in asm? We should > just do them all in C, right? I looked a bit harder at code gen > and a couple of them are still emitting larx/stcx. As long as we can guarantee that the C compiler won't

[v6 1/2] raid6/altivec: Add vpermxor implementation for raid6 Q syndrome

2017-08-03 Thread Matt Brown
This patch uses the vpermxor instruction to optimise the raid6 Q syndrome. This instruction was made available with POWER8, ISA version 2.07. It allows for both vperm and vxor instructions to be done in a single instruction. This has been tested for correctness on a ppc64le vm with a basic RAID6

Re: [PATCH] powerpc/mm: Invalidate partition table cache on host proc tbl base update

2017-08-03 Thread Aneesh Kumar K.V
Suraj Jitindar Singh writes: > The host process table base is stored in the partition table by calling > the function native_register_process_table(). Currently this just sets > the entry in memory and is missing a proceeding cache invalidation > instruction. Any update

Re: [PATCH] powerpc/mm: Invalidate partition table cache on host proc tbl base update

2017-08-03 Thread Suraj Jitindar Singh
On Fri, 2017-08-04 at 11:31 +1000, Benjamin Herrenschmidt wrote: > On Fri, 2017-08-04 at 11:02 +1000, Suraj Jitindar Singh wrote: > > > > I guess there's the possibility of: > > [x] randomly crash > > > > This is required to run a powernv kernel as a guest because we need > > to > > know when

[v5 15/15] mm: debug for raw alloctor

2017-08-03 Thread Pavel Tatashin
When CONFIG_DEBUG_VM is enabled, this patch sets all the memory that is returned by memblock_virt_alloc_try_nid_raw() to ones to ensure that no places excpect zeroed memory. Signed-off-by: Pavel Tatashin Reviewed-by: Steven Sistare

[v5 04/15] mm: discard memblock data later

2017-08-03 Thread Pavel Tatashin
There is existing use after free bug when deferred struct pages are enabled: The memblock_add() allocates memory for the memory array if more than 128 entries are needed. See comment in e820__memblock_setup(): * The bootstrap memblock region count maximum is 128 entries *

Re: [v5 11/15] arm64/kasan: explicitly zero kasan shadow memory

2017-08-03 Thread Ard Biesheuvel
(+ arm64 maintainers) Hi Pavel, On 3 August 2017 at 22:23, Pavel Tatashin wrote: > To optimize the performance of struct page initialization, > vmemmap_populate() will no longer zero memory. > > We must explicitly zero the memory that is allocated by

Re: [PATCH] powerpc/mm: Invalidate partition table cache on host proc tbl base update

2017-08-03 Thread Suraj Jitindar Singh
On Thu, 2017-08-03 at 17:35 +1000, Benjamin Herrenschmidt wrote: > On Thu, 2017-08-03 at 16:30 +1000, Michael Ellerman wrote: > > Suraj Jitindar Singh writes: > > > > > The host process table base is stored in the partition table by > > > calling > > > the function

[v5 11/15] arm64/kasan: explicitly zero kasan shadow memory

2017-08-03 Thread Pavel Tatashin
To optimize the performance of struct page initialization, vmemmap_populate() will no longer zero memory. We must explicitly zero the memory that is allocated by vmemmap_populate() for kasan, as this memory does not go through struct page initialization path. Signed-off-by: Pavel Tatashin

[v5 01/15] x86/mm: reserve only exiting low pages

2017-08-03 Thread Pavel Tatashin
Struct pages are initialized by going through __init_single_page(). Since the existing physical memory in memblock is represented in memblock.memory list, struct page for every page from this list goes through __init_single_page(). The second memblock list: memblock.reserved, manages the

[v5 07/15] mm: defining memblock_virt_alloc_try_nid_raw

2017-08-03 Thread Pavel Tatashin
A new variant of memblock_virt_alloc_* allocations: memblock_virt_alloc_try_nid_raw() - Does not zero the allocated memory - Does not panic if request cannot be satisfied Signed-off-by: Pavel Tatashin Reviewed-by: Steven Sistare

[PATCH v3] powerpc/powernv: Use darn instr for random_seed on p9

2017-08-03 Thread Matt Brown
This adds the powernv_get_random_darn function which utilises the darn instruction, introduced in POWER9. The powernv_get_random_darn function is used as the ppc_md.get_random_seed on P9. The DARN instruction can potentially throw an error, so we attempt to register the powernv_get_random_darn

Re: [PATCH v2] powerpc/powernv: Use darn instr for random_seed on p9

2017-08-03 Thread Matt Brown
On Tue, Aug 1, 2017 at 10:57 PM, Segher Boessenkool wrote: > On Mon, Jul 31, 2017 at 07:10:15PM +1000, Michael Ellerman wrote: >> And ___PPC_RA() is not quite right. The L field is only 2 bits wide, not >> the 5 that ___PPC_RA() allows. >> >> We don't have a __PPC_L()

[v5 13/15] mm: stop zeroing memory during allocation in vmemmap

2017-08-03 Thread Pavel Tatashin
Replace allocators in sprase-vmemmap to use the non-zeroing version. So, we will get the performance improvement by zeroing the memory in parallel when struct pages are zeroed. Signed-off-by: Pavel Tatashin Reviewed-by: Steven Sistare

[v5 12/15] mm: explicitly zero pagetable memory

2017-08-03 Thread Pavel Tatashin
Soon vmemmap_alloc_block() will no longer zero the block, so zero memory at its call sites for everything except struct pages. Struct page memory is zero'd by struct page initialization. Signed-off-by: Pavel Tatashin Reviewed-by: Steven Sistare

[v5 09/15] sparc64: optimized struct page zeroing

2017-08-03 Thread Pavel Tatashin
Add an optimized mm_zero_struct_page(), so struct page's are zeroed without calling memset(). We do eight regular stores, thus avoid cost of membar. Signed-off-by: Pavel Tatashin Reviewed-by: Steven Sistare Reviewed-by: Daniel Jordan

Re: [v5 09/15] sparc64: optimized struct page zeroing

2017-08-03 Thread Sam Ravnborg
Hi Pavel. On Thu, Aug 03, 2017 at 05:23:47PM -0400, Pavel Tatashin wrote: > Add an optimized mm_zero_struct_page(), so struct page's are zeroed without > calling memset(). We do eight regular stores, thus avoid cost of membar. The commit message does no longer reflect the implementation, and

Re: [PATCH 1/4] powerpc/prom: avoid endian conversions for linux, memory-limit node

2017-08-03 Thread Hari Bathini
On Friday 04 August 2017 07:17 AM, Benjamin Herrenschmidt wrote: On Fri, 2017-08-04 at 11:37 +1000, Benjamin Herrenschmidt wrote: On Thu, 2017-08-03 at 14:54 +0530, Hari Bathini wrote: As linux,memory-limit node is set and also later used by the kernel, avoid endian conversions for this

Re: [PATCH v3] powerpc/mm: Implemented default_hugepagesz verification for powerpc

2017-08-03 Thread Aneesh Kumar K.V
Victor Aoqui writes: > Implemented default hugepage size verification (default_hugepagesz=) > in order to allow allocation of defined number of pages (hugepages=) > only for supported hugepage sizes. > > Signed-off-by: Victor Aoqui I am

Re: [PATCH 1/4] powerpc/prom: avoid endian conversions for linux, memory-limit node

2017-08-03 Thread Hari Bathini
On Friday 04 August 2017 09:21 AM, Michael Ellerman wrote: Hari Bathini writes: As linux,memory-limit node is set and also later used by the kernel, avoid endian conversions for this property. Fixes: 493adffcb43f ("powerpc: Make prom_init.c endian safe") Cc:

[PATCH] powerpc/fsl/dts: fix the i2c-mux compatible for t104xqds

2017-08-03 Thread Peter Rosin
The sanctioned compatible is "nxp,pca9547". Signed-off-by: Peter Rosin --- arch/powerpc/boot/dts/fsl/t104xqds.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/boot/dts/fsl/t104xqds.dtsi b/arch/powerpc/boot/dts/fsl/t104xqds.dtsi index

Re: [PATCH] powerpc/xive: fix the fuzz value in xive_pick_irq_target()

2017-08-03 Thread Benjamin Herrenschmidt
On Thu, 2017-08-03 at 19:52 +1000, Michael Ellerman wrote: > What if num is 0? > > Which it would be in the fallback case, if the affinity mask is empty, > AFAICS. How can the mask be empty though ? But yes, as I noted there is a problem if the value is 0. Not sure what to do if we are given an