[PATCH v2 8/8] regulator: sy8824x: add SY20278 support

2019-08-28 Thread Jisheng Zhang
The differences between SY8824C and SY20278 are different regs for mode/enable. Signed-off-by: Jisheng Zhang --- drivers/regulator/sy8824x.c | 13 + 1 file changed, 13 insertions(+) diff --git a/drivers/regulator/sy8824x.c b/drivers/regulator/sy8824x.c index 10d9180a0d77

[PATCH v2 7/8] dt-bindings: sy8824x: Document SY20278 support

2019-08-28 Thread Jisheng Zhang
SY20276 is an I2C-controlled adjustable voltage regulator made by Silergy Corp. The differences between SY8824C and SY20278 are different regs for mode/enable. Signed-off-by: Jisheng Zhang --- Documentation/devicetree/bindings/regulator/sy8824x.txt | 1 + 1 file changed, 1 insertion(+) diff

[PATCH v2 6/8] regulator: sy8824x: add SY20276 support

2019-08-28 Thread Jisheng Zhang
The differences between SY8824C and SY20276 are different vsel_min, vsel_step, vsel_count and regs for mode/enable. Signed-off-by: Jisheng Zhang --- drivers/regulator/sy8824x.c | 13 + 1 file changed, 13 insertions(+) diff --git a/drivers/regulator/sy8824x.c b/drivers/regulator

[PATCH v2 5/8] dt-bindings: sy8824x: Document SY20276 support

2019-08-28 Thread Jisheng Zhang
SY20276 is an I2C-controlled adjustable voltage regulator made by Silergy Corp. The differences between SY8824C and SY20276 are different vsel_min, vsel_step, vsel_count and regs for mode/enable. Signed-off-by: Jisheng Zhang --- Documentation/devicetree/bindings/regulator/sy8824x.txt | 3 ++- 1

[PATCH v2 4/8] regulator: sy8824x: add SY8824E support

2019-08-28 Thread Jisheng Zhang
The only difference between SY8824E and SY8824C is the vsel_min. Signed-off-by: Jisheng Zhang --- drivers/regulator/Kconfig | 2 +- drivers/regulator/sy8824x.c | 17 +++-- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/drivers/regulator/Kconfig b/drivers

[PATCH v2 3/8] dt-bindings: sy8824x: Document SY8824E support

2019-08-28 Thread Jisheng Zhang
SY8824E is an I2C-controlled adjustable voltage regulator made by Silergy Corp. The only difference between SY8824C and SY8824E is the vsel_min. Signed-off-by: Jisheng Zhang --- Documentation/devicetree/bindings/regulator/sy8824x.txt | 6 -- 1 file changed, 4 insertions(+), 2 deletions

[PATCH v2 2/8] regulator: add support for SY8824C regulator

2019-08-28 Thread Jisheng Zhang
SY8824C is an I2C attached single output regulator made by Silergy Corp, which is used on several Synaptics berlin platforms to control the power supply of the ARM cores. Add a driver for it. Signed-off-by: Jisheng Zhang --- drivers/regulator/Kconfig | 7 ++ drivers/regulator/Makefile

[PATCH v2 1/8] regulator: add binding for the SY8824C voltage regulator

2019-08-28 Thread Jisheng Zhang
SY8824C is an I2C-controlled adjustable voltage regulator made by Silergy Corp. Add its device tree binding. Signed-off-by: Jisheng Zhang --- .../devicetree/bindings/regulator/sy8824x.txt | 20 +++ 1 file changed, 20 insertions(+) create mode 100644 Documentation/devicetree

[PATCH v2 0/8] regulator: support Silergy SY8824C/SY8824E etc.

2019-08-28 Thread Jisheng Zhang
Add support for Silergy SY8824C/SY8824E/SY20276/SY20278 regulator. Changes since v1: - use c++ comment style for SPDX header - add prefix for BUCK_EN and MODE Jisheng Zhang (8): regulator: add binding for the SY8824C voltage regulator regulator: add support for SY8824C regulator dt

Re: [PATCH 2/8] regulator: add support for SY8824C regulator

2019-08-27 Thread Jisheng Zhang
On Wed, 28 Aug 2019 11:27:05 +0800 Jisheng Zhang wrote: > Hi Mark, > > On Tue, 27 Aug 2019 20:44:37 +0100 Mark Brown wrote: > > > On Tue, Aug 27, 2019 at 08:45:33AM +0000, Jisheng Zhang wrote: > > > > This looks mostly good and I'll apply it, a cou

Re: [PATCH 2/8] regulator: add support for SY8824C regulator

2019-08-27 Thread Jisheng Zhang
Hi Mark, On Tue, 27 Aug 2019 20:44:37 +0100 Mark Brown wrote: > On Tue, Aug 27, 2019 at 08:45:33AM +0000, Jisheng Zhang wrote: > > This looks mostly good and I'll apply it, a couple of small > things though: > > > @@ -0,0 +1,192 @@ > > +// SPDX-

[PATCH 8/8] regulator: sy8824x: add SY20278 support

2019-08-27 Thread Jisheng Zhang
The differences between SY8824C and SY20278 are different regs for mode/enable. Signed-off-by: Jisheng Zhang --- drivers/regulator/sy8824x.c | 13 + 1 file changed, 13 insertions(+) diff --git a/drivers/regulator/sy8824x.c b/drivers/regulator/sy8824x.c index 9410c3470870

[PATCH 7/8] dt-bindings: sy8824x: Document SY20278 support

2019-08-27 Thread Jisheng Zhang
SY20276 is an I2C-controlled adjustable voltage regulator made by Silergy Corp. The differences between SY8824C and SY20278 are different regs for mode/enable. Signed-off-by: Jisheng Zhang --- Documentation/devicetree/bindings/regulator/sy8824x.txt | 1 + 1 file changed, 1 insertion(+) diff

[PATCH 6/8] regulator: sy8824x: add SY20276 support

2019-08-27 Thread Jisheng Zhang
The differences between SY8824C and SY20276 are different vsel_min, vsel_step, vsel_count and regs for mode/enable. Signed-off-by: Jisheng Zhang --- drivers/regulator/sy8824x.c | 13 + 1 file changed, 13 insertions(+) diff --git a/drivers/regulator/sy8824x.c b/drivers/regulator

[PATCH 2/8] regulator: add support for SY8824C regulator

2019-08-27 Thread Jisheng Zhang
SY8824C is an I2C attached single output regulator made by Silergy Corp, which is used on several Synaptics berlin platforms to control the power supply of the ARM cores. Add a driver for it. Signed-off-by: Jisheng Zhang --- drivers/regulator/Kconfig | 7 ++ drivers/regulator/Makefile

[PATCH 5/8] dt-bindings: sy8824x: Document SY20276 support

2019-08-27 Thread Jisheng Zhang
SY20276 is an I2C-controlled adjustable voltage regulator made by Silergy Corp. The differences between SY8824C and SY20276 are different vsel_min, vsel_step, vsel_count and regs for mode/enable. Signed-off-by: Jisheng Zhang --- Documentation/devicetree/bindings/regulator/sy8824x.txt | 3 ++- 1

[PATCH 4/8] regulator: sy8824x: add SY8824E support

2019-08-27 Thread Jisheng Zhang
The only difference between SY8824E and SY8824C/D is the vsel_min. Signed-off-by: Jisheng Zhang --- drivers/regulator/Kconfig | 2 +- drivers/regulator/sy8824x.c | 17 +++-- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/drivers/regulator/Kconfig b/drivers

[PATCH 3/8] dt-bindings: sy8824x: Document SY8824E support

2019-08-27 Thread Jisheng Zhang
SY8824E is an I2C-controlled adjustable voltage regulator made by Silergy Corp. The only difference between SY8824C and SY8824E is the vsel_min. Signed-off-by: Jisheng Zhang --- Documentation/devicetree/bindings/regulator/sy8824x.txt | 6 -- 1 file changed, 4 insertions(+), 2 deletions

[PATCH 1/8] regulator: add binding for the SY8824C voltage regulator

2019-08-27 Thread Jisheng Zhang
SY8824C is an I2C-controlled adjustable voltage regulator made by Silergy Corp. Add its device tree binding. Signed-off-by: Jisheng Zhang --- .../devicetree/bindings/regulator/sy8824x.txt | 20 +++ 1 file changed, 20 insertions(+) create mode 100644 Documentation/devicetree

[PATCH 0/8] regulator: support Silergy SY8824C/SY8824E etc.

2019-08-27 Thread Jisheng Zhang
Add support for Silergy SY8824C/SY8824E/SY20276/SY20278 regulator. Jisheng Zhang (8): regulator: add binding for the SY8824C voltage regulator regulator: add support for SY8824C regulator dt-bindings: sy8824x: Document SY8824E support regulator: sy8824x: add SY8824E support dt-bindings

[tip: x86/cleanups] x86/ftrace: Remove mcount() declaration

2019-08-26 Thread tip-bot2 for Jisheng Zhang
The following commit has been merged into the x86/cleanups branch of tip: Commit-ID: 248d327ed7b6d3ebda2ac7b38482a306108bcd3e Gitweb: https://git.kernel.org/tip/248d327ed7b6d3ebda2ac7b38482a306108bcd3e Author:Jisheng Zhang AuthorDate:Mon, 26 Aug 2019 09:13:12 Committer

Re: [PATCH 1/3] ftrace: introdue ftrace_call_init

2019-08-26 Thread Jisheng Zhang
Hi all, On Tue, 20 Aug 2019 11:27:38 +0200 (CEST) Miroslav Benes wrote: > > Hi, > > On Mon, 19 Aug 2019, Jisheng Zhang wrote: > > > On some arch, the FTRACE_WITH_REGS is implemented with gcc's > > -fpatchable-function-entry (=2), gcc adds 2 NOPs at the beginni

[PATCH] ftrace/x86: Remove mcount() declaration

2019-08-26 Thread Jisheng Zhang
Commit 562e14f72292 ("ftrace/x86: Remove mcount support") removed the support for using mcount, so we could remove the mcount() declaration to clean up. Signed-off-by: Jisheng Zhang --- arch/x86/include/asm/ftrace.h | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/x86/i

[PATCH v3] ARM: ftrace: remove mcount(),ftrace_caller_old() and ftrace_call_old()

2019-08-23 Thread Jisheng Zhang
Commit d3c61619568c ("ARM: 8788/1: ftrace: remove old mcount support") removed the old mcount support, but forget to remove these three declarations. This patch removes them. Signed-off-by: Jisheng Zhang --- Changes since v2: - really remove mcount() declaration too. I made a mi

[PATCH v2] ARM: ftrace: remove mcount(),ftrace_caller_old() and ftrace_call_old()

2019-08-23 Thread Jisheng Zhang
Commit d3c61619568c ("ARM: 8788/1: ftrace: remove old mcount support") removed the old mcount support, but forget to remove these three declarations. This patch removes them. Signed-off-by: Jisheng Zhang --- Changes since v1: - remove mcount() declaration too arch/arm/include/as

[PATCH] kprobes/parisc: remove arch_kprobe_on_func_entry()

2019-08-21 Thread Jisheng Zhang
The common kprobes provides a weak implementation of arch_kprobe_on_func_entry(). The parisc version is the same as the common version, so remove it. Signed-off-by: Jisheng Zhang --- arch/parisc/kernel/kprobes.c | 4 1 file changed, 4 deletions(-) diff --git a/arch/parisc/kernel/kprobes.c

[PATCH] ARM: ftrace: remove ftrace_caller_old() and ftrace_call_old()

2019-08-21 Thread Jisheng Zhang
Commit d3c61619568c ("ARM: 8788/1: ftrace: remove old mcount support") removed the old mcount support, but forget to remove these two declarations. Remove them to clean up. Signed-off-by: Jisheng Zhang --- arch/arm/include/asm/ftrace.h | 3 --- 1 file changed, 3 deletions(-) diff --

[PATCH] kprobes/x86: use instruction_pointer and instruction_pointer_set

2019-08-20 Thread Jisheng Zhang
Use an arch-independent way to get/set the instruction pointer, we can make the x86 kprobe_ftrace_handler() more common. Signed-off-by: Jisheng Zhang Acked-by: Masami Hiramatsu --- arch/x86/kernel/kprobes/ftrace.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git

Re: [PATCH 1/3] ftrace: introdue ftrace_call_init

2019-08-20 Thread Jisheng Zhang
Hi, On Tue, 20 Aug 2019 11:27:38 +0200 (CEST) Miroslav Benes wrote: > > > Hi, > > On Mon, 19 Aug 2019, Jisheng Zhang wrote: > > > On some arch, the FTRACE_WITH_REGS is implemented with gcc's > > -fpatchable-function-entry (=2), gcc adds 2 NOPs at the begi

Re: [PATCH 4/4] arm64: implement KPROBES_ON_FTRACE

2019-08-19 Thread Jisheng Zhang
On Mon, 19 Aug 2019 22:22:12 +0530 "Naveen N. Rao" wrote: > > > Jisheng Zhang wrote: > > This patch implements KPROBES_ON_FTRACE for arm64. > > > > ~ # mount -t debugfs debugfs /sys/kernel/debug/ > > ~ # cd /sys/kernel/debug/ > > /sys/kernel/

Re: [PATCH 1/4] kprobes: adjust kprobe addr for KPROBES_ON_FTRACE

2019-08-19 Thread Jisheng Zhang
On Tue, 20 Aug 2019 09:01:30 +0900 Masami Hiramatsu wrote: > > Hi Jisheng, Hi, > > On Mon, 19 Aug 2019 11:36:09 +0000 > Jisheng Zhang wrote: > > > For KPROBES_ON_FTRACE case, we need to adjust the kprobe's addr > > correspondingly. > > No,

Re: [PATCH 3/4] kprobes: move kprobe_ftrace_handler() from x86 and make it weak

2019-08-19 Thread Jisheng Zhang
On Tue, 20 Aug 2019 09:07:35 +0900 Masami Hiramatsu wrote: > > > Hi Jisheng, Hi, > > On Mon, 19 Aug 2019 11:37:32 + > Jisheng Zhang wrote: > > > This code could be reused. So move it from x86 to common code. > > Yes, it can be among some arc

Re: [PATCH 1/4] kprobes: adjust kprobe addr for KPROBES_ON_FTRACE

2019-08-19 Thread Jisheng Zhang
On Mon, 19 Aug 2019 22:13:02 +0530 "Naveen N. Rao" wrote: > CAUTION: Email originated externally, do not click links or open attachments > unless you recognize the sender and know the content is safe. > > > Jisheng Zhang wrote: > > For KPROBES_ON_FTRACE case,

[PATCH 4/4] arm64: implement KPROBES_ON_FTRACE

2019-08-19 Thread Jisheng Zhang
LED] after the patch: /sys/kernel/debug # cat kprobes/list ff801009ff7c k _do_fork+0x4[DISABLED][FTRACE] Signed-off-by: Jisheng Zhang --- arch/arm64/Kconfig| 1 + arch/arm64/kernel/probes/Makefile | 1 + arch/arm64/kernel/probes/ftrace.c | 16 3 files chan

[PATCH 3/4] kprobes: move kprobe_ftrace_handler() from x86 and make it weak

2019-08-19 Thread Jisheng Zhang
This code could be reused. So move it from x86 to common code. Signed-off-by: Jisheng Zhang --- arch/x86/kernel/kprobes/ftrace.c | 44 kernel/kprobes.c | 44 2 files changed, 44 insertions(+), 44 deletions

[PATCH 2/4] kprobes/x86: use instruction_pointer and instruction_pointer_set

2019-08-19 Thread Jisheng Zhang
This is to make the kprobe_ftrace_handler() common, so we can move it to common code in next patch. Signed-off-by: Jisheng Zhang --- arch/x86/kernel/kprobes/ftrace.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/arch/x86/kernel/kprobes/ftrace.c b/arch/x86/kernel

[PATCH 1/4] kprobes: adjust kprobe addr for KPROBES_ON_FTRACE

2019-08-19 Thread Jisheng Zhang
For KPROBES_ON_FTRACE case, we need to adjust the kprobe's addr correspondingly. Signed-off-by: Jisheng Zhang --- kernel/kprobes.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kernel/kprobes.c b/kernel/kprobes.c index 9873fc627d61..f8400753a8a9 100644 --- a/kernel/kprobes.c +++ b

[PATCH 0/4] arm64: KPROBES_ON_FTRACE

2019-08-19 Thread Jisheng Zhang
Implement KPROBES_ON_FTRACE for arm64. Applied after FTRACE_WITH_REGS: http://lists.infradead.org/pipermail/linux-arm-kernel/2019-August/674404.html Jisheng Zhang (4): kprobes: adjust kprobe addr for KPROBES_ON_FTRACE kprobes/x86: use instruction_pointer and instruction_pointer_set kprobes

Re: [PATCH 1/3] ftrace: introdue ftrace_call_init

2019-08-19 Thread Jisheng Zhang
On Mon, 19 Aug 2019 19:16:22 +0800 Jisheng Zhang wrote: > On some arch, the FTRACE_WITH_REGS is implemented with gcc's > -fpatchable-function-entry (=2), gcc adds 2 NOPs at the beginning > of each function, so this makes the MCOUNT_ADDR useless. In ftrace > common framework,

[PATCH 3/3] arm64: use -fpatchable-function-entry if available

2019-08-19 Thread Jisheng Zhang
From: Torsten Duwe Test whether gcc supports -fpatchable-function-entry and use it to promote DYNAMIC_FTRACE to DYNAMIC_FTRACE_WITH_REGS. Amend support for the new object section that holds the locations (__patchable_function_entries) and define a proper "notrace" attribute to switch it off.

[PATCH 2/3] arm64: implement ftrace with regs

2019-08-19 Thread Jisheng Zhang
From: Torsten Duwe Implement ftrace with regs, based on the new gcc flag -fpatchable-function-entry (=2) Now that gcc8 added 2 NOPs at the beginning of each function, replace the first NOP thus generated with a quick LR saver (move it to scratch reg x9), so the 2nd replacement insn, the call to

[PATCH 1/3] ftrace: introdue ftrace_call_init

2019-08-19 Thread Jisheng Zhang
_call_init(). Signed-off-by: Jisheng Zhang --- include/linux/ftrace.h | 1 + kernel/trace/ftrace.c | 4 2 files changed, 5 insertions(+) diff --git a/include/linux/ftrace.h b/include/linux/ftrace.h index 8a8cb3c401b2..8175ffb671f0 100644 --- a/include/linux/ftrace.h +++ b/include/linu

[PATCH 0/3] arm64: ftrace with regs

2019-08-19 Thread Jisheng Zhang
Try to make the arm64 ftrace with regs merged. The later two patches are from Torsten. The whole series applies cleanly on v5.3-rc5 Jisheng Zhang (1): ftrace: introdue ftrace_call_init Torsten Duwe (2): arm64: implement ftrace with regs arm64: use -fpatchable-function-entry if available

[PATCH net-next] net: mvneta: use devm_platform_ioremap_resource() to simplify code

2019-07-25 Thread Jisheng Zhang
devm_platform_ioremap_resource() wraps platform_get_resource() and devm_ioremap_resource() in a single helper, let's use that helper to simplify the code. Signed-off-by: Jisheng Zhang --- drivers/net/ethernet/marvell/mvneta.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git

[PATCH] mmc: sdhci-pltfm: Use devm_platform_ioremap_resource() to simplify code

2019-07-25 Thread Jisheng Zhang
devm_platform_ioremap_resource() wraps platform_get_resource() and devm_ioremap_resource() in a single helper, let's use that helper to simplify the code. Signed-off-by: Jisheng Zhang --- drivers/mmc/host/sdhci-pltfm.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git

[PATCH v2 net-next] net: stmmac: move reset gpio parse & request to stmmac_mdio_register

2019-06-06 Thread Jisheng Zhang
Move the reset gpio dt parse and request to stmmac_mdio_register(), thus makes the mdio code straightforward. This patch also replace stack var mdio_bus_data with data to simplify the code. Signed-off-by: Jisheng Zhang --- Since v1: - rebase on the latest net-next tree .../net/ethernet

Re: [PATCH net-next] net: stmmac: Switch to devm_alloc_etherdev_mqs

2019-05-28 Thread Jisheng Zhang
On Tue, 28 May 2019 11:07:53 -0700 David Miller wrote: > > You never even tried to compiled this patch. > oops, my bad. I patched the another branch and tested the patch but when I manually patch net-next tree, I made a mistake. Sorry.

[PATCH net-next v2] net: stmmac: Switch to devm_alloc_etherdev_mqs

2019-05-28 Thread Jisheng Zhang
Make use of devm_alloc_etherdev_mqs() to simplify the code. Signed-off-by: Jisheng Zhang --- Since V1: - fix the build error, sorry, my bad. drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 11 +++ 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/drivers/net/ethernet

[PATCH net-next] net: stmmac: use dev_info() before netdev is registered

2019-05-28 Thread Jisheng Zhang
this patch: [3.155028] stmmaceth f7b6.ethernet: device MAC address 52:1a:55:18:9e:9d Signed-off-by: Jisheng Zhang --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/d

[PATCH net-next] net: stmmac: Switch to devm_alloc_etherdev_mqs

2019-05-27 Thread Jisheng Zhang
Make use of devm_alloc_etherdev_mqs() to simplify the code. Signed-off-by: Jisheng Zhang --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net

[PATCH] net: mvneta: Fix err code path of probe

2019-05-27 Thread Jisheng Zhang
Signed-off-by: Jisheng Zhang --- drivers/net/ethernet/marvell/mvneta.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/net/ethernet/marvell/mvneta.c b/drivers/net/ethernet/marvell/mvneta.c index e758650b2c26..269bd73be1a0 100644 --- a/drivers/net/ethernet/marvel

[PATCH] net: stmmac: move reset gpio parse & request to stmmac_mdio_register

2019-05-22 Thread Jisheng Zhang
Move the reset gpio dt parse and request to stmmac_mdio_register(), thus makes the mdio code straightforward. This patch also replace stack var mdio_bus_data with data to simplify the code. Signed-off-by: Jisheng Zhang --- .../net/ethernet/stmicro/stmmac/stmmac_mdio.c | 58

[PATCH] net: stmmac: fix reset gpio free missing

2019-05-22 Thread Jisheng Zhang
Commit 984203ceff27 ("net: stmmac: mdio: remove reset gpio free") removed the reset gpio free, when the driver is unbinded or rmmod, we miss the gpio free. This patch uses managed API to request the reset gpio, so that the gpio could be freed properly. Signed-off-by: Jisheng Zh

Re: [PATCH V3 04/16] PCI: dwc: Perform dbi regs write lock towards the end

2019-04-22 Thread Jisheng Zhang
On Wed, 17 Apr 2019 09:56:33 + Gustavo Pimentel wrote: > > On Tue, Apr 16, 2019 at 20:27:18, Vidya Sagar wrote: > > > Remove multiple write enable and disable sequences of dbi registers as > > Tegra194 implements writes to BAR-0 register (offset: 0x10) controlled by > > DBI write-lock

[PATCH] PCI: Make pci_aer_init() when !CONFIG_PCIEAER void too

2019-04-12 Thread Jisheng Zhang
Commit 60ed982a4e78 ("PCI/AER: Move internal declarations to drivers/pci/pci.h") makes pci_aer_init() void, but the version when !CONFIG_PCIEAER isn't modified accordingly, fix it. Signed-off-by: Jisheng Zhang --- drivers/pci/pci.h | 2 +- 1 file changed, 1 insertion(+), 1 deletio

Re: [PATCH v3 3/5] PCI: dwc: Free MSI in the error code path of dw_pcie_host_init()

2019-03-29 Thread Jisheng Zhang
On Thu, 28 Mar 2019 17:08:43 + Robin Murphy wrote: > > > On 18/03/2019 09:56, Jisheng Zhang wrote: > > If we ever did some msi related initializations, we need to call > > dw_pcie_free_msi() in the error code path. > > > > Signed-off-by: Jisheng Zhan

[PATCH v4 5/5] PCI: dwc: Save root bus for driver remove

2019-03-29 Thread Jisheng Zhang
) { ... pci_stop_root_bus(pp->root_bus); pci_remove_root_bus(pp->root_bus); dw_pcie_free_msi(pp); ... } Signed-off-by: Jisheng Zhang Acked-by: Gustavo Pimentel --- drivers/pci/controller/dwc/pcie-designware-host.c | 12 ++-- drivers/pci/controller/dw

[PATCH v4 4/5] PCI: dwc: Use devm_pci_alloc_host_bridge() to simplify the code

2019-03-29 Thread Jisheng Zhang
Use devm_pci_alloc_host_bridge() to simplify the error code path. Signed-off-by: Jisheng Zhang Acked-by: Gustavo Pimentel --- .../pci/controller/dwc/pcie-designware-host.c | 21 +++ 1 file changed, 8 insertions(+), 13 deletions(-) diff --git a/drivers/pci/controller/dwc/pcie

[PATCH v4 2/5] PCI: dwc: Free the page for MSI IRQ in dw_pcie_free_msi()

2019-03-29 Thread Jisheng Zhang
To avoid memory leak, we need to free the page for MSI in dw_pcie_free_msi(). Signed-off-by: Jisheng Zhang Acked-by: Gustavo Pimentel --- drivers/pci/controller/dwc/pcie-designware-host.c | 12 drivers/pci/controller/dwc/pcie-designware.h | 1 + 2 files changed, 9 insertions

[PATCH v4 3/5] PCI: dwc: Free MSI in the error code path of dw_pcie_host_init()

2019-03-29 Thread Jisheng Zhang
If we ever did some msi related initializations, we need to call dw_pcie_free_msi() in the error code path. We also remove the IS_ENABLED(CONFIG_PCI_MSI) check for MSI init, because pci_msi_enabled() already has a stub for !CONFIG_PCI_MSI. Signed-off-by: Jisheng Zhang Acked-by: Gustavo Pimentel

[PATCH v4 1/5] PCI: dwc: Fix dw_pcie_free_msi() if msi_irq is invalid

2019-03-29 Thread Jisheng Zhang
We should check msi_irq before calling irq_set_chained_handler() and irq_set_handler_data(). Signed-off-by: Jisheng Zhang Acked-by: Gustavo Pimentel --- drivers/pci/controller/dwc/pcie-designware-host.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/pci

[PATCH v4 0/5] PCI: dwc: Support remove

2019-03-29 Thread Jisheng Zhang
: - address all Gustavo's comments - add Gustavo's ACK to patch1, patch3, patch4 Changes since v1: - address Bjorn's comments, I.E Capitalize, s/irq/IRQ/, s/msi/MSI/ Jisheng Zhang (5): PCI: dwc: Fix dw_pcie_free_msi() if msi_irq is invalid PCI: dwc: Free the page for MSI IRQ

Re: [PATCH] PCI: Fix to avoid potential NULL pointer dereference

2019-03-18 Thread Jisheng Zhang
On Mon, 18 Mar 2019 19:26:30 -0500 Aditya Pakki wrote: > > In gen_pci_probe, of_match_node can return a NULL pointer in case of This could not happen. If the probe is called, it means OF registered a device with a valid compatible string, so of_match_node cannot be NULL. > failure. The patch

Re: [PATCH] pinctrl: berlin: as370: Fix to avoid NULL pointer dereference

2019-03-18 Thread Jisheng Zhang
On Mon, 18 Mar 2019 18:37:27 -0500 Aditya Pakki wrote: > > > of_match_device in as370_pinctrl_probe can return a NULL value > when the matching device is not found. The patch avoids a potential Similar as the comment to your previous patch, this could not happen. If the probe is called, it

Re: [PATCH] pinctrl: berlin: Fix to avoid NULL pointer dereference

2019-03-18 Thread Jisheng Zhang
On Mon, 18 Mar 2019 18:31:29 -0500 Aditya Pakki wrote: > > > of_match_device can return a NULL value when the matching device is This could not happen. If the probe is called, it means OF registered a device with a valid compatible string, so match cannot be NULL. > not found. The patch avoids

Re: PCI: dwc: Free MSI in the error code path of dw_pcie_host_init()

2019-03-18 Thread Jisheng Zhang
On Mon, 18 Mar 2019 17:47:49 +0800 Jisheng Zhang wrote: > If we ever did some msi related initializations, we need to call > dw_pcie_free_msi() in the error code path. Sorry, "PATCH" is missing in the email title, please ignore this one

[PATCH v3 5/5] PCI: dwc: Save root bus for driver remove

2019-03-18 Thread Jisheng Zhang
) { ... pci_stop_root_bus(pp->root_bus); pci_remove_root_bus(pp->root_bus); dw_pcie_free_msi(pp); ... } Signed-off-by: Jisheng Zhang --- drivers/pci/controller/dwc/pcie-designware-host.c | 12 ++-- drivers/pci/controller/dwc/pcie-designware.h | 1 + 2

[PATCH v3 4/5] PCI: dwc: Use devm_pci_alloc_host_bridge() to simplify the code

2019-03-18 Thread Jisheng Zhang
Use devm_pci_alloc_host_bridge() to simplify the error code path. Signed-off-by: Jisheng Zhang Acked-by: Gustavo Pimentel --- .../pci/controller/dwc/pcie-designware-host.c | 21 +++ 1 file changed, 8 insertions(+), 13 deletions(-) diff --git a/drivers/pci/controller/dwc/pcie

[PATCH v3 3/5] PCI: dwc: Free MSI in the error code path of dw_pcie_host_init()

2019-03-18 Thread Jisheng Zhang
If we ever did some msi related initializations, we need to call dw_pcie_free_msi() in the error code path. Signed-off-by: Jisheng Zhang Acked-by: Gustavo Pimentel --- drivers/pci/controller/dwc/pcie-designware-host.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git

PCI: dwc: Free MSI in the error code path of dw_pcie_host_init()

2019-03-18 Thread Jisheng Zhang
If we ever did some msi related initializations, we need to call dw_pcie_free_msi() in the error code path. Signed-off-by: Jisheng Zhang Acked-by: Gustavo Pimentel --- drivers/pci/controller/dwc/pcie-designware-host.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git

[PATCH v3 2/5] PCI: dwc: Free the page for MSI IRQ in dw_pcie_free_msi()

2019-03-18 Thread Jisheng Zhang
To avoid memory leak, we need to free the page for MSI in dw_pcie_free_msi(). Signed-off-by: Jisheng Zhang --- drivers/pci/controller/dwc/pcie-designware-host.c | 12 drivers/pci/controller/dwc/pcie-designware.h | 1 + 2 files changed, 9 insertions(+), 4 deletions(-) diff

[PATCH v3 1/5] PCI: dwc: Fix dw_pcie_free_msi() if msi_irq is invalid

2019-03-18 Thread Jisheng Zhang
We should check msi_irq before calling irq_set_chained_handler() and irq_set_handler_data(). Signed-off-by: Jisheng Zhang Acked-by: Gustavo Pimentel --- drivers/pci/controller/dwc/pcie-designware-host.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/pci

[PATCH v3 0/5] PCI: dwc: Support remove

2019-03-18 Thread Jisheng Zhang
: - address Bjorn's comments, I.E Capitalize, s/irq/IRQ/, s/msi/MSI/ Jisheng Zhang (5): PCI: dwc: Fix dw_pcie_free_msi() if msi_irq is invalid PCI: dwc: Free the page for MSI IRQ in dw_pcie_free_msi() PCI: dwc: Free MSI in the error code path of dw_pcie_host_init() PCI: dwc: Use

kernel 5.0 blk_clear_pm_only triggers a warning during resume

2019-03-11 Thread Jisheng Zhang
Hi, kernel version: 5.0 I got below warning during resume: [ 673.65] sd 0:0:0:0: [sda] Starting disk [ 673.658899] WARNING: CPU: 3 PID: 1039 at blk_clear_pm_only+0x2a/0x30 [ 673.658902] CPU: 3 PID: 1039 Comm: kworker/u8:49 Not tainted 5.0.0+ #1 [ 673.658902] sd 2:0:0:0: [sdb] Starting

[PATCH v2 5/5] PCI: dwc: Save root bus for driver remove

2019-02-28 Thread Jisheng Zhang
) { ... pci_stop_root_bus(pp->root_bus); pci_remove_root_bus(pp->root_bus); dw_pcie_free_msi(pp); ... } Signed-off-by: Jisheng Zhang --- drivers/pci/controller/dwc/pcie-designware-host.c | 1 + drivers/pci/controller/dwc/pcie-designware.h | 1 + 2 files chan

[PATCH v2 4/5] PCI: dwc: Use devm_pci_alloc_host_bridge() to simplify the code

2019-02-28 Thread Jisheng Zhang
Use devm_pci_alloc_host_bridge() to simplify the error code path. Signed-off-by: Jisheng Zhang --- .../pci/controller/dwc/pcie-designware-host.c | 21 +++ 1 file changed, 8 insertions(+), 13 deletions(-) diff --git a/drivers/pci/controller/dwc/pcie-designware-host.c b/drivers

[PATCH v2 3/5] PCI: dwc: Free MSI in the error code path of dw_pcie_host_init()

2019-02-28 Thread Jisheng Zhang
If we ever did some msi related initializations, we need to call dw_pcie_free_msi() in the error code path. Signed-off-by: Jisheng Zhang --- drivers/pci/controller/dwc/pcie-designware-host.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/pci/controller/dwc

[PATCH v2 2/5] PCI: dwc: Free the page for MSI IRQ in dw_pcie_free_msi()

2019-02-28 Thread Jisheng Zhang
To avoid memory leak, we need to free the page for MSI in dw_pcie_free_msi(). Signed-off-by: Jisheng Zhang --- drivers/pci/controller/dwc/pcie-designware-host.c | 3 +++ drivers/pci/controller/dwc/pcie-designware.h | 1 + 2 files changed, 4 insertions(+) diff --git a/drivers/pci

[PATCH v2 1/5] PCI: dwc: Fix dw_pcie_free_msi() if msi_irq is invalid

2019-02-28 Thread Jisheng Zhang
We should check msi_irq before calling irq_set_chained_handler() and irq_set_handler_data(). Signed-off-by: Jisheng Zhang --- drivers/pci/controller/dwc/pcie-designware-host.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/pci/controller/dwc/pcie-designware

[PATCH v2 0/5] PCI: dwc: Support remove

2019-02-28 Thread Jisheng Zhang
Currently, the PCI dwc host users don't support the remove, but nothing prevent us from supporting it. To achieve this goal, we need to ensure we can do necessary clean up work. Changes since v1: - address Bjorn's comments, I.E Capitalize, s/irq/IRQ/, s/msi/MSI/ Jisheng Zhang (5): PCI: dwc

Re: [PATCH 0/5] PCI: dwc: support remove

2019-02-26 Thread Jisheng Zhang
On Tue, 26 Feb 2019 15:11:03 -0600 Bjorn Helgaas wrote: > > > On Tue, Feb 26, 2019 at 5:55 AM Jisheng Zhang > wrote: > > > > Currently, the PCI dwc host users don't support the remove, but nothing > > prevent us from supporting it. To achieve this goal, w

[PATCH 5/5] PCI: dwc: save root bus for driver remove

2019-02-26 Thread Jisheng Zhang
) { ... pci_stop_root_bus(pp->root_bus); pci_remove_root_bus(pp->root_bus); dw_pcie_free_msi(pp); ... } Signed-off-by: Jisheng Zhang --- drivers/pci/controller/dwc/pcie-designware-host.c | 1 + drivers/pci/controller/dwc/pcie-designware.h | 1 + 2 files chan

[PATCH 4/5] PCI: dwc: use devm_pci_alloc_host_bridge() to simplify the code

2019-02-26 Thread Jisheng Zhang
Use devm_pci_alloc_host_bridge() to simplify the error code path. Signed-off-by: Jisheng Zhang --- .../pci/controller/dwc/pcie-designware-host.c | 21 +++ 1 file changed, 8 insertions(+), 13 deletions(-) diff --git a/drivers/pci/controller/dwc/pcie-designware-host.c b/drivers

[PATCH 3/5] PCI: dwc: free msi in the error code path of dw_pcie_host_init()

2019-02-26 Thread Jisheng Zhang
If we ever did some msi related initializations, we need to call dw_pcie_free_msi() in the error code path. Signed-off-by: Jisheng Zhang --- drivers/pci/controller/dwc/pcie-designware-host.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/pci/controller/dwc

[PATCH 2/5] PCI: dwc: free the page for MSI irq in dw_pcie_free_msi()

2019-02-26 Thread Jisheng Zhang
To avoid memory leak, we need to free the page for MSI in dw_pcie_free_msi(). Signed-off-by: Jisheng Zhang --- drivers/pci/controller/dwc/pcie-designware-host.c | 3 +++ drivers/pci/controller/dwc/pcie-designware.h | 1 + 2 files changed, 4 insertions(+) diff --git a/drivers/pci

[PATCH 1/5] PCI: dwc: fix dw_pcie_free_msi() if msi_irq is invalid

2019-02-26 Thread Jisheng Zhang
we should check msi_irq before calling irq_set_chained_handler() and irq_set_handler_data(). Signed-off-by: Jisheng Zhang --- drivers/pci/controller/dwc/pcie-designware-host.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/pci/controller/dwc/pcie-designware

[PATCH 0/5] PCI: dwc: support remove

2019-02-26 Thread Jisheng Zhang
Currently, the PCI dwc host users don't support the remove, but nothing prevent us from supporting it. To achieve this goal, we need to ensure we can do necessary clean up work. Jisheng Zhang (5): PCI: dwc: fix dw_pcie_free_msi() if msi_irq is invalid PCI: dwc: free the page for MSI irq

Re: [PATCH] watchdog: dw: use devm_watchdog_register_device()

2019-01-25 Thread Jisheng Zhang
Hi, On Fri, 25 Jan 2019 00:04:25 -0800 Guenter Roeck wrote: > Hi, > > On 1/24/19 11:52 PM, Jisheng Zhang wrote: > > Use devm_watchdog_register_device() to simplify the code. > > > > Signed-off-by: Jisheng Zhang > > --- > > drivers/watchdog/dw_wdt.c |

[PATCH] watchdog: dw: remove useless pr_fmt

2019-01-24 Thread Jisheng Zhang
When switch to watchdog infrastructure, pr_* usage is removed, so there's no any users of the pr_fmt, remove it. Signed-off-by: Jisheng Zhang --- drivers/watchdog/dw_wdt.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/watchdog/dw_wdt.c b/drivers/watchdog/dw_wdt.c index

[PATCH] watchdog: dw: use devm_watchdog_register_device()

2019-01-24 Thread Jisheng Zhang
Use devm_watchdog_register_device() to simplify the code. Signed-off-by: Jisheng Zhang --- drivers/watchdog/dw_wdt.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/watchdog/dw_wdt.c b/drivers/watchdog/dw_wdt.c index 501aebb5b81f..c053c2de5c2f 100644 --- a/drivers

[PATCH] pinctrl: berlin: as370: use generic "pwm" as pwm function name

2019-01-24 Thread Jisheng Zhang
So that we could use the generic "pwm" for two or more pins, e.g pwm0_pmux: pwm0-pmux { groups = "PWM0", "PWM1"; function = "pwm"; }; Signed-off-by: Jisheng Zhang --- drivers/pinctrl/berlin/pinctrl-as370.c

[PATCH] i3c: fix missing detach if failed to retrieve i3c dev

2019-01-24 Thread Jisheng Zhang
If we failed to retrieve the i3c dev, we should detach the i3c dev I.E i3c_master_detach_i3c_dev(). Signed-off-by: Jisheng Zhang --- drivers/i3c/master.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/i3c/master.c b/drivers/i3c/master.c index c39f89d2deba

[PATCH] i3c: master: dw: fix deadlock

2019-01-24 Thread Jisheng Zhang
ing to lock >xferqueue.lock. Signed-off-by: Jisheng Zhang --- drivers/i3c/master/dw-i3c-master.c | 18 -- 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/drivers/i3c/master/dw-i3c-master.c b/drivers/i3c/master/dw-i3c-master.c index f8c00b94817f..bb03079fbade

Re: [PATCH net] net: mvneta: fix operation for 64K PAGE_SIZE

2018-12-19 Thread Jisheng Zhang
On Wed, 19 Dec 2018 10:24:37 +0100 Marcin Wojtas wrote: > Hi Jisheng, > > śr., 19 gru 2018 o 04:11 Jisheng Zhang > napisał(a): > > > > > > On Mon, 17 Dec 2018 08:37:35 +0100 Thomas Petazzoni wrote: > > > > > Hello Marcin, > > > > &g

Re: [PATCH net] net: mvneta: fix operation for 64K PAGE_SIZE

2018-12-18 Thread Jisheng Zhang
On Mon, 17 Dec 2018 08:37:35 +0100 Thomas Petazzoni wrote: > Hello Marcin, > > On Mon, 17 Dec 2018 00:25:58 +0100, Marcin Wojtas wrote: > > > Thanks. Indeed, the patch is valid as a fix for current version of SW > > BM. However, because this concept is broken, I will rework it and > > submit

Re: [PATCH net] net: mvneta: fix operation for 64K PAGE_SIZE

2018-12-12 Thread Jisheng Zhang
Hi Marcin, On Wed, 12 Dec 2018 09:22:57 +0100 Marcin Wojtas wrote: > Hi Jisheng, > > śr., 12 gru 2018 o 03:48 Jisheng Zhang > napisał(a): > > > > Hi, > > > > On Tue, 11 Dec 2018 13:56:49 +0100 Marcin Wojtas wrote: > > > > > Rece

Re: [PATCH net] net: mvneta: fix operation for 64K PAGE_SIZE

2018-12-11 Thread Jisheng Zhang
Hi, On Tue, 11 Dec 2018 13:56:49 +0100 Marcin Wojtas wrote: > Recent changes in the mvneta driver reworked allocation > and handling of the ingress buffers to use entire pages. > Apart from that in SW BM scenario the HW must be informed > via PRXDQS about the biggest possible incoming buffer >

[BUG] sleep in atomic in 8250 runtime PM code path

2018-09-28 Thread Jisheng Zhang
Hi, Recently I found I could trigger sleep in atomic bug on berlin after commit d76c74387e1c ("serial: 8250_dw: Fix runtime PM handling"). The path looks like: dw8250_probe => serial850_register_8250_port => uart_add_one_port=> register_console => console_unlock => univ8250_console_write =>

[BUG] sleep in atomic in 8250 runtime PM code path

2018-09-28 Thread Jisheng Zhang
Hi, Recently I found I could trigger sleep in atomic bug on berlin after commit d76c74387e1c ("serial: 8250_dw: Fix runtime PM handling"). The path looks like: dw8250_probe => serial850_register_8250_port => uart_add_one_port=> register_console => console_unlock => univ8250_console_write =>

[PATCH] MAINTAINERS: fix pattern in ARM/Synaptics berlin SoC section

2018-09-28 Thread Jisheng Zhang
t's update the entries accordingly. Fixes: bc52497a595d ("MAINTAINERS: update entry for ARM/berlin") Signed-off-by: Jisheng Zhang Reported-by: Joe Perches --- MAINTAINERS | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index a255240d1452.

<    1   2   3   4   5   6   7   8   9   10   >