Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1353477
| From | Toshi Kani <toshi.kani@hpe.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH v2-UPDATE2 3/4] resource: Add device-managed insert/remove_resource() |
| Date | 2016-03-09 00:20 +0100 |
| Message-ID | <raz4Z-7IS-1@gated-at.bofh.it> (permalink) |
| References | <ratsB-3P7-7@gated-at.bofh.it> <raw78-5OE-13@gated-at.bofh.it> <rax3c-6qY-23@gated-at.bofh.it> <rayiC-7ah-21@gated-at.bofh.it> <rayBY-7hS-19@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Tue, 2016-03-08 at 14:44 -0800, Dan Williams wrote: > On Tue, Mar 8, 2016 at 2:23 PM, Linus Torvalds > <torvalds@linux-foundation.org> wrote: > > On Tue, Mar 8, 2016 at 12:59 PM, Dan Williams <dan.j.williams@intel.com > > > wrote: > > > > > > Here's the usage patch from Toshi [1] (copied below). It is indeed a > > > resource injected by nfit / nvdimm bus implementation. We just > > > happen > > > to support nfit and libnvdimm as modules. > > > > > > The goal of these patches is to use the ACPI NFIT data to create a > > > "Persistent Memory" rather than "reserved" resource. This is for > > > platform-firmware implementations that use E820-Type2 rather than > > > E820-Type7 to describe pmem. > > > > So my worry is that there is likely exactly one or two of these kinds > > of sites. > > > > Why couldn't they just use insert_resource() and then remove it > > manually? > > You mean instead of introducing a devm_insert_resource() as a helpful > first-class-citizen api, just arrange for the resource to be inserted > locally? Sure. > > I assume Toshi was looking to keep the devm semantics like the rest of > the nfit driver, but we can do that locally with devm_add_action() and > skip the new general purpose api. Yes, I prefer the devm semantics. insert_resource() and remove_resource() are not exported interfaces. So, with devm_add_action(), we still need to introduce built-in exported wrappers for insert/remove_resource(), unless we change to export them directly. Since we need to export "something", I think it is better to export their devm interfaces. Thanks, -Toshi
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH v2-UPDATE2 3/4] resource: Add device-managed insert/remove_resource() Toshi Kani <toshi.kani@hpe.com> - 2016-03-08 18:20 +0100
Re: [PATCH v2-UPDATE2 3/4] resource: Add device-managed insert/remove_resource() Ingo Molnar <mingo@kernel.org> - 2016-03-08 18:40 +0100
Re: [PATCH v2-UPDATE2 3/4] resource: Add device-managed insert/remove_resource() Linus Torvalds <torvalds@linux-foundation.org> - 2016-03-08 21:10 +0100
Re: [PATCH v2-UPDATE2 3/4] resource: Add device-managed insert/remove_resource() Dan Williams <dan.j.williams@intel.com> - 2016-03-08 22:10 +0100
Re: [PATCH v2-UPDATE2 3/4] resource: Add device-managed insert/remove_resource() Linus Torvalds <torvalds@linux-foundation.org> - 2016-03-08 23:30 +0100
Re: [PATCH v2-UPDATE2 3/4] resource: Add device-managed insert/remove_resource() Dan Williams <dan.j.williams@intel.com> - 2016-03-08 23:50 +0100
Re: [PATCH v2-UPDATE2 3/4] resource: Add device-managed insert/remove_resource() Toshi Kani <toshi.kani@hpe.com> - 2016-03-09 00:20 +0100
Re: [PATCH v2-UPDATE2 3/4] resource: Add device-managed insert/remove_resource() Linus Torvalds <torvalds@linux-foundation.org> - 2016-03-09 00:40 +0100
Re: [PATCH v2-UPDATE2 3/4] resource: Add device-managed insert/remove_resource() Toshi Kani <toshi.kani@hpe.com> - 2016-03-09 01:10 +0100
csiph-web