Re: [PATCH] ioat: remove chanerr mask setting for IOAT v3.x

2012-11-27 Thread Dave Jiang
On 11/26/2012 09:56 PM, Dan Williams wrote: > On Fri, Nov 16, 2012 at 3:26 PM, Dave Jiang wrote: >> The CHANERRMSK_INT register should be 0. The existing code set a value >> for a workaround to address a pre-silicon bug on the Intel 5520 IO hub that >> has been fixed

[PATCH v2] ioat: remove chanerr mask setting for IOAT v3.x

2012-11-27 Thread Dave Jiang
The existing code set a value in the PCI_CHANERRMSK_INT register for a workaround to address a pre-silicon bug on the Intel 5520 IO hub that has been fixed when the hardware was released. There is no need for this code. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma_v3.c |7 +-- 1

[PATCH] ioatdma: fix race between updating ioat->head and IOAT_COMPLETION_PENDING

2013-02-07 Thread Dave Jiang
ace. Signed-off-by: Dave Jiang Reviewed-by: Dan Williams --- drivers/dma/ioat/dma.h|1 drivers/dma/ioat/dma_v2.c | 113 + drivers/dma/ioat/dma_v3.c | 111 +--- 3 files changed, 128 insertions(+), 97 deleti

[PATCH] ioatdma: allow all channels to have irq coalescing support

2013-02-26 Thread Dave Jiang
Looks like only the RAID channels are allowed to have irq coalescing support in the existing code. Fixing that. The ioat3 cleanup code can handle memcpy ops anyways Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma_v3.c | 12 +++- 1 file changed, 3 insertions(+), 9 deletions(-) diff

[PATCH] MAINTAINERS: update Intel C600 SAS driver maintainers

2012-09-25 Thread Dave Jiang
Cc: Lukasz Dorau Cc: Maciej Patelczyk Signed-off-by: Dave Jiang --- MAINTAINERS |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index b17587d..162f602 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -3552,11 +3552,12 @@ K: \b(ABS|SYN

[PATCH] MAINTAINERS: add to ioatdma maintainer list

2013-10-02 Thread Dave Jiang
: Maintained +M: Dave Jiang +S: Supported F: drivers/dma/ioat* INTEL IOMMU (VT-d) -- 1.8.3.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org

[PATCH] ioat: Add alignment workaround for IVB platforms

2012-12-03 Thread Dave Jiang
The PCI IDs for IvyBridge IOAT DMA needs to go into a header file since dma_v3.c looks them up for certain hardware workarounds. Need to add to the alignment workaround for IOAT 3.2 since it wasn't fixed in IVB. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma_v3.c |

[PATCH] ioat: remove chanerr mask setting for IOAT v3.x

2012-11-16 Thread Dave Jiang
The CHANERRMSK_INT register should be 0. The existing code set a value for a workaround to address a pre-silicon bug on the Intel 5520 IO hub that has been fixed when the hardware was released. There is no need for this code. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma_v3.c |8

Re: [PATCH] dmatest: masking tests for channel capabilities

2013-06-17 Thread Dave Jiang
o be someting like: (1 << DMA_MEMCPY) And also in that case for user scripts you have bits that are here and there for the bitmask instead of something simple and sequential. -- Dave Jiang Application Engineer, Storage Divsion Intel Corp. dave.ji...@intel.com -- To unsubscribe from this lis

Re: [PATCH 2/2] ioatdma: add DMA_PRIVATE capabilities flag

2013-06-19 Thread Dave Jiang
function call. Signed-off-by: Jon Mason Acked-by: Dave Jiang --- drivers/dma/ioat/dma_v3.c |1 + 1 file changed, 1 insertion(+) diff --git a/drivers/dma/ioat/dma_v3.c b/drivers/dma/ioat/dma_v3.c index ca6ea9b..ac2aeef 100644 --- a/drivers/dma/ioat/dma_v3.c +++ b/drivers/dma/ioat/dma_v3.c

Re: [PATCH v2] ioat: remove chanerr mask setting for IOAT v3.x

2013-03-21 Thread Dave Jiang
. There is no need for this code. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma_v3.c |7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/dma/ioat/dma_v3.c b/drivers/dma/ioat/dma_v3.c index f7f1dc6..fda3b8a1 100644 --- a/drivers/dma/ioat/dma_v3.c +++ b/drivers

[PATCH] ioatdma: Adding Haswell devid for ioatdma

2013-03-25 Thread Dave Jiang
Adding Haswell PCI device IDs for ioatdma and simplify the detection of certain Xeon CPUs that has alignment bugs so that modifications can be changed at a single place going forward. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma_v3.c | 28 +++- drivers/dma/ioat

[PATCH] ioatdma: make debug output more readable

2013-03-04 Thread Dave Jiang
Making OP field a hex instead of integer to make it more readable. Also add the dump out of the NEXT field. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma.h|2 +- drivers/dma/ioat/dma_v3.c |3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/dma/ioat

Re: [PATCH] ioatdma: make debug output more readable

2013-03-05 Thread Dave Jiang
On 03/05/2013 03:20 PM, Dan Williams wrote: On 3/4/13 9:59 AM, "Dave Jiang" wrote: Making OP field a hex instead of integer to make it more readable. Also add the dump out of the NEXT field. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma.h|2 +- drivers/dma/ioat/dma_v

[PATCH v2] ioatdma: make debug output more readable

2013-03-05 Thread Dave Jiang
Making OP field a hex instead of integer to make it more readable. Also add the dump out of the NEXT field. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma.h|2 +- drivers/dma/ioat/dma_v3.c |3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/dma/ioat

[PATCH v2 0/5] ioatdma: Intel S1200 support patches

2013-04-10 Thread Dave Jiang
on to get raid6test working. --- Dave Jiang (5): ioatdma: Removing hw bug workaround for CB3.x .2 and earlier ioatdma: Adding support for 16 src PQ ops and super extended descriptors ioatdma: S1200 platforms ioatdma channel 2 and 3 falsely advertise RAID cap ioatdma: Adding w

[PATCH v2 1/5] ioatdma: Removing hw bug workaround for CB3.x .2 and earlier

2013-04-10 Thread Dave Jiang
CB3.2 and earlier hardware has silicon bugs that are no longer needed with the new hardware. We don't have to use a NULL op to signal interrupt for RAID ops any longer. This code make sure the legacy workarounds only happen on legacy hardware. Signed-off-by: Dave Jiang --- drivers/dma

[PATCH v2 2/5] ioatdma: Adding support for 16 src PQ ops and super extended descriptors

2013-04-10 Thread Dave Jiang
ached" to the op descriptor during operation. This is a new feature for ioatdma v3.3. Signed-off-by: Dave Jiang Acked-by: Dan Williams --- drivers/dma/ioat/dma.h | 17 ++ drivers/dma/ioat/dma_v2.h|2 drivers/dma/ioat/dma_v3.c

[PATCH v2 3/5] ioatdma: S1200 platforms ioatdma channel 2 and 3 falsely advertise RAID cap

2013-04-10 Thread Dave Jiang
This workaround checks for channel 2&3 and remove RAID cap. Signed-off-by: Dave Jiang Acked-by: Dan Williams --- drivers/dma/ioat/dma_v3.c | 15 +++ 1 file changed, 15 insertions(+) diff --git a/drivers/dma/ioat/dma_v3.c b/drivers/dma/ioat/dma_v3.c index 02afdb5..343320c 10

[PATCH v2 4/5] ioatdma: Adding write back descriptor error status support for ioatdma 3.3

2013-04-10 Thread Dave Jiang
report the "errors" up the stack. We are also going to mask those error interrupts and handle them when the "chain" has completed at the end. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma.h |1 drivers/dma/ioa

[PATCH v2 5/5] async_tx: allow generic async_memcpy() not be effected by channel switch

2013-04-10 Thread Dave Jiang
ow us to remove the ifdef for channel switching fixup. Signed-off-by: Dave Jiang --- crypto/async_tx/async_memcpy.c | 76 +++- drivers/md/raid5.c | 15 +--- include/linux/async_tx.h |5 +++ include/linux/dmaengine.h |

[PATCH v3] ioatdma: Adding support for 16 src PQ ops and super extended descriptors

2013-04-15 Thread Dave Jiang
ached" to the op descriptor during operation. This is a new feature for ioatdma v3.3. Signed-off-by: Dave Jiang Acked-by: Dan Williams --- drivers/dma/ioat/dma.h | 17 ++ drivers/dma/ioat/dma_v2.h|2 drivers/dma/ioat/dma_v3.c

[PATCH v3] async_tx: allow generic async_memcpy() not be effected by channel switch

2013-04-15 Thread Dave Jiang
ow us to remove the ifdef for channel switching fixup. Signed-off-by: Dave Jiang --- crypto/async_tx/async_memcpy.c | 76 +++ crypto/async_tx/async_raid6_recov.c |4 +- drivers/md/raid5.c | 15 --- include/linux/async

Re: [PATCH] ioat: device control support

2013-05-17 Thread Dave Jiang
Acked-by: Dave Jiang On 05/17/2013 10:53 AM, Jon Mason wrote: Add device control support for CBDMA v2 and v3 in the ioat driver. This allows DMA engine clients to call into the ioat driver and issue a DMA_TERMINATE_ALL. Signed-off-by: Jon Mason --- drivers/dma/ioat/dma_v2.c | 22

[PATCH 00/10] Add Intel Atom S1200 seris ioatdma support

2013-03-26 Thread Dave Jiang
implemention. The series is dependent on the haswell update patch sent prior. --- Dave Jiang (10): ioatdma: Adding PCI IDs for Intel Atom S1200 product family ioatdma devices ioatdma: Add 64bit chansts register read for ioat v3.3. ioatdma: channel reset scheme fixup on Intel

[PATCH 02/10] ioatdma: Add 64bit chansts register read for ioat v3.3.

2013-03-26 Thread Dave Jiang
The channel status register for v3.3 is now 64bit. Use readq if available on v3.3 platforms. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma.h | 22 +- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/drivers/dma/ioat/dma.h b/drivers/dma/ioat/dma.h index

[PATCH 03/10] ioatdma: channel reset scheme fixup on Intel Atom S1200 platforms

2013-03-26 Thread Dave Jiang
generations. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma.c|8 +- drivers/dma/ioat/dma.h| 10 ++ drivers/dma/ioat/dma_v3.c | 236 + 3 files changed, 171 insertions(+), 83 deletions(-) diff --git a/drivers/dma/ioat/dma.c b/drivers/dma

[PATCH 04/10] ioatdma: Removing hw bug workaround for CB3.x .2 and earlier

2013-03-26 Thread Dave Jiang
CB3.2 and earlier hardware has silicon bugs that are no longer needed with the new hardware. We don't have to use a NULL op to signal interrupt for RAID ops any longer. This code make sure the legacy workarounds only happen on legacy hardware. Signed-off-by: Dave Jiang --- drivers/dma

[PATCH 05/10] ioatdma: skip legacy reset bits since v3.3 plattform doesn't need it

2013-03-26 Thread Dave Jiang
Make it so only 3.2 and earlier platform need the PCI config register clearings since this implementation does not have the registers. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma_v3.c | 34 +- 1 file changed, 21 insertions(+), 13 deletions(-) diff --git

[PATCH 07/10] ioatdma: skip silicon bug workaround for pq_align for cb3.3

2013-03-26 Thread Dave Jiang
The alignment workaround is only necessary for cb3.2 or earlier platforms. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma_v3.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/drivers/dma/ioat/dma_v3.c b/drivers/dma/ioat/dma_v3.c index a6d4175..a55c346

[PATCH 09/10] ioatdma: Adding write back descriptor error status support for ioatdma 3.3

2013-03-26 Thread Dave Jiang
report the "errors" up the stack. We are also going to mask those error interrupts and handle them when the "chain" has completed at the end. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma_v3.c| 87 -- drivers/dma/ioa

[PATCH 10/10] ioatdma: S1200 platforms ioatdma channel 2 and 3 falsely advertise RAID cap

2013-03-26 Thread Dave Jiang
This workaround checks for channel 2&3 and remove RAID cap. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma_v3.c | 15 +++ 1 file changed, 15 insertions(+) diff --git a/drivers/dma/ioat/dma_v3.c b/drivers/dma/ioat/dma_v3.c index 83d44f3..6f6d2ec 100644 --- a/drivers/dma/

[PATCH 06/10] ioatdma: Removing PQ val disable for cb3.3

2013-03-26 Thread Dave Jiang
The PQ Val ops work on the newer hardware so we should actually provide support for it and remove the disabling bits. Signed-off-by: Dave Jiang --- drivers/dma/Kconfig |2 - drivers/dma/ioat/dma.h |1 drivers/dma/ioat/dma_v3.c| 134

[PATCH 08/10] ioatdma: Adding support for 16 src PQ ops and super extended descriptors

2013-03-26 Thread Dave Jiang
ached" to the op descriptor during operation. This is a new feature for ioatdma v3.3. Signed-off-by: Dave Jiang --- drivers/dma/ioat/dma.h | 18 ++ drivers/dma/ioat/dma_v2.h|2 drivers/dma/ioat/dma_v3.c| 394 -- drivers/dma

[PATCH 01/10] ioatdma: Adding PCI IDs for Intel Atom S1200 product family ioatdma devices

2013-03-26 Thread Dave Jiang
These should be good for the IOAT DMA devices on the Intel Atom S1269, S1279, and S1289 platforms. We are also adding IOAT v3.3 definition for the new DMA engine. Signed-off-by: Dave Jiang --- drivers/dma/ioat/hw.h |6 ++ drivers/dma/ioat/pci.c |6 ++ 2 files changed, 12

Re: [PATCH 09/10] ioatdma: Adding write back descriptor error status support for ioatdma 3.3

2013-03-26 Thread Dave Jiang
On 03/26/2013 04:47 PM, Dan Williams wrote: On 3/26/13 3:43 PM, "Dave Jiang" wrote: v3.3 provides support for write back descriptor error status. This allows reporting of errors in a descriptor field. In supporting this, certain errors such as P/Q validation errors no longer

[PATCH] async_tx: allow generic async_memcpy() not be effected by channel switch

2013-03-27 Thread Dave Jiang
This adds a generic async_memcpy() for the DMA engines that cannot do channel switch. Previously it would exclude all DMA engines that don't have all equal capabilities for all ops with the DMA_ASYNC_TX check. Signed-off-by: Dave Jiang --- crypto/async_tx/async_memcpy.c |

Re: [PATCH 06/10] ioatdma: Removing PQ val disable for cb3.3

2013-03-29 Thread Dave Jiang
On 03/27/2013 11:48 AM, Dan Williams wrote: On Tue, Mar 26, 2013 at 3:43 PM, Dave Jiang wrote: The PQ Val ops work on the newer hardware so we should actually provide support for it and remove the disabling bits. Signed-off-by: Dave Jiang --- drivers/dma/Kconfig |2 - drivers

[PATCH] ioat: Adding Ivy Bridge IOATDMA PCI device IDs

2012-08-24 Thread Dave Jiang
Signed-off-by: Dave Jiang --- drivers/dma/ioat/pci.c | 22 ++ 1 files changed, 22 insertions(+), 0 deletions(-) diff --git a/drivers/dma/ioat/pci.c b/drivers/dma/ioat/pci.c index 5e3a40f..c057306 100644 --- a/drivers/dma/ioat/pci.c +++ b/drivers/dma/ioat/pci.c @@ -40,6

[PATCH v2] ioat: Adding Ivy Bridge IOATDMA PCI device IDs

2012-09-18 Thread Dave Jiang
Signed-off-by: Dave Jiang --- Sorry about the churn. I had to move the PCI dev IDs to the header file after realizing that dma_v3.c actually sometimes check the PCI IDs in order to work around certain silicon bugs. drivers/dma/ioat/hw.h | 11 +++ drivers/dma/ioat/pci.c | 11

Re: [PATCH 1/2] efi: Make 'efi_enabled' a function to query EFI facilities

2013-01-21 Thread Dave Jiang
irlie Cc: H. Peter Anvin Cc: Corentin Chary Cc: Matthew Garrett Cc: Dave Jiang Cc: Olof Johansson Cc: Peter Jones Cc: Colin Ian King Cc: Steve Langasek Cc: Tony Luck Cc: Konrad Rzeszutek Wilk Cc: Rafael J. Wysocki Cc: sta...@vger.kernel.org Signed-off-by: Matt Fleming --- a

x86_64 frame pointer via thread context

2005-08-05 Thread Dave Jiang
Hi, I've been playing around with extracting the frame pointer from rBP register and using that to perform backtracing on the x86_64 platform. With a non-threaded user application, I was able to do that successfully. However, when attempting to do that with multi-threaded app, this seems to fai

Re: x86_64 frame pointer via thread context

2005-08-08 Thread Dave Jiang
r you won't get it in rBP. It is possible that userspace or toolchain may be suspect, However, why is the value bad in kernel space when rBP from pt_regs is dumped? -- Dave -- Dave Jiang Software Engineer Phone: (480) 517-0372

Re: x86_64 frame pointer via thread context

2005-08-08 Thread Dave Jiang
Dave Jiang wrote: Jan Engelhardt wrote: Am I doing something wrong, or is this intended to be this way on x86_64, or is something incorrect in the kernel? This method works fine on i386. Thanks for any help! I just tested your program on SLES9 with updated kernel and RBP looks correct to me

Re: x86_64 frame pointer via thread context

2005-08-08 Thread Dave Jiang
Andi Kleen wrote: Dave Jiang <[EMAIL PROTECTED]> writes: Am I doing something wrong, or is this intended to be this way on x86_64, or is something incorrect in the kernel? This method works fine on i386. Thanks for any help! I just tested your program on SLES9 with updated kernel a

Re: x86_64 frame pointer via thread context

2005-08-08 Thread Dave Jiang
Petr Vandrovec wrote: Dave Jiang wrote: Andi Kleen wrote: Dave Jiang <[EMAIL PROTECTED]> writes: Am I doing something wrong, or is this intended to be this way on x86_64, or is something incorrect in the kernel? This method works fine on i386. Thanks for any help! I just teste

Re: x86_64 frame pointer via thread context

2005-08-08 Thread Dave Jiang
me of them from clobbering rbp? -- Dave -- Dave Jiang Software Engineer Phone: (480) 517-0372 MontaVista Software, Inc.Fax: (480) 517-0262 2141 E Broadway Rd, St 108 Web: www.mvista.com Tempe, AZ 85282 mailto:[

Re: [PATCH] x86_64 RESTORE_CONTEXT missing '\n'

2007-03-08 Thread Dave Jiang
Andi Kleen wrote: > On Wednesday 07 March 2007 21:45, Dave Jiang wrote: >> The RESTORE_CONTEXT macro is missing the '\n' at the end. It was removed in >> the >> previous patch that touched system.h. It causes compile failure if any >> inline asm is added

[PATCH] MPSC serial driver tx locking

2007-03-06 Thread Dave Jiang
port transmit lock provides a finer granular locking and protects registers being clobbered while printks are nested within UART writes. Signed-off-by: Dave Jiang <[EMAIL PROTECTED]> Signed-off-by: Mark A. Greer <[EMAIL PROTECTED]> --- drivers/serial/mpsc.c | 25 -

[PATCH] x86_64 RESTORE_CONTEXT missing '\n'

2007-03-07 Thread Dave Jiang
The RESTORE_CONTEXT macro is missing the '\n' at the end. It was removed in the previous patch that touched system.h. It causes compile failure if any inline asm is added after the macro. Discovered this when playing with kgdb. Signed-off-by: Dave Jiang <[EMAIL PROTECTED]> -

Re: [lkp-robot] [mm] 15d36fecd0: WARNING:at_kernel/memremap.c:#devm_memremap_pages

2018-08-30 Thread Dave Jiang
On 08/30/2018 02:22 AM, Rong Chen wrote: > > > On 08/24/2018 12:55 AM, Dave Jiang wrote: >> I am not able to reproduce when I booted my test system with "mem=8G >> memmap=4G!8G". I ended up with a single pmem: > The issue seems to be related to specific machi

Re: [lkp-robot] [mm] 15d36fecd0: WARNING:at_kernel/memremap.c:#devm_memremap_pages

2018-08-23 Thread Dave Jiang
I am not able to reproduce when I booted my test system with "mem=8G memmap=4G!8G". I ended up with a single pmem: [ 57.750556] nd_pmem namespace0.0: unable to guarantee persistence of writes [ 57.881573] pmem0: detected capacity change from 0 to 4294967296 However in the reported kmsg, it app

Re: linux-next: Signed-off-by missing for commit in the xarray tree

2018-07-25 Thread Dave Jiang
On 07/25/2018 05:03 PM, Stephen Rothwell wrote: > Hi Matthew, > > On Wed, 25 Jul 2018 16:36:21 -0700 Matthew Wilcox wrote: >> >> On Thu, Jul 26, 2018 at 07:28:14AM +1000, Stephen Rothwell wrote: >>> >>> Commits >>> >>> 890e537e2b42 ("filesystem-dax: Introduce dax_lock_mapping_entry()") >>>

Re: [PATCH v2 0/6] kaddr and pfn can be NULL to ->direct_access()

2018-07-25 Thread Dave Jiang
Pretty straight forward series. Huaisheng, I can apply the whole series to libnvdimm if we can get ack's from maintainer of dcssblk and dm-writecache for the respective bits. On 07/25/2018 09:28 AM, Huaisheng Ye wrote: > From: Huaisheng Ye > > Changes since v1 [1]: > * Involve the previous patch

Re: [PATCH v2] x86/numa_emulation: fix parsing of numa_meminfo for uniform numa emulation

2018-10-09 Thread Dave Jiang
On 09/19/2018 11:12 AM, Dave Jiang wrote: > During fakenuma processing in numa_emulation(), pi gets passed in and > processed as new fake numa nodes are being split out. Once the original > memory region is proccessed, it gets removed from the pi by > numa_remove_memb

Re: [PATCH] nvdimm: make nvdimm_bus_type const

2024-02-05 Thread Dave Jiang
g Kroah-Hartman > Suggested-by: Greg Kroah-Hartman > Signed-off-by: Ricardo B. Marliere Reviewed-by: Dave Jiang > --- > drivers/nvdimm/bus.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/nvdimm/bus.c b/drivers/nvdimm/bus.c > index ef

Re: [PATCH] device-dax: make dax_bus_type const

2024-02-05 Thread Dave Jiang
g Kroah-Hartman > Suggested-by: Greg Kroah-Hartman > Signed-off-by: Ricardo B. Marliere Reviewed-by: Dave Jiang > --- > drivers/dax/bus.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/dax/bus.c b/drivers/dax/bus.c > index 1659b787b65f..

Re: [PATCH] dax: constify the struct device_type usage

2024-02-23 Thread Dave Jiang
read-only memory which can not be modified at runtime. > > Cc: Greg Kroah-Hartman > Signed-off-by: Ricardo B. Marliere Reviewed-by: Dave Jiang > --- > drivers/dax/bus.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/dax/bus.c b/driver

Re: [PATCH] dax: remove SLAB_MEM_SPREAD flag usage

2024-02-27 Thread Dave Jiang
On 2/24/24 6:47 AM, chengming.z...@linux.dev wrote: > From: Chengming Zhou > > The SLAB_MEM_SPREAD flag is already a no-op as of 6.8-rc1, remove > its usage so we can delete it from slab. No functional change. Can you please provide a Link tag to the lore post that indicates SLAB_MEM_SPREAD

[GIT PULL] NVDIMM//DAX changes for 6.9

2024-03-14 Thread Dave Jiang
Hi Linus, please pull from: git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm.git tags/libnvdimm-for-6.9 ... to get updates to the nvdimm tree. They are a number of updates to interfaces used by nvdimm/dax and a documentation fix. Doc fixes: ACPI_NFIT Kconfig documetation f

Re: [PATCH][next] dax: remove redundant assignment to variable rc

2024-04-15 Thread Dave Jiang
ning: Value stored to 'rc' is never > read [deadcode.DeadStores] > > Signed-off-by: Colin Ian King Reviewed-by: Dave Jiang > --- > drivers/dax/bus.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/drivers/dax/bus.c b/drivers/dax/bus.c > index 797e

Re: [PATCH v1 1/1] ACPI: NFIT: Switch to use acpi_evaluate_dsm_typed()

2023-10-02 Thread Dave Jiang
On 10/2/23 06:54, Andy Shevchenko wrote: > The acpi_evaluate_dsm_typed() provides a way to check the type of the > object evaluated by _DSM call. Use it instead of open coded variant. > > Signed-off-by: Andy Shevchenko Reviewed-by: Dave Jiang > --- > drivers/acpi/nfit/cor

[GIT PULL] NVDIMM Fixes for 6.6-rc5

2023-10-02 Thread Dave Jiang
Hi Linus, please pull from: git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm.git tags/libnvdimm-fixes-6.6-rc5 ...to receive a small fix for libnvdimm correcting the calculation of idt size in the NFIT code. It has appeared in -next for a few days with no reported issues. --- The f

Re: [PATCH] nvdimm-btt: fix a potential memleak in btt_freelist_init

2023-12-07 Thread Dave Jiang
On 12/6/23 20:43, Dinghao Liu wrote: > When an error happens in btt_freelist_init(), its caller > discover_arenas() will directly free arena, which makes > arena->freelist allocated in btt_freelist_init() a leaked > memory. Fix this by freeing arena->freelist in all error > handling paths of btt

Re: [PATCH] nvdimm-btt: simplify code with the scope based resource management

2023-12-11 Thread Dave Jiang
On 12/10/23 03:27, Dinghao Liu wrote: > Use the scope based resource management (defined in > linux/cleanup.h) to automate resource lifetime > control on struct btt_sb *super in discover_arenas(). > > Signed-off-by: Dinghao Liu > --- > drivers/nvdimm/btt.c | 12 > 1 file changed,

Re: [PATCH] nvdimm: Remove usage of the deprecated ida_simple_xx() API

2023-12-11 Thread Dave Jiang
On 12/10/23 10:13, Christophe JAILLET wrote: > ida_alloc() and ida_free() should be preferred to the deprecated > ida_simple_get() and ida_simple_remove(). > > This is less verbose. > > Signed-off-by: Christophe JAILLET Reviewed-by: Dave Jiang > --- > drivers/nvd

Re: [PATCH] nvdimm-btt: simplify code with the scope based resource management

2023-12-13 Thread Dave Jiang
On 12/12/23 20:12, dinghao@zju.edu.cn wrote: >> >> On 12/10/23 03:27, Dinghao Liu wrote: >>> Use the scope based resource management (defined in >>> linux/cleanup.h) to automate resource lifetime >>> control on struct btt_sb *super in discover_arenas(). >>> >>> Signed-off-by: Dinghao Liu >>

Re: [PATCH] [v2] nvdimm-btt: simplify code with the scope based resource management

2023-12-14 Thread Dave Jiang
On 12/14/23 01:39, Dinghao Liu wrote: > Use the scope based resource management (defined in > linux/cleanup.h) to automate resource lifetime > control on struct btt_sb *super in discover_arenas(). > > Signed-off-by: Dinghao Liu Reviewed-by: Dave Jiang > --- > > Cha

Re: [PATCH] driver core: Add a guard() definition for the device_lock()

2023-12-14 Thread Dave Jiang
Cc: Ira Weiny > Cc: Peter Zijlstra > Cc: Greg Kroah-Hartman > Cc: Andrew Morton > Signed-off-by: Dan Williams Reviewed-by: Dave Jiang > --- > Hi Greg, > > I wonder if you might include this change in v6.7-rc to ease some patch > sets alternately going through my tree and

Re: [PATCH] ACPI: NFIT: add missing MODULE_DESCRIPTION() macro

2024-06-06 Thread Dave Jiang
On 6/3/24 6:30 AM, Jeff Johnson wrote: > make allmodconfig && make W=1 C=1 reports: > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/acpi/nfit/nfit.o > > Add the missing invocation of the MODULE_DESCRIPTION() macro. > > Signed-off-by: Jeff Johnson

Re: [PATCH RESEND] nvdimm: add missing MODULE_DESCRIPTION() macros

2024-06-06 Thread Dave Jiang
ON() in drivers/nvdimm/nd_btt.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/nvdimm/nd_e820.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/nvdimm/of_pmem.o > WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/nvdimm/nd_virtio.o > > Signed-off-by:

Re: [PATCH] nvdimm: Fix devs leaks in scan_labels()

2024-06-06 Thread Dave Jiang
On 6/3/24 8:16 PM, Li Zhijian wrote: > Don't allocate devs again when it's valid pointer which has pionted to > the memory allocated above with size (count + 2 * sizeof(dev)). > > A kmemleak reports: > unreferenced object 0x88800dda1980 (size 16): > comm "kworker/u10:5", pid 69, jiffies 4

Re: [PATCH] nvdimm: Use of_property_present() and of_property_read_bool()

2024-08-07 Thread Dave Jiang
ar functions. > of_(find|get)_property() leak the DT struct property and data pointers > which is a problem for dynamically allocated nodes which may be freed. > > Signed-off-by: Rob Herring (Arm) Reviewed-by: Dave Jiang > --- > drivers/nvdimm/of_pmem.c | 2 +- > drivers/n

Re: [PATCH] nvdimm/pmem: Set dax flag for all 'PFN_MAP' cases

2024-08-07 Thread Dave Jiang
e the dax flag to queue_limits") > Signed-off-by: Zhihao Cheng Reviewed-by: Dave Jiang > --- > drivers/nvdimm/pmem.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/nvdimm/pmem.c b/drivers/nvdimm/pmem.c > index 1ae8b2351654..210fb77f5

Re: [PATCH v2] virtio_pmem: Check device status before requesting flush

2024-08-20 Thread Dave Jiang
On 8/20/24 10:22 AM, Philip Chen wrote: > If a pmem device is in a bad status, the driver side could wait for > host ack forever in virtio_pmem_flush(), causing the system to hang. > > So add a status check in the beginning of virtio_pmem_flush() to return > early if the device is not activated

Re: [PATCH 5.11 007/122] dmaengine: idxd: Fix clobbering of SWERR overflow bit on writeback

2021-04-20 Thread Dave Jiang
On 4/20/2021 1:13 PM, Pavel Machek wrote: Hi! Current code blindly writes over the SWERR and the OVERFLOW bits. Write back the bits actually read instead so the driver avoids clobbering the OVERFLOW bit that comes after the register is read. I believe this is incorrect. Changelog explains th

Re: [PATCH 1/3] acpi: nfit: add declaration in a local header

2023-05-22 Thread Dave Jiang
/core.c:1717:13: error: no previous prototype for 'nfit_intel_shutdown_status' [-Werror=missing-prototypes] Add a declaration in a header that gets included from both sides to shut up the warning and ensure that the prototypes actually match. Signed-off-by: Arnd Bergmann Reviewed-by:

Re: [PATCH 2/3] testing: nvdimm: add missing prototypes for wrapped functions

2023-05-22 Thread Dave Jiang
__wrap_devm_memremap' [-Werror=missing-prototypes] 86 | void *__wrap_devm_memremap(struct device *dev, resource_size_t offset, | ^~~~ ... Add prototypes to avoid the warning. Signed-off-by: Arnd Bergmann Reviewed-by: Dave Jiang --- tools/testing/nvd

Re: [PATCH 3/3] libnvdimm: mark 'security_show' static again

2023-05-22 Thread Dave Jiang
:352:9: error: no previous prototype for 'security_show' This is also not an appropriate name for a global symbol in the kernel, so just make it static again. Fixes: 15a8348707ff ("libnvdimm: Introduce CONFIG_NVDIMM_SECURITY_TEST flag") Signed-off-by: Arnd Bergmann Rev

Re: [PATCH] nvdimm: make security_show static

2023-06-16 Thread Dave Jiang
/dimm_devs.c:352:9: warning: symbol 'security_show' was not declared. Should it be static? Signed-off-by: Ben Dooks Reviewed-by: Dave Jiang --- drivers/nvdimm/dimm_devs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/nvdimm/dimm_devs.c b/drivers/nvdimm/d

Re: [PATCH] ACPI: NFIT: limit string attribute write

2023-07-05 Thread Dave Jiang
On 7/4/23 01:17, Ben Dooks wrote: If we're writing what could be an arbitrary sized string into an attribute we should probably use snprintf() just to be safe. Most of the other attriubtes are some sort of integer so unlikely to be an issue so not altered at this time. Signed-off-by: Ben Dook

Re: [PATCH] ACPI: NFIT: add helper to_nfit_mem() to take device to nfit_mem

2023-07-05 Thread Dave Jiang
Dooks Reviewed-by: Dave Jiang --- drivers/acpi/nfit/core.c | 27 +-- 1 file changed, 13 insertions(+), 14 deletions(-) diff --git a/drivers/acpi/nfit/core.c b/drivers/acpi/nfit/core.c index 0fcc247fdfac..9213b426b125 100644 --- a/drivers/acpi/nfit/core.c +++ b/drivers

Re: [PATCH v2] ACPI: NFIT: limit string attribute write

2023-07-11 Thread Dave Jiang
On 7/11/23 02:37, Ben Dooks wrote: If we're writing what could be an arbitrary sized string into an attribute we should probably use sysfs_emit() just to be safe. Most of the other attriubtes are some sort of integer so unlikely to be an issue so not altered at this time. Signed-off-by: Ben D

Re: [PATCH] drivers: nvdimm: fix dereference after free

2023-08-17 Thread Dave Jiang
On 8/17/23 04:41, Konstantin Meskhidze wrote: 'nd_pmu->pmu.attr_groups' is dereferenced in function 'nvdimm_pmu_free_hotplug_memory' call after it has been freed. Because in function 'nvdimm_pmu_free_hotplug_memory' memory pointed by the fields of 'nd_pmu->pmu.attr_groups' is deallocated it is

Re: [PATCH] drivers: nvdimm: fix memleak

2023-08-17 Thread Dave Jiang
On 8/17/23 04:59, Konstantin Meskhidze wrote: Memory pointed by 'nd_pmu->pmu.attr_groups' is allocated in function 'register_nvdimm_pmu' and is lost after 'kfree(nd_pmu)' call in function 'unregister_nvdimm_pmu'. Co-developed-by: Ivanov Mikhail Signed-off-by: Konstantin Meskhidze Applied

Re: [PATCH] drivers: nvdimm: fix dereference after free

2023-08-17 Thread Dave Jiang
On 8/17/23 08:45, Dave Jiang wrote: On 8/17/23 04:41, Konstantin Meskhidze wrote: 'nd_pmu->pmu.attr_groups' is dereferenced in function 'nvdimm_pmu_free_hotplug_memory' call after it has been freed. Because in function 'nvdimm_pmu_free_hotplug_memory'

Re: [PATCH] nvdimm: of_pmem: Add kfree for kstrdup

2023-08-28 Thread Dave Jiang
On 8/27/23 23:23, Chen Ni wrote: Add kfree() for kstrdup() in order to avoid memory leak. Signed-off-by: Chen Ni Can you please add a fixes tag? Thanks! --- drivers/nvdimm/of_pmem.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/nvdimm/of_pmem.c b/drivers/nvdimm/of_

[GIT PULL] NVDIMM and DAX for 6.6

2023-08-30 Thread Dave Jiang
Hi Linus, please pull from git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm.git tags/libnvdimm-for-6.6 ... to receive the libnvdimm and DAX updates for v6.6 This is mostly small cleanups, fixes, and with a change to prevent zero-sized namespace exposed to user for nvdimm. It ha

Re: [PATCH] drivers: nvdimm: fix possible memory leak

2023-09-08 Thread Dave Jiang
On 9/5/23 02:15, Konstantin Meskhidze wrote: Memory pointed by 'nd_pmu->pmu.attr_groups[NVDIMM_PMU_CPUMASK_ATTR]->attrs[0]' is allocated in function 'nvdimm_pmu_cpu_hotplug_init' via 'create_cpumask_attr_group' call. But not released in function 'nvdimm_pmu_free_hotplug_memory' or anywhere els

Re: [PATCH] dax: refactor deprecated strncpy

2023-09-13 Thread Dave Jiang
Cc: linux-harden...@vger.kernel.org > Signed-off-by: Justin Stitt Reviewed-by: Dave Jiang > --- > Note: build-tested only. > --- > drivers/dax/bus.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/dax/bus.c b/drivers/dax/bus.c > index 0ee9

Re: [PATCH v3] libnvdimm/of_pmem: Use devm_kstrdup instead of kstrdup and check its return value

2023-09-14 Thread Dave Jiang
On 9/14/23 00:03, Chen Ni wrote: > Use devm_kstrdup() instead of kstrdup() and check its return value to > avoid memory leak. > > Fixes: 49bddc73d15c ("libnvdimm/of_pmem: Provide a unique name for bus > provider") > Signed-off-by: Chen Ni Reviewed-by: Dave J

Re: [PATCH v1 2/2] ACPI: NFIT: Use modern scope based rollback

2023-09-26 Thread Dave Jiang
On 9/26/23 11:45, Michal Wilczynski wrote: > Change rollback in acpi_nfit_init_interleave_set() to use modern scope > based attribute __free(). This is similar to C++ RAII and is a preferred > way for handling local memory allocations. > > Suggested-by: Dave Jiang >

Re: [PATCH v1 1/2] ACPI: NFIT: Fix memory leak, and local use of devm_*()

2023-09-26 Thread Dave Jiang
ak'. > > Fix this by switching from devm_kcalloc() to kcalloc(), and adding > proper rollback. > > Fixes: eaf961536e16 ("libnvdimm, nfit: add interleave-set state-tracking > infrastructure") > Reported-by: Andy Shevchenko > Signed-off-by: Michal W

Re: [PATCH v5 05/14] vfio/mdev: idxd: add basic mdev registration and helper functions

2021-02-16 Thread Dave Jiang
On 2/10/2021 4:59 PM, Jason Gunthorpe wrote: On Fri, Feb 05, 2021 at 01:53:24PM -0700, Dave Jiang wrote: +static int check_vma(struct idxd_wq *wq, struct vm_area_struct *vma) { - /* FIXME: Fill in later */ + if (vma->vm_end < vma->vm_start) + retur

Re: [PATCH v3] driver core: auxiliary bus: Fix calling stage for auxiliary bus init

2021-02-11 Thread Dave Jiang
On 2/11/2021 12:44 AM, Greg KH wrote: On Wed, Feb 10, 2021 at 01:16:11PM -0700, Dave Jiang wrote: MODULE_LICENSE("GPL v2"); MODULE_DESCRIPTION("Auxiliary Bus"); MODULE_AUTHOR("David Ertman "); As this code can not be built as a module, can you remove these

Re: [PATCH v3] driver core: auxiliary bus: Fix calling stage for auxiliary bus init

2021-02-11 Thread Dave Jiang
On 2/10/2021 11:54 PM, Greg KH wrote: On Wed, Feb 10, 2021 at 01:16:11PM -0700, Dave Jiang wrote: When the auxiliary device code is built into the kernel, it can be executed before the auxiliary bus is registered. This causes bus->p to be not allocated and triggers a NULL pointer derefere

[PATCH v4] driver core: auxiliary bus: Fix calling stage for auxiliary bus init

2021-02-11 Thread Dave Jiang
0x1f/0x30 [ 1.950670] Modules linked in: [ 1.950670] CR2: 0060 [ 1.950670] --[ end trace cd7d1b226d3ca901 ]-- Fixes: 7de3697e9cbd ("Add auxiliary bus support") Reported-by: Jacob Pan Acked-by: Dave Ertman Reviewed-by: Dan Williams Signed-off-by: Dave Jiang --- v4: - Remove re

Re: [PATCH v4] driver core: auxiliary bus: Fix calling stage for auxiliary bus init

2021-02-11 Thread Dave Jiang
On 2/11/2021 10:59 AM, Greg KH wrote: On Thu, Feb 11, 2021 at 10:42:49AM -0700, Dave Jiang wrote: When the auxiliary device code is built into the kernel, it can be executed before the auxiliary bus is registered. This causes bus->p to be not allocated and triggers a NULL pointer derefere

[PATCH] driver core: auxiliary bus: Remove unneeded module bits

2021-02-11 Thread Dave Jiang
Remove module bits in the auxiliary bus code since the auxiliary bus cannot be built as a module and the relevant code is not needed. Cc: Dave Ertman Suggested-by: Greg Kroah-Hartman Signed-off-by: Dave Jiang --- drivers/base/auxiliary.c |5 - 1 file changed, 5 deletions(-) diff

Re: [PATCH v5 04/14] vfio/mdev: idxd: Add auxialary device plumbing for idxd mdev support

2021-02-12 Thread Dave Jiang
On 2/10/2021 4:46 PM, Jason Gunthorpe wrote: On Fri, Feb 05, 2021 at 01:53:18PM -0700, Dave Jiang wrote: diff --git a/drivers/dma/idxd/idxd.h b/drivers/dma/idxd/idxd.h index a2438b3166db..f02c96164515 100644 +++ b/drivers/dma/idxd/idxd.h @@ -8,6 +8,7 @@ #include #include #include

  1   2   3   4   >