Re: [PATCH 3/8] powerpc: Mark functions called inside uaccess blocks w/ 'notrace'

2020-10-20 Thread Michael Ellerman
Peter Zijlstra writes: > On Fri, Oct 16, 2020 at 07:56:16AM +0100, Christoph Hellwig wrote: >> On Thu, Oct 15, 2020 at 10:01:54AM -0500, Christopher M. Riedl wrote: >> > Functions called between user_*_access_begin() and user_*_access_end() >> > should be either inlined or marked 'notrace' to prev

[PATCH v2 1/3] powerpc/uaccess: Don't use "m<>" constraint with GCC 4.9

2020-10-20 Thread Christophe Leroy
GCC 4.9 sometimes fails to build with "m<>" constraint in inline assembly. CC lib/iov_iter.o In file included from ./arch/powerpc/include/asm/cmpxchg.h:6:0, from ./arch/powerpc/include/asm/atomic.h:11, from ./include/linux/atomic.h:7, from

[PATCH v2 2/3] powerpc: Fix incorrect stw{, ux, u, x} instructions in __set_pte_at

2020-10-20 Thread Christophe Leroy
From: Mathieu Desnoyers The placeholder for instruction selection should use the second argument's operand, which is %1, not %0. This could generate incorrect assembly code if the memory addressing of operand %0 is a different form from that of operand %1. Fixes: 9bf2b5cdc5fe ("powerpc: Fixes fo

[PATCH v2 3/3] powerpc: Fix update form addressing in inline assembly

2020-10-20 Thread Christophe Leroy
In several places, inline assembly uses the "%Un" modifier to enable the use of instruction with update form addressing, but the associated "<>" constraint is missing. As mentioned in previous patch, this fails with gcc 4.9, so "<>" can't be used directly. Use UPD_CONSTR macro everywhere %Un modi

Re: [PATCH 3/3] powerpc: Fix pre-update addressing in inline assembly

2020-10-20 Thread Christophe Leroy
Le 19/10/2020 à 22:24, Segher Boessenkool a écrit : On Mon, Oct 19, 2020 at 12:12:48PM +, Christophe Leroy wrote: In several places, inline assembly uses the "%Un" modifier to enable the use of instruction with pre-update addressing, Calling this "pre-update" is misleading: the register

Re: [PATCH 2/2] powerpc/watchpoint: Workaround P10 DD1 issue with VSX-32 byte instructions

2020-10-20 Thread kernel test robot
, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/Ravi-Bangoria/powerpc-Introduce-POWER10_DD1-feature/20201020-134813 base: https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next confi

RE: [PATCH 08/20] dt-bindings: usb: renesas-xhci: Refer to the usb-xhci.yaml file

2020-10-20 Thread Yoshihiro Shimoda
Hi, > From: Serge Semin, Sent: Wednesday, October 14, 2020 7:14 PM > > With minor peculiarities (like uploading some vendor-specific firmware) > these are just Generic xHCI controllers fully compatible with its > properties. Make sure the Renesas USB xHCI DT nodes are also validated > against the

[PATCH v3 01/16] dt-bindings: usb: usb-hcd: Convert generic USB properties to DT schema

2020-10-20 Thread Serge Semin
The generic USB HCD properties have been described in the legacy bindings text file: Documentation/devicetree/bindings/usb/generic.txt . Let's convert it' content into the USB HCD DT schema properties so all USB DT nodes would be validated to have them properly utilized. Signed-off-by: Serge Semin

[PATCH v3 02/16] dt-bindings: usb: usb-hcd: Add "otg-rev" property restriction

2020-10-20 Thread Serge Semin
There are only four OTG revisions are currently supported by the kernel: 0x0100, 0x0120, 0x0130, 0x0200. Any another value is considered as invalid. Signed-off-by: Serge Semin Reviewed-by: Rob Herring --- Documentation/devicetree/bindings/usb/usb-hcd.yaml | 1 + 1 file changed, 1 insertion(+)

[PATCH v3 03/16] dt-bindings: usb: usb-hcd: Add "ulpi/serial/hsic" PHY types

2020-10-20 Thread Serge Semin
Aside from the UTMI+ there are also ULPI, Serial and HSIC PHY types that can be specified in the phy_type HCD property. Add them to the enumeration of the acceptable values. Signed-off-by: Serge Semin Reviewed-by: Rob Herring --- Changelog v2: - Grammar fix: "s/PHY types can be/PHY types that

[PATCH v3 04/16] dt-bindings: usb: usb-hcd: Add "tpl-support" property

2020-10-20 Thread Serge Semin
The host controller device might be designed to work for the particular products or applications. In that case its DT node is supposed to be equipped with the tpl-support property. Signed-off-by: Serge Semin Reviewed-by: Rob Herring --- Changelog v2: - Grammar fix: "s/it'/its" - Discard '|' fr

[PATCH v3 00/16] dt-bindings: usb: Add generic USB HCD, xHCI, DWC USB3 DT schema

2020-10-20 Thread Serge Semin
We've performed some work on the Generic USB HCD, xHCI and DWC USB3 DT bindings in the framework of the Baikal-T1 SoC support integration into the kernel. This patchset is a result of that work. First of all we moved the generic USB properties from the legacy text bindings into the USB HCD DT sche

[PATCH v3 07/16] dt-bindings: usb: xhci: Add Broadcom STB v2 compatible device

2020-10-20 Thread Serge Semin
For some reason the "brcm,xhci-brcm-v2" compatible string has been missing in the original bindings file. Add it to the Generic xHCI Controllers DT schema since the controller driver expects it to be supported. Signed-off-by: Serge Semin Acked-by: Florian Fainelli Reviewed-by: Rob Herring ---

[PATCH v3 12/16] dt-bindings: usb: dwc3: Add Frame Length Adj constraints

2020-10-20 Thread Serge Semin
In accordance with the IP core databook the snps,quirk-frame-length-adjustment property can be set within [0, 0x3F]. Let's make sure the DT schema applies a correct constraints on the property. Signed-off-by: Serge Semin Reviewed-by: Rob Herring --- Documentation/devicetree/bindings/usb/snps,dw

[PATCH v3 11/16] dt-bindings: usb: dwc3: Add Tx De-emphasis constraints

2020-10-20 Thread Serge Semin
In accordance with the driver comments the PIPE3 de-emphasis can be tuned to be either -6dB, -2.5dB or disabled. Let's add the de-emphasis property constraints so the DT schema would make sure the controller DT node is equipped with correct value. Signed-off-by: Serge Semin Reviewed-by: Rob Herri

[PATCH v3 14/16] dt-bindings: usb: meson-g12a-usb: Validate DWC2/DWC3 sub-nodes

2020-10-20 Thread Serge Semin
Amlogic G12A USB DT sub-nodes are supposed to be compatible with the generic DWC USB2 and USB3 devices. Since now we've got DT schemas for both of the later IP cores let's make sure that the Amlogic G12A USB DT nodes are fully evaluated including the DWC sub-nodes. Signed-off-by: Serge Semin Revi

[PATCH v3 09/16] dt-bindings: usb: Convert DWC USB3 bindings to DT schema

2020-10-20 Thread Serge Semin
DWC USB3 DT node is supposed to be compliant with the Generic xHCI Controller schema, but with additional vendor-specific properties, the controller-specific reference clocks and PHYs. So let's convert the currently available legacy text-based DWC USB3 bindings to the DT schema and make sure the DW

[PATCH v3 15/16] dt-bindings: usb: keystone-dwc3: Validate DWC3 sub-node

2020-10-20 Thread Serge Semin
TI Keystone DWC3 compatible DT node is supposed to have a DWC USB3 compatible sub-node to describe a fully functioning USB interface. Since DWC USB3 has now got a DT schema describing its DT node, let's make sure the TI Keystone DWC3 sub-node passes validation against it. Signed-off-by: Serge Semi

[PATCH v3 05/16] dt-bindings: usb: usb-hcd: Add generic "usb-phy" property

2020-10-20 Thread Serge Semin
Even though the Generic PHY framework is the more preferable way of setting the USB PHY up, there are still many dts-files and DT bindings which rely on having the legacy "usb-phy" specified to attach particular USB PHYs to USB cores. Let's have the "usb-phy" property described in the generic USB H

[PATCH v3 08/16] dt-bindings: usb: renesas-xhci: Refer to the usb-xhci.yaml file

2020-10-20 Thread Serge Semin
With minor peculiarities (like uploading some vendor-specific firmware) these are just Generic xHCI controllers fully compatible with its properties. Make sure the Renesas USB xHCI DT nodes are also validated against the Generic xHCI DT schema. Signed-off-by: Serge Semin Reviewed-by: Rob Herring

[PATCH v3 10/16] dt-bindings: usb: dwc3: Add interrupt-names property support

2020-10-20 Thread Serge Semin
The controller driver supports two types of DWC USB3 devices: with a common interrupt lane and with individual interrupts for each mode. Add support for both these cases to the DWC USB3 DT schema. Signed-off-by: Serge Semin Reviewed-by: Rob Herring --- Changelog v2: - Grammar fix: "s/both of t

[PATCH v3 06/16] dt-bindings: usb: Convert xHCI bindings to DT schema

2020-10-20 Thread Serge Semin
Currently the DT bindings of Generic xHCI Controllers are described by means of the legacy text file. Since such format is deprecated in favor of the DT schema, let's convert the Generic xHCI Controllers bindings file to the corresponding yaml files. There will be two of them: a DT schema for the x

[PATCH v3 16/16] dt-bindings: usb: qcom,dwc3: Validate DWC3 sub-node

2020-10-20 Thread Serge Semin
Qualcomm msm8996/sc7180/sdm845 DWC3 compatible DT nodes are supposed to have a DWC USB3 compatible sub-node to describe a fully functioning USB interface. Let's use the available DWC USB3 DT schema to validate the Qualcomm DWC3 sub-nodes. Note since the generic DWC USB3 DT node is supposed to be n

[PATCH v3 13/16] dt-bindings: usb: meson-g12a-usb: Fix FL-adj property value

2020-10-20 Thread Serge Semin
An empty snps,quirk-frame-length-adjustment won't cause any change performed by the driver. Moreover the DT schema validation will fail, since it expects the property being assigned with some value. So set fix the example by setting a valid FL-adj value in accordance with Neil Armstrong comment. L

Re: [PATCH v4] powerpc/pseries: Avoid using addr_to_pfn in real mode

2020-10-20 Thread Ganesh
On 7/24/20 12:09 PM, Ganesh Goudar wrote: When an UE or memory error exception is encountered the MCE handler tries to find the pfn using addr_to_pfn() which takes effective address as an argument, later pfn is used to poison the page where memory error occurred, recent rework in this area made

Re: [PATCH 3/3] powerpc: Fix pre-update addressing in inline assembly

2020-10-20 Thread Segher Boessenkool
On Tue, Oct 20, 2020 at 09:44:33AM +0200, Christophe Leroy wrote: > Le 19/10/2020 à 22:24, Segher Boessenkool a écrit : > >>but the associated "<>" constraint is missing. > > > >But that is just fine. Pointless, sure, but not a bug. > > Most of those are from prehistoric code. So at some point in

[PATCH 00/29] dt-bindings: usb: Harmonize xHCI/EHCI/OHCI/DWC3 nodes name

2020-10-20 Thread Serge Semin
As the subject states this series is an attempt to harmonize the xHCI, EHCI, OHCI and DWC USB3 DT nodes with the DT schema introduced in the framework of the patchset [1]. Firstly as Krzysztof suggested we've removed a support of DWC USB3 controllers with "synopsys,"-vendor prefix compatible strin

[PATCH 15/29] powerpc: dts: akebono: Harmonize EHCI/OHCI DT nodes name

2020-10-20 Thread Serge Semin
In accordance with the Generic EHCI/OHCI bindings the corresponding node name is suppose to comply with the Generic USB HCD DT schema, which requires the USB nodes to have the name acceptable by the regexp: "^usb(@.*)?" . Make sure the "generic-ehci" and "generic-ohci"-compatible nodes are correctl

Re: [PATCH v2 3/3] powerpc: Fix update form addressing in inline assembly

2020-10-20 Thread Segher Boessenkool
Hi! On Tue, Oct 20, 2020 at 07:40:09AM +, Christophe Leroy wrote: > In several places, inline assembly uses the "%Un" modifier > to enable the use of instruction with update form addressing, > but the associated "<>" constraint is missing. > > As mentioned in previous patch, this fails with g

Re: [PATCH] powerpc/powernv/dump: Handle multiple writes to ack attribute

2020-10-20 Thread Michael Ellerman
On Sat, 17 Oct 2020 22:12:36 +0530, Vasant Hegde wrote: > Even though we use self removing sysfs helper, we still need > to make sure we do the final kobject delete conditionally. > sysfs_remove_file_self() will handle parallel calls to remove > the sysfs attribute file and returns true only in the

Re: [PATCH v2] powerpc/powernv/dump: Fix race while processing OPAL dump

2020-10-20 Thread Michael Ellerman
On Sat, 17 Oct 2020 22:12:10 +0530, Vasant Hegde wrote: > Every dump reported by OPAL is exported to userspace through a sysfs > interface and notified using kobject_uevent(). The userspace daemon > (opal_errd) then reads the dump and acknowledges that the dump is > saved safely to disk. Once ackno

Re: [PATCH 1/2] powerpc: Fix user data corruption with P9N DD2.1 VSX CI load workaround emulation

2020-10-20 Thread Michael Ellerman
On Tue, 13 Oct 2020 15:37:40 +1100, Michael Neuling wrote: > __get_user_atomic_128_aligned() stores to kaddr using stvx which is a > VMX store instruction, hence kaddr must be 16 byte aligned otherwise > the store won't occur as expected. > > Unfortunately when we call __get_user_atomic_128_aligne

Re: [PATCH v2 0/2] Fixes for coregroup

2020-10-20 Thread Michael Ellerman
On Mon, 19 Oct 2020 09:57:14 +0530, Srikar Dronamraju wrote: > These patches fixes problems introduced by the coregroup patches. > The first patch we remove a redundant variable. > Second patch allows to boot with CONFIG_CPUMASK_OFFSTACK enabled. > > Changelog v1->v2: > https://lore.kernel.org/lin

Re: [PATCH 15/29] powerpc: dts: akebono: Harmonize EHCI/OHCI DT nodes name

2020-10-20 Thread Krzysztof Kozlowski
On Tue, Oct 20, 2020 at 02:59:45PM +0300, Serge Semin wrote: > In accordance with the Generic EHCI/OHCI bindings the corresponding node > name is suppose to comply with the Generic USB HCD DT schema, which > requires the USB nodes to have the name acceptable by the regexp: > "^usb(@.*)?" . Make sur

Re: [PATCH v3 09/16] dt-bindings: usb: Convert DWC USB3 bindings to DT schema

2020-10-20 Thread Rob Herring
On Tue, 20 Oct 2020 14:20:54 +0300, Serge Semin wrote: > DWC USB3 DT node is supposed to be compliant with the Generic xHCI > Controller schema, but with additional vendor-specific properties, the > controller-specific reference clocks and PHYs. So let's convert the > currently available legacy tex

Re: mm: Question about the use of 'accessed' flags and pte_young() helper

2020-10-20 Thread Vlastimil Babka
On 10/8/20 11:49 AM, Christophe Leroy wrote: In a 10 years old commit (https://github.com/linuxppc/linux/commit/d069cb4373fe0d451357c4d3769623a7564dfa9f), powerpc 8xx has made the handling of PTE accessed bit conditional to CONFIG_SWAP. Since then, this has been extended to some other powerpc va

Re: [PATCH] serial: pmac_zilog: don't init if zilog is not available

2020-10-20 Thread Greg KH
On Tue, Oct 20, 2020 at 06:23:03PM +0200, Laurent Vivier wrote: > We can avoid to probe for the Zilog device (and generate ugly kernel warning) > if kernel is built for Mac but not on a Mac. > > Signed-off-by: Laurent Vivier > --- > drivers/tty/serial/pmac_zilog.c | 11 +++ > 1 file chan

[PATCH] serial: pmac_zilog: don't init if zilog is not available

2020-10-20 Thread Laurent Vivier
We can avoid to probe for the Zilog device (and generate ugly kernel warning) if kernel is built for Mac but not on a Mac. Signed-off-by: Laurent Vivier --- drivers/tty/serial/pmac_zilog.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/drivers/tty/serial/pmac_zilog.c b/drivers/

Re: [PATCH] serial: pmac_zilog: don't init if zilog is not available

2020-10-20 Thread Laurent Vivier
Le 20/10/2020 à 18:28, Greg KH a écrit : > On Tue, Oct 20, 2020 at 06:23:03PM +0200, Laurent Vivier wrote: >> We can avoid to probe for the Zilog device (and generate ugly kernel warning) >> if kernel is built for Mac but not on a Mac. >> >> Signed-off-by: Laurent Vivier >> --- >> drivers/tty/ser

Re: [PATCH] serial: pmac_zilog: don't init if zilog is not available

2020-10-20 Thread Greg KH
On Tue, Oct 20, 2020 at 06:37:41PM +0200, Laurent Vivier wrote: > Le 20/10/2020 à 18:28, Greg KH a écrit : > > On Tue, Oct 20, 2020 at 06:23:03PM +0200, Laurent Vivier wrote: > >> We can avoid to probe for the Zilog device (and generate ugly kernel > >> warning) > >> if kernel is built for Mac but

Re: [PATCH] serial: pmac_zilog: don't init if zilog is not available

2020-10-20 Thread Laurent Vivier
Le 20/10/2020 à 19:37, Greg KH a écrit : > On Tue, Oct 20, 2020 at 06:37:41PM +0200, Laurent Vivier wrote: >> Le 20/10/2020 à 18:28, Greg KH a écrit : >>> On Tue, Oct 20, 2020 at 06:23:03PM +0200, Laurent Vivier wrote: We can avoid to probe for the Zilog device (and generate ugly kernel

Re: [PATCH] serial: pmac_zilog: don't init if zilog is not available

2020-10-20 Thread Greg KH
On Tue, Oct 20, 2020 at 08:19:26PM +0200, Laurent Vivier wrote: > Le 20/10/2020 à 19:37, Greg KH a écrit : > > On Tue, Oct 20, 2020 at 06:37:41PM +0200, Laurent Vivier wrote: > >> Le 20/10/2020 à 18:28, Greg KH a écrit : > >>> On Tue, Oct 20, 2020 at 06:23:03PM +0200, Laurent Vivier wrote: > W

Re: mm: Question about the use of 'accessed' flags and pte_young() helper

2020-10-20 Thread Johannes Weiner
On Tue, Oct 20, 2020 at 05:52:07PM +0200, Vlastimil Babka wrote: > On 10/8/20 11:49 AM, Christophe Leroy wrote: > > In a 10 years old commit > > (https://github.com/linuxppc/linux/commit/d069cb4373fe0d451357c4d3769623a7564dfa9f), > > powerpc 8xx has > > made the handling of PTE accessed bit condit

Re: [PATCH] serial: pmac_zilog: don't init if zilog is not available

2020-10-20 Thread Laurent Vivier
Le 20/10/2020 à 20:32, Greg KH a écrit : > On Tue, Oct 20, 2020 at 08:19:26PM +0200, Laurent Vivier wrote: >> Le 20/10/2020 à 19:37, Greg KH a écrit : >>> On Tue, Oct 20, 2020 at 06:37:41PM +0200, Laurent Vivier wrote: Le 20/10/2020 à 18:28, Greg KH a écrit : > On Tue, Oct 20, 2020 at 06:2

Re: [PATCH v3 05/16] dt-bindings: usb: usb-hcd: Add generic "usb-phy" property

2020-10-20 Thread Martin Blumenstingl
On Tue, Oct 20, 2020 at 1:21 PM Serge Semin wrote: > > Even though the Generic PHY framework is the more preferable way of > setting the USB PHY up, there are still many dts-files and DT bindings > which rely on having the legacy "usb-phy" specified to attach particular > USB PHYs to USB cores. Le

Re: [PATCH] serial: pmac_zilog: don't init if zilog is not available

2020-10-20 Thread Brad Boyer
On Tue, Oct 20, 2020 at 08:42:53PM +0200, Laurent Vivier wrote: > Le 20/10/2020 ?? 20:32, Greg KH a ??crit??: > > On Tue, Oct 20, 2020 at 08:19:26PM +0200, Laurent Vivier wrote: > >> Le 20/10/2020 ?? 19:37, Greg KH a ??crit??: > >>> Why not fix it to work properly like other arch checks are done >

Re: [PATCH] serial: pmac_zilog: don't init if zilog is not available

2020-10-20 Thread Finn Thain
On Tue, 20 Oct 2020, Brad Boyer wrote: > > Wouldn't it be better to rearrange this code to only run if the devices > are present? This is a macio driver on pmac and a platform driver on > mac, so shouldn't it be possible to only run this code when the > appropriate entries are present in the r

[PATCH kernel 0/2] powerpc/dma: Fallback to dma_ops when persistent memory present

2020-10-20 Thread Alexey Kardashevskiy
This allows mixing direct DMA (to/from RAM) and IOMMU (to/from apersistent memory) on the PPC64/pseries platform. This was supposed to be a single patch but unexpected move of direct DMA functions happened. This is based on sha1 7cf726a59435 Linus Torvalds "Merge tag 'linux-kselftest-kunit-5.10-rc

Re: [PATCH v3 01/16] dt-bindings: usb: usb-hcd: Convert generic USB properties to DT schema

2020-10-20 Thread Chunfeng Yun
On Tue, 2020-10-20 at 14:20 +0300, Serge Semin wrote: > The generic USB HCD properties have been described in the legacy bindings > text file: Documentation/devicetree/bindings/usb/generic.txt . Let's > convert it' content into the USB HCD DT schema properties so all USB DT ^ its? > nodes

[PATCH kernel 2/2] powerpc/dma: Fallback to dma_ops when persistent memory present

2020-10-20 Thread Alexey Kardashevskiy
So far we have been using huge DMA windows to map all the RAM available. The RAM is normally mapped to the VM address space contiguously, and there is always a reasonable upper limit for possible future hot plugged RAM which makes it easy to map all RAM via IOMMU. Now there is persistent memory ("

[PATCH kernel 1/2] Revert "dma-mapping: move large parts of to kernel/dma"

2020-10-20 Thread Alexey Kardashevskiy
This reverts commit 19c65c3d30bb5a97170e425979d2e44ab2096c7d which was a right move but sadly there is a POWERPC/pseries hardware config which uses a mixture of direct and IOMMU DMA but bringing this logic to the generic code won't benefit anybody else. The user of this revert comes in the next pat

[powerpc:fixes-test] BUILD SUCCESS d1781f23704707d350b8c9006e2bdf5394bf91b2

2020-10-20 Thread kernel test robot
defconfig mips allyesconfig mips allmodconfig powerpc allyesconfig powerpc allmodconfig powerpc allnoconfig i386 randconfig-a002-20201020 i386

[powerpc:merge] BUILD SUCCESS 598b738031de83cadbcf745ad0ad2bd69a0ee012

2020-10-20 Thread kernel test robot
ig powerpc allyesconfig powerpc allmodconfig powerpc allnoconfig i386 randconfig-a002-20201020 i386 randconfig-a005-20201020 i386 randconfig-a003-20201020 i386 randconfig-a00

Re: [PATCH 2/2] dt: Remove booting-without-of.rst

2020-10-20 Thread Mauro Carvalho Chehab
Hi Rob, Em Thu, 8 Oct 2020 09:24:20 -0500 Rob Herring escreveu: > booting-without-of.rstt is an ancient document that first outlined > Flattened DeviceTree on PowerPC initially. The DT world has evolved a > lot in the 15 years since and booting-without-of.rst is pretty stale. > The name of the