Re: RESCIND Re: [v02] REPOST powerpc/migration: Handle unitialized timer reset

2018-09-26 Thread Michael Ellerman
Michael Bringmann writes: > Hello, Michael: > I am an idiot this morning. Not enough coffee. Emailing when insufficiently caffeinated, that is dangerous :) > I confused this posting with another. Please forget the request. No worries. > We do want to omit > > [PATCH v08 0/5] powerp

[PATCH -next] PCI: hotplug: Use kmemdup rather than duplicating its implementation in pnv_php_add_devtree()

2018-09-26 Thread YueHaibing
Use kmemdup rather than duplicating its implementation Signed-off-by: YueHaibing --- drivers/pci/hotplug/pnv_php.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/pci/hotplug/pnv_php.c b/drivers/pci/hotplug/pnv_php.c index 5070620..ee54f5b 100644 --- a/drivers/pci/h

Re: [PATCH] powerpc/tm: Avoid possible userspace r1 corruption on reclaim

2018-09-26 Thread Michael Ellerman
Michael Neuling writes: > On Tue, 2018-09-25 at 22:00 +1000, Michael Ellerman wrote: >> Michael Neuling writes: >> > Current we store the userspace r1 to PACATMSCRATCH before finally >> > saving it to the thread struct. >> > >> > In theory an exception could be taken here (like a machine check o

Re: How to define some additional KBUILD_CFLAGS after building include/generated/asm-offsets.h ?

2018-09-26 Thread Michael Ellerman
Masahiro Yamada writes: > 2018-09-25 10:16 GMT+09:00 Michael Ellerman : >> Christophe LEROY writes: >> >>> Le 24/09/2018 à 14:10, Michael Ellerman a écrit : Christophe Leroy writes: > I'm trying to implement TLS based stack protector in the Linux Kernel. > For that I need to gi

Re: [PATCH v4 1/2] powerpc/32: add stack protector support

2018-09-26 Thread Christophe LEROY
Le 26/09/2018 à 21:16, Segher Boessenkool a écrit : On Wed, Sep 26, 2018 at 11:40:38AM +, Christophe Leroy wrote: +static __always_inline void boot_init_stack_canary(void) +{ + unsigned long canary; + + /* Try to get a semi random initial value. */ + get_random_bytes(&ca

Re: [PATCH v2 2/7] include: add setbits32/clrbits32/clrsetbits32/setbits64/clrbits64/clrsetbits64 in linux/setbits.h

2018-09-26 Thread LABBE Corentin
On Tue, Sep 25, 2018 at 07:05:00AM +0200, Christophe LEROY wrote: > > > Le 24/09/2018 à 21:04, Corentin Labbe a écrit : > > This patch adds setbits32/clrbits32/clrsetbits32 and > > setbits64/clrbits64/clrsetbits64 in linux/setbits.h header. > > Fix the patch subject and description. > > > > >

Re: [PATCH v2 1/7] powerpc: rename setbits32/clrbits32 to setbits32_be/clrbits32_be

2018-09-26 Thread LABBE Corentin
On Tue, Sep 25, 2018 at 06:56:23AM +0200, Christophe LEROY wrote: > Fix the patch title. > > > Le 24/09/2018 à 21:04, Corentin Labbe a écrit : > > Since setbits32/clrbits32 work on be32, it's better to remove ambiguity on > > the used data type. > > > > Signed-off-by: Corentin Labbe > > --- > >

Re: How to define some additional KBUILD_CFLAGS after building include/generated/asm-offsets.h ?

2018-09-26 Thread Masahiro Yamada
Hi. 2018-09-25 10:16 GMT+09:00 Michael Ellerman : > Christophe LEROY writes: > >> Le 24/09/2018 à 14:10, Michael Ellerman a écrit : >>> Christophe Leroy writes: >>> I'm trying to implement TLS based stack protector in the Linux Kernel. For that I need to give to GCC the offset at which

[PATCH] powerpc/tm: Reformat comments

2018-09-26 Thread Michael Neuling
The comments in this file don't conform to the coding style so take them to "Comment Formatting Re-Education Camp" Suggested-by: Michael "Camp Drill Sargent" Ellerman Signed-off-by: Michael Neuling --- arch/powerpc/kernel/tm.S | 49 +--- 1 file changed, 31 in

Re: [PATCH 03/30] mm: remove CONFIG_HAVE_MEMBLOCK

2018-09-26 Thread Mike Rapoport
On Wed, Sep 26, 2018 at 05:34:32PM -0700, Alexander Duyck wrote: > On Wed, Sep 26, 2018 at 11:32 AM Mike Rapoport > wrote: > > > > On Wed, Sep 26, 2018 at 09:58:41AM -0700, Alexander Duyck wrote: > > > On Fri, Sep 14, 2018 at 5:11 AM Mike Rapoport > > > wrote: > > > > > > > > All architecures u

Re: [PATCH 1/5] dma-mapping: make the get_required_mask method available unconditionally

2018-09-26 Thread Benjamin Herrenschmidt
On Thu, 2018-09-20 at 20:52 +0200, Christoph Hellwig wrote: > This save some duplication for ia64, and makes the interface more > general. In the long run we want each dma_map_ops instance to fill this > out, but this will take a little more prep work. > > Signed-off-by: Christoph Hellwig (For

Re: [PATCH 5/5] dma-direct: always allow dma mask <= physiscal memory size

2018-09-26 Thread Benjamin Herrenschmidt
On Thu, 2018-09-20 at 20:52 +0200, Christoph Hellwig wrote: > This way an architecture with less than 4G of RAM can support dma_mask > smaller than 32-bit without a ZONE_DMA. Apparently that is a common > case on powerpc. Anything that uses a b43 wifi adapter which has a 31-bit limitation actuall

Re: [PATCH 3/5] dma-direct: refine dma_direct_alloc zone selection

2018-09-26 Thread Benjamin Herrenschmidt
On Thu, 2018-09-20 at 20:52 +0200, Christoph Hellwig wrote: > +static gfp_t __dma_direct_optimal_gfp_mask(struct device *dev, u64 dma_mask, > + u64 *phys_mask) > +{ > + if (force_dma_unencrypted()) > + *phys_mask = __dma_to_phys(dev, dma_mask); > + else > +

Re: [PATCH 2/5] dma-direct: add an explicit dma_direct_get_required_mask

2018-09-26 Thread Benjamin Herrenschmidt
On Thu, 2018-09-20 at 20:52 +0200, Christoph Hellwig wrote: > This is somewhat modelled after the powerpc version, and differs from > the legacy fallback in use fls64 instead of pointlessly splitting up the > address into low and high dwords and in that it takes (__)phys_to_dma > into account. Thi

Re: [PATCH 03/30] mm: remove CONFIG_HAVE_MEMBLOCK

2018-09-26 Thread Alexander Duyck
On Wed, Sep 26, 2018 at 11:32 AM Mike Rapoport wrote: > > On Wed, Sep 26, 2018 at 09:58:41AM -0700, Alexander Duyck wrote: > > On Fri, Sep 14, 2018 at 5:11 AM Mike Rapoport > > wrote: > > > > > > All architecures use memblock for early memory management. There is no > > > need > > > for the CON

Re: [PATCH v3 3/3] dt-bindings: watchdog: add mpc8xxx-wdt support

2018-09-26 Thread Rob Herring
On Mon, 17 Sep 2018 06:22:53 + (UTC), Christophe Leroy wrote: > Add description of DT bindings for mpc8xxx-wdt driver which > handles the CPU watchdog timer on the mpc83xx, mpc86xx and mpc8xx. > > Signed-off-by: Christophe Leroy > --- > .../devicetree/bindings/watchdog/mpc8xxx-wdt.txt | 25

Re: [PATCH -next] PCI/AER: Remove duplicated include from err.c

2018-09-26 Thread Bjorn Helgaas
On Wed, Sep 26, 2018 at 11:00:10AM +, YueHaibing wrote: > Remove duplicated include. > > Signed-off-by: YueHaibing Applied to pci/hotplug for v4.20, thanks! > --- > drivers/pci/pcie/err.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/drivers/pci/pcie/err.c b/drivers/pci/pcie/err

Re: [PATCH v4 1/2] powerpc/32: add stack protector support

2018-09-26 Thread Segher Boessenkool
On Wed, Sep 26, 2018 at 11:40:38AM +, Christophe Leroy wrote: > +static __always_inline void boot_init_stack_canary(void) > +{ > + unsigned long canary; > + > + /* Try to get a semi random initial value. */ > + get_random_bytes(&canary, sizeof(canary)); > + canary ^= mftb(); > +

Re: [PATCH v3 2/2] powerpc/64: add stack protector support

2018-09-26 Thread Segher Boessenkool
On Wed, Sep 26, 2018 at 11:41:26AM +0200, Christophe LEROY wrote: > Le 26/09/2018 à 11:28, Segher Boessenkool a écrit : > >On Wed, Sep 26, 2018 at 09:58:30AM +0200, Christophe LEROY wrote: > >>Segher, any idea about this problem ? > > > arch/powerpc/platforms/powermac/bootx_init.o: In function

Re: [PATCH 03/30] mm: remove CONFIG_HAVE_MEMBLOCK

2018-09-26 Thread Mike Rapoport
On Wed, Sep 26, 2018 at 09:58:41AM -0700, Alexander Duyck wrote: > On Fri, Sep 14, 2018 at 5:11 AM Mike Rapoport wrote: > > > > All architecures use memblock for early memory management. There is no need > > for the CONFIG_HAVE_MEMBLOCK configuration option. > > > > Signed-off-by: Mike Rapoport >

Re: [PATCH 1/2] soc: fsl: qbman: qman_portal: defer probing when qman is not available

2018-09-26 Thread Li Yang
On Wed, Sep 26, 2018 at 4:28 AM Alexandre Belloni wrote: > > On 25/09/2018 21:45:56+0200, Olof Johansson wrote: > > Hi, > > > > > > On Thu, Aug 23, 2018 at 11:36 PM Alexandre Belloni > > wrote: > > > > > > If the qman driver (qman_ccsr) doesn't probe or fail to probe before > > > qman_portal, qm_

Re: [PATCH 03/30] mm: remove CONFIG_HAVE_MEMBLOCK

2018-09-26 Thread Alexander Duyck
On Fri, Sep 14, 2018 at 5:11 AM Mike Rapoport wrote: > > All architecures use memblock for early memory management. There is no need > for the CONFIG_HAVE_MEMBLOCK configuration option. > > Signed-off-by: Mike Rapoport > diff --git a/include/linux/memblock.h b/include/linux/memblock.h > index

RESCIND Re: [v02] REPOST powerpc/migration: Handle unitialized timer reset

2018-09-26 Thread Michael Bringmann
Hello, Michael: I am an idiot this morning. Not enough coffee. I confused this posting with another. Please forget the request. We do want to omit [PATCH v08 0/5] powerpc/hotplug: Update affinity for migrated CPUs https://lists.ozlabs.org/pipermail/linuxppc-dev/2018-July/176301.html t

Re: [v02] REPOST powerpc/migration: Handle unitialized timer reset

2018-09-26 Thread Michael Bringmann
Hello, Michael: Please look at v03 of the patch set which was posted just on 09/25/2018. We had a last minute brainstorm of how to simplify the code after the v02 REPOST. Also, note that we would like to invalidate the set, [PATCH v08 0/5] powerpc/hotplug: Update affinity for migrated CPU

Re: [PATCH] powerpc: Move a dereference below a NULL test

2018-09-26 Thread zhong jiang
On 2018/9/26 22:22, Michal Suchánek wrote: > On Wed, 26 Sep 2018 19:46:08 +0800 > zhong jiang wrote: > >> It is safe to move dereference below a NULL test. >> >> Signed-off-by: zhong jiang >> --- >> arch/powerpc/kernel/cacheinfo.c | 5 ++--- >> 1 file changed, 2 insertions(+), 3 deletions(-) >>

Re: [PATCH 14/30] memblock: add align parameter to memblock_alloc_node()

2018-09-26 Thread Michal Hocko
On Wed 26-09-18 16:43:35, Mike Rapoport wrote: > On Wed, Sep 26, 2018 at 11:36:48AM +0200, Michal Hocko wrote: > > On Wed 26-09-18 11:31:27, Michal Hocko wrote: > > > On Fri 14-09-18 15:10:29, Mike Rapoport wrote: > > > > With the align parameter memblock_alloc_node() can be used as drop in > > > >

Re: [PATCH] powerpc: Move a dereference below a NULL test

2018-09-26 Thread Michal Suchánek
On Wed, 26 Sep 2018 19:46:08 +0800 zhong jiang wrote: > It is safe to move dereference below a NULL test. > > Signed-off-by: zhong jiang > --- > arch/powerpc/kernel/cacheinfo.c | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) > > diff --git a/arch/powerpc/kernel/cacheinfo.c > b/ar

[PATCH 1/1] powerpc/config: Enable CONFIG_PRINTK_TIME

2018-09-26 Thread Petr Vorel
for 64bit configs which use for CONFIG_LOG_BUF_SHIFT the same or higher value than the default (currently 17). Signed-off-by: Petr Vorel --- arch/powerpc/configs/g5_defconfig | 1 + arch/powerpc/configs/maple_defconfig | 1 + arch/powerpc/configs/powernv_defconfig | 1 + arch/powerpc/conf

Re: [PATCH v4] powerpc/64s: reimplement book3s idle code in C

2018-09-26 Thread Akshay Adiga
On Fri, Sep 14, 2018 at 11:52:40AM +1000, Nicholas Piggin wrote: > + > + /* > + * On POWER9, SRR1 bits do not match exactly as expected. > + * SRR1_WS_GPRLOSS (10b) can also result in SPR loss, so > + * always test PSSCR if there is any state loss. > + */ > + if (likely(

Re: [PATCH] powerpc: Move a dereference below a NULL test

2018-09-26 Thread zhong jiang
On 2018/9/26 21:58, Christophe LEROY wrote: > > > Le 26/09/2018 à 13:46, zhong jiang a écrit : >> It is safe to move dereference below a NULL test. >> >> Signed-off-by: zhong jiang >> --- >> arch/powerpc/kernel/cacheinfo.c | 5 ++--- >> 1 file changed, 2 insertions(+), 3 deletions(-) >> >> diff

Re: [PATCH] powerpc: Move a dereference below a NULL test

2018-09-26 Thread Christophe LEROY
Le 26/09/2018 à 13:46, zhong jiang a écrit : It is safe to move dereference below a NULL test. Signed-off-by: zhong jiang --- arch/powerpc/kernel/cacheinfo.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/arch/powerpc/kernel/cacheinfo.c b/arch/powerpc/kernel/cach

Re: [PATCH 14/30] memblock: add align parameter to memblock_alloc_node()

2018-09-26 Thread Mike Rapoport
On Wed, Sep 26, 2018 at 11:36:48AM +0200, Michal Hocko wrote: > On Wed 26-09-18 11:31:27, Michal Hocko wrote: > > On Fri 14-09-18 15:10:29, Mike Rapoport wrote: > > > With the align parameter memblock_alloc_node() can be used as drop in > > > replacement for alloc_bootmem_pages_node() and __alloc_b

[PATCH] powerpc/64s: consolidate MCE counter increment.

2018-09-26 Thread Michal Suchanek
The code in machine_check_exception excludes 64s hvmode when incrementing the MCE counter only to call opal_machine_check to increment it specifically for this case. Remove the exclusion and special case. Fixes: a43c1590426c ("powerpc/pseries: Flush SLB contents on SLB MCE error

[PATCH] powerpc: Move a dereference below a NULL test

2018-09-26 Thread zhong jiang
It is safe to move dereference below a NULL test. Signed-off-by: zhong jiang --- arch/powerpc/kernel/cacheinfo.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/arch/powerpc/kernel/cacheinfo.c b/arch/powerpc/kernel/cacheinfo.c index a8f20e5..7f19714 100644 --- a/arch/pow

[PATCH] powerpc: xive: Move a dereference below a NULL test

2018-09-26 Thread zhong jiang
It is safe to move dereference below a NULL test. Signed-off-by: zhong jiang --- arch/powerpc/sysdev/xive/common.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/arch/powerpc/sysdev/xive/common.c b/arch/powerpc/sysdev/xive/common.c index 959a2a6..9824074 100644 --- a

Re: powerpc/numa: Use associativity if VPHN hcall is successful

2018-09-26 Thread Michael Ellerman
On Tue, 2018-09-25 at 12:25:15 UTC, Srikar Dronamraju wrote: > Currently associativity is used to lookup node-id even if the preceding > VPHN hcall failed. However this can cause CPU to be made part of the > wrong node, (most likely to be node 0). This is because VPHN is not > enabled on kvm guests

Re: powerpc/tm: Avoid possible userspace r1 corruption on reclaim

2018-09-26 Thread Michael Ellerman
On Tue, 2018-09-25 at 09:36:47 UTC, Michael Neuling wrote: > Current we store the userspace r1 to PACATMSCRATCH before finally > saving it to the thread struct. > > In theory an exception could be taken here (like a machine check or > SLB miss) that could write PACATMSCRATCH and hence corrupt the

Re: powerpc/tm: Fix userspace r13 corruption

2018-09-26 Thread Michael Ellerman
On Mon, 2018-09-24 at 07:27:04 UTC, Michael Neuling wrote: > When we treclaim we store the userspace checkpointed r13 to a scratch > SPR and then later save the scratch SPR to the user thread struct. > > Unfortunately, this doesn't work as accessing the user thread struct > can take an SLB fault a

Re: [v02] REPOST powerpc/migration: Handle unitialized timer reset

2018-09-26 Thread Michael Ellerman
On Thu, 2018-09-20 at 16:45:13 UTC, Michael Bringmann wrote: > After migration of a powerpc LPAR, the kernel executes code to > update the system state to reflect new platform characteristics. > Such changes include modifications to device tree properties > provided to the system by PHYP. Property

Re: [PATCH 03/30] mm: remove CONFIG_HAVE_MEMBLOCK

2018-09-26 Thread Mike Rapoport
On Wed, Sep 26, 2018 at 11:24:04AM +0200, Michal Hocko wrote: > On Fri 14-09-18 15:10:18, Mike Rapoport wrote: > > All architecures use memblock for early memory management. There is no need > > for the CONFIG_HAVE_MEMBLOCK configuration option. > > git grep says > arch/csky/Kconfig: select HAVE_

Re: [PATCH v3 2/2] powerpc/64: add stack protector support

2018-09-26 Thread Christophe LEROY
Le 26/09/2018 à 13:50, Michael Ellerman a écrit : Christophe LEROY writes: Le 26/09/2018 à 11:28, Segher Boessenkool a écrit : On Wed, Sep 26, 2018 at 09:58:30AM +0200, Christophe LEROY wrote: Segher, any idea about this problem ? arch/powerpc/platforms/powermac/bootx_init.o: In functio

Re: [PATCH v3 2/2] powerpc/64: add stack protector support

2018-09-26 Thread Michael Ellerman
Christophe LEROY writes: > Le 26/09/2018 à 11:28, Segher Boessenkool a écrit : >> On Wed, Sep 26, 2018 at 09:58:30AM +0200, Christophe LEROY wrote: >>> Segher, any idea about this problem ? >> > arch/powerpc/platforms/powermac/bootx_init.o: In function `bootx_printf': > /var/lib/jenkins-s

Re: [PATCH 02/30] mm: remove CONFIG_NO_BOOTMEM

2018-09-26 Thread Mike Rapoport
On Wed, Sep 26, 2018 at 11:22:39AM +0200, Michal Hocko wrote: > On Fri 14-09-18 15:10:17, Mike Rapoport wrote: > > All achitectures select NO_BOOTMEM which essentially becomes 'Y' for any > > kernel configuration and therefore it can be removed. > > git grep suggests that DEFERRED_STRUCT_PAGE_INIT

[PATCH v4 2/2] powerpc/64: add stack protector support

2018-09-26 Thread Christophe Leroy
On PPC64, as register r13 points to the paca_struct at all time, this patch adds a copy of the canary there, which is copied at task_switch. That new canary is then used by using the following GCC options: -mstack-protector-guard=tls -mstack-protector-guard-reg=r13 -mstack-protector-guard-offset=of

[PATCH v4 1/2] powerpc/32: add stack protector support

2018-09-26 Thread Christophe Leroy
This functionality was tentatively added in the past (commit 6533b7c16ee5 ("powerpc: Initial stack protector (-fstack-protector) support")) but had to be reverted (commit f2574030b0e3 ("powerpc: Revert the initial stack protector support") because of GCC implementing it differently whether it had b

Re: [PATCH] kdb: use correct pointer when 'btc' calls 'btt'

2018-09-26 Thread Christophe LEROY
Le 26/09/2018 à 13:11, Daniel Thompson a écrit : On 16/09/2018 20:06, Daniel Thompson wrote: On Fri, Sep 14, 2018 at 12:35:44PM +, Christophe Leroy wrote: On a powerpc 8xx, 'btc' fails as follows: Entering kdb (current=0x(ptrval), pid 282) due to Keyboard Entry kdb> btc btc: cpu status:

Re: Re: [PATCH] kdb: use correct pointer when 'btc' calls 'btt'

2018-09-26 Thread Daniel Thompson
On 16/09/2018 20:06, Daniel Thompson wrote: On Fri, Sep 14, 2018 at 12:35:44PM +, Christophe Leroy wrote: On a powerpc 8xx, 'btc' fails as follows: Entering kdb (current=0x(ptrval), pid 282) due to Keyboard Entry kdb> btc btc: cpu status: Currently on cpu 0 Available cpus: 0 kdb_getarea: Ba

[PATCH -next] PCI/AER: Remove duplicated include from err.c

2018-09-26 Thread YueHaibing
Remove duplicated include. Signed-off-by: YueHaibing --- drivers/pci/pcie/err.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/pci/pcie/err.c b/drivers/pci/pcie/err.c index 4da2a62b..773197a 100644 --- a/drivers/pci/pcie/err.c +++ b/drivers/pci/pcie/err.c @@ -12,7 +12,6 @@ #includ

Re: [PATCH 4/4] dma-mapping: clear dev->dma_ops in arch_teardown_dma_ops

2018-09-26 Thread Robin Murphy
On 25/09/18 21:16, Christoph Hellwig wrote: Looking at the code I think this commit is simply broken for architectures not using arch_setup_dma_ops, but instead setting up the dma ops through arch specific magic. I'll revert the patch. Ugh, sorry about missing that too. Ack to a revert - think

Re: [PATCH v2 5/6] powerpc/powernv: hold device_hotplug_lock when calling memtrace_offline_pages()

2018-09-26 Thread David Hildenbrand
On 25/09/2018 14:15, Balbir Singh wrote: > On Tue, Sep 25, 2018 at 11:14:56AM +0200, David Hildenbrand wrote: >> Let's perform all checking + offlining + removing under >> device_hotplug_lock, so nobody can mess with these devices via >> sysfs concurrently. >> >> Cc: Benjamin Herrenschmidt >> Cc:

Re: [PATCH 00/30] mm: remove bootmem allocator

2018-09-26 Thread Michal Hocko
On Fri 14-09-18 15:10:15, Mike Rapoport wrote: [...] > 326 files changed, 866 insertions(+), 2539 deletions(-) > delete mode 100644 include/linux/bootmem.h > delete mode 100644 mm/bootmem.c > delete mode 100644 mm/nobootmem.c I _really_ love this part the most! Not only we got rid of the trans

Re: [PATCH v3 2/2] powerpc/64: add stack protector support

2018-09-26 Thread Christophe LEROY
Le 26/09/2018 à 11:28, Segher Boessenkool a écrit : On Wed, Sep 26, 2018 at 09:58:30AM +0200, Christophe LEROY wrote: Segher, any idea about this problem ? arch/powerpc/platforms/powermac/bootx_init.o: In function `bootx_printf': /var/lib/jenkins-slave/workspace/snowpatch/snowpatch-linux-

Re: [PATCH 29/30] mm: remove include/linux/bootmem.h

2018-09-26 Thread Michal Hocko
On Fri 14-09-18 15:10:44, Mike Rapoport wrote: > Move remaining definitions and declarations from include/linux/bootmem.h > into include/linux/memblock.h and remove the redundant header. > > The includes were replaced with the semantic patch below and then > semi-automated removal of duplicated '#

Re: [PATCH 21/30] memblock: replace alloc_bootmem with memblock_alloc

2018-09-26 Thread Michal Hocko
On Fri 14-09-18 15:10:36, Mike Rapoport wrote: > The alloc_bootmem(size) is a shortcut for allocation of SMP_CACHE_BYTES > aligned memory. When the align parameter of memblock_alloc() is 0, the > alignment is implicitly set to SMP_CACHE_BYTES and thus alloc_bootmem(size) > and memblock_alloc(size,

Re: [PATCH 16/30] memblock: replace __alloc_bootmem_node with appropriate memblock_ API

2018-09-26 Thread Michal Hocko
On Fri 14-09-18 15:10:31, Mike Rapoport wrote: > Use memblock_alloc_try_nid whenever goal (i.e. minimal address is > specified) and memblock_alloc_node otherwise. > > Signed-off-by: Mike Rapoport Acked-by: Michal Hocko -- Michal Hocko SUSE Labs

Re: [PATCH 14/30] memblock: add align parameter to memblock_alloc_node()

2018-09-26 Thread Michal Hocko
On Wed 26-09-18 11:31:27, Michal Hocko wrote: > On Fri 14-09-18 15:10:29, Mike Rapoport wrote: > > With the align parameter memblock_alloc_node() can be used as drop in > > replacement for alloc_bootmem_pages_node() and __alloc_bootmem_node(), > > which is done in the following patches. > > /me co

Re: [PATCH 14/30] memblock: add align parameter to memblock_alloc_node()

2018-09-26 Thread Michal Hocko
On Fri 14-09-18 15:10:29, Mike Rapoport wrote: > With the align parameter memblock_alloc_node() can be used as drop in > replacement for alloc_bootmem_pages_node() and __alloc_bootmem_node(), > which is done in the following patches. /me confused. Why do we need this patch at all? Maybe it should

Re: [PATCH v3 2/2] powerpc/64: add stack protector support

2018-09-26 Thread Segher Boessenkool
On Wed, Sep 26, 2018 at 09:58:30AM +0200, Christophe LEROY wrote: > Segher, any idea about this problem ? > >>arch/powerpc/platforms/powermac/bootx_init.o: In function `bootx_printf': > >>/var/lib/jenkins-slave/workspace/snowpatch/snowpatch-linux- > >>sparse/linux/arch/powerpc/platforms/powermac/b

Re: [PATCH 07/30] memblock: remove _virt from APIs returning virtual address

2018-09-26 Thread Michal Hocko
On Fri 14-09-18 15:10:22, Mike Rapoport wrote: > The conversion is done using > > sed -i 's@memblock_virt_alloc@memblock_alloc@g' \ > $(git grep -l memblock_virt_alloc) > > Signed-off-by: Mike Rapoport As I've said earlier, I am not entirely thrilled by this change. It is unnecessary chur

Re: [PATCH 1/2] soc: fsl: qbman: qman_portal: defer probing when qman is not available

2018-09-26 Thread Alexandre Belloni
On 25/09/2018 21:45:56+0200, Olof Johansson wrote: > Hi, > > > On Thu, Aug 23, 2018 at 11:36 PM Alexandre Belloni > wrote: > > > > If the qman driver (qman_ccsr) doesn't probe or fail to probe before > > qman_portal, qm_ccsr_start will be either NULL or a stale pointer to an > > unmapped page. >

Re: [PATCH 05/30] mm: nobootmem: remove dead code

2018-09-26 Thread Michal Hocko
On Fri 14-09-18 15:10:20, Mike Rapoport wrote: > Several bootmem functions and macros are not used. Remove them. > > Signed-off-by: Mike Rapoport Acked-by: Michal Hocko -- Michal Hocko SUSE Labs

Re: [PATCH 03/30] mm: remove CONFIG_HAVE_MEMBLOCK

2018-09-26 Thread Michal Hocko
On Fri 14-09-18 15:10:18, Mike Rapoport wrote: > All architecures use memblock for early memory management. There is no need > for the CONFIG_HAVE_MEMBLOCK configuration option. git grep says arch/csky/Kconfig: select HAVE_MEMBLOCK > Signed-off-by: Mike Rapoport Other than that Acked-by: Micha

Re: [PATCH 02/30] mm: remove CONFIG_NO_BOOTMEM

2018-09-26 Thread Michal Hocko
On Fri 14-09-18 15:10:17, Mike Rapoport wrote: > All achitectures select NO_BOOTMEM which essentially becomes 'Y' for any > kernel configuration and therefore it can be removed. git grep suggests that DEFERRED_STRUCT_PAGE_INIT still depends on NO_BOOTMEM but I have a vague feeling that I've seen a

Re: [PATCH v5 18/22] powerpc/mm: Extend pte_fragment functionality to nohash/32

2018-09-26 Thread Aneesh Kumar K.V
On 9/26/18 1:40 PM, Christophe LEROY wrote: Le 26/09/2018 à 04:48, Aneesh Kumar K.V a écrit : Christophe Leroy writes: In order to allow the 8xx to handle pte_fragments, this patch extends the use of pte_fragments to nohash/32 platforms. Signed-off-by: Christophe Leroy ---   arch/powerpc/

Re: [PATCH v5 18/22] powerpc/mm: Extend pte_fragment functionality to nohash/32

2018-09-26 Thread Christophe LEROY
Le 26/09/2018 à 04:48, Aneesh Kumar K.V a écrit : Christophe Leroy writes: In order to allow the 8xx to handle pte_fragments, this patch extends the use of pte_fragments to nohash/32 platforms. Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/mmu_context.h | 2 +- ar

Re: [PATCH v3 2/2] powerpc/64: add stack protector support

2018-09-26 Thread Christophe LEROY
Segher, any idea about this problem ? Christophe Le 26/09/2018 à 09:05, Russell Currey a écrit : On Tue, 2018-09-25 at 17:56 +0200, Christophe LEROY wrote: Snowpatch reports failure on pmac32_defconfig, as follows: arch/powerpc/platforms/powermac/bootx_init.o: In function `bootx_printf': /var

Re: [PATCH v3 2/2] powerpc/64: add stack protector support

2018-09-26 Thread Russell Currey
On Tue, 2018-09-25 at 17:56 +0200, Christophe LEROY wrote: > Snowpatch reports failure on pmac32_defconfig, as follows: > > arch/powerpc/platforms/powermac/bootx_init.o: In function `bootx_printf': > /var/lib/jenkins-slave/workspace/snowpatch/snowpatch-linux- > sparse/linux/arch/powerpc/platforms/