Re: [ndctl PATCH] ndctl: make completion smarter wrt mode/type/idle options

2016-06-27 Thread Verma, Vishal L
On Mon, 2016-06-27 at 14:13 -0700, Dan Williams wrote: > On Mon, Jun 27, 2016 at 1:43 PM, Vishal Verma m> wrote: > > > > Add three new 'filters' for mode, type, and idle. > > > > 'mode' and 'type' work with each other to prevent a blk namespace > > from > > showing

Re: btt ndctl question

2016-07-26 Thread Verma, Vishal L
On Tue, 2016-07-26 at 14:58 -0600, Vishal Verma wrote: > On 07/26, Linda Knippers wrote: > > > > My system has 4 8G NVDIMMs and I have them configured in different > > ways, as you can > > see from the ndctl output: > > > > $ ndctl list > > [ > >   { > > "dev":"namespace3.0", > >

Re: [PATCH 1/3] pmem: clarify a debug print in pmem_clear_poison

2016-07-19 Thread Verma, Vishal L
On Tue, 2016-07-19 at 08:53 -0700, Dan Williams wrote: > On Mon, Jul 18, 2016 at 5:44 PM, Vishal Verma m> wrote: > > Prefix the sector number being cleared with a '0x' to make it clear > > that > > this is a hex value. > > > > Signed-off-by: Vishal Verma

Re: [PATCH] acpi, nfit: print command names instead of numbers

2016-06-29 Thread Verma, Vishal L
On Wed, 2016-06-29 at 16:12 -0700, Dan Williams wrote: > On Wed, Jun 29, 2016 at 4:00 PM, Vishal Verma m> wrote: > > > > For the debug prints in acpi_nfit_ctl(), all the prints except the > > input > > buffer dump printed the command name. Make this also do the same for

Re: [PATCH] ndctl: add a BTT check utility

2017-01-30 Thread Verma, Vishal L
On Fri, 2017-01-20 at 18:14 -0500, Jeff Moyer wrote: > > > +static int btt_map_read(struct arena_info *a, __u32 lba, __u32 > > *mapping, > > + int *trim, int *error) > > +{ > > + __u32 raw_mapping, postmap, ze, z_flag, e_flag; > > + > > + raw_mapping =

Re: [PATCH] ndctl: add a BTT check utility

2017-01-20 Thread Verma, Vishal L
On Fri, 2017-01-20 at 18:14 -0500, Jeff Moyer wrote: > Hi, Vishal, > > Vishal Verma writes: > > > Add the check-namespace command to ndctl. This will check the BTT > > metadata layout for the given namespace, and if requested, correct > > any > > errors found. Not all

Re: [Lsf-pc] [LSF/MM TOPIC] Badblocks checking/representation in filesystems

2017-01-18 Thread Verma, Vishal L
On Wed, 2017-01-18 at 13:32 -0800, Dan Williams wrote: > On Wed, Jan 18, 2017 at 1:02 PM, Darrick J. Wong > wrote: > > On Wed, Jan 18, 2017 at 03:39:17PM -0500, Jeff Moyer wrote: > > > Jan Kara writes: > > > > > > > On Tue 17-01-17 15:14:21, Vishal Verma

Re: [LSF/MM TOPIC] Badblocks checking/representation in filesystems

2017-01-19 Thread Verma, Vishal L
> > > > > > > Original Message > > > > > > > Subject: [LSF/MM TOPIC] Badblocks checking/representation > > > > > > > in filesystems > > > > > > > Sent: Jan 13, 2017 1:40 PM > > > > > > > Fr

Re: [LSF/MM TOPIC] Badblocks checking/representation in filesystems

2017-01-19 Thread Verma, Vishal L
On Tue, 2017-01-17 at 17:58 -0800, Andiry Xu wrote: > On Tue, Jan 17, 2017 at 3:51 PM, Vishal Verma m> wrote: > > On 01/17, Andiry Xu wrote: > > > > > > > > > > > > > > > > The pmem_do_bvec() read logic is like this: > > > > > > > > > > pmem_do_bvec() > > > > >

Re: [ndctl PATCH v2 2/3] ndctl: add a BTT check utility

2017-02-28 Thread Verma, Vishal L
On Tue, 2017-02-28 at 16:11 -0500, Jeff Moyer wrote: > Hi, Vishal, > > Vishal Verma writes: > > > Add the check-namespace command to ndctl. This will check the BTT > > metadata layout for the given namespace, and if requested, correct > > any > > errors found. Not all

Re: [PATCH] libnvdimm: allow legacy (e820) pmem region to clear bad blocks

2016-09-09 Thread Verma, Vishal L
On Thu, 2016-09-08 at 20:57 -0700, Dan Williams wrote: > On Thu, Sep 8, 2016 at 5:28 PM, Verma, Vishal L > <vishal.l.ve...@intel.com> wrote: > > > > On Thu, 2016-09-08 at 16:33 -0700, Dave Jiang wrote: > > > > > > Bad blocks can be injected via /sys/b

Re: [PATCH] dev-dax: add support to display badblocks in sysfs for dev-dax

2016-09-28 Thread Verma, Vishal L
On Wed, 2016-09-28 at 11:52 -0700, Dave Jiang wrote: > Adding support to show badblocks in the pmem region that's provided > by the poison_list. This should show up in > /sys/class/dax/daxN.N/badblocks as read only. I think we can allow error injection by making this read/write. See

Re: [PATCH] libnvdimm: use consistent naming for request_mem_region()

2016-11-28 Thread Verma, Vishal L
On Mon, 2016-11-28 at 11:25 -0800, Dan Williams wrote: > Here is an example /proc/iomem listing for a system with 2 > namespaces, > one in "sector" mode and one in "memory" mode: > >   1fc00-2fbff : Persistent Memory (legacy) > 1fc00-2fbff : namespace1.0 >  

[LSF/MM TOPIC] Badblocks checking/representation in filesystems

2017-01-13 Thread Verma, Vishal L
The current implementation of badblocks, where we consult the badblocks list for every IO in the block driver works, and is a last option failsafe, but from a user perspective, it isn't the easiest interface to work with. A while back, Dave Chinner had suggested a move towards smarter handling,

Re: [ndctl PATCH 0/7] introduce 'daxctl list', and 'ndctl list' updates

2017-01-09 Thread Verma, Vishal L
On Mon, 2017-01-09 at 14:00 -0800, Dan Williams wrote: > On Mon, Jan 9, 2017 at 1:56 PM, Vishal Verma > wrote: > > On 01/06, Dan Williams wrote: > > > * The 'ndctl list' command awkwardly prints out all the > > > corresponding > > >   device-dax information when a

Re: [PATCH] nfit: Fix extended status translations for ACPI DSMs

2016-12-05 Thread Verma, Vishal L
On Mon, 2016-12-05 at 13:37 -0800, Dan Williams wrote: > On Mon, Dec 5, 2016 at 1:27 PM, Vishal Verma > wrote: > > > > ACPI DSMs can have an 'extended' status which can be non-zero to > > convey > > additional information about the command. In the xlat_status > >

Re: [ndctl PATCH v3 6/7] ndctl: add a BTT check utility

2017-03-14 Thread Verma, Vishal L
On Mon, 2017-03-13 at 19:26 -0400, Linda Knippers wrote: > Hi Vishal, > > Thanks for all your work on this.  I finally got a chance to do some > testing and have a few usability suggestions for you to consider. Thanks for the comments, Linda. See below, but yes I can send follow on patches for

Re: [PATCH v2] libnvdimm: fix clear poison locking with spinlock and mempool

2017-04-11 Thread Verma, Vishal L
On Tue, 2017-04-11 at 15:09 -0700, Dave Jiang wrote: > The following warning results from holding a lane spinlock, > preempt_disable(), or the btt map spinlock and then trying to take the > reconfig_mutex to walk the poison list and potentially add new > entries. > > BUG: sleeping function called

Re: [RFC PATCH] x86, mce: change the mce notifier to 'blocking' from 'atomic'

2017-04-12 Thread Verma, Vishal L
On Wed, 2017-04-12 at 22:22 +0200, Borislav Petkov wrote: > On Wed, Apr 12, 2017 at 01:59:03PM -0600, Vishal Verma wrote: > > I don't think we can do anything about the panic path errors. > > Then the fix should be a lot easier: > > --- > diff --git a/drivers/acpi/nfit/mce.c

Re: [PATCH] acpi, nfit: fix the memory error check in nfit_handle_mce

2017-04-20 Thread Verma, Vishal L
On Thu, 2017-04-20 at 16:18 -0600, Vishal Verma wrote: > The check for an MCE being a memory error in the NFIT mce handler was > bogus. Fix it to check for the correct MCA status compound error code. > > Reported-by: Tony Luck > Cc: Forgot to

Re: [ndctl PATCH] ndctl, check: Add a sigbus handler to detect metadata corruption

2017-04-18 Thread Verma, Vishal L
On Mon, 2017-04-17 at 11:37 -0400, Jeff Moyer wrote: > Vishal Verma writes: > > > If we have poison/badblocks in the BTT metadata sections, the mmap- > > reads > > happening in the checker will trigger a SIGBUS, and the program > > will > > halt abruptly. Add a sigbus

Re: [RFC PATCH] x86, mce: change the mce notifier to 'blocking' from 'atomic'

2017-04-21 Thread Verma, Vishal L
On Thu, 2017-04-13 at 13:31 +0200, Borislav Petkov wrote: > On Thu, Apr 13, 2017 at 12:29:25AM +0200, Borislav Petkov wrote: > > On Wed, Apr 12, 2017 at 03:26:19PM -0700, Luck, Tony wrote: > > > We can futz with that and have them specify which chain (or both) > > > that they want to be added to.

Re: [ndctl PATCH v2 2/3] ndctl: add a BTT check utility

2017-03-01 Thread Verma, Vishal L
On Wed, 2017-03-01 at 07:54 -0800, Dan Williams wrote: > On Wed, Mar 1, 2017 at 7:02 AM, Jeff Moyer <jmo...@redhat.com> wrote: > > "Verma, Vishal L" <vishal.l.ve...@intel.com> writes: > > > > > > - Differentiate the use off BTT_PG_SIZE,

Re: [ndctl PATCH] ndctl, check: Add a sigbus handler to detect metadata corruption

2017-04-14 Thread Verma, Vishal L
On Fri, 2017-04-14 at 00:10 +, Rudoff, Andy wrote: > > If we have poison/badblocks in the BTT metadata sections, the mmap- > > reads > > happening in the checker will trigger a SIGBUS, and the program > > will > > halt abruptly. Add a sigbus handler which notifies the user of > > this, and > >

Re: [ndctl PATCH] ndctl, check: Add a sigbus handler to detect metadata corruption

2017-04-14 Thread Verma, Vishal L
On Fri, 2017-04-14 at 19:26 +, Rudoff, Andy wrote: > On Fri, Apr 14, 2017 at 12:00 PM, Verma, Vishal L [...] > > Yeah, I thought about this a little more too.  Here’s what I think > should happen: > > Without --repair, I agree with this patch, although the err

Re: [PATCH v5 6/7] libnvdimm, btt: refactor initial_offset calculations

2017-08-14 Thread Verma, Vishal L
On Fri, 2017-08-11 at 18:39 -0700, Dan Williams wrote: > On Tue, Aug 8, 2017 at 5:07 PM, Vishal Verma > wrote: > > In preparation for BTT error clearing, refactor the initial offset > > calculations. Until now, all callers of arena_{read,write}_bytes > > assumed > > a

Re: [PATCH v2 5/6] libnvdimm, btt: rework error clearing

2017-07-17 Thread Verma, Vishal L
On Mon, 2017-07-17 at 15:00 -0700, Dan Williams wrote: > On Mon, Jul 17, 2017 at 2:27 PM, Vishal Verma m> wrote: > > Clearing errors or badblocks during a BTT write requires sending an > > ACPI > > DSM, which means potentially sleeping. Since a BTT IO happens in > >

Re: [ndctl PATCH] ndctl: correctly propagate errors from sysfs_write_attr

2017-07-18 Thread Verma, Vishal L
On Tue, 2017-07-18 at 14:30 -0600, Vishal Verma wrote: > In libndctl, if a sysfs_write_attr failed, we simply returned ENXIO, > which would print a confusing error message ("unsupported > configuration") for something like EACCESS.. > > Propagate the actuall return from the sysfs helper in all

Re: [PATCH v4] libnvdimm, btt: BTT updates for UEFI 2.7 format

2017-06-28 Thread Verma, Vishal L
On Wed, 2017-06-28 at 13:14 -0700, Dan Williams wrote: > On Wed, Jun 28, 2017 at 1:07 PM, Vishal Verma m> wrote: > > The UEFI 2.7 specification defines an updated BTT metadata format, > > bumping the revision to 2.0. Add support for the new format, while > > retaining

Re: [PATCH] test: regression test for a kernel panic on running ARS for BTTs

2017-04-27 Thread Verma, Vishal L
On Thu, 2017-04-27 at 16:06 -0700, Dan Williams wrote: > On Thu, Apr 27, 2017 at 3:39 PM, Vishal Verma m> wrote: > > Runing an Address Range Scrub on a region with a BTT namespace would > > cause a kernel null pointer dereference. This tests we don't regress > > that. >

Re: [PATCH v4 0/6] BTT error clearing rework

2017-07-31 Thread Verma, Vishal L
On Mon, 2017-07-31 at 23:15 +, Kani, Toshimitsu wrote: > On Wed, 2017-07-26 at 17:35 -0600, Vishal Verma wrote: >  : > > > > Clearing errors or badblocks during a BTT write requires sending an > > ACPI DSM, which means potentially sleeping. Since a BTT IO happens > > in > > atomic context

Re: [PATCH v5] ndctl: add clear error support for ndctl

2017-05-02 Thread Verma, Vishal L
On Tue, 2017-05-02 at 17:08 -0700, Dave Jiang wrote: > On 05/02/2017 04:54 PM, Vishal Verma wrote: > > On 05/02, Dave Jiang wrote: > > > > > > + > > > + if (!S_ISCHR(stats.st_mode)) { > > > + error("%s not DAX device\n", dev_name); > > > + return -1; > > > + } > > > + > > > > A

Re: [PATCH 1/2] x86/MCE: Export memory_error()

2017-05-10 Thread Verma, Vishal L
On Thu, 2017-05-11 at 00:16 +0200, Borislav Petkov wrote: > On Wed, May 10, 2017 at 10:03:42PM +0000, Verma, Vishal L wrote: > > ... Depending on how frequently machine checks happen that are not > > memory errors but have the addr field set (hopefully rare anyway), > > we >

Re: [PATCH v5 2/2] ndctl: add list --media-errors support

2017-05-11 Thread Verma, Vishal L
On Thu, 2017-05-11 at 10:52 -0700, Dave Jiang wrote: > > On 05/11/2017 10:48 AM, Kani, Toshimitsu wrote: > > On Thu, 2017-05-11 at 10:37 -0700, Dave Jiang wrote: > > > ACPI NFIT enabled platforms provide media errors as absolute > > > phyiscal > > > address offsets. Add an option to ndctl to

Re: [PATCH 1/2] x86/MCE: Export memory_error()

2017-05-10 Thread Verma, Vishal L
On Tue, 2017-04-25 at 15:07 -0600, Vishal Verma wrote: > On 04/24, Borislav Petkov wrote: > > From: Borislav Petkov > > Date: Mon, 24 Apr 2017 13:16:50 +0200 > > Subject: [PATCH 1/2] x86/MCE: Export memory_error() > > > > Export the function which checks whether an MCE is a memory

Re: [PATCH 1/2] x86/MCE: Export memory_error()

2017-05-17 Thread Verma, Vishal L
On Wed, 2017-05-17 at 14:38 +0200, Borislav Petkov wrote: > On Wed, May 10, 2017 at 10:22:32PM +0000, Verma, Vishal L wrote: > > > I'll prep the queue next week and run tests. > > > > > > > Ok, Thanks Boris! > > Ok, I've pushed a branch: > > https

Re: [PATCH 1/2] x86/MCE: Export memory_error()

2017-05-10 Thread Verma, Vishal L
On Wed, 2017-05-10 at 22:08 +0200, Borislav Petkov wrote: > On Wed, May 10, 2017 at 08:06:53PM +0000, Verma, Vishal L wrote: > > Ah I was under the impression that this can go in for 4.12.. > > ... and the reason for hurrying it into 4.12 is? > The memory error check i

Re: [PATCH 1/2] x86/MCE: Export memory_error()

2017-05-10 Thread Verma, Vishal L
On Wed, 2017-05-10 at 23:57 +0200, Borislav Petkov wrote: > On Wed, May 10, 2017 at 09:12:12PM +0000, Verma, Vishal L wrote: > > The memory error check in the nfit handler is a valid, and simple > > fix. > > I need the big picture here: "Without

Re: [PATCH 1/2] x86/MCE: Export memory_error()

2017-05-10 Thread Verma, Vishal L
On Wed, 2017-05-10 at 22:04 +0200, Borislav Petkov wrote: > On Wed, May 10, 2017 at 07:31:30PM +0000, Verma, Vishal L wrote: > > I didn't see the above patches in the RAS branches of the tip tree - > > You need to be patient - we have merge window right now. Next week, > a

Re: [PATCH] libnvdimm: rework region badblocks clearing

2017-05-01 Thread Verma, Vishal L
On Mon, 2017-05-01 at 09:38 -0700, Dan Williams wrote: > On Mon, May 1, 2017 at 9:20 AM, Kani, Toshimitsu > wrote: > > On Mon, 2017-05-01 at 09:16 -0700, Dan Williams wrote: > > > On Mon, May 1, 2017 at 9:12 AM, Kani, Toshimitsu > > com> > > > wrote: > > > >

Re: [PATCH] nvdimm, btt: make sure initializing new metadata clears poison

2017-05-08 Thread Verma, Vishal L
On Mon, 2017-05-08 at 10:00 -0700, Dan Williams wrote: > On Wed, Apr 26, 2017 at 3:43 PM, Vishal Verma om> wrote: > > If we had badblocks/poison in the metadata area of a BTT, > > recreating the > > BTT would not clear the poison in all cases, notably the flog area. > >

Re: [PATCH 3/3] acpi nfit: nfit_test supports translate SPA

2017-09-21 Thread Verma, Vishal L
On Fri, 2017-08-18 at 13:50 +0900, Yasunori Goto wrote: > nfit_test supports translate SPA > > To test ndctl list which use interface of Translate SPA, > nfit_test needs to emulates it. > This test module searches region which includes SPA and  > returns 1 dimm handle which is last one. > > >

Re: [PATCH 0/3] acpi nfit: make emulation of translate SPA on nfit_test

2017-09-21 Thread Verma, Vishal L
On Fri, 2017-08-18 at 13:46 +0900, Yasunori Goto wrote: > This patch set is to emulate translate SPA feature by nfit_test.ko. > > Certainly the nfit acpi driver supports translate SPA interface  > via ND_CMD_CALL. But nfit_test does not support it yet. > > To test translate SPA with nfit_test,

Re: [PATCH v4 0/3] acpi nfit: make emulation of translate SPA on nfit_test

2017-10-06 Thread Verma, Vishal L
On Thu, 2017-10-05 at 21:57 -0700, Dan Williams wrote: > On Fri, Sep 22, 2017 at 12:44 AM, Yasunori Goto m> wrote: > > > > Hello > > > > I made a v4 patch set to emulate translate SPA by nfit_test.ko > > module. > > If possible, please merge it. > > > > > > This

Re: FAIL: dax-errors.sh failures on 4.14.0-rc4+

2017-10-13 Thread Verma, Vishal L
On Tue, 2017-10-10 at 03:04 +, Cheng-mean Liu (SOCCER) wrote: > Hi: > > I am hitting the following ndctl test failure, all code from > ndctl/Linux upstream kernel. > > Is this a know issue? > > FAIL: dax-errors.sh > SKIP: daxdev-errors.sh > > FAIL: dax-errors.sh > === > >

Re: [ndctl PATCH 7/7] ndctl: auto initialize labels

2017-08-29 Thread Verma, Vishal L
On Tue, 2017-08-29 at 13:02 -0700, Dan Williams wrote: > If we are reconfiguring an ND_DEVICE_NAMESPACE_IO namespace take the > opportunity to potentially initialize labels. DIMM capacity that is > not > aliased will surface as a label-less namespace by default. If every > DIMM > in the interleave

Re: [ndctl PATCH 7/7] ndctl: auto initialize labels

2017-08-29 Thread Verma, Vishal L
On Tue, 2017-08-29 at 14:48 -0700, Dan Williams wrote: > On Tue, Aug 29, 2017 at 2:32 PM, Verma, Vishal L > <vishal.l.ve...@intel.com> wrote: > > On Tue, 2017-08-29 at 13:02 -0700, Dan Williams wrote: > > > If we are reconfiguring an ND_DEVICE_

Re: [PATCH v6 6/6] libnvdimm, btt: rework error clearing

2017-08-24 Thread Verma, Vishal L
On Wed, 2017-08-23 at 17:23 +, Kani, Toshimitsu wrote: > On Tue, 2017-08-22 at 16:19 -0600, Vishal Verma wrote: >  : > > + > > +/* The block had a media error, and needs to be > > cleared */ > > +if (btt_is_badblock(btt, arena, arena- > > > freelist[lane].block)) { > > > >

Re: [PATCH 1/4] libnvdimm: move poison list functions to a new 'badrange' file

2017-10-09 Thread Verma, Vishal L
On Fri, 2017-10-06 at 11:52 -0700, Dan Williams wrote: > On Thu, Oct 5, 2017 at 6:53 PM, Vishal Verma > wrote: > > From: Dave Jiang > > > > From: Dave Jiang > > > > nfit_test needs to use the poison list manipulation code

Re: [ndctl PATCH 6/8] ndctl/test: add a new unit test for inject-error

2017-10-09 Thread Verma, Vishal L
On Thu, 2017-10-05 at 19:54 -0600, Vishal Verma wrote: > +do_tests() > +{ > +   # TODO > +   return > +} Not sure how this happened, but I managed to include a stale version of this file or something, that only has the boilerplate. I'll fix up for the next rev.

Re: [ndctl PATCH] rpmbuild: ensure the rpmbuild working directories are present

2017-11-27 Thread Verma, Vishal L
On Wed, 2017-11-22 at 15:49 -0800, Dan Williams wrote: > On Wed, Nov 22, 2017 at 2:15 PM, Verma, Vishal L > <vishal.l.ve...@intel.com> wrote: > > > > On Wed, 2017-11-22 at 14:13 -0800, Dan Williams wrote: > > > On Wed, Nov 22, 2017 at 2:00 PM, Vishal Verma <vi

Re: [ndctl PATCH] rpmbuild: ensure the rpmbuild working directories are present

2017-11-22 Thread Verma, Vishal L
On Wed, 2017-11-22 at 14:13 -0800, Dan Williams wrote: > On Wed, Nov 22, 2017 at 2:00 PM, Vishal Verma om> wrote: > > The rpmbuild and make-git-snapshot assume that the various > > ~/rpmbuild/* > > directories are present. In case they weren't, git-archive would > > fail

Re: [patch] btt: fix uninitialized err_lock

2017-12-13 Thread Verma, Vishal L
On Wed, 2017-12-13 at 16:33 -0500, Jeff Moyer wrote: > Hi, > > When a sector mode namespace is initially created, the arena's > err_lock > is not initialized. If, on the other hand, the namespace already > exists, the mutex is initialized. To fix the issue, I moved the > mutex > initialization

Limitation in the badblocks routines

2017-11-07 Thread Verma, Vishal L
I think I've found a limitation in the badblocks implementation (block/badblocks.c), which we now also use for nvdimm badblocks.  Consider the following operations: badblocks_set(bb, 32, 1); badblocks_set(bb, 34, 1); badblocks_set(bb, 36, 1); badblocks_show will now correctly report: 32 1 34 1

Re: [ndctl PATCH] libndctl, nfit: Fix in/out sizes for error injection commands

2017-11-08 Thread Verma, Vishal L
On Wed, 2017-11-08 at 10:48 -0800, Dan Williams wrote: > On Wed, Nov 8, 2017 at 10:07 AM, Dan Williams om> wrote: > > On Tue, Nov 7, 2017 at 2:50 PM, Vishal Verma > com> wrote: > > > The input/output size bounds being set in the various > > >

Re: [PATCH v5 3/4] ndctl: convert region actions to use util_filter_walk()

2018-05-09 Thread Verma, Vishal L
On Wed, 2018-05-09 at 16:26 -0700, Dan Williams wrote: > On Wed, May 9, 2018 at 4:24 PM, Dave Jiang <dave.ji...@intel.com> wrote: > > > > > > On 05/09/2018 04:23 PM, Dan Williams wrote: > > > On Wed, May 9, 2018 at 4:17 PM, Verma, Vishal L > > > <

Re: [PATCH v5 3/4] ndctl: convert region actions to use util_filter_walk()

2018-05-09 Thread Verma, Vishal L
On Fri, 2018-04-27 at 15:08 -0700, Dave Jiang wrote: > util_filter_walk() does the looping through of busses and regions. > Removing > duplicate code in region ops and provide filter functions so we can > utilize util_filter_walk() and share common code. > > Signed-off-by: Dave Jiang

Re: [PATCH v5 2/4] ndctl: convert namespace actions to use util_filter_walk()

2018-05-09 Thread Verma, Vishal L
On Fri, 2018-04-27 at 15:08 -0700, Dave Jiang wrote: > util_filter_walk() does the looping through of busses and regions. > Removing > duplicate code in namespace ops and provide filter functions so we can > utilize util_filter_walk() and share common code. > > Signed-off-by: Dave Jiang

Re: [PATCH] ndctl: remove warning caused by -D_FORTIFY_SOURCE=2 and -O0 compile flags

2018-05-11 Thread Verma, Vishal L
On Thu, 2018-05-10 at 16:47 -0700, Dave Jiang wrote: > Compiler spits out warning with -D_FORTIFY_SOURCE=2 and -O0. Moving to > -O2 > to remove warnings. > > Signed-off-by: Dave Jiang > --- > README.md |2 +- > autogen.sh |2 +- > 2 files changed, 2 insertions(+),

Re: [ndctl PATCH] ndctl: warn on variables declared after statement

2018-05-11 Thread Verma, Vishal L
On Fri, 2018-05-11 at 10:47 -0700, Dan Williams wrote: > Similar to the kernel, require all variables to be declared before > statements. > > Signed-off-by: Dan Williams > --- > configure.ac |1 + > 1 file changed, 1 insertion(+) > > diff --git a/configure.ac

Re: [PATCH] ndctl: remove warning caused by -D_FORTIFY_SOURCE=2 and -O0 compile flags

2018-05-11 Thread Verma, Vishal L
On Fri, 2018-05-11 at 09:49 -0700, Dave Jiang wrote: > Compiler spits out warning with -D_FORTIFY_SOURCE=2 and -O0. Moving to > -O2 > to remove warnings. > > Signed-off-by: Dave Jiang > --- > > -v2: Add -O2 option to configure.ac as well. (Vishal) Thanks for the update,

Re: [PATCH] ndctl: remove warning caused by -D_FORTIFY_SOURCE=2 and -O0 compile flags

2018-05-11 Thread Verma, Vishal L
On Fri, 2018-05-11 at 09:03 -0700, Dan Williams wrote: > On Fri, May 11, 2018 at 9:00 AM, Verma, Vishal L > <vishal.l.ve...@intel.com> wrote: > > On Thu, 2018-05-10 at 16:47 -0700, Dave Jiang wrote: > > > Compiler spits out warning with -D_FORTIFY_SOURCE=2 and -O0

Re: [PATCH] ndctl: remove warning caused by -D_FORTIFY_SOURCE=2 and -O0 compile flags

2018-05-11 Thread Verma, Vishal L
On Fri, 2018-05-11 at 16:15 +, Verma, Vishal L wrote: > On Fri, 2018-05-11 at 09:03 -0700, Dan Williams wrote: > > On Fri, May 11, 2018 at 9:00 AM, Verma, Vishal L > > <vishal.l.ve...@intel.com> wrote: > > > On Thu, 2018-05-10 at 16:47 -0700, Dave Jiang wro

Re: [ndctl PATCH] ndctl: hide null uuids

2018-05-23 Thread Verma, Vishal L
On Tue, 2018-05-22 at 09:19 -0700, Dan Williams wrote: > Clean up the namespace listing to hide the 'raw_uuid' field when it is > zero. > > Signed-off-by: Dan Williams > --- > util/json.c | 19 +-- > 1 file changed, 9 insertions(+), 10 deletions(-)

Re: [ndctl PATCH] test: add a MADV_HWPOISON test

2018-05-23 Thread Verma, Vishal L
On Tue, 2018-05-22 at 09:19 -0700, Dan Williams wrote: > Check that injecting soft-poison to a dax mapping results in SIGBUS with > the expected BUS_MCEERR_AR siginfo data. > > Signed-off-by: Dan Williams > --- > test/dax-pmd.c | 130 >

Re: [PATCH 2/2] test: cleanup test scripts

2018-06-12 Thread Verma, Vishal L
On Mon, 2018-06-11 at 12:45 -0400, Masayoshi Mizuma wrote: > From: Masayoshi Mizuma > > Include 'common' file to use some fucntions for test scripts. > > Signed-off-by: Masayoshi Mizuma > --- > test/blk-exhaust.sh | 21 +++- > test/btt-check.sh | 35

Re: [PATCH v6 1/4] ndctl, util: add OPTION_FILENAME to parse_opt_type

2018-06-12 Thread Verma, Vishal L
On Wed, 2018-05-16 at 02:42 +, Qi, Fuli wrote: > > -Original Message- > > From: Dan Williams [mailto:dan.j.willi...@intel.com] > > Sent: Saturday, May 12, 2018 1:42 AM > > To: Qi, Fuli/斉 福利 > > Cc: linux-nvdimm > > Subject: Re: [PATCH v6 1/4] ndctl, util: add OPTION_FILENAME to > >

Re: [PATCH v2 0/2] ndctl, test: add some helper function and cleanup test script

2018-06-13 Thread Verma, Vishal L
On Tue, 2018-06-12 at 21:56 -0400, Masayoshi Mizuma wrote: > Some test scripts have same function. So, let's cleanup > to stop the duplication by intoducing 'test/common' file. > Test scripts includes the common file to use the functions. > > Changelog: > - Add SPDX style license header to the

Re: [ndctl PATCH] ndctl, contrib: Add helper scripts for new release

2018-06-15 Thread Verma, Vishal L
On Fri, 2018-06-15 at 07:58 -0700, Dan Williams wrote: > On Fri, Jun 15, 2018 at 1:14 AM, Vishal Verma > wrote: > > Add a couple of helper scripts to codify the release process. > > First is do_abidiff: This builds RPMs for two different versions of > > ndctl (specified as a git revision range,

Re: [PATCH 2/2] nfit, test: cleanup test scripts

2018-06-18 Thread Verma, Vishal L
On Thu, 2018-06-14 at 15:43 -0400, Masayoshi Mizuma wrote: > From: Masayoshi Mizuma > > Cleanup some test scripts by using helper functions. > > Signed-off-by: Masayoshi Mizuma > --- > test/blk-exhaust.sh | 21 ++-- > test/btt-check.sh | 52

Re: [ndctl PATCH] ndctl, list: display the 'map' location in listings

2018-05-29 Thread Verma, Vishal L
On Mon, 2018-05-28 at 11:04 -0700, Dan Williams wrote: > On Fri, May 25, 2018 at 3:36 PM Vishal Verma > wrote: > > > For 'fsdax' and 'devdax' namespaces, a 'map' location may be specified > > for page structures storage. This can be 'mem', for system RAM, or > > 'dev' > > for using pmem as the

Re: [ndctl PATCH v2] ndctl, list: display the 'map' location in listings

2018-06-04 Thread Verma, Vishal L
On Fri, 2018-06-01 at 17:01 -0700, Dan Williams wrote: > On Tue, May 29, 2018 at 4:15 PM, Vishal Verma > wrote: > > For 'fsdax' and 'devdax' namespaces, a 'map' location may be specified > > for page structures storage. This can be 'mem', for system RAM, or > > 'dev' > > for using pmem as the

Re: [ndctl PATCH] ndctl: add an api for getting ars_status flags

2018-06-05 Thread Verma, Vishal L
On Tue, 2018-06-05 at 19:07 -0700, Dan Williams wrote: > On Tue, Jun 5, 2018 at 5:00 PM, Vishal Verma > wrote: > > The ARS status command defines a 'flags' field that wasn't being > > exposed > > via an API yet. Add a new ndctl_cmd_ars_get_flags() helper to retrieve > > this field. > > > >

Re: [ndctl PATCH v2] ndctl: add an api for getting the ars_status overflow flag

2018-06-06 Thread Verma, Vishal L
On Wed, 2018-06-06 at 12:51 -0700, Dan Williams wrote: > On Wed, Jun 6, 2018 at 11:26 AM, Vishal Verma > wrote: > > The ARS status command defines a 'flags' field that wasn't being > > exposed > > via an API yet. Since there is only one flag defined in ACPI 6.2, add a > > helper for retrieving it

Re: [ndctl PATCH v2] ndctl: add an api for getting the ars_status overflow flag

2018-06-06 Thread Verma, Vishal L
On Wed, 2018-06-06 at 13:00 -0700, Dan Williams wrote: > On Wed, Jun 6, 2018 at 12:53 PM, Verma, Vishal L > wrote: > > On Wed, 2018-06-06 at 12:51 -0700, Dan Williams wrote: > > > On Wed, Jun 6, 2018 at 11:26 AM, Vishal Verma > > om> > > > wrote: > >

Re: [ndctl PATCH v3] ndctl: add an api for getting the ars_status overflow flag

2018-06-06 Thread Verma, Vishal L
On Wed, 2018-06-06 at 13:22 -0700, Dan Williams wrote: > On Wed, Jun 6, 2018 at 1:18 PM, Vishal Verma > wrote: > > The ARS status command defines a 'flags' field that wasn't being > > exposed > > via an API yet. Since there is only one flag defined in ACPI 6.2, add a > > helper for retrieving it

Re: [ndctl PATCH 1/3] ndctl: simplify JSON print flag handling

2018-06-29 Thread Verma, Vishal L
On Fri, 2018-06-29 at 16:51 -0700, Dan Williams wrote: > On Fri, Jun 29, 2018 at 4:39 PM, Ross Zwisler > wrote: > > json_object_to_json_string_ext()'s second argument is a flags field > > which > > we always want to be JSON_C_TO_STRING_PRETTY. We were going to a > > lot of > > trouble for

Re: [PATCH] ndctl: Use max_available_extent for creating namespaces

2018-06-26 Thread Verma, Vishal L
On Tue, 2018-06-26 at 09:37 -0600, Keith Busch wrote: > The available_size attribute returns all the unused regions, but a > namespace has to use contiguous free regions. This patch uses the > attribute returning the largest capacity that can be created for > determining if the namespace can be

Re: [PATCH] ndctl: Use max_available_extent for creating namespaces

2018-06-26 Thread Verma, Vishal L
On Tue, 2018-06-26 at 09:32 -0700, Dan Williams wrote: > On Tue, Jun 26, 2018 at 9:27 AM, Verma, Vishal L > wrote: > > On Tue, 2018-06-26 at 10:29 -0600, Keith Busch wrote: > > > On Tue, Jun 26, 2018 at 09:19:28AM -0700, Verma, Vishal L wrote: > > > > On Tue,

Re: [ndctl PATCHv2] ndctl: Use max_available_extent for namespaces

2018-06-26 Thread Verma, Vishal L
On Tue, 2018-06-26 at 11:00 -0600, Keith Busch wrote: > The available_size attribute returns all the unused regions, but a > namespace has to use contiguous free regions. This patch uses the > attribute returning the largest capacity that can be created for > determining if the namespace can be

[ANNOUNCE] ndctl v61

2018-06-26 Thread Verma, Vishal L
https://github.com/pmem/ndctl/releases/tag/v61 This release incorporates functionality up to the 4.18 kernel, and a number of bug fixes and improvements. Highlights include a fix to the error injection APIs to inject fewer bytes of errors per sector, support for building documentation with

Re: [PATCH] ndctl, list: add controller temperature threshold

2018-06-25 Thread Verma, Vishal L
On Mon, 2018-06-25 at 17:42 +0900, QI Fuli wrote: > This patch adds controller temperature threshold to list. > When the dimm-controller-temperature event fires, users need to know > the current controller temperature threshold value. > > Signed-off-by: QI Fuli > --- > ndctl/util/json-smart.c |

Re: [ndctl PATCH 2/2] ndctl: Add 'list' verbose documentation

2018-06-26 Thread Verma, Vishal L
On Tue, 2018-06-26 at 14:46 -0600, Keith Busch wrote: > Signed-off-by: Keith Busch > --- > Documentation/ndctl/ndctl-list.txt | 12 > 1 file changed, 12 insertions(+) > I think this can all just go in the first patch? > diff --git a/Documentation/ndctl/ndctl-list.txt >

Re: [PATCH v2] ndctl, filter: fix "keyword 'all' is ignored" in util__filter()

2018-05-02 Thread Verma, Vishal L
On Thu, 2018-04-26 at 09:56 +0900, QI Fuli wrote: > This is a follow up patch for commit c70adc3cf6bf ("ndctl, filter: > refactor > util__filter() to support multiple space-seperated arguments") > refactored util__filter() to support multiple space-seperated > arguments. > But, when the keyword

Re: [PATCH] ndctl: add options to update firmware manpage

2018-02-02 Thread Verma, Vishal L
On Fri, 2018-02-02 at 16:47 -0700, Dave Jiang wrote: > update firmware is missing the long/short option in the manpage. > Adding > the missing sections. > > Signed-off-by: Dave Jiang > --- > Documentation/ndctl/ndctl-update-firmware.txt | 17 > + > 1

Re: [PATCH 1/2] libnvdimm/nfit_test: add firmware download emulation

2018-01-31 Thread Verma, Vishal L
On Fri, 2018-01-26 at 10:55 -0700, Dave Jiang wrote: > Adding support in nfit_test for DSM v1.6 firmware update sequence. > The test > will simulate the flashing of firmware to the DIMM. A bogus version > string > will be returned as the test has no idea how to parse the firmware > binary. > Any

Re: [PATCH v3] libnvdimm, testing: Add emulation for smart injection commands

2018-02-08 Thread Verma, Vishal L
On Thu, 2018-02-08 at 12:54 -0800, Dan Williams wrote: > On Thu, Feb 8, 2018 at 12:49 PM, Vishal Verma om> wrote: > > Add support for the smart injection command in the nvdimm unit test > > framework. This allows for directly injecting to smart fields and > > flags > >

Re: [RFC PATCH v3 0/5] ndctl: monitor: monitor the smart events of

2018-02-09 Thread Verma, Vishal L
On Fri, 2018-02-09 at 17:02 +0900, QI Fuli wrote: > This is a patch set of ndctl monitor, a tiny daemon to monitor the > smart > events of nvdimm dimms. When a smart event fires, monitor will output > the notification which including dimm health status to syslog or a > special file according to

Re: [RFC PATCH v3 2/5] ndctl: monitor: add ndctl create-monitor command

2018-02-12 Thread Verma, Vishal L
On Sun, 2018-02-11 at 12:48 -0800, Dan Williams wrote: > On Fri, Feb 9, 2018 at 12:02 AM, QI Fuli > wrote: > > This patch is used to add $ndctl create-monitor command, by which > > users can > > create a new monitor. Users can select the DIMMS to be monitored by > > using

Re: [PATCH 2/2] ndctl: add "all" dimm-id option for update-firmware

2018-02-21 Thread Verma, Vishal L
On Wed, 2018-02-21 at 15:06 -0700, Dave Jiang wrote: > Adding all option to allow ndctl to update all DIMMs at once. I was going to ask that we should also update the documentation for this command to include the new 'all' behavior, but it looks like during the revisions of the original series,

Re: [ndclt PATCH] ndctl, monitor: Fix duplicate prefix in monitor.log

2018-08-02 Thread Verma, Vishal L
On Thu, 2018-08-02 at 09:22 -0400, Masayoshi Mizuma wrote: > Hi QI, > > On 08/02/2018 05:42 AM, Qi, Fuli wrote: > ... > > > > diff --git a/ndctl/monitor.c b/ndctl/monitor.c index > > > > c6419ad..4e5daf5 > > > > 100644 > > > > --- a/ndctl/monitor.c > > > > +++ b/ndctl/monitor.c > > > > @@

Re: [ndctl PATCH] ndctl, monitor: add [--verbose] option to emit extra debug messages

2018-08-02 Thread Verma, Vishal L
On Thu, 2018-08-02 at 23:21 +0900, QI Fuli wrote: > In the ndctl monitor, currently the debug messages cannot be outputted to log. > This patch is used for adding [--verbose] option to ndctl monitor to emit > debug messages. Also, the log level of some messages are changed by this > patch. > >

Re: [ndctl PATCHv4] ndctl: Use max_available_extent for namespace

2018-08-02 Thread Verma, Vishal L
On Thu, 2018-08-02 at 15:49 -0400, Masayoshi Mizuma wrote: > Hi Keith, > > I tested your patch with the following test script. > The result is good to me. > > Please feel free to add: > >Tested-by: Masayoshi Mizuma > > Test script: > --- > #!/bin/bash -Ex > > NDCTL=./ndctl/ndctl > >

Re: [PATCH] ACPI: nfit: return -ENODEV if fail to find NFIT at startup

2018-08-03 Thread Verma, Vishal L
On Fri, 2018-08-03 at 05:39 -0400, Ocean He wrote: > From: Ocean He > > In the beginning of acpi_nfit_add, if fail to find NFIT table then > should > return -ENODEV, instead of 0. > > Signed-off-by: Ocean He > --- > drivers/acpi/nfit/core.c | 2 +- > 1 file changed, 1 insertion(+), 1

Re: [PATCH] libnvdimm, bus: check id immediately following ida_simple_get

2018-08-03 Thread Verma, Vishal L
On Fri, 2018-08-03 at 08:08 -0400, Ocean He wrote: > From: Ocean He > > The id check was not executed immediately following ida_simple_get. > Just > change the codes position, without function change. > > Signed-off-by: Ocean He > --- > drivers/nvdimm/bus.c | 4 ++-- > 1 file changed, 2

Re: [PATCH v2] ndctl, test: add a new unit test for max_available_extent namespace

2018-08-03 Thread Verma, Vishal L
On Fri, 2018-08-03 at 14:52 -0400, Masayoshi Mizuma wrote: > From: Masayoshi Mizuma > > Add a new unit test to test max_available_extent namespace. > This feature is implemented by the following patches. > > kernel side: >

Re: [PATCH] acpi/nfit: queue issuing of ars when an uc error notification comes in

2018-07-27 Thread Verma, Vishal L
On Fri, 2018-07-27 at 09:04 -0700, Dave Jiang wrote: > When the ACPI UC error notifier gets called and ARS_REQ bit is set > with the passed in flag, we can receive -EBUSY if ARS_REQ bit is already > set for the nfit_spa->ars_state. When that happens, the ARS request is > dropped. That can

Re: [ndctl PATCH 0/4] Some fixups and improvements ndctl monitor

2018-08-10 Thread Verma, Vishal L
On Tue, 2018-08-07 at 22:17 +0900, QI Fuli wrote: > Fix a couple of issues about log collection, and add [Install] section > to systemd unit file of ndclt-monitor. > > Signed-off-by: QI Fuli > --- > QI Fuli (4): > ndctl, monitor: fix the lack of detection of invalid path of log file >

Re: [ndctl PATCHv4] ndctl: Add 'list' verbose options

2018-08-10 Thread Verma, Vishal L
On Wed, 2018-08-08 at 16:41 -0600, Keith Busch wrote: > The informational and miscellaneous flag options are becoming more > numerous, and can be difficult to remember what can be listed. This > patch adds a 'verbose' option that increases the detail listed by > automatically enabling options

Re: [PATCH 1/2] Create Intel pmem shutdown latch rule

2018-08-07 Thread Verma, Vishal L
On Tue, 2018-08-07 at 16:26 -0600, Keith Busch wrote: > This patch provides a udev rule and the program it runs for Intel > nvdimms. The program the rule executes runs two commands to allow > applications to manage unsafe shutdowns. > > The first command enables the shutdown latch. Without

  1   2   3   4   >