mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Rafael J. Wysocki" <rjw@sisk.pl>
To: Yasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com>
Cc: Toshi Kani <toshi.kani@hp.com>,
	rafael.j.wysocki@intel.com, vasilis.liaskovitis@profitbricks.com,
	linux-kernel@vger.kernel.org, linux-acpi@vger.kernel.org,
	tangchen@cn.fujitsu.com, wency@cn.fujitsu.com
Subject: Re: Cannot hot remove a memory device (patch, updated)
Date: Tue, 06 Aug 2013 16:17:22 +0200	[thread overview]
Message-ID: <6353598.sj7IaxTFSj@vostro.rjw.lan> (raw)
In-Reply-To: <52005BA3.9020303@jp.fujitsu.com>

On Tuesday, August 06, 2013 11:12:51 AM Yasuaki Ishimatsu wrote:
> (2013/08/06 9:15), Rafael J. Wysocki wrote:
> > On Monday, August 05, 2013 05:19:56 PM Toshi Kani wrote:
> >> On Mon, 2013-08-05 at 15:14 +0200, Rafael J. Wysocki wrote:
> >>    :
> >>> Can you please test the appended patch?  I tested it somewhat, but since the
> >>> greatest number of physical nodes per ACPI device object I can get on my test
> >>> machines is 2 (and even that after hacking the kernel somewhat), that was kind
> >>> of unconclusive.
> >>>
> >>> Thanks,
> >>> Rafael
> >>>
> >>>
> >>> ---
> >>> From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> >>> Subject: ACPI: Drop physical_node_id_bitmap from struct acpi_device
> >>>
> >>> The physical_node_id_bitmap in struct acpi_device is only used for
> >>> looking up the first currently unused phyiscal dependent node ID
> >>> by acpi_bind_one().  It is not really necessary, however, because
> >>> acpi_bind_one() walks the entire physical_node_list of the given
> >>> device object for sanity checking anyway and if that list is always
> >>> sorted by node_id, it is straightforward to find the first gap
> >>> between the currently used node IDs and use that number as the ID
> >>> of the new list node.
> >>>
> >>> This also removes the artificial limit of the maximum number of
> >>> dependent physical devices per ACPI device object, which now depends
> >>> only on the capacity of unsigend int.
> >>>
> >>> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> >>
> >> I like the change. Much better :-)
> >>
> >> Acked-by: Toshi Kani <toshi.kani@hp.com>
> >
> > However, it introduces a bug in acpi_unbind_one(), because the size of the name
> > array in there has to be increased too.  Updated patch follows.
> >
> > Thanks,
> > Rafael
> >
> >
> > ---
> > From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> > Subject: ACPI: Drop physical_node_id_bitmap from struct acpi_device
> >
> > The physical_node_id_bitmap in struct acpi_device is only used for
> > looking up the first currently unused dependent phyiscal node ID
> > by acpi_bind_one().  It is not really necessary, however, because
> > acpi_bind_one() walks the entire physical_node_list of the given
> > device object for sanity checking anyway and if that list is always
> > sorted by node_id, it is straightforward to find the first gap
> > between the currently used node IDs and use that number as the ID
> > of the new list node.
> >
> > This also removes the artificial limit of the maximum number of
> > dependent physical devices per ACPI device object, which now depends
> > only on the capacity of unsigend int.
> >
> > Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> 
> Reviewed-by: Yasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com>
> Tested-by: Yasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com>
> 
> I confirmed that I can add and remove a memory device correctly.

Great, thanks for the confirmation!

Rafael


  reply	other threads:[~2013-08-06 14:07 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-01  8:37 Cannot hot remove a memory device Yasuaki Ishimatsu
2013-08-01 21:43 ` Rafael J. Wysocki
2013-08-02 21:46   ` Toshi Kani
2013-08-02 23:43     ` Rafael J. Wysocki
2013-08-03  0:04       ` Toshi Kani
2013-08-03  1:01         ` Rafael J. Wysocki
2013-08-04  0:37           ` Toshi Kani
2013-08-04 14:12             ` Rafael J. Wysocki
2013-08-05  4:00             ` Yasuaki Ishimatsu
2013-08-05  7:59               ` Yasuaki Ishimatsu
2013-08-05 13:14                 ` Cannot hot remove a memory device (patch) Rafael J. Wysocki
2013-08-05 23:19                   ` Toshi Kani
2013-08-06  0:15                     ` Cannot hot remove a memory device (patch, updated) Rafael J. Wysocki
2013-08-06  2:12                       ` Yasuaki Ishimatsu
2013-08-06 14:17                         ` Rafael J. Wysocki [this message]
2013-08-06 15:28                       ` Toshi Kani
2013-08-08 17:15         ` Cannot hot remove a memory device Toshi Kani
2013-08-08 22:12           ` Rafael J. Wysocki
2013-08-08 22:50             ` Toshi Kani
2013-08-08 23:14               ` Rafael J. Wysocki
2013-08-08 23:35                 ` Toshi Kani
2013-08-11 21:13               ` Rafael J. Wysocki
2013-08-12 20:40                 ` Toshi Kani
2013-08-13  0:45                   ` Rafael J. Wysocki
2013-08-13  1:02                     ` Toshi Kani
2013-08-13 12:02                       ` Rafael J. Wysocki
2013-08-13 17:14                         ` Toshi Kani

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6353598.sj7IaxTFSj@vostro.rjw.lan \
    --to=rjw@sisk.pl \
    --cc=isimatu.yasuaki@jp.fujitsu.com \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rafael.j.wysocki@intel.com \
    --cc=tangchen@cn.fujitsu.com \
    --cc=toshi.kani@hp.com \
    --cc=vasilis.liaskovitis@profitbricks.com \
    --cc=wency@cn.fujitsu.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®