<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/acpi/acpi_memhotplug.c, branch v3.8</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v3.8</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v3.8'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2013-01-03T12:10:21Z</updated>
<entry>
<title>ACPI / memhotplug: remove redundant logic of acpi memory hotadd</title>
<updated>2013-01-03T12:10:21Z</updated>
<author>
<name>Liu Jinsong</name>
<email>jinsong.liu@intel.com</email>
</author>
<published>2012-12-16T13:08:41Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=8611ea5f5d708d60ab29ed3cdb33e67168404fc0'/>
<id>urn:sha1:8611ea5f5d708d60ab29ed3cdb33e67168404fc0</id>
<content type='text'>
When memory hotadd, acpi_memory_enable_device has already been done
at drv-&gt;ops.add (acpi_memory_device_add), no need to do it again
at notify callback.

At acpi_memory_enable_device, acpi_memory_get_device_resources
is also a redundant action, since it has been done at drv-&gt;ops.add.

Signed-off-by: Liu Jinsong &lt;jinsong.liu@intel.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI: Update Memory hotplug error messages</title>
<updated>2012-11-21T22:20:22Z</updated>
<author>
<name>Toshi Kani</name>
<email>toshi.kani@hp.com</email>
</author>
<published>2012-11-20T23:42:28Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=ab6c57099db14d64c383e4d0392eab05d013630f'/>
<id>urn:sha1:ab6c57099db14d64c383e4d0392eab05d013630f</id>
<content type='text'>
Updated Memory hotplug error messages with acpi_handle_&lt;level&gt;(),
dev_&lt;level&gt;() and pr_&lt;level&gt;().  Added missing "\n".

Signed-off-by: Toshi Kani &lt;toshi.kani@hp.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI / memhotplug: bind the memory device when the driver is being loaded</title>
<updated>2012-11-16T01:12:38Z</updated>
<author>
<name>Wen Congyang</name>
<email>wency@cn.fujitsu.com</email>
</author>
<published>2012-11-16T01:12:38Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=61d8eff14417fb6d6c5d57e4f0f7925e9e99fce3'/>
<id>urn:sha1:61d8eff14417fb6d6c5d57e4f0f7925e9e99fce3</id>
<content type='text'>
We had introduced acpi_hotmem_initialized to avoid strange add_memory fail
message.  But the memory device may not be used by the kernel, and the
device should be bound when the driver is being loaded.  Remove
acpi_hotmem_initialized to allow that the device can be bound when the
driver is being loaded.

Signed-off-by: Wen Congyang &lt;wency@cn.fujitsu.com&gt;
Reviewed-by: Yasuaki Ishimatsu &lt;isimatu.yasuaki@jp.fujitsu.com&gt;
Acked-by: David Rientjes &lt;rientjes@google.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI / memhotplug: don't allow to eject the memory device if it is being used</title>
<updated>2012-11-16T01:10:37Z</updated>
<author>
<name>Wen Congyang</name>
<email>wency@cn.fujitsu.com</email>
</author>
<published>2012-11-16T01:10:37Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=65479472571fbf91502b7854be45ec0026b5229e'/>
<id>urn:sha1:65479472571fbf91502b7854be45ec0026b5229e</id>
<content type='text'>
We eject the memory device even if it is in use.  It is very dangerous,
and it will cause the kernel to be panicked.

Signed-off-by: Wen Congyang &lt;wency@cn.fujitsu.com&gt;
Reviewed-by: Yasuaki Ishimatsu &lt;isimatu.yasuaki@jp.fujitsu.com&gt;
Acked-by: David Rientjes &lt;rientjes@google.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI / memhotplug: free memory device if acpi_memory_enable_device() failed</title>
<updated>2012-11-16T01:08:16Z</updated>
<author>
<name>Wen Congyang</name>
<email>wency@cn.fujitsu.com</email>
</author>
<published>2012-11-16T01:08:16Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e0b7b24dd9559fcda0f8bfd6acbcad81682c4fdd'/>
<id>urn:sha1:e0b7b24dd9559fcda0f8bfd6acbcad81682c4fdd</id>
<content type='text'>
If acpi_memory_enable_device() fails, acpi_memory_enable_device() will
return a non-zero value, which means we fail to bind the memory device to
this driver.  So we should free memory device before
acpi_memory_device_add() returns.

Signed-off-by: Wen Congyang &lt;wency@cn.fujitsu.com&gt;
Reviewed-by: Yasuaki Ishimatsu &lt;isimatu.yasuaki@jp.fujitsu.com&gt;
Acked-by: David Rientjes &lt;rientjes@google.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI / memhotplug: fix memory leak when memory device is unbound from acpi_memhotplug</title>
<updated>2012-11-16T01:06:06Z</updated>
<author>
<name>Wen Congyang</name>
<email>wency@cn.fujitsu.com</email>
</author>
<published>2012-11-16T01:06:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=386e52b95550db87c93455e3c0efe3cc4543f036'/>
<id>urn:sha1:386e52b95550db87c93455e3c0efe3cc4543f036</id>
<content type='text'>
We allocate memory to store acpi_memory_info, so we should free it before
freeing mem_device.

Signed-off-by: Wen Congyang &lt;wency@cn.fujitsu.com&gt;
Reviewed-by: Yasuaki Ishimatsu &lt;isimatu.yasuaki@jp.fujitsu.com&gt;
Acked-by: David Rientjes &lt;rientjes@google.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI / memhotplug: deal with eject request in hotplug queue</title>
<updated>2012-11-16T01:04:05Z</updated>
<author>
<name>Wen Congyang</name>
<email>wency@cn.fujitsu.com</email>
</author>
<published>2012-11-16T01:04:05Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=315bbae9c5cb1f54a6d6fd47b9cf325fbedccf05'/>
<id>urn:sha1:315bbae9c5cb1f54a6d6fd47b9cf325fbedccf05</id>
<content type='text'>
The memory device can be removed by 2 ways:
 1. send eject request by SCI
 2. echo 1 &gt;/sys/bus/pci/devices/PNP0C80:XX/eject

We handle the 1st case in the module acpi_memhotplug, and handle
the 2nd case in ACPI eject notification. This 2 events may happen
at the same time, so we may touch acpi_memory_device.res_list at
the same time. This patch reimplements memory-hotremove support
through an ACPI eject notification. Now the memory device is
offlined and hotremoved only in the function acpi_memory_device_remove()
which is protected by device_lock().

Signed-off-by: Wen Congyang &lt;wency@cn.fujitsu.com&gt;
Reviewed-by: Yasuaki Ishimatsu &lt;isimatu.yasuaki@jp.fujitsu.com&gt;
Reviewed-by: Toshi Kani &lt;toshi.kani@hp.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI / memory-hotplug: add memory offline code to acpi_memory_device_remove()</title>
<updated>2012-11-16T00:56:01Z</updated>
<author>
<name>Yasuaki Ishimatsu</name>
<email>isimatu.yasuaki@jp.fujitsu.com</email>
</author>
<published>2012-11-15T06:59:31Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=19387b27e42d5e20a8188cfa15dc902114d98c43'/>
<id>urn:sha1:19387b27e42d5e20a8188cfa15dc902114d98c43</id>
<content type='text'>
The memory device can be removed by 2 ways:
 1. send eject request by SCI
 2. echo 1 &gt;/sys/bus/pci/devices/PNP0C80:XX/eject

In the 1st case, acpi_memory_disable_device() will be called.
In the 2nd case, acpi_memory_device_remove() will be called.
acpi_memory_device_remove() will also be called when we unbind the
memory device from the driver acpi_memhotplug or a driver initialization
fails.

acpi_memory_disable_device() has already implemented a code which
offlines memory and releases acpi_memory_info struct. But
acpi_memory_device_remove() has not implemented it yet.

So the patch move offlining memory and releasing acpi_memory_info struct
codes to a new function acpi_memory_remove_memory(). And it is used by both
acpi_memory_device_remove() and acpi_memory_disable_device().

Signed-off-by: Yasuaki Ishimatsu &lt;isimatu.yasuaki@jp.fujitsu.com&gt;
Signed-off-by: Wen Congyang &lt;wency@cn.fujitsu.com&gt;
Acked-by: David Rientjes &lt;rientjes@google.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI / memory-hotplug: call acpi_bus_trim() to remove memory device</title>
<updated>2012-11-14T23:22:27Z</updated>
<author>
<name>Wen Congyang</name>
<email>wency@cn.fujitsu.com</email>
</author>
<published>2012-11-14T23:22:27Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=54c4c7db6cb94d7d1217df6d7fca6847c61744ab'/>
<id>urn:sha1:54c4c7db6cb94d7d1217df6d7fca6847c61744ab</id>
<content type='text'>
The memory device has been ejected and powoffed, so we can call
acpi_bus_trim() to remove the memory device from acpi bus.

Signed-off-by: Wen Congyang &lt;wency@cn.fujitsu.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI: Add _OST support for ACPI memory hotplug</title>
<updated>2012-06-04T05:09:21Z</updated>
<author>
<name>Toshi Kani</name>
<email>toshi.kani@hp.com</email>
</author>
<published>2012-05-24T02:25:22Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=b1f00de66f8809b451a33ce47e461ef0e33c09e8'/>
<id>urn:sha1:b1f00de66f8809b451a33ce47e461ef0e33c09e8</id>
<content type='text'>
Changed acpi_memory_device_notify() to call ACPI _OST method
when ACPI memory hotplug operation has completed.

Signed-off-by: Toshi Kani &lt;toshi.kani@hp.com&gt;
Signed-off-by: Len Brown &lt;len.brown@intel.com&gt;
</content>
</entry>
</feed>
