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-next>] [day] [month] [year] [list]
Date:	Mon, 15 Oct 2012 03:46:47 +0000
From:	"Yangfei (Felix)" <felix.yang@...wei.com>
To:	"linux-assembly@...r.kernel.org" <linux-assembly@...r.kernel.org>
CC:	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Hardcoded instruction causes certain features to fail on ARM
 platfrom due to endianness

Hi all,

    I found that hardcoded instruction in inline asm can cause certains certain features fail to work on ARM platform due to endianness.
    As an example, consider the following code snippet of platform_do_lowpower function from arch/arm/mach-realview/hotplug.c:
                / *
                 * here's the WFI
                 */
                asm(".word      0xe320f003\n"
                    :
                    :
                    : "memory", "cc");

    The instruction generated from this inline asm will not work on big-endian ARM platform, such as ARM BE-8 format. Instead, an exception will be generated.

    Here the code should be:
                / *
                 * here's the WFI
                 */
                asm("WFI\n"
                    :
                    :
                    : "memory", "cc");

    Seems the kernel doesn't support ARM BE-8 well. I don't know why this problem happens.
    Can anyone tell me who owns this part? I can prepare a patch then. 
    Thanks.
--
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