lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Fri, 14 Sep 2012 08:49:03 -0600
From:	Toshi Kani <toshi.kani@...com>
To:	Yinghai Lu <yinghai@...nel.org>
Cc:	Len Brown <lenb@...nel.org>, linux-acpi@...r.kernel.org,
	linux-kernel@...r.kernel.org, Ashok Raj <ashok.raj@...el.com>
Subject: Re: [PATCH] ACPI: Enable SCI_EMULATE to manually simulate physical
 hotplug testing.

On Thu, 2012-09-13 at 20:50 -0700, Yinghai Lu wrote:
> On Thu, Sep 13, 2012 at 5:22 PM, Toshi Kani <toshi.kani@...com> wrote:
> >> > >> +
> >> > >> +     /*
> >> > >> +      * Check for internal object and make sure there is a handler
> >> > >> +      * registered for this object
> >> > >> +      */
> >> > >> +     obj_desc = acpi_ns_get_attached_object(node);
> >> > >> +     if (obj_desc) {
> >> > >> +             if (obj_desc->common_notify.notify_list[0]) {
> >> > >
> >> > > Is the above check necessary?  acpi_ev_queue_notify_request() sets up to
> >> > > call the global handler, acpi_gbl_global_notify[0], even if the object
> >> > > does not have a local handler registered.
> >> >
> >> > Not sure.
> >> >
> >> > maybe Len or other acpi guyes could answer your questions.
> >>
> >> I think this check should be removed, but would like someone to
> >> verify...
> >
> >
> > Hi Yinghai,
> >
> > Attached is my suggested update to your patch. It allows a SCI to be
> > sent to any object, and therefore can be used for testing the global
> > notify handler. Some drivers such as dock.c only register their handler
> > to the global notify handler. I also made a few minor changes. I have
> > been testing with this update and it is working fine. I like this
> > feature, so I hope we can make progress with this update.
> 
> len, can you check them?

Len and others can double check, but let me explain why this update is
necessary. acpi_ev_queue_notify_request() has the following internal
procedure and checks.

1. Call acpi_ev_is_notify_object() to make sure that notify is allowed
on the target object.

2. Get a proper list ID to notify_list[] for the notify value. Your
patch hardcodes this ID as 0, which is not correct.

3. Check if the target object has global handler or local handler
registered. Technically, your patch can copy this code to fix it.
However, I do not recommend copying such code since it is ACPICA
internal code and should not be exposed to drivers. ACPICA update can
break such code. Hence, I deleted the check from your patch.

4. If all checks passed, call acpi_ev_notify_dispatch() with the notify
request.

Feel free to add my sign-off when you update the patch. I take the
responsibility for the update.
Signed-off-by: Toshi Kani <toshi.kani@...com>

Thanks,
-Toshi

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ