Messages in this thread | | | Date | Tue, 21 Jan 2014 09:15:01 -0800 | Subject | Re: [GIT] Security subsystem changes for 3.14 | From | Linus Torvalds <> |
| |
Since I got a conflict on this one and had to look at the code:
On Mon, Jan 20, 2014 at 5:11 AM, James Morris <jmorris@namei.org> wrote: > > Peter Huewe (5): > tpm/tpm_ppi: Check return value of acpi_get_name
that commit looks wrong (and mainline had fixed it correctly in the meantime).
The problem with
+ if (ACPI_FAILURE(status)) + return status;
is that this is a callback for acpi_walk_namespace(), and returning a failure status means that the walk will be interrupted.
So you actually want to return AE_OK if the acpi_get_name() call fails, because that just skips the failing node. Returning failure will skip *all* the nodes.
In practice it probably doesn't matter (acpi_get_name() isn't supposed to fail), but I thought I'd point it out since I had to stare at the conflict.
Linus
| |