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

2018-07-25 Thread Huaisheng HS1 Ye
> From: Dave Jiang > Sent: Thursday, July 26, 2018 5:36 AM > Subject: [External] Re: [PATCH v2 0/6] kaddr and pfn can be NULL to > ->direct_access() > > Pretty straight forward series. Huaisheng, I can apply the whole series > to libnvdimm if we can get ack's from maintainer of dcssblk and >

Re: [PATCH v4 0/2] ext4: fix DAX dma vs truncate/hole-punch

2018-07-25 Thread Ross Zwisler
On Wed, Jul 11, 2018 at 10:17:41AM +0200, Jan Kara wrote: > On Tue 10-07-18 13:10:29, Ross Zwisler wrote: > > Changes since v3: > > * Added an ext4_break_layouts() call to ext4_insert_range() to ensure > >that the {ext4,xfs}_break_layouts() calls have the same meaning. > >(Dave, Darrick

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 v6 10/11] nfit_test: add test support for Intel nvdimm security DSMs

2018-07-25 Thread Dave Jiang
Add nfit_test support for DSM functions "Get Security State", "Set Passphrase", "Disable Passphrase", "Unlock Unit", "Freeze Lock", and "Secure Erase" for the fake DIMMs. Also adding a sysfs knob in order to put the DIMMs in "locked" state. The order of testing DIMM unlocking would be. 1a.

[PATCH v6 11/11] libnvdimm: add documentation for nvdimm security support

2018-07-25 Thread Dave Jiang
Add theory of operation for the security support that's going into libnvdimm. Signed-off-by: Dave Jiang --- Documentation/nvdimm/security | 70 + 1 file changed, 70 insertions(+) create mode 100644 Documentation/nvdimm/security diff --git

[PATCH v6 09/11] nfit_test: add context to dimm_dev for nfit_test

2018-07-25 Thread Dave Jiang
In order to access the nfit_test context via sideband sysfs knobs, the dimm_dev needs to be more than struct device in order to point back to struct nfit_test. Wrapping the original struct device with a struct nfit_dimm_dev and saving the nfit_test as private driver data. Also changing the

[PATCH v6 08/11] nfit/libnvdimm: add support for issue secure erase DSM to Intel nvdimm

2018-07-25 Thread Dave Jiang
Add support to issue a secure erase DSM to the Intel nvdimm. The required passphrase is acquired from userspace through the kernel key management. To trigger the action, "erase" is written to the "security" sysfs attribute. libnvdimm will support the erase generic API call. Signed-off-by: Dave

[PATCH v6 06/11] nfit/libnvdimm: add disable passphrase support to Intel nvdimm.

2018-07-25 Thread Dave Jiang
Add support to disable passphrase (security) for the Intel nvdimm. The passphrase used for disabling is pulled from userspace via the kernel key management. The action is triggered by writing "disable" to the sysfs attribute "security". libnvdimm will support the generic disable API call.

[PATCH v6 00/11] Adding security support for nvdimm

2018-07-25 Thread Dave Jiang
The following series implements security support for nvdimm. Mostly adding new security DSM support from the Intel NVDIMM DSM spec v1.7, but also adding generic support libnvdimm for other vendors. The most important security features are unlocking locked nvdimms, and updating/setting security

[PATCH v6 04/11] nfit/libnvdimm: add unlock of nvdimm support for Intel DIMMs

2018-07-25 Thread Dave Jiang
Add support to allow query the security status of the Intel nvdimms and also unlock the dimm via the kernel key management APIs. The passphrase is expected to be pulled from userspace through keyutils. Moving the Intel related bits to its own source file as well. Signed-off-by: Dave Jiang

[PATCH v6 07/11] nfit/libnvdimm: add freeze security support to Intel nvdimm

2018-07-25 Thread Dave Jiang
Add support for freeze security on Intel nvdimm. This locks out any changes to security for the DIMM unless a reboot is done. This is triggered by writing "freeze" to the "security" sysfs attribute. libnvdimm will support the generic freeze_lock API call. Signed-off-by: Dave Jiang Reviewed-by:

[PATCH v6 01/11] nfit: add support for Intel DSM 1.7 commands

2018-07-25 Thread Dave Jiang
Add command definition for security commands defined in Intel DSM specification v1.7. This includes "get security state", "set passphrase", "unlock unit", "freeze lock", "secure erase", "ovewrite", and "overwrite query". Since we are adding a lot of Intel definitions, moving the relevant bits to

[PATCH v6 02/11] libnvdimm: create keyring to store security keys

2018-07-25 Thread Dave Jiang
Prepping the libnvdimm to support security management by adding a keyring in order to provide passphrase management through the kernel key management APIs. Signed-off-by: Dave Jiang Reviewed-by: Dan Williams --- drivers/nvdimm/core.c |7 ++- drivers/nvdimm/dimm_devs.c | 29

[PATCH v6 03/11] nfit/libnvdimm: store dimm id as a member to struct nvdimm

2018-07-25 Thread Dave Jiang
The generated dimm id is needed for the sysfs attribute as well as being used as the identifier/description for the security key. Since it's constant and should never change, store it as a member of struct nvdimm. Signed-off-by: Dave Jiang Reviewed-by: Dan Williams --- drivers/acpi/nfit/core.c

[PATCH v6 05/11] nfit/libnvdimm: add set passphrase support for Intel nvdimms

2018-07-25 Thread Dave Jiang
Add support for setting and/or updating passphrase on the Intel nvdimms. The passphrase is pulled from userspace through the kernel key management. We trigger the update via writing "update" to the sysfs attribute "security". The state of the security can also be read via the "security" attribute.

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

2018-07-25 Thread Ross Zwisler
On Thu, Jul 26, 2018 at 12:28:43AM +0800, Huaisheng Ye wrote: > From: Huaisheng Ye > > Changes since v1 [1]: > * Involve the previous patches for pfn can be NULL. > * Reword the patch descriptions according to Christian's comment. > * According to Ross's suggestion, replace local pointer

[PATCH v2 6/6] filesystem-dax: Do not request kaddr and pfn when not required

2018-07-25 Thread Huaisheng Ye
From: Huaisheng Ye Some functions within fs/dax don't need to get local pointer kaddr or variable pfn from direct_access. Using NULL instead of having to pass in useless pointer or variable that caller then just throw away. Signed-off-by: Huaisheng Ye --- fs/dax.c | 13 - 1 file

[PATCH v2 5/6] md/dm-writecache: Don't request pointer dummy_addr when not required

2018-07-25 Thread Huaisheng Ye
From: Huaisheng Ye Function persistent_memory_claim doesn't need to get local pointer dummy_addr from direct_access. Using NULL instead of having to pass in a useless local pointer that caller then just throw away. Suggested-by: Ross Zwisler Signed-off-by: Huaisheng Ye ---

[PATCH v2 4/6] dax/super: Do not request a pointer kaddr when not required

2018-07-25 Thread Huaisheng Ye
From: Huaisheng Ye Function __bdev_dax_supported doesn't need to get local pointer kaddr from direct_access. Using NULL instead of having to pass in a useless local pointer that caller then just throw away. Signed-off-by: Huaisheng Ye --- drivers/dax/super.c | 3 +-- 1 file changed, 1

[PATCH v2 3/6] tools/testing/nvdimm: kaddr and pfn can be NULL to ->direct_access()

2018-07-25 Thread Huaisheng Ye
From: Huaisheng Ye The mock / test version of pmem_direct_access() needs to check the validity of pointers kaddr and pfn for NULL assignment. If anyone equals to NULL, it doesn't need to calculate the value. If pointer equals to NULL, that is to say callers may have no need for kaddr or pfn, so

[PATCH v2 2/6] s390, dcssblk: kaddr and pfn can be NULL to ->direct_access()

2018-07-25 Thread Huaisheng Ye
From: Huaisheng Ye dcssblk_direct_access() needs to check the validity of pointers kaddr and pfn for NULL assignment. If anyone equals to NULL, it doesn't need to calculate the value. If either of them is equal to NULL, that is to say callers may have no need for kaddr or pfn, so this patch is

[PATCH v2 1/6] libnvdimm, pmem: kaddr and pfn can be NULL to ->direct_access()

2018-07-25 Thread Huaisheng Ye
From: Huaisheng Ye pmem_direct_access() needs to check the validity of pointers kaddr and pfn for NULL assignment. If anyone equals to NULL, it doesn't need to calculate the value. If pointer equals to NULL, that is to say callers may have no need for kaddr or pfn, so this patch is prepared for

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

2018-07-25 Thread Huaisheng Ye
From: Huaisheng Ye Changes since v1 [1]: * Involve the previous patches for pfn can be NULL. * Reword the patch descriptions according to Christian's comment. * According to Ross's suggestion, replace local pointer dummy_addr with NULL within md/dm-writecache for direct_access. [1]:

Re: [Qemu-devel] [RFC v3] qemu: Add virtio pmem device

2018-07-25 Thread Pankaj Gupta
> > >> > >> This patch has no n/M in the subject line; but is included in a thread > >> that also has a 0/2 cover letter, as well as 1/2 and 2/2 patches in > >> separate mails. Is that intentional? > > > > Yes, kernel series has 0-2 patches and Qemu has this one. I thought its > > good to

Re: [Qemu-devel] [RFC v3] qemu: Add virtio pmem device

2018-07-25 Thread Eric Blake
On 07/25/2018 12:01 AM, Pankaj Gupta wrote: This patch has no n/M in the subject line; but is included in a thread that also has a 0/2 cover letter, as well as 1/2 and 2/2 patches in separate mails. Is that intentional? Yes, kernel series has 0-2 patches and Qemu has this one. I thought its

Re: [PATCH v7 4/4] kexec_file: Load kernel at top of system RAM if required

2018-07-25 Thread Baoquan He
On 07/23/18 at 04:34pm, Michal Hocko wrote: > On Thu 19-07-18 23:17:53, Baoquan He wrote: > > Kexec has been a formal feature in our distro, and customers owning > > those kind of very large machine can make use of this feature to speed > > up the reboot process. On uefi machine, the kexec_file