Re: [RFC PATCH v2 00/19] RDMA/FS DAX truncate proposal V1,000,002 ; -)

2019-08-28 Thread John Hubbard
On 8/28/19 7:02 PM, Ira Weiny wrote: On Mon, Aug 26, 2019 at 03:55:10PM +1000, Dave Chinner wrote: On Fri, Aug 23, 2019 at 10:08:36PM -0700, Ira Weiny wrote: On Sat, Aug 24, 2019 at 10:11:24AM +1000, Dave Chinner wrote: On Fri, Aug 23, 2019 at 09:04:29AM -0300, Jason Gunthorpe wrote: ... Su

Re: [ndctl PATCH 3/3] ndctl/namespace: add a --continue option to create namespaces greedily

2019-08-28 Thread Dan Williams
On Wed, Aug 28, 2019 at 5:17 PM Vishal Verma wrote: > > Add a --continue option to ndctl-create-namespaces to allow the creation > of as many namespaces as possible, that meet the given filter > restrictions. > > The creation loop will be aborted if a failure is encountered at any > point. > > Lin

Re: [RFC PATCH v2 00/19] RDMA/FS DAX truncate proposal V1,000,002 ; -)

2019-08-28 Thread Ira Weiny
On Mon, Aug 26, 2019 at 03:55:10PM +1000, Dave Chinner wrote: > On Fri, Aug 23, 2019 at 10:08:36PM -0700, Ira Weiny wrote: > > On Sat, Aug 24, 2019 at 10:11:24AM +1000, Dave Chinner wrote: > > > On Fri, Aug 23, 2019 at 09:04:29AM -0300, Jason Gunthorpe wrote: > > > > > > > IMHO it is wrong to try a

[ndctl PATCH 3/3] ndctl/namespace: add a --continue option to create namespaces greedily

2019-08-28 Thread Vishal Verma
Add a --continue option to ndctl-create-namespaces to allow the creation of as many namespaces as possible, that meet the given filter restrictions. The creation loop will be aborted if a failure is encountered at any point. Link: https://github.com/pmem/ndctl/issues/106 Reported-by: Steve Scarga

[ndctl PATCH 1/3] Documentation: refactor 'bus options' into its own include

2019-08-28 Thread Vishal Verma
Create a new 'xable-bus-options.txt' file that is included everywhere that previously relied upon xable-region-options.txt for bus options inclusion. While at it, fix the formatting for the first description text block from an include - the empty line at the start caused the first block to be inco

[ndctl PATCH 0/3] greedy namespace creation

2019-08-28 Thread Vishal Verma
Patch 1 and 2 refactor and clarify the documentation for the way filtering works using --bus=, --region=, and --dimm= options for all commands. Patch 3 adds a new --continue option to continue creating as many namespaces as possible for the given filter spec. Vishal Verma (3): Documentation: re

[ndctl PATCH 2/3] Documentation: clarify bus/dimm/region filtering

2019-08-28 Thread Vishal Verma
Reword the option descriptions in xable-{bus,dimm,region}-options.txt to clarify that the options are a filtering restriction rather than a directive to perform an action on the supplied objects, especially in case of the 'all' keyword. Link: https://github.com/pmem/ndctl/issues/106 Cc: Jeff Moyer

Re: [PATCH 01/19] dax: remove block device dependencies

2019-08-28 Thread Dan Williams
On Wed, Aug 28, 2019 at 3:53 PM Dave Chinner wrote: > > On Wed, Aug 28, 2019 at 01:58:43PM -0400, Vivek Goyal wrote: > > On Tue, Aug 27, 2019 at 11:58:09PM -0700, Christoph Hellwig wrote: > > > On Tue, Aug 27, 2019 at 12:38:28PM -0400, Vivek Goyal wrote: > > > > > For bdev_dax_pgoff > > > > > I'd

Re: [ndctl RFC PATCH] ndctl/namespace: create namespaces greedily

2019-08-28 Thread Verma, Vishal L
On Wed, 2019-08-28 at 15:38 -0700, Scargall, Steve wrote: > Thanks for the clarification. I have a much better understanding > now. > > Updating the ndctl-create-namespace man page to clarify what ' > --region=all' does and does not do in combination with other arguments > and options would be b

Re: [PATCH 01/19] dax: remove block device dependencies

2019-08-28 Thread Dave Chinner
On Wed, Aug 28, 2019 at 01:58:43PM -0400, Vivek Goyal wrote: > On Tue, Aug 27, 2019 at 11:58:09PM -0700, Christoph Hellwig wrote: > > On Tue, Aug 27, 2019 at 12:38:28PM -0400, Vivek Goyal wrote: > > > > For bdev_dax_pgoff > > > > I'd much rather have the partition offset if there is on in the daxde

RE: [ndctl RFC PATCH] ndctl/namespace: create namespaces greedily

2019-08-28 Thread Scargall, Steve
Thanks for the clarification. I have a much better understanding now. Updating the ndctl-create-namespace man page to clarify what '--region=all' does and does not do in combination with other arguments and options would be beneficial. This would actually provide a more immediate solution to

为什么质量不合格率居高不下,成本得不到很好的控制

2019-08-28 Thread 卜牍
linux-nvdimm 附 件 亲 启 6:25:41 ___ Linux-nvdimm mailing list Linux-nvdimm@lists.01.org https://lists.01.org/mailman/listinfo/linux-nvdimm

Re: [ndctl RFC PATCH] ndctl/namespace: create namespaces greedily

2019-08-28 Thread Dan Williams
On Wed, Aug 28, 2019 at 2:22 PM Verma, Vishal L wrote: > > On Wed, 2019-08-28 at 21:16 +, Verma, Vishal L wrote: > > On Wed, 2019-08-28 at 13:47 -0700, Scargall, Steve wrote: > > > Hi Jeff, > > > > > > The issue is more of repetition. On an 8-socket system, should a > > > user really be exp

Re: [ndctl RFC PATCH] ndctl/namespace: create namespaces greedily

2019-08-28 Thread Verma, Vishal L
On Wed, 2019-08-28 at 21:16 +, Verma, Vishal L wrote: > On Wed, 2019-08-28 at 13:47 -0700, Scargall, Steve wrote: > > Hi Jeff, > > > > The issue is more of repetition. On an 8-socket system, should a > > user really be expected to type 'ndctl create-namespace' eight times > > vs. running 'n

Re: [ndctl RFC PATCH] ndctl/namespace: create namespaces greedily

2019-08-28 Thread Verma, Vishal L
On Wed, 2019-08-28 at 13:47 -0700, Scargall, Steve wrote: > Hi Jeff, > > The issue is more of repetition. On an 8-socket system, should a > user really be expected to type 'ndctl create-namespace' eight times > vs. running 'ndctl create-namespace --region=all' once? SAP HANA is > an example a

RE: [ndctl RFC PATCH] ndctl/namespace: create namespaces greedily

2019-08-28 Thread Scargall, Steve
Hi Jeff, The issue is more of repetition. On an 8-socket system, should a user really be expected to type 'ndctl create-namespace' eight times vs. running 'ndctl create-namespace --region=all' once? SAP HANA is an example app the requires one namespace per region. Scripting is a viable so

Re: [PATCH] libnvdimm, region: Use struct_size() in kzalloc()

2019-08-28 Thread Kees Cook
On Wed, Aug 28, 2019 at 01:30:24PM -0500, Gustavo A. R. Silva wrote: > Hi all, > > Friendly ping: > > Who can take this, please? > > Thanks > -- > Gustavo > > On 6/10/19 4:06 PM, Gustavo A. R. Silva wrote: > > One of the more common cases of allocation size calculations is finding > > the size

Re: [PATCH] libnvdimm, region: Use struct_size() in kzalloc()

2019-08-28 Thread Verma, Vishal L
On Wed, 2019-08-28 at 14:36 -0500, Gustavo A. R. Silva wrote: > struct_size() does not apply to those scenarios. See below... > > > [1]: > > https://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm.git/tree/drivers/nvdimm/region_devs.c#n1030 > > struct_size() only applies to structures of

Re: [ndctl RFC PATCH] ndctl/namespace: create namespaces greedily

2019-08-28 Thread Jeff Moyer
Vishal Verma writes: > When a --region=all option is supplied to ndctl-create-namespace, it > happily ignores it, since create-namespace has historically only created > one namespace per invocation. > > This can be cumbersome, so change create-namespace to create namespaces > greedily. When --reg

[ndctl RFC PATCH] ndctl/namespace: create namespaces greedily

2019-08-28 Thread Vishal Verma
When a --region=all option is supplied to ndctl-create-namespace, it happily ignores it, since create-namespace has historically only created one namespace per invocation. This can be cumbersome, so change create-namespace to create namespaces greedily. When --region=all is specified, or if a --re

Re: [PATCH] libnvdimm, region: Use struct_size() in kzalloc()

2019-08-28 Thread Gustavo A. R. Silva
Hi Vishal, On 8/28/19 1:51 PM, Verma, Vishal L wrote: [..] > > Hi Gustavo, > > The patch looks good to me, however it looks like it might've missed > some instances where this replacement can be performed? > struct_size() does not apply to those scenarios. See below... > > [1]: > https://

Re: [PATCH] libnvdimm, region: Use struct_size() in kzalloc()

2019-08-28 Thread Verma, Vishal L
On Mon, 2019-06-10 at 16:06 -0500, Gustavo A. R. Silva wrote: > One of the more common cases of allocation size calculations is > finding > the size of a structure that has a zero-sized array at the end, along > with memory for some number of elements for that array. For example: > > struct nd_reg

Re: [PATCH] libnvdimm, region: Use struct_size() in kzalloc()

2019-08-28 Thread Gustavo A. R. Silva
Hi all, Friendly ping: Who can take this, please? Thanks -- Gustavo On 6/10/19 4:06 PM, Gustavo A. R. Silva wrote: > One of the more common cases of allocation size calculations is finding > the size of a structure that has a zero-sized array at the end, along > with memory for some number of e

Re: [PATCH 01/19] dax: remove block device dependencies

2019-08-28 Thread Vivek Goyal
On Tue, Aug 27, 2019 at 11:58:09PM -0700, Christoph Hellwig wrote: > On Tue, Aug 27, 2019 at 12:38:28PM -0400, Vivek Goyal wrote: > > > For bdev_dax_pgoff > > > I'd much rather have the partition offset if there is on in the daxdev > > > somehow so that we can get rid of the block device entirely.

Re: [PATCH v2 0/3] libnvdimm/security: Enumerate the frozen state and other cleanups

2019-08-28 Thread Jeff Moyer
Dan Williams writes: > Changes since v1 [1]: > - Cleanup patch1, simplify flags return in the overwrite case and > consolidate frozen-state cases (Jeff) > - Clarify the motivation for patch2 (Jeff) > - Collect Dave's Reviewed-by The series tests out fine for me. Thanks, Dan! -Jeff > > [1]:

Re: [PATCH v2 1/3] libnvdimm/security: Introduce a 'frozen' attribute

2019-08-28 Thread Jeff Moyer
Dan Williams writes: > In the process of debugging a system with an NVDIMM that was failing to > unlock it was found that the kernel is reporting 'locked' while the DIMM > security interface is 'frozen'. Unfortunately the security state is > tracked internally as an enum which prevents it from co

Re: [PATCH v2 2/3] libnvdimm/security: Tighten scope of nvdimm->busy vs security operations

2019-08-28 Thread Jeff Moyer
Dan Williams writes: > An attempt to freeze DIMMs currently runs afoul of default blocking of > all security operations in the entry to the 'store' routine for the > 'security' sysfs attribute. > > The blanket blocking of all security operations while the DIMM is in > active use in a region is to

[patch] libnvdimm/pfn: Fix namespace creation on misaligned addresses

2019-08-28 Thread Jeff Moyer
Yi reported[1] that after commit a3619190d62e ("libnvdimm/pfn: stop padding pmem namespaces to section alignment"), it was no longer possible to create a device dax namespace with a 1G alignment. The reason was that the pmem region was not itself 1G-aligned. The code happily skips past the first

Re: [PATCH] ndctl: Use the same align value as original namespace on reconfigure

2019-08-28 Thread Aneesh Kumar K.V
"Verma, Vishal L" writes: > On Wed, 2019-08-07 at 10:14 +0530, Aneesh Kumar K.V wrote: >> When using reconfigure command to add a `name` to the namespace we end >> up updating the align attribute. Avoid this by using the value from >> the original namespace. Do this only if we are keeping the nam