Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1470930 > unrolled thread

Re: [PATCH 2/3] acpi, nfit: add dimm device notification support

Started by"Kani, Toshimitsu" <toshi.kani@hpe.com>
First post2016-08-26 20:30 +0200
Last post2016-08-30 00:20 +0200
Articles 3 — 2 participants

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH 2/3] acpi, nfit: add dimm device notification support "Kani, Toshimitsu" <toshi.kani@hpe.com> - 2016-08-26 20:30 +0200
    Re: [PATCH 2/3] acpi, nfit: add dimm device notification support Dan Williams <dan.j.williams@intel.com> - 2016-08-26 20:50 +0200
      Re: [PATCH 2/3] acpi, nfit: add dimm device notification support "Kani, Toshimitsu" <toshi.kani@hpe.com> - 2016-08-30 00:20 +0200

#1470930 — Re: [PATCH 2/3] acpi, nfit: add dimm device notification support

From"Kani, Toshimitsu" <toshi.kani@hpe.com>
Date2016-08-26 20:30 +0200
SubjectRe: [PATCH 2/3] acpi, nfit: add dimm device notification support
Message-ID<sau37-2a3-5@gated-at.bofh.it>
On Tue, 2016-08-23 at 14:54 -0700, Dan Williams wrote:
> Per "ACPI 6.1 Section 9.20.3" NVDIMM devices, children of the
> ACPI0012 NVDIMM Root device, can receive health event notifications.
> 
> Given that these devices are precluded from registering a
> notification handler via acpi_driver.acpi_device_ops (due to no
> _HID), we use acpi_install_notify_handler() directly.  

I've confirmed that this ACPI notify handler is called properly.

> The registered handler, acpi_nvdimm_notify(), triggers a poll(2)
> event on the nmemX/nfit/flags sysfs attribute when a health event
> notification is received.

This sounds good idea, but should we document that the value of sysfs
'flags' itself does not get updated?  User space program will then need
to call its _DSM to get health status.

Thanks,
-Toshi

[toc] | [next] | [standalone]


#1470945

FromDan Williams <dan.j.williams@intel.com>
Date2016-08-26 20:50 +0200
Message-ID<saumt-2ih-13@gated-at.bofh.it>
In reply to#1470930
On Fri, Aug 26, 2016 at 11:26 AM, Kani, Toshimitsu <toshi.kani@hpe.com> wrote:
> On Tue, 2016-08-23 at 14:54 -0700, Dan Williams wrote:
>> Per "ACPI 6.1 Section 9.20.3" NVDIMM devices, children of the
>> ACPI0012 NVDIMM Root device, can receive health event notifications.
>>
>> Given that these devices are precluded from registering a
>> notification handler via acpi_driver.acpi_device_ops (due to no
>> _HID), we use acpi_install_notify_handler() directly.
>
> I've confirmed that this ACPI notify handler is called properly.
>
>> The registered handler, acpi_nvdimm_notify(), triggers a poll(2)
>> event on the nmemX/nfit/flags sysfs attribute when a health event
>> notification is received.
>
> This sounds good idea, but should we document that the value of sysfs
> 'flags' itself does not get updated?  User space program will then need
> to call its _DSM to get health status.

Yes, this plus the new scrub attribute behavior need documentation.
I'll prepare a refresh for Documentation/nvdimm/nvdimm.txt.

The need to call a _DSM after a notification event is documented in
the ACPI spec, but you're right, we do need to connect that language
to the Linux specific mechanism.

[toc] | [prev] | [next] | [standalone]


#1472137

From"Kani, Toshimitsu" <toshi.kani@hpe.com>
Date2016-08-30 00:20 +0200
Message-ID<sbD4l-4Fy-1@gated-at.bofh.it>
In reply to#1470945
On Fri, 2016-08-26 at 11:39 -0700, Dan Williams wrote:
> On Fri, Aug 26, 2016 at 11:26 AM, Kani, Toshimitsu <toshi.kani@hpe.co
> m> wrote:
> > 
> > On Tue, 2016-08-23 at 14:54 -0700, Dan Williams wrote:
> > > 
> > > Per "ACPI 6.1 Section 9.20.3" NVDIMM devices, children of the
> > > ACPI0012 NVDIMM Root device, can receive health event
> > > notifications.
> > > 
> > > Given that these devices are precluded from registering a
> > > notification handler via acpi_driver.acpi_device_ops (due to no
> > > _HID), we use acpi_install_notify_handler() directly.
> > 
> > I've confirmed that this ACPI notify handler is called properly.
> > 
> > > 
> > > The registered handler, acpi_nvdimm_notify(), triggers a poll(2)
> > > event on the nmemX/nfit/flags sysfs attribute when a health event
> > > notification is received.
> > 
> > This sounds good idea, but should we document that the value of
> > sysfs 'flags' itself does not get updated?  User space program will
> > then need to call its _DSM to get health status.
> 
> Yes, this plus the new scrub attribute behavior need documentation.
> I'll prepare a refresh for Documentation/nvdimm/nvdimm.txt.
>
> The need to call a _DSM after a notification event is documented in
> the ACPI spec, but you're right, we do need to connect that language
> to the Linux specific mechanism.

Sounds great.  With that:

Reviewed-by: Toshi Kani <toshi.kani@hpe.com>

Thanks!
-Toshi

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web