]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
ACPICA: Utilities: Cleanup style issue for bit clearing
authorLv Zheng <lv.zheng@intel.com>
Fri, 17 Nov 2017 23:40:23 +0000 (15:40 -0800)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 27 Nov 2017 00:20:30 +0000 (01:20 +0100)
ACPICA commit b49a0e1e26f3c61df7113f18f441c83739eb5514

It's reported in Linux community that change to utmath.c contains a style
problem:
 [.../utmath.c:137]: (style) Same expression on both sides of '^='.
 [.../utmath.c:174]: (style) Same expression on both sides of '^='.
This patch fixes this problem. ACPICA BZ 1422, reported by David Binderman,
fixed by Lv Zheng.

Link: https://github.com/acpica/acpica/commit/b49a0e1e
Link: https://bugs.acpica.org/show_bug.cgi?id=1422
Reported-by: David Binderman <dcb314@hotmail.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/acpica/utmath.c

index 5f9c680076c4f95943b28a0b4f34fecacfd6f99b..2055a858e5f5961cf42cdf1c2c6e8dd0fb4fc1a4 100644 (file)
@@ -134,7 +134,7 @@ acpi_status acpi_ut_short_shift_left(u64 operand, u32 count, u64 *out_result)
 
        if ((count & 63) >= 32) {
                operand_ovl.part.hi = operand_ovl.part.lo;
-               operand_ovl.part.lo ^= operand_ovl.part.lo;
+               operand_ovl.part.lo = 0;
                count = (count & 63) - 32;
        }
        ACPI_SHIFT_LEFT_64_BY_32(operand_ovl.part.hi,
@@ -171,7 +171,7 @@ acpi_status acpi_ut_short_shift_right(u64 operand, u32 count, u64 *out_result)
 
        if ((count & 63) >= 32) {
                operand_ovl.part.lo = operand_ovl.part.hi;
-               operand_ovl.part.hi ^= operand_ovl.part.hi;
+               operand_ovl.part.hi = 0;
                count = (count & 63) - 32;
        }
        ACPI_SHIFT_RIGHT_64_BY_32(operand_ovl.part.hi,