[PATCH v3 7/8] tools/perf: Enable Hz/hz prinitg for --metric-only option

2020-02-29 Thread Kajol Jain
Commit 54b5091606c18 ("perf stat: Implement --metric-only mode") added function 'valid_only_metric()' which drops "Hz" or "hz", if it is part of "ScaleUnit". This patch enable it since hv_24x7 supports couple of frequency events. Signed-off-by: Kajol Jain --- tools/perf/util/stat-display.c | 2

[PATCH v3 8/8] perf/tools/pmu-events/powerpc: Add hv_24x7 socket/chip level metric events

2020-02-29 Thread Kajol Jain
The hv_24×7 feature in IBM® POWER9™ processor-based servers provide the facility to continuously collect large numbers of hardware performance metrics efficiently and accurately. This patch adds hv_24x7 metric file for different Socket/chip resources. Result: power9 platform: command:# ./perf

[PATCH v3 7/8] tools/perf: Enable Hz/hz prinitg for --metric-only option

2020-02-29 Thread Kajol Jain
Commit 54b5091606c18 ("perf stat: Implement --metric-only mode") added function 'valid_only_metric()' which drops "Hz" or "hz", if it is part of "ScaleUnit". This patch enable it since hv_24x7 supports couple of frequency events. Signed-off-by: Kajol Jain --- tools/perf/util/stat-display.c | 2

[PATCH V2 0/9] crypto/nx: Enable GZIP engine and provide userpace API

2020-02-29 Thread Haren Myneni
Power9 processor supports Virtual Accelerator Switchboard (VAS) which allows kernel and userspace to send compression requests to Nest Accelerator (NX) directly. The NX unit comprises of 2 842 compression engines and 1 GZIP engine. Linux kernel already has 842 compression support on kernel. This

[PATCH V2 9/9] Documentation/powerpc: VAS API

2020-02-29 Thread Haren Myneni
Power9 introduced Virtual Accelerator Switchboard (VAS) which allows userspace to communicate with Nest Accelerator (NX) directly. But kernel has to establish channel to NX for userspace. This document describes user space API that application can use to establish communication channel.

[PATCH v3 6/8] perf/tools: Enhance JSON/metric infrastructure to handle "?"

2020-02-29 Thread Kajol Jain
Patch enhances current metric infrastructure to handle "?" in the metric expression. The "?" can be use for parameters whose value not known while creating metric events and which can be replace later at runtime to the proper value. It also add flexibility to create multiple events out of single

[PATCH v3 5/8] powerpc/hv-24x7: Update post_mobility_fixup() to handle migration

2020-02-29 Thread Kajol Jain
Function 'read_sys_info_pseries()' is added to get system parameter values like number of sockets and chips per socket. and it gets these details via rtas_call with token "PROCESSOR_MODULE_INFO". Incase lpar migrate from one system to another, system parameter details like chips per sockets or

[PATCH v3 3/8] powerpc/hv-24x7: Add sysfs files inside hv-24x7 device to show processor details

2020-02-29 Thread Kajol Jain
To expose the system dependent parameter like total number of sockets and numbers of chips per socket, patch adds two sysfs files. "sockets" and "chips" are added to /sys/devices/hv_24x7/interface/ of the "hv_24x7" pmu. Signed-off-by: Kajol Jain --- arch/powerpc/perf/hv-24x7.c | 22

[PATCH v3 1/8] powerpc/perf/hv-24x7: Fix inconsistent output values incase multiple hv-24x7 events run

2020-02-29 Thread Kajol Jain
Commit 2b206ee6b0df ("powerpc/perf/hv-24x7: Display change in counter values")' added to print _change_ in the counter value rather then raw value for 24x7 counters. Incase of transactions, the event count is set to 0 at the beginning of the transaction. It also sets the event's prev_count to the

[PATCH v3 2/8] powerpc/hv-24x7: Add rtas call in hv-24x7 driver to get processor details

2020-02-29 Thread Kajol Jain
For hv_24x7 socket/chip level events, specific chip-id to which the data requested should be added as part of pmu events. But number of chips/socket in the system details are not exposed. Patch implements read_sys_info_pseries() to get system parameter values like number of sockets and chips per

[PATCH V2 2/9] powerpc/vas: Define VAS_TX_WIN_OPEN ioctl API

2020-02-29 Thread Haren Myneni
Define the VAS_TX_WIN_OPEN ioctl interface for NX GZIP access from user space. This interface is used to open GZIP send window and mmap region which can be used by userspace to send requests to NX directly with copy/paste instructions. Signed-off-by: Haren Myneni ---

[PATCH V3 3/9] powerpc/vas: Add VAS user space API

2020-02-29 Thread Haren Myneni
On power9, userspace can send GZIP compression requests directly to NX once kernel establishes NX channel / window with VAS. This patch provides user space API which allows user space to establish channel using open VAS_TX_WIN_OPEN ioctl, mmap and close operations. Each window corresponds to

[PATCH V2 1/9] powerpc/vas: Initialize window attributes for GZIP coprocessor type

2020-02-29 Thread Haren Myneni
Initialize send and receive window attributes for GZIP high and normal priority types. Signed-off-by: Haren Myneni --- arch/powerpc/platforms/powernv/vas-window.c | 17 - 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/arch/powerpc/platforms/powernv/vas-window.c

[PATCH v3 0/8] powerpc/perf: Add json file metric support for the hv_24x7 socket/chip level events

2020-02-29 Thread Kajol Jain
First patch of the patchset fix inconsistent results we are getting when we run multiple 24x7 events. Patchset adds json file metric support for the hv_24x7 socket/chip level events. "hv_24x7" pmu interface events needs system dependent parameter like socket/chip/core. For example, hv_24x7 chip

[PATCH v3 0/8] powerpc/perf: Add json file metric support for the hv_24x7 socket/chip level events

2020-02-29 Thread Kajol Jain
First patch of the patchset fix inconsistent results we are getting when we run multiple 24x7 events. Patchset adds json file metric support for the hv_24x7 socket/chip level events. "hv_24x7" pmu interface events needs system dependent parameter like socket/chip/core. For example, hv_24x7 chip

[PATCH V2 8/9] crypto/nx: Remove 'pid' in vas_tx_win_attr struct

2020-02-29 Thread Haren Myneni
When window is opened, pid reference is taken for user space windows. Not needed for kernel windows. So remove 'pid' in vas_tx_win_attr struct. Signed-off-by: Haren Myneni --- arch/powerpc/include/asm/vas.h| 1 - drivers/crypto/nx/nx-common-powernv.c | 1 - 2 files changed, 2

[PATCH V2 7/9] crypto/nx: Enable and setup GZIP compression type

2020-02-29 Thread Haren Myneni
Changes to probe GZIP device-tree nodes, open RX windows and setup GZIP compression type. No plans to provide GZIP usage in kernel right now, but this patch enables GZIP for user space usage. Signed-off-by: Haren Myneni --- drivers/crypto/nx/nx-common-powernv.c | 43

Re: [RFC PATCH v1] powerpc/prom_init: disable XIVE in Secure VM.

2020-02-29 Thread Cédric Le Goater
On 2/29/20 8:54 AM, Ram Pai wrote: > XIVE is not correctly enabled for Secure VM in the KVM Hypervisor yet. > > Hence Secure VM, must always default to XICS interrupt controller. have you tried XIVE emulation 'kernel-irqchip=off' ? > If XIVE is requested through kernel command line option

[PATCH V2 6/9] crypto/nx: Make enable code generic to add new GZIP compression type

2020-02-29 Thread Haren Myneni
Make setup and enable code generic to support new GZIP compression type. Changed nx842 reference to nx and moved some code to new functions. The actual functionality is not changed. Signed-off-by: Haren Myneni --- drivers/crypto/nx/nx-common-powernv.c | 159 +-

[PATCH v3 6/8] perf/tools: Enhance JSON/metric infrastructure to handle "?"

2020-02-29 Thread Kajol Jain
Patch enhances current metric infrastructure to handle "?" in the metric expression. The "?" can be use for parameters whose value not known while creating metric events and which can be replace later at runtime to the proper value. It also add flexibility to create multiple events out of single

[PATCH v3 5/8] powerpc/hv-24x7: Update post_mobility_fixup() to handle migration

2020-02-29 Thread Kajol Jain
Function 'read_sys_info_pseries()' is added to get system parameter values like number of sockets and chips per socket. and it gets these details via rtas_call with token "PROCESSOR_MODULE_INFO". Incase lpar migrate from one system to another, system parameter details like chips per sockets or

[PATCH v3 4/8] Documentation/ABI: Add ABI documentation for chips and sockets

2020-02-29 Thread Kajol Jain
Add documentation for the following sysfs files: /sys/devices/hv_24x7/interface/chips, /sys/devices/hv_24x7/interface/sockets Signed-off-by: Kajol Jain --- .../testing/sysfs-bus-event_source-devices-hv_24x7 | 14 ++ 1 file changed, 14 insertions(+) diff --git

[PATCH v3 1/8] powerpc/perf/hv-24x7: Fix inconsistent output values incase multiple hv-24x7 events run

2020-02-29 Thread Kajol Jain
Commit 2b206ee6b0df ("powerpc/perf/hv-24x7: Display change in counter values")' added to print _change_ in the counter value rather then raw value for 24x7 counters. Incase of transactions, the event count is set to 0 at the beginning of the transaction. It also sets the event's prev_count to the

Re: [PATCH v3 7/7] mm/memremap: Set caching mode for PCI P2PDMA memory to WC

2020-02-29 Thread Dan Williams
On Fri, Feb 21, 2020 at 10:25 AM Logan Gunthorpe wrote: > > PCI BAR IO memory should never be mapped as WB, however prior to this > the PAT bits were set WB and it was typically overridden by MTRR > registers set by the firmware. > > Set PCI P2PDMA memory to be WC (writecombining) as the only

Re: [PATCH v3 2/7] mm/memory_hotplug: Rename mhp_restrictions to mhp_params

2020-02-29 Thread Dan Williams
On Fri, Feb 21, 2020 at 10:25 AM Logan Gunthorpe wrote: > > The mhp_restrictions struct really doesn't specify anything resembling > a restriction anymore so rename it to be mhp_params as it is a list > of extended parameters. > > Signed-off-by: Logan Gunthorpe Tests ok, and looks good to me:

Re: [PATCH v3 6/7] mm/memory_hotplug: Add pgprot_t to mhp_params

2020-02-29 Thread Dan Williams
On Fri, Feb 21, 2020 at 10:25 AM Logan Gunthorpe wrote: > > devm_memremap_pages() is currently used by the PCI P2PDMA code to create > struct page mappings for IO memory. At present, these mappings are created > with PAGE_KERNEL which implies setting the PAT bits to be WB. However, on > x86, an

Re: [PATCH 6/8] powerpc: Update MPC5XXX MAINTAINERS entry

2020-02-29 Thread Anatolij Gustschin
On Tue, 25 Feb 2020 10:31:44 +1100 Michael Ellerman m...@ellerman.id.au wrote: >It's several years since the last commit from Anatolij, so mark >MPC5XXX as "Odd Fixes" rather than "Maintained". > >Also the git link no longer works so remove it. > >Cc: Anatolij Gustschin >Signed-off-by: Michael

Re: [PATCH v3 4/7] x86/mm: Introduce _set_memory_prot()

2020-02-29 Thread Dan Williams
On Fri, Feb 21, 2020 at 10:25 AM Logan Gunthorpe wrote: > > For use in the 32bit arch_add_memory() to set the pgprot type of the > memory to add. > > Cc: Thomas Gleixner > Cc: Ingo Molnar > Cc: Borislav Petkov > Cc: "H. Peter Anvin" > Cc: x...@kernel.org > Cc: Dave Hansen > Cc: Andy

RE: [RFC PATCH v1] powerpc/prom_init: disable XIVE in Secure VM.

2020-02-29 Thread Ram Pai
On Sat, Feb 29, 2020 at 09:27:54AM +0100, Cédric Le Goater wrote: > On 2/29/20 8:54 AM, Ram Pai wrote: > > XIVE is not correctly enabled for Secure VM in the KVM Hypervisor yet. > > > > Hence Secure VM, must always default to XICS interrupt controller. > > have you tried XIVE emulation

Re: [PATCH v3 3/7] x86/mm: Thread pgprot_t through init_memory_mapping()

2020-02-29 Thread Dan Williams
On Fri, Feb 21, 2020 at 10:25 AM Logan Gunthorpe wrote: > > In prepartion to support a pgprot_t argument for arch_add_memory(). > > It's required to move the prototype of init_memory_mapping() seeing > the original location came before the definition of pgprot_t. > > Cc: Thomas Gleixner > Cc:

Re: Re: [PATCH] powerpc/Kconfig: Make FSL_85XX_CACHE_SRAM configurable

2020-02-29 Thread Scott Wood
On Tue, 2020-01-21 at 14:38 +0800, 王文虎 wrote: > 发件人:Scott Wood > 发送日期:2020-01-21 13:49:59 > 收件人:"王文虎" > 抄送人:wangwenhu ,Kumar Gala ,B > enjamin Herrenschmidt ,Paul Mackerras < > pau...@samba.org>,Michael Ellerman , > linuxppc-dev@lists.ozlabs.org,linux-ker...@vger.kernel.org, >

[PATCH v4 4/8] ASoC: fsl_asrc: Change asrc_width to asrc_format

2020-02-29 Thread Shengjiu Wang
asrc_format is more inteligent, which is align with the alsa definition snd_pcm_format_t, we don't need to convert it to format in driver, and it can distinguish S24_LE & S24_3LE. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c | 19 ++- sound/soc/fsl/fsl_asrc.h

[PATCH v4 3/8] ASoC: fsl-asoc-card: Change asrc-width to asrc-format

2020-02-29 Thread Shengjiu Wang
asrc_format is more inteligent, which is align with the alsa definition snd_pcm_format_t, we don't need to convert it to format in driver, and it can distinguish S24_LE & S24_3LE. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl-asoc-card.c | 9 ++--- 1 file changed, 2 insertions(+), 7

[PATCH v4 2/8] ARM: dts: imx6qdl: Change asrc-width to asrc-format

2020-02-29 Thread Shengjiu Wang
asrc_format is more inteligent, which is align with the alsa definition snd_pcm_format_t, we don't need to convert it to format in driver, and it can distinguish S24_LE & S24_3LE. default value is SNDRV_PCM_FORMAT_S16_LE(2). Signed-off-by: Shengjiu Wang --- arch/arm/boot/dts/imx6qdl.dtsi | 2 +-

[PATCH v4 1/8] ASoC: dt-bindings: fsl_asrc: Change asrc-width to asrc-format

2020-02-29 Thread Shengjiu Wang
asrc_format is more inteligent, which is align with the alsa definition snd_pcm_format_t, we don't need to convert it to format in driver, and it can distinguish S24_LE & S24_3LE. Signed-off-by: Shengjiu Wang --- Documentation/devicetree/bindings/sound/fsl,asrc.txt | 4 +++- 1 file changed, 3

[PATCH v3 3/8] powerpc/hv-24x7: Add sysfs files inside hv-24x7 device to show processor details

2020-02-29 Thread Kajol Jain
To expose the system dependent parameter like total number of sockets and numbers of chips per socket, patch adds two sysfs files. "sockets" and "chips" are added to /sys/devices/hv_24x7/interface/ of the "hv_24x7" pmu. Signed-off-by: Kajol Jain --- arch/powerpc/perf/hv-24x7.c | 22

[PATCH v3 4/8] Documentation/ABI: Add ABI documentation for chips and sockets

2020-02-29 Thread Kajol Jain
Add documentation for the following sysfs files: /sys/devices/hv_24x7/interface/chips, /sys/devices/hv_24x7/interface/sockets Signed-off-by: Kajol Jain --- .../testing/sysfs-bus-event_source-devices-hv_24x7 | 14 ++ 1 file changed, 14 insertions(+) diff --git

[PATCH v3 2/8] powerpc/hv-24x7: Add rtas call in hv-24x7 driver to get processor details

2020-02-29 Thread Kajol Jain
For hv_24x7 socket/chip level events, specific chip-id to which the data requested should be added as part of pmu events. But number of chips/socket in the system details are not exposed. Patch implements read_sys_info_pseries() to get system parameter values like number of sockets and chips per

[PATCH V2 5/9] crypto/nx: Rename nx-842-powernv file name to nx-common-powernv

2020-02-29 Thread Haren Myneni
Rename nx-842-powernv.c to nx-common-powernv.c to add code for setup and enable new GZIP compression type. The actual functionality is not changed in this patch. Signed-off-by: Haren Myneni --- drivers/crypto/nx/Makefile|2 +- drivers/crypto/nx/nx-842-powernv.c| 1062

[PATCH V2 4/9] crypto/nx: Initialize coproc entry with kzalloc

2020-02-29 Thread Haren Myneni
coproc entry is initialized during NX probe on power9, but not on P8. nx842_delete_coprocs() is used for both and frees receive window if it is allocated. Getting crash for rmmod on P8 since coproc->vas.rxwin is not initialized. This patch replaces kmalloc with kzalloc in nx842_powernv_probe()

[PATCH v4 0/8] ASoC: Add new module driver for new ASRC

2020-02-29 Thread Shengjiu Wang
Add new module driver for new ASRC in i.MX8MN, several commits are added for change DT binding asrc-width to asrc-format Shengjiu Wang (8): ASoC: dt-bindings: fsl_asrc: Change asrc-width to asrc-format ARM: dts: imx6qdl: Change asrc-width to asrc-format ASoC: fsl-asoc-card: Change

Re: [PATCH v3 0/6] implement KASLR for powerpc/fsl_booke/64

2020-02-29 Thread Scott Wood
On Sat, 2020-02-29 at 15:27 +0800, Jason Yan wrote: > > 在 2020/2/29 12:28, Scott Wood 写道: > > On Fri, 2020-02-28 at 14:47 +0800, Jason Yan wrote: > > > > > > 在 2020/2/28 13:53, Scott Wood 写道: > > > > > > > > I don't see any debug setting for %pK (or %p) to always print the > > > > actual > > >

[PATCH v4 8/8] ASoC: fsl_easrc: Add EASRC ASoC CPU DAI and platform drivers

2020-02-29 Thread Shengjiu Wang
EASRC (Enhanced Asynchronous Sample Rate Converter) is a new IP module found on i.MX8MN. It is different with old ASRC module. The primary features for the EASRC are as follows: - 4 Contexts - groups of channels with an independent time base - Fully independent and concurrent context control -

Re: [PATCH 8/8] powerpc: Update 83xx/85xx MAINTAINERS entry

2020-02-29 Thread Scott Wood
On Tue, 2020-02-25 at 10:31 +1100, Michael Ellerman wrote: > Scott said he was still maintaining this "sort of", so change the > status to Odd Fixes. > > Kumar has long ago moved on to greener pastures. > > Remove the dead penguinppc.org link. > > Cc: Scott Wood > Cc: Kumar Gala >

[PATCH v4 6/8] ASoC: fsl_asrc: Move common definition to fsl_asrc_common

2020-02-29 Thread Shengjiu Wang
There is a new ASRC included in i.MX serial platform, there are some common definition can be shared with each other. So move the common definition to a separate header file. And add fsl_asrc_pair_priv and fsl_asrc_priv for the variable specific for the module, which can be used internally.

[PATCH v4 5/8] ASoC: fsl_asrc: rename asrc_priv to asrc

2020-02-29 Thread Shengjiu Wang
In order to move common structure to fsl_asrc_common.h we change the name of asrc_priv to asrc, the asrc_priv will be used by new struct fsl_asrc_priv. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c | 300 +-- sound/soc/fsl/fsl_asrc.h | 4 +-

[PATCH v4 7/8] ASoC: dt-bindings: fsl_easrc: Add document for EASRC

2020-02-29 Thread Shengjiu Wang
EASRC (Enhanced Asynchronous Sample Rate Converter) is a new IP module found on i.MX8MN. Signed-off-by: Shengjiu Wang --- .../devicetree/bindings/sound/fsl,easrc.yaml | 96 +++ 1 file changed, 96 insertions(+) create mode 100644

Re: [PATCH 2/2] powerpc/83xx: Add some error handling in 'quirk_mpc8360e_qe_enet10()'

2020-02-29 Thread Scott Wood
On Sat, 2020-02-08 at 15:09 +0100, Christophe JAILLET wrote: > In some error handling path, we should call "of_node_put(np_par)" or > some resource may be leaking in case of error. > > Fixes: 8159df72d43e ("83xx: add support for the kmeter1 board.") > Signed-off-by: Christophe JAILLET > --- >

Re: [PATCH] powerpc/fsl_booke: avoid creating duplicate tlb1 entry

2020-02-29 Thread Scott Wood
On Thu, 2020-01-23 at 11:19 +, Laurentiu Tudor wrote: > In the current implementation, the call to loadcam_multi() is wrapped > between switch_to_as1() and restore_to_as0() calls so, when it tries > to create its own temporary AS=1 TLB1 entry, it ends up duplicating the > existing one created