Re: [RFC PATCH v3 1/2] mempinfd: Add new syscall to provide memory pin

2021-02-09 Thread Zhou Wang
On 2021/2/9 20:01, Greg KH wrote: > On Tue, Feb 09, 2021 at 07:58:15PM +0800, Zhou Wang wrote: >> On 2021/2/9 17:37, Greg KH wrote: >>> On Tue, Feb 09, 2021 at 05:17:46PM +0800, Zhou Wang wrote: >>>> On 2021/2/8 6:02, Andy Lutomirski wrote: >>>>> >&g

Re: [RFC PATCH v3 1/2] mempinfd: Add new syscall to provide memory pin

2021-02-09 Thread Zhou Wang
On 2021/2/9 17:37, Greg KH wrote: > On Tue, Feb 09, 2021 at 05:17:46PM +0800, Zhou Wang wrote: >> On 2021/2/8 6:02, Andy Lutomirski wrote: >>> >>> >>>> On Feb 7, 2021, at 12:31 AM, Zhou Wang wrote: >>>> >>>> SVA(share virtual

Re: [RFC PATCH v3 1/2] mempinfd: Add new syscall to provide memory pin

2021-02-09 Thread Zhou Wang
On 2021/2/8 5:51, Arnd Bergmann wrote: > On Sun, Feb 7, 2021 at 9:18 AM Zhou Wang wrote: > >> diff --git a/arch/arm64/include/asm/unistd32.h >> b/arch/arm64/include/asm/unistd32.h >> index cccfbbe..3f49529 100644 >> --- a/arch/arm64/include/asm/unistd32.h &

Re: [RFC PATCH v3 1/2] mempinfd: Add new syscall to provide memory pin

2021-02-09 Thread Zhou Wang
On 2021/2/8 6:02, Andy Lutomirski wrote: > > >> On Feb 7, 2021, at 12:31 AM, Zhou Wang wrote: >> >> SVA(share virtual address) offers a way for device to share process virtual >> address space safely, which makes more convenient for user space device >> dr

Re: [RFC PATCH v3 1/2] mempinfd: Add new syscall to provide memory pin

2021-02-09 Thread Zhou Wang
On 2021/2/8 5:34, Matthew Wilcox wrote: > On Sun, Feb 07, 2021 at 04:18:03PM +0800, Zhou Wang wrote: >> SVA(share virtual address) offers a way for device to share process virtual >> address space safely, which makes more convenient for user space device >> driver coding. Ho

[RFC PATCH v3 2/2] selftests/vm: add mempinfd test

2021-02-07 Thread Zhou Wang
This test gets a fd from new mempinfd syscall and creates multiple threads to do pin/unpin memory. Signed-off-by: Zhou Wang Suggested-by: Barry Song --- tools/testing/selftests/vm/Makefile | 1 + tools/testing/selftests/vm/mempinfd.c | 131 ++ 2 files

[RFC PATCH v3 0/2] mempinfd: Add new syscall to provide memory pin

2021-02-07 Thread Zhou Wang
/msg3805205.html Zhou Wang (2): mempinfd: Add new syscall to provide memory pin selftests/vm: add mempinfd test arch/arm64/include/asm/unistd.h | 2 +- arch/arm64/include/asm/unistd32.h | 2 + fs/Makefile | 1 + fs/mempinfd.c

[RFC PATCH v3 1/2] mempinfd: Add new syscall to provide memory pin

2021-02-07 Thread Zhou Wang
pin page cases in other places, can_do_mlock is used to check permission and input parameters. Signed-off-by: Zhou Wang Signed-off-by: Sihang Chen Suggested-by: Barry Song --- arch/arm64/include/asm/unistd.h | 2 +- arch/arm64/include/asm/unistd32.h | 2 + fs/Makefile

Re: [RFC PATCH v2] uacce: Add uacce_ctrl misc device

2021-01-26 Thread Zhou Wang
On 2021/1/25 23:47, Jason Gunthorpe wrote: > On Mon, Jan 25, 2021 at 04:34:56PM +0800, Zhou Wang wrote: > >> +static int uacce_pin_page(struct uacce_pin_container *priv, >> + struct uacce_pin_address *addr) >> +{ >> +unsigned int f

Re: [RFC PATCH v2] uacce: Add uacce_ctrl misc device

2021-01-25 Thread Zhou Wang
On 2021/1/25 17:28, Greg Kroah-Hartman wrote: > On Mon, Jan 25, 2021 at 04:34:56PM +0800, Zhou Wang wrote: >> +static int uacce_pin_page(struct uacce_pin_container *priv, >> + struct uacce_pin_address *addr) >> +{ >> +unsigned int flag

[RFC PATCH v2] uacce: Add uacce_ctrl misc device

2021-01-25 Thread Zhou Wang
r one file will be unpinned in file release process. Signed-off-by: Zhou Wang Signed-off-by: Sihang Chen Suggested-by: Barry Song --- Changes v1 -> v2: - Some tiny fixes - Follow Greg's suggestion to get mm-list and iommu-list involved. v1: https://lwn.net/Articles/843432/ --- drivers/

Re: [PATCH] uacce: Add uacce_ctrl misc device

2021-01-22 Thread Zhou Wang
On 2021/1/21 17:44, Greg Kroah-Hartman wrote: > On Thu, Jan 21, 2021 at 05:09:14PM +0800, Zhou Wang wrote: >> When IO page fault happens, DMA performance will be affected. Pin user page >> can avoid IO page fault, this patch introduces a new char device named >> /dev/uacce_ctr

[PATCH] uacce: Add uacce_ctrl misc device

2021-01-21 Thread Zhou Wang
under one file will be unpinned in file release process. Signed-off-by: Zhou Wang Signed-off-by: Sihang Chen Suggested-by: Barry Song --- drivers/misc/uacce/uacce.c | 172 +++- include/uapi/misc/uacce/uacce.h | 16 2 files changed, 187 insertions

Re: [PATCH 0/2] Introduce PCI_FIXUP_IOMMU

2020-12-16 Thread Zhou Wang
On 2020/6/23 23:04, Bjorn Helgaas wrote: > On Fri, Jun 19, 2020 at 10:26:54AM +0800, Zhangfei Gao wrote: >> Have studied _DSM method, two issues we met comparing using quirk. >> >> 1. Need change definition of either pci_host_bridge or pci_dev, like adding >> member can_stall, >> while pci system d

Re: [PATCH] crypto: hisilicon/zip - add a work_queue for zip irq

2020-11-19 Thread Zhou Wang
te a 'work_queue' and set as 'WQ_UNBOUND' to do the back half work > on some different CPUS. > > Signed-off-by: Yang Shen > Reviewed-by: Zaibo Xu Reviewed-by: Zhou Wang Thanks, Zhou > --- > drivers/crypto/hisilicon/zip/zip_main.c | 26

Re: [PATCH v3 0/2] uacce: fix some coding styles

2020-11-02 Thread Zhou Wang
On 2020/11/2 16:33, Greg Kroah-Hartman wrote: > On Mon, Nov 02, 2020 at 03:38:49PM +0800, Zhou Wang wrote: >> On 2020/11/2 15:09, Greg Kroah-Hartman wrote: >>> On Mon, Nov 02, 2020 at 02:41:12PM +0800, Zhou Wang wrote: >>>> On 2020/9/23 18:09, Kai Ye wrote: >&

Re: [PATCH v3 0/2] uacce: fix some coding styles

2020-11-01 Thread Zhou Wang
On 2020/11/2 15:09, Greg Kroah-Hartman wrote: > On Mon, Nov 02, 2020 at 02:41:12PM +0800, Zhou Wang wrote: >> On 2020/9/23 18:09, Kai Ye wrote: >>> 1. delete some redundant code. >>> 2. modify the module author information. "Hisilicon" >>> spelling i

Re: [PATCH v3 2/2] uacce: modify the module author information.

2020-11-01 Thread Zhou Wang
On 2020/9/23 18:09, Kai Ye wrote: > The spelling of "Hisilicon" is modified. > > Signed-off-by: Kai Ye > Reviewed-by: Zhou Wang > Reviewed-by: Jonathan Cameron > Acked-by: Zhangfei Gao > --- > drivers/misc/uacce/uacce.c | 2 +- > 1 file changed, 1 insert

Re: [PATCH v3 1/2] uacce: delete some redundant code.

2020-11-01 Thread Zhou Wang
On 2020/9/23 18:09, Kai Ye wrote: > Delete some redundant code. > > Signed-off-by: Kai Ye > Reviewed-by: Zhou Wang > Reviewed-by: Jonathan Cameron > Acked-by: Zhangfei Gao > --- > drivers/misc/uacce/uacce.c | 11 --- > 1 file changed, 11 deletions(-) >

Re: [PATCH v3 0/2] uacce: fix some coding styles

2020-11-01 Thread Zhou Wang
On 2020/9/23 18:09, Kai Ye wrote: > 1. delete some redundant code. > 2. modify the module author information. "Hisilicon" > spelling is error. > > Changes v2 -> v3: > Two things, splited to two patches. > Changes v1 -> v2: > deleted extra NULL pointer check in uacce_fops. > > Kai Ye (

Re: [BUG] crypto: hisilicon: accessing the data mapped to streaming DMA

2020-08-06 Thread Zhou Wang
On 2020/8/3 9:29, Jia-Ju Bai wrote: > > > On 2020/8/3 9:12, Zhou Wang wrote: >> On 2020/8/2 22:52, Jia-Ju Bai wrote: >>> In qm_qp_ctx_cfg(), "sqc" and "aeqc" are mapped to streaming DMA: >>>eqc_dma = dma_map_single(..., eqc, ...); >

Re: [BUG] crypto: hisilicon: accessing the data mapped to streaming DMA

2020-08-02 Thread Zhou Wang
On 2020/8/2 22:52, Jia-Ju Bai wrote: > In qm_qp_ctx_cfg(), "sqc" and "aeqc" are mapped to streaming DMA: > eqc_dma = dma_map_single(..., eqc, ...); > .. > aeqc_dma = dma_map_single(..., aeqc, ...); Only sqc, cqc will be configured in qm_qp_ctx_cfg. > > Then "sqc" and "aeqc" are accesse

Re: [PATCH] uacce: fix some coding styles

2020-07-30 Thread Zhou Wang
On 2020/7/30 14:13, Kai Ye wrote: > 1. delete some redundant code. > 2. modify the module author information. > > Signed-off-by: Kai Ye Fine to me. Reviewed-by: Zhou Wang Thanks, Zhou > --- > Changes in V2: > deleted extra NULL pointer check in uacce_fops. >

Re: [PATCH][next] dmaengine: hisilicon: Use struct_size() in devm_kzalloc()

2020-06-21 Thread Zhou Wang
: Gustavo A. R. Silva Looks good to me, thanks! Reviewed-by: Zhou Wang > --- > drivers/dma/hisi_dma.c | 5 + > 1 file changed, 1 insertion(+), 4 deletions(-) > > diff --git a/drivers/dma/hisi_dma.c b/drivers/dma/hisi_dma.c > index ed3619266a48..e1a958ae7925 100644 > --

Re: [PATCH] crypto: hisilicon - fix strncpy warning with strlcpy

2020-06-04 Thread Zhou Wang
On 2020/6/4 14:50, Herbert Xu wrote: > On Thu, Jun 04, 2020 at 02:44:16PM +0800, Zhangfei Gao wrote: >> >> I think it is fine. >> 1. Currently the name size is 64, bigger enough. >> Simply grep in driver name, 64 should be enough. >> We can make it larger when there is a request. >> 2. it does not

Re: [PATCH] crypto: hisilicon/qm - allow smaller reads in debugfs

2020-05-28 Thread Zhou Wang
tes which would > have been copied if there were enough space and scnprintf() returns the > number of bytes which were actually copied. It doesn't matter here > because the strings are very short so they can't go over 256 bytes. > > Signed-off-by: Dan Carpenter Looks go

Re: [PATCH 3/4] crypto: hisilicon/zip - constify struct debugfs_reg32

2020-05-08 Thread Zhou Wang
480 218765574 > drivers/crypto/hisilicon/zip/zip_main.o > > After: >textdata bss dec hex filename > 156205776 480 218765574 > drivers/crypto/hisilicon/zip/zip_main.o > > Signed-off-by: Rikard Falkeborn Reviewed-by: Zhou Wang

Re: [PATCH][crypto-next] crypto: hisilicon: fix spelling mistake "HZIP_COMSUMED_BYTE" -> "HZIP_CONSUMED_BYTE"

2019-08-12 Thread Zhou Wang
On 2019/8/12 19:15, Colin King wrote: > From: Colin Ian King > > There is a spelling mistake in the hzip_dfx_regs array, fix this. > > Signed-off-by: Colin Ian King > --- > drivers/crypto/hisilicon/zip/zip_main.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers

Re: [PATCH resend v2] lib: scatterlist: Fix to support no mapped sg

2019-08-08 Thread Zhou Wang
On 2019/8/8 21:40, Jens Axboe wrote: > On 7/28/19 6:44 PM, Zhou Wang wrote: >> On 2019/7/24 11:54, Zhou Wang wrote: >>> In function sg_split, the second sg_calculate_split will return -EINVAL >>> when in_mapped_nents is 0. >>> >>> Indeed there i

Re: [PATCH resend v2] lib: scatterlist: Fix to support no mapped sg

2019-08-05 Thread Zhou Wang
On 2019/7/29 9:44, Zhou Wang wrote: > On 2019/7/24 11:54, Zhou Wang wrote: >> In function sg_split, the second sg_calculate_split will return -EINVAL >> when in_mapped_nents is 0. >> >> Indeed there is no need to do second sg_calculate_split and sg_split_mapped >&

[PATCH v3 3/7] crypto: hisilicon - add HiSilicon ZIP accelerator support

2019-08-02 Thread Zhou Wang
The HiSilicon ZIP accelerator implements the zlib and gzip algorithm. It uses Hisilicon QM as the interface to the CPU. This patch provides PCIe driver to the accelerator and registers it to crypto acomp interface. It also uses sgl as data input/output interface. Signed-off-by: Zhou Wang Signed

Re: [PATCH resend v2] lib: scatterlist: Fix to support no mapped sg

2019-07-28 Thread Zhou Wang
On 2019/7/24 11:54, Zhou Wang wrote: > In function sg_split, the second sg_calculate_split will return -EINVAL > when in_mapped_nents is 0. > > Indeed there is no need to do second sg_calculate_split and sg_split_mapped > when in_mapped_nents is 0, as in_mapped_nents indicates no

[PATCH resend v2] lib: scatterlist: Fix to support no mapped sg

2019-07-23 Thread Zhou Wang
In function sg_split, the second sg_calculate_split will return -EINVAL when in_mapped_nents is 0. Indeed there is no need to do second sg_calculate_split and sg_split_mapped when in_mapped_nents is 0, as in_mapped_nents indicates no mapped entry in original sgl. Signed-off-by: Zhou Wang Acked

Re: [PATCH] lib: scatterlist: Fix to support no mapped sg

2019-04-19 Thread Zhou Wang
On 2019/4/19 18:43, Robert Jarzmik wrote: > Zhou Wang writes: > >> In function sg_split, the second sg_calculate_split will return -EINVAL >> when in_mapped_nents is 0. >> >> Indeed there is no need to do second sg_calculate_split and sg_split_mapped &g

[PATCH] lib: scatterlist: Fix to support no mapped sg

2019-04-18 Thread Zhou Wang
In function sg_split, the second sg_calculate_split will return -EINVAL when in_mapped_nents is 0. Indeed there is no need to do second sg_calculate_split and sg_split_mapped when in_mapped_nents is 0, as in_mapped_nents indicates no mapped entry in original sgl. Signed-off-by: Zhou Wang

Re: [PATCH] pci: fix warning for struct hisi_pcie_platform_ops

2019-04-15 Thread Zhou Wang
-gnu- > drivers/pci/controller/dwc/pcie-hisi.c:365:21: warning: symbol > 'hisi_pcie_platform_ops' was not declared. Should it be static? > > Fixes: a2ec1996098("PCI: hisi: Add DT almost-ECAM support for Hip06/Hip07 > host controllers") > Reported-by: Hulk Ro

Re: [PATCH v2 2/4] crypto: hisilicon: Add queue management driver for HiSilicon QM module

2019-02-19 Thread Zhou Wang
On 2019/2/20 12:10, Herbert Xu wrote: > On Sat, Feb 02, 2019 at 10:25:43AM +0800, Zhou Wang wrote: >> >> In fact, I planned to register to acomp later. >> >> It also makes sense to use scomp if hardware engine is faster than CPU. >> So how about registering to sco

Re: [PATCH v2 2/4] crypto: hisilicon: Add queue management driver for HiSilicon QM module

2019-02-01 Thread Zhou Wang
On 2019/2/1 23:39, Herbert Xu wrote: > On Fri, Feb 01, 2019 at 03:15:54PM +0800, Zhou Wang wrote: >> >>> Polling in softirq context is unacceptable. Can't your hardware >>> send interrupts to signal completion? What is the average speed >>> of processing a

Re: [PATCH v2 2/4] crypto: hisilicon: Add queue management driver for HiSilicon QM module

2019-01-31 Thread Zhou Wang
On 2019/2/1 13:22, Herbert Xu wrote: > On Wed, Jan 23, 2019 at 09:08:51PM +0800, Zhou Wang wrote: >> >> +/** >> + * hisi_qp_poll() - Poll current cqe to see if a task is finished. >> + * @qp: The qp which will poll. >> + * >> + * This function polls curren

Re: [PATCH v2 0/4] crypto: hisilicon: Add HiSilicon QM and ZIP controller driver

2019-01-28 Thread Zhou Wang
On 2019/1/23 21:08, Zhou Wang wrote: > This series adds HiSilicon QM and ZIP controller driver in crypto subsystem. > > A simple QM/ZIP driver which helps to provide an example for a general > accelerator framework is under review in community[1]. Based on this simple > driver, t

[PATCH v2 2/4] crypto: hisilicon: Add queue management driver for HiSilicon QM module

2019-01-23 Thread Zhou Wang
mailboxes and doorbells. Specific task request are descripted by specific description buffer, which will be controlled and pass to related accelerator IP by QM. This patch adds a QM driver used by the accelerator driver to access the QM hardware. Signed-off-by: Zhou Wang Signed-off-by: Kenneth Lee

[PATCH v2 4/4] MAINTAINERS: add maintainer for HiSilicon QM and ZIP controller driver

2019-01-23 Thread Zhou Wang
Add Zhou Wang as a maintainer for HiSilicon QM and ZIP controller driver. Signed-off-by: Zhou Wang Reviewed-by: John Garry --- MAINTAINERS | 8 1 file changed, 8 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 51029a4..6e6be9b 100644 --- a/MAINTAINERS +++ b/MAINTAINERS

[PATCH v2 3/4] crypto: hisilicon: Add HiSilicon ZIP accelerator support

2019-01-23 Thread Zhou Wang
The HiSilicon ZIP accelerator implements the zlib and gzip algorithm. It uses Hisilicon QM as the interface to the CPU. This patch provides PCIe driver to the accelerator and register it to the crypto subsystem. Signed-off-by: Zhou Wang Signed-off-by: Shiju Jose Signed-off-by: Kenneth Lee

[PATCH v2 1/4] Documentation: Add debugfs doc for hisi_zip

2019-01-23 Thread Zhou Wang
Add debugfs descriptions for HiSilicon ZIP and QM driver. Signed-off-by: Zhou Wang Reviewed-by: Jonathan Cameron --- Documentation/ABI/testing/debugfs-hisi-zip | 50 ++ 1 file changed, 50 insertions(+) create mode 100644 Documentation/ABI/testing/debugfs-hisi-zip

[PATCH v2 0/4] crypto: hisilicon: Add HiSilicon QM and ZIP controller driver

2019-01-23 Thread Zhou Wang
hange to register zlib/gzip to scomp. - Remove hisi_qm_mem_init/uninit, make QM interfaces compact. - Some tiny fixes. Links: - v1 https://lwn.net/Articles/775484/ - rfc https://lkml.org/lkml/2018/12/13/290 Reference: [1] https://lkml.org/lkml/2018/11/12/1951 Zhou Wang (4): Documentation: Add debugfs

Re: [PATCH 3/4] crypto: hisilicon: Add HiSilicon ZIP accelerator support

2019-01-17 Thread Zhou Wang
On 2019/1/18 12:55, Herbert Xu wrote: > On Wed, Jan 16, 2019 at 10:12:47PM +0800, Zhou Wang wrote: >> >> A stupid question: how do we test scomp alg? >> >> It seems we can not use general comp API, e.g. crypto_alloc_comp >> to do this. >> >> Coul

Re: [PATCH 3/4] crypto: hisilicon: Add HiSilicon ZIP accelerator support

2019-01-16 Thread Zhou Wang
On 2019/1/11 14:34, Zhou Wang wrote: > On 2019/1/11 14:08, Herbert Xu wrote: >> On Sat, Dec 22, 2018 at 03:51:44PM +0800, Zhou Wang wrote: >>> >>> +static struct crypto_alg hisi_zip_zlib = { >>> + .cra_name

Re: [PATCH 3/4] crypto: hisilicon: Add HiSilicon ZIP accelerator support

2019-01-10 Thread Zhou Wang
On 2019/1/11 14:08, Herbert Xu wrote: > On Sat, Dec 22, 2018 at 03:51:44PM +0800, Zhou Wang wrote: >> >> +static struct crypto_alg hisi_zip_zlib = { >> +.cra_name = "zlib-deflate", >> +.cra_flags = CRYPTO_AL

Re: [PATCH 0/4] crypto: hisilicon: Add HiSilicon QM and ZIP controller driver

2019-01-09 Thread Zhou Wang
On 2018/12/22 15:51, Zhou Wang wrote: > This series adds HiSilicon QM and ZIP controller driver in crypto subsystem. > > A simple QM/ZIP driver which helps to provide an example for a general > accelerator framework is under review in community[1]. Based on this simple > driver, t

[PATCH 4/4] MAINTAINERS: add maintainer for HiSilicon QM and ZIP controller driver

2018-12-22 Thread Zhou Wang
Add Zhou Wang as a maintainer for HiSilicon QM and ZIP controller driver. Signed-off-by: Zhou Wang Reviewed-by: John Garry --- MAINTAINERS | 8 1 file changed, 8 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 0767f1d..5be84e2 100644 --- a/MAINTAINERS +++ b/MAINTAINERS

[PATCH 1/4] Documentation: Add debugfs doc for hisi_zip

2018-12-22 Thread Zhou Wang
Add debugfs descriptions for HiSilicon ZIP and QM driver. Signed-off-by: Zhou Wang Reviewed-by: Jonathan Cameron --- Documentation/ABI/testing/debugfs-hisi-zip | 50 ++ 1 file changed, 50 insertions(+) create mode 100644 Documentation/ABI/testing/debugfs-hisi-zip

[PATCH 2/4] crypto: hisilicon: Add queue management driver for HiSilicon QM module

2018-12-22 Thread Zhou Wang
mailboxes and doorbells. Specific task request are descripted by specific description buffer, which will be controlled and pass to related accelerator IP by QM. This patch adds a QM driver used by the accelerator driver to access the QM hardware. Signed-off-by: Zhou Wang Signed-off-by: Kenneth Lee

[PATCH 0/4] crypto: hisilicon: Add HiSilicon QM and ZIP controller driver

2018-12-22 Thread Zhou Wang
l.org/lkml/2018/11/12/1951 Zhou Wang (4): Documentation: Add debugfs doc for hisi_zip crypto: hisilicon: Add queue management driver for HiSilicon QM module crypto: hisilicon: Add HiSilicon ZIP accelerator support MAINTAINERS: add maintainer for HiSilicon QM and ZIP controller driver Document

[PATCH 3/4] crypto: hisilicon: Add HiSilicon ZIP accelerator support

2018-12-22 Thread Zhou Wang
The HiSilicon ZIP accelerator implements the zlib and gzip algorithm. It uses Hisilicon QM as the interface to the CPU. This patch provides PCIe driver to the accelerator and register it to the crypto subsystem. Signed-off-by: Zhou Wang Signed-off-by: Shiju Jose Signed-off-by: Kenneth Lee

[PATCH RFC 3/4] crypto: hisilicon: Add HiSilicon ZIP accelerator support

2018-12-13 Thread Zhou Wang
The HiSilicon ZIP accelerator implements the zlib and gzip algorithm. It uses Hisilicon QM as the interface to the CPU. This patch provides PCIe driver to the accelerator and register it to the crypto subsystem. Signed-off-by: Zhou Wang Signed-off-by: Shiju Jose Signed-off-by: Kenneth Lee

[PATCH RFC 2/4] crypto: hisilicon: Add queue management driver for HiSilicon QM module

2018-12-13 Thread Zhou Wang
mailboxes and doorbells. Specific task request are descripted by specific description buffer, which will be controlled and pass to related accelerator IP by QM. This patch adds a QM driver used by the accelerator driver to access the QM hardware. Signed-off-by: Zhou Wang Signed-off-by: Kenneth Lee

[PATCH RFC 4/4] MAINTAINERS: add maintainer for HiSilicon QM and ZIP controller driver

2018-12-13 Thread Zhou Wang
Add Zhou Wang as a maintainer for HiSilicon QM and ZIP controller driver. Signed-off-by: Zhou Wang reviewed-by: John Garry --- MAINTAINERS | 8 1 file changed, 8 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 0767f1d..5be84e2 100644 --- a/MAINTAINERS +++ b/MAINTAINERS

[PATCH RFC 0/4] crypto: hisilicon: Add HiSilicon QM and ZIP controller driver

2018-12-13 Thread Zhou Wang
l.org/lkml/2018/11/12/1951 Zhou Wang (4): Documentation: Add debugfs doc for hisi_zip crypto: hisilicon: Add queue management driver for HiSilicon QM module crypto: hisilicon: Add HiSilicon ZIP accelerator support MAINTAINERS: add maintainer for HiSilicon QM and ZIP controller driver Document

[PATCH RFC 1/4] Documentation: Add debugfs doc for hisi_zip

2018-12-13 Thread Zhou Wang
Add debugfs descriptions for HiSilicon ZIP and QM driver. Signed-off-by: Zhou Wang reviewed-by: Jonathan Cameron --- Documentation/ABI/testing/debugfs-hisi-zip | 50 ++ 1 file changed, 50 insertions(+) create mode 100644 Documentation/ABI/testing/debugfs-hisi-zip

Re: [RFC/RFT PATCH 3/3] PCI/ACPI: Add ACPI pci_bus_find_numa_node() implementation

2017-05-15 Thread Zhou Wang
On 2017/5/15 17:17, Lorenzo Pieralisi wrote: > On Mon, May 15, 2017 at 02:13:47PM +0800, Zhou Wang wrote: >> On 2017/4/26 18:06, Lorenzo Pieralisi wrote: >>> The introduction of pci_bus_find_numa_node(pci_bus) allows at PCI >>> host bridge registration to detec

Re: [RFC/RFT PATCH 3/3] PCI/ACPI: Add ACPI pci_bus_find_numa_node() implementation

2017-05-14 Thread Zhou Wang
On 2017/4/26 18:06, Lorenzo Pieralisi wrote: > The introduction of pci_bus_find_numa_node(pci_bus) allows at PCI > host bridge registration to detect the NUMA node for a given > struct pci_bus.dev. Implement an ACPI method that, through > the struct pci_bus.bridge ACPI companion, retrieve and retur

Re: [PATCH] pci: dwc: hisi needs PCI_HOST_COMMON

2017-03-22 Thread Zhou Wang
On 2017/3/22 16:00, Arnd Bergmann wrote: > On Mar 22, 2017 04:27, "Zhou Wang" <mailto:wangzh...@hisilicon.com>> wrote: > > On 2017/3/21 23:48, Jingoo Han wrote: > > (+cc: Joao Pinto, Zhou Wang, Gabriele Paoloni) > > > > On Tuesday

Re: [PATCH] pci: dwc: hisi needs PCI_HOST_COMMON

2017-03-21 Thread Zhou Wang
On 2017/3/21 23:48, Jingoo Han wrote: > (+cc: Joao Pinto, Zhou Wang, Gabriele Paoloni) > > On Tuesday, March 21, 2017 10:32 AM, Arnd Bergmann wrote: >> >> Without PCI_HOST_COMMON support enabled, we get a link error: >> >> drivers/pci/dwc/built-in.o: In func

Re: [PATCH] ACPI/PCI: Fix bus range comparation in pci_mcfg_lookup

2017-01-11 Thread Zhou Wang
On 2017/1/12 5:37, Bjorn Helgaas wrote: > On Wed, Jan 04, 2017 at 03:00:06PM +0800, Zhou Wang wrote: >> The configuration data provided by an MCFG region (ie PCI segment and >> bus range) may span multiple host bridges. >> >> Current code in pci_mcfg_lookup() carries

Re: [PATCH] ACPI/PCI: Fix bus range comparation in pci_mcfg_lookup

2017-01-10 Thread Zhou Wang
On 2017/1/10 5:45, Rafael J. Wysocki wrote: > On Mon, Jan 9, 2017 at 4:39 AM, Zhou Wang wrote: >> On 2017/1/4 15:00, Zhou Wang wrote: >>> The configuration data provided by an MCFG region (ie PCI segment and >>> bus range) may span multiple host bridges. >>>

Re: [PATCH] ACPI/PCI: Fix bus range comparation in pci_mcfg_lookup

2017-01-08 Thread Zhou Wang
On 2017/1/4 15:00, Zhou Wang wrote: > The configuration data provided by an MCFG region (ie PCI segment and > bus range) may span multiple host bridges. > > Current code in pci_mcfg_lookup() carries out an exact match of host > bridge bus range start value against the MCFG regi

[PATCH] ACPI/PCI: Fix bus range comparation in pci_mcfg_lookup

2017-01-03 Thread Zhou Wang
. Signed-off-by: Zhou Wang Reviewed-by: Tomasz Nowicki Acked-by: Lorenzo Pieralisi --- drivers/acpi/pci_mcfg.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/acpi/pci_mcfg.c b/drivers/acpi/pci_mcfg.c index a6a4cea..2944353 100644 --- a/drivers/acpi/pci_mcfg.c +++ b

Re: [RFC PATCH] ACPI/PCI: Fix bus range comparation in pci_mcfg_lookup

2017-01-03 Thread Zhou Wang
On 2017/1/3 20:00, Lorenzo Pieralisi wrote: > On Thu, Dec 22, 2016 at 05:07:43PM +0800, Zhou Wang wrote: >> Multiple PCIe host bridges may exists in one PCIe segment. So bus range for >> each >> host bridge should be in the coverage of bus range of related PCIe segment.

Re: [RFC PATCH] ACPI/PCI: Fix bus range comparation in pci_mcfg_lookup

2017-01-03 Thread Zhou Wang
On 2017/1/3 14:39, Tomasz Nowicki wrote: > On 22.12.2016 10:07, Zhou Wang wrote: >> Multiple PCIe host bridges may exists in one PCIe segment. So bus range for >> each >> host bridge should be in the coverage of bus range of related PCIe segment. >> >> Thi

Re: [RFC PATCH] ACPI/PCI: Fix bus range comparation in pci_mcfg_lookup

2017-01-02 Thread Zhou Wang
On 2016/12/22 17:07, Zhou Wang wrote: > Multiple PCIe host bridges may exists in one PCIe segment. So bus range for > each > host bridge should be in the coverage of bus range of related PCIe segment. > > This patch will support this kind of scenario: > > MCFG: >

[RFC PATCH] ACPI/PCI: Fix bus range comparation in pci_mcfg_lookup

2016-12-22 Thread Zhou Wang
: bus range: 0x00~0x1f. segment: 0. host bridge 2: bus range: 0x20~0x4f. segment: 0. Signed-off-by: Zhou Wang --- drivers/acpi/pci_mcfg.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/acpi/pci_mcfg.c

Re: [PATCH] PCI: hisi: fix deferred probing

2015-11-12 Thread Zhou Wang
> Signed-off-by: Arnd Bergmann > Hi Arnd, Many thanks, it looks good to me. so Acked-by: Zhou Wang Regards, Zhou > diff --git a/drivers/pci/host/pcie-hisi.c b/drivers/pci/host/pcie-hisi.c > index 35457ecd8e70..163671a4f798 100644 > --- a/drivers/pci/host/pcie-hisi.c > +++ b/

[PATCH v13 2/6] PCI: designware: Remove *_mod_base

2015-10-29 Thread Zhou Wang
.html Signed-off-by: Zhou Wang Signed-off-by: Gabriele Paoloni Signed-off-by: Arnd Bergmann Tested-by: James Morse Tested-by: Gabriel Fernandez Tested-by: Minghuan Lian Acked-by: Pratyush Anand --- drivers/pci/host/pci-dra7xx.c | 8 drivers/pci/host/pc

[PATCH v13 5/6] PCI: designware: Add ARM64 support

2015-10-29 Thread Zhou Wang
nware: Remove *_mod_base". Signed-off-by: Zhou Wang Signed-off-by: Gabriele Paoloni Signed-off-by: Arnd Bergmann Tested-by: James Morse Tested-by: Gabriel Fernandez Tested-by: Minghuan Lian Acked-by: Pratyush Anand --- drivers/pci/host/pcie-designwa

[PATCH v13 6/6] PCI: hisi: Add PCIe host support for HiSilicon SoC Hip05

2015-10-29 Thread Zhou Wang
This patch adds PCIe host support for HiSilicon SoC Hip05, related DT binding document and maintainer update. Signed-off-by: Zhou Wang Signed-off-by: Gabriele Paoloni Signed-off-by: liudongdong Acked-by: Rob Herring --- .../bindings/arm/hisilicon/hisilicon.txt | 17

[PATCH v13 3/6] PCI: designware: Replace DT PCI ranges parse with of_pci_get_host_bridge_resources

2015-10-29 Thread Zhou Wang
This patch uses the new of_pci_get_host_bridge_resources API in place of the PCI OF DT parser For reference see previous suggestions from Gabriele[1] [1] http://www.spinics.net/lists/linux-pci/msg42194.html Signed-off-by: Zhou Wang Signed-off-by: Gabriele Paoloni Tested-by: James Morse

[PATCH v13 0/6] PCI: hisi: Add PCIe host support for HiSilicon SoC Hip05

2015-10-29 Thread Zhou Wang
/lists/linux-pci/msg42539.html Link of v2: - http://www.spinics.net/lists/linux-pci/msg41844.html Link of RFC v1: - http://www.spinics.net/lists/linux-pci/msg41305.html Link of RFC: - http://www.spinics.net/lists/linux-pci/msg40434.html [1] http://lists.infradead.org/pipermail/linux-arm-kernel/

[PATCH v13 1/6] PCI: designware: Move calculation of bus addresses to DRA7xx

2015-10-29 Thread Zhou Wang
s only applicable to DRA7xx. This patch moves the calculation of the bus addresses to the DRA7xx driver and is needed to allow the rework of designware to use the new DT parsing API. Signed-off-by: Gabriele Paoloni Signed-off-by: Zhou Wang Acked-by: Pratyush Anand --- drivers/pci/host/pc

[PATCH v13 4/6] ARM/PCI: Replace pci_sys_data->align_resource with global function pointer

2015-10-29 Thread Zhou Wang
hods), but the pci_sys_data->align_resource pointer was used only by Marvell (see mvebu_pcie_enable()), so this would only be a problem if we had a system with a combination of Marvell and other host bridges [bhelgaas: changelog] Signed-off-by: Gabriele Paoloni Signed-off-by: Zhou Wang Si

Re: [PATCH v12 0/8] PCI: hisi: Add PCIe host support for HiSilicon SoC Hip05

2015-10-28 Thread Zhou Wang
On 2015/10/28 6:32, Bjorn Helgaas wrote: > Hi Zhou, > > On Mon, Oct 26, 2015 at 07:35:42PM +0800, Zhou Wang wrote: >> This patchset adds PCIe host support for HiSilicon SoC Hip05. The PCIe hosts >> use PCIe IP core from Synopsys, So this driver is based on designware PCIe &

Re: [PATCH v12 7/8] Documentation: DT: Add HiSilicon PCIe host binding

2015-10-28 Thread Zhou Wang
On 2015/10/28 3:19, Rob Herring wrote: > On Mon, Oct 26, 2015 at 6:35 AM, Zhou Wang wrote: >> This patch adds related DTS binding document for HiSilicon PCIe host driver. >> >> Signed-off-by: Zhou Wang > > Acked-by: Rob Herring > Thanks for your review. Zho

[PATCH v12 5/8] PCI: designware: Remove *_mod_base

2015-10-26 Thread Zhou Wang
This patch reverts commit f4c55c5a3f7f ("PCI: designware: Program ATU with untranslated address") based on 1/8 in this series. we delete *_mod_base in pcie-designware. This was discussed in [1] [1] http://www.spinics.net/lists/arm-kernel/msg436779.html Signed-off-by: Zhou Wang Sig

[PATCH v12 2/8] ARM/PCI: remove align_resource in pci_sys_data

2015-10-26 Thread Zhou Wang
ch solves the issue by removing "align_resource" from "pci_sys_data" struct and defining a static global function pointer in "bios32.c" Signed-off-by: Gabriele Paoloni Signed-off-by: Zhou Wang Acked-by: Pratyush Anand --- arch/arm/include/asm/mach/pci.h | 6 -- arch

[PATCH v12 3/8] PCI: designware: Replace DT PCI ranges parse with of_pci_get_host_bridge_resources

2015-10-26 Thread Zhou Wang
This patch uses the new of_pci_get_host_bridge_resources API in place of the PCI OF DT parser For reference see previous suggestions from Gabriele[1] [1] http://www.spinics.net/lists/linux-pci/msg42194.html Signed-off-by: Zhou Wang Signed-off-by: Gabriele Paoloni Tested-by: James Morse

[PATCH v12 4/8] PCI: designware: Add ARM64 support

2015-10-26 Thread Zhou Wang
This patch tries to unify ARM32 and ARM64 PCIe in designware driver. Delete function dw_pcie_setup, dw_pcie_scan_bus, dw_pcie_map_irq and struct hw_pci, move related operations to dw_pcie_host_init. Signed-off-by: Zhou Wang Signed-off-by: Gabriele Paoloni Signed-off-by: Arnd Bergmann Tested-by

[PATCH v12 6/8] PCI: hisi: Add PCIe host support for HiSilicon SoC Hip05

2015-10-26 Thread Zhou Wang
This patch adds PCIe host support for HiSilicon SoC Hip05. Signed-off-by: Zhou Wang Signed-off-by: Gabriele Paoloni Signed-off-by: liudongdong --- drivers/pci/host/Kconfig | 8 ++ drivers/pci/host/Makefile| 1 + drivers/pci/host/pcie-hisi.c | 198

[PATCH v12 0/8] PCI: hisi: Add PCIe host support for HiSilicon SoC Hip05

2015-10-26 Thread Zhou Wang
[1] http://lists.infradead.org/pipermail/linux-arm-kernel/2015-July/359741.html Zhou Wang (6): PCI: designware: Replace DT PCI ranges parse with of_pci_get_host_bridge_resources PCI: designware: Add ARM64 support PCI: designware: Remove *_mod_base PCI: hisi: Add PCIe host support for HiSilicon

[PATCH v12 1/8] PCI: designware: move calculation of bus addresses to DRA7xx

2015-10-26 Thread Zhou Wang
s only applicable to DRA7xx. This patch moves the calculation of the bus addresses to the DRA7xx driver and is needed to allow the rework of designware to use the new DT parsing API. Signed-off-by: Gabriele Paoloni Signed-off-by: Zhou Wang Acked-by: Pratyush Anand --- drivers/pci/host/pc

[PATCH v12 8/8] MAINTAINERS: Add pcie-hisi maintainer

2015-10-26 Thread Zhou Wang
Signed-off-by: Zhou Wang --- MAINTAINERS | 7 +++ 1 file changed, 7 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 7ba7ab7..944a229 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -8047,6 +8047,13 @@ S: Maintained F: Documentation/devicetree/bindings/pci/xgene-pci

[PATCH v12 7/8] Documentation: DT: Add HiSilicon PCIe host binding

2015-10-26 Thread Zhou Wang
This patch adds related DTS binding document for HiSilicon PCIe host driver. Signed-off-by: Zhou Wang --- .../bindings/arm/hisilicon/hisilicon.txt | 17 + .../devicetree/bindings/pci/hisilicon-pcie.txt | 44 ++ 2 files changed, 61 insertions(+) create

Re: [PATCH v11 4/6] PCI: hisi: Add PCIe host support for HiSilicon SoC Hip05

2015-10-26 Thread Zhou Wang
On 2015/10/23 2:46, Bjorn Helgaas wrote: > Hi Zhou, > > This looks pretty good to me; just a mask question and add a printk. > > On Fri, Oct 16, 2015 at 06:23:39PM +0800, Zhou Wang wrote: >> This patch adds PCIe host support for HiSilicon SoC Hip05.

Re: [PATCH v11 3/6] PCI: designware: Add ARM64 support

2015-10-26 Thread Zhou Wang
On 2015/10/23 2:28, Bjorn Helgaas wrote: > Hi Zhou, > > On Fri, Oct 16, 2015 at 06:23:38PM +0800, Zhou Wang wrote: >> This patch tries to unify ARM32 and ARM64 PCIe in designware driver. Delete >> function dw_pcie_setup, dw_pcie_scan_bus, dw_pcie_map_irq and struct hw

Re: [PATCH v11 1/6] PCI: designware: move calculation of bus addresses to DRA7xx

2015-10-26 Thread Zhou Wang
On 2015/10/23 0:35, Bjorn Helgaas wrote: > Hi Gabriele, > > On Thu, Oct 22, 2015 at 07:21:41AM +, Gabriele Paoloni wrote: >>> -Original Message- >>> From: Bjorn Helgaas [mailto:helg...@kernel.org] > #define PCIECTRL_DRA7XX_CONF_PHY_CS 0x010C #define

[PATCH v11 6/6] MAINTAINERS: Add pcie-hisi maintainer

2015-10-16 Thread Zhou Wang
Signed-off-by: Zhou Wang --- MAINTAINERS | 7 +++ 1 file changed, 7 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 7ba7ab7..944a229 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -8047,6 +8047,13 @@ S: Maintained F: Documentation/devicetree/bindings/pci/xgene-pci

[PATCH v11 4/6] PCI: hisi: Add PCIe host support for HiSilicon SoC Hip05

2015-10-16 Thread Zhou Wang
This patch adds PCIe host support for HiSilicon SoC Hip05. Signed-off-by: Zhou Wang Signed-off-by: Gabriele Paoloni Signed-off-by: liudongdong --- drivers/pci/host/Kconfig | 8 ++ drivers/pci/host/Makefile| 1 + drivers/pci/host/pcie-hisi.c | 196

[PATCH v11 1/6] PCI: designware: move calculation of bus addresses to DRA7xx

2015-10-16 Thread Zhou Wang
s only applicable to DRA7xx. This patch moves the calculation of the bus addresses to the DRA7xx driver and is needed to allow the rework of designware to use the new DT parsing API. Signed-off-by: Gabriele Paoloni Signed-off-by: Zhou Wang Acked-by: Pratyush Anand --- drivers/pci/host/pc

[PATCH v11 3/6] PCI: designware: Add ARM64 support

2015-10-16 Thread Zhou Wang
don't have ARM32 PCIe related board to do test. It will be appreciated if someone could help to test it. Signed-off-by: Zhou Wang Signed-off-by: Gabriele Paoloni Signed-off-by: Arnd Bergmann Tested-by: James Morse Tested-by: Gabriel Fernandez Tested-by: Minghuan Lian Acked-by: Pratyush A

[PATCH v11 5/6] Documentation: DT: Add HiSilicon PCIe host binding

2015-10-16 Thread Zhou Wang
This patch adds related DTS binding document for HiSilicon PCIe host driver. Signed-off-by: Zhou Wang --- .../bindings/arm/hisilicon/hisilicon.txt | 17 + .../devicetree/bindings/pci/hisilicon-pcie.txt | 44 ++ 2 files changed, 61 insertions(+) create

[PATCH v11 2/6] ARM/PCI: remove align_resource in pci_sys_data

2015-10-16 Thread Zhou Wang
ch solves the issue by removing "align_resource" from "pci_sys_data" struct and defining a static global function pointer in "bios32.c" Signed-off-by: Gabriele Paoloni Signed-off-by: Zhou Wang Acked-by: Pratyush Anand --- arch/arm/include/asm/mach/pci.h | 6 -- arch

[PATCH v11 0/6] PCI: hisi: Add PCIe host support for HiSilicon SoC Hip05

2015-10-16 Thread Zhou Wang
41305.html Link of RFC: - http://www.spinics.net/lists/linux-pci/msg40434.html [1] http://lists.infradead.org/pipermail/linux-arm-kernel/2015-July/359741.html Zhou Wang (4): PCI: designware: Add ARM64 support PCI: hisi: Add PCIe host support for HiSilicon SoC Hip05 Documentation: DT: Add HiSilicon P

  1   2   >