Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754739AbbKWOOp (ORCPT ); Mon, 23 Nov 2015 09:14:45 -0500 Received: from smtp.codeaurora.org ([198.145.29.96]:55400 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754497AbbKWOOn (ORCPT ); Mon, 23 Nov 2015 09:14:43 -0500 Message-ID: <56531F4F.9010100@codeaurora.org> Date: Mon, 23 Nov 2015 09:14:39 -0500 From: Christopher Covington User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:36.0) Gecko/20100101 Thunderbird/36.0 MIME-Version: 1.0 To: Arnd Bergmann , Nicolas Pitre CC: Russell King - ARM Linux , Peter Maydell , =?UTF-8?B?TcOlbnMgUnVsbGfDpXJk?= , "linux-arm-msm@vger.kernel.org" , Stephen Boyd , lkml - Kernel Mailing List , Steven Rostedt , arm-mail-list Subject: Re: [RFC/PATCH 0/3] ARM: Use udiv/sdiv for __aeabi_{u}idiv library functions References: <1448068997-26631-1-git-send-email-sboyd@codeaurora.org> <4527012.vmieWOaE32@wuerfel> <8472808.1HUuK2O5nn@wuerfel> In-Reply-To: <8472808.1HUuK2O5nn@wuerfel> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2150 Lines: 69 On 11/23/2015 03:15 AM, Arnd Bergmann wrote: > On Sunday 22 November 2015 21:36:45 Nicolas Pitre wrote: >> On Sun, 22 Nov 2015, Arnd Bergmann wrote: >> >>> I've also found some /proc/cpuinfo output to cross-reference SoCs >>> to their core names. >>> >>> variant part revision name features >>> dove: 0 0x581 5 PJ4 idivt >> >> I just managed to boot my dusty Dove DB and ran a quick test programon >> it. Its cpuinfo corresponds to the above. >> >> $ cat m.c >> #include >> int mydiv(int, int); >> int main() >> { >> printf("div test\n"); >> printf("%d\n", mydiv(12345678, 37)); >> return 0; >> } >> $ cat d.c >> int mydiv(int x, int y) >> { >> return x/y; >> } >> $ gcc -o test m.c d.c >> $ ./test >> div test >> 333666 >> $ gcc -o test m.c d.c -march=armv7ve -mthumb >> $ ./test >> div test >> 333666 >> $ gcc -o test m.c d.c -march=armv7ve -marm >> $ ./test >> div test >> Illegal instruction (core dumped) >> $ > > Ok, thanks a lot! So the reporting in /proc/cpuinfo clearly matches > the actual features, and we can just treat this as no LPAE / no IDIV > for kernel compilation, as nobody ever seems to use THUMB2_KERNEL > in practice. > > PJ4-MP is like Cortex-A15/A7/A12/A17 and supports both IDIV and LPAE, > which leaves the question whether Scorpion or Krait do the same as > well, or whether they are outliers and need a special configuration. LPAE is only supported in the Krait 450. http://www.anandtech.com/show/7537/qualcomms-snapdragon-805-25ghz-128bit-memory-interface-d3d11class-graphics-more I'm pretty sure idiv support came earlier, but I don't have the specifics on hand. Regards, Christopher Covington -- Qualcomm Innovation Center, Inc. The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/