From: Hanjun Guo <guohanjun@huawei.com>
To: Lukas Wunner <lukas@wunner.de>, "Moore, Robert" <robert.moore@intel.com>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>,
"linux-acpi@vger.kernel.org" <linux-acpi@vger.kernel.org>,
"devel@acpica.org" <devel@acpica.org>,
"platform-driver-x86@vger.kernel.org"
<platform-driver-x86@vger.kernel.org>,
Darren Hart <dvhart@infradead.org>,
Corentin Chary <corentin.chary@gmail.com>,
"Lee, Chun-Yi" <jlee@suse.com>,
"alsa-devel@alsa-project.org" <alsa-devel@alsa-project.org>,
Takashi Iwai <tiwai@suse.de>, Hui Wang <hui.wang@canonical.com>,
Mark Brown <broonie@kernel.org>, "Zheng, Lv" <lv.zheng@intel.com>,
David Box <david.e.box@linux.intel.com>
Subject: Re: [PATCH 1/5] ACPICA: Add acpi_dev_present
Date: Tue, 24 Nov 2015 12:40:51 +0800 [thread overview]
Message-ID: <5653EA53.8040909@huawei.com> (raw)
In-Reply-To: <20151123233234.GA26361@wunner.de>
On 2015/11/24 7:32, Lukas Wunner wrote:
> Hi Robert,
>
> On Mon, Nov 23, 2015 at 10:22:27PM +0000, Moore, Robert wrote:
>>>> acpi_dev_present
>> Do you really want to be walking the ACPICA namespace for every call?
> That's what the drivers currently do. Typically this is called only once
> on initialization by the driver's ->probe callback.
>
> What did you have in mind instead, cache the result? Or store the HIDs
> in the namespace in a hash that can be queried faster?
Will those drivers be loaded before the acpi namespace is scanned? if not, I think
those IDs already cached, in acpi_init_device_object(),
INIT_LIST_HEAD(&device->pnp.ids);
...
acpi_set_pnp_ids(handle, &device->pnp, type);
please see API acpi_device_hid(), so I think you can introduce a API with
acpi_device and HID passed as arguments in scan.c
Thanks
Hanjun
next prev parent reply other threads:[~2015-11-24 4:40 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-23 14:34 [PATCH 0/5] Add acpi_dev_present Lukas Wunner
2015-11-23 14:34 ` [PATCH 1/5] ACPICA: " Lukas Wunner
2015-11-23 22:34 ` Rafael J. Wysocki
2015-11-23 22:22 ` Moore, Robert
2015-11-23 23:32 ` Lukas Wunner
2015-11-24 4:40 ` Hanjun Guo [this message]
2015-11-24 14:15 ` Moore, Robert
2015-11-24 14:22 ` Rafael J. Wysocki
2015-11-24 14:54 ` Hanjun Guo
2015-11-23 14:34 ` [PATCH 4/5] ALSA: hda - Use acpi_dev_present Lukas Wunner
2015-11-24 1:51 ` [alsa-devel] " Hui Wang
2015-11-23 14:34 ` [PATCH 5/5] ASoC: Intel: " Lukas Wunner
2015-11-23 14:48 ` Mark Brown
2015-11-23 22:37 ` Rafael J. Wysocki
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=5653EA53.8040909@huawei.com \
--to=guohanjun@huawei.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=corentin.chary@gmail.com \
--cc=david.e.box@linux.intel.com \
--cc=devel@acpica.org \
--cc=dvhart@infradead.org \
--cc=hui.wang@canonical.com \
--cc=jlee@suse.com \
--cc=linux-acpi@vger.kernel.org \
--cc=lukas@wunner.de \
--cc=lv.zheng@intel.com \
--cc=platform-driver-x86@vger.kernel.org \
--cc=rjw@rjwysocki.net \
--cc=robert.moore@intel.com \
--cc=tiwai@suse.de \
/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;
as well as URLs for NNTP newsgroup(s).