From mboxrd@z Thu Jan 1 00:00:00 1970 Received: with ECARTIS (v1.0.0; list linux-mips); Thu, 10 Apr 2014 09:46:17 +0200 (CEST) Received: from mailapp01.imgtec.com ([195.89.28.114]:48125 "EHLO mailapp01.imgtec.com" rhost-flags-OK-OK-OK-OK) by eddie.linux-mips.org with ESMTP id S6817913AbaDJHqPGsH5N (ORCPT ); Thu, 10 Apr 2014 09:46:15 +0200 Received: from KLMAIL01.kl.imgtec.org (unknown [192.168.5.35]) by Websense Email Security Gateway with ESMTPS id C997E81A61039; Thu, 10 Apr 2014 08:46:06 +0100 (IST) Received: from LEMAIL01.le.imgtec.org (192.168.152.62) by KLMAIL01.kl.imgtec.org (192.168.5.35) with Microsoft SMTP Server (TLS) id 14.3.181.6; Thu, 10 Apr 2014 08:46:08 +0100 Received: from [192.168.154.89] (192.168.154.89) by LEMAIL01.le.imgtec.org (192.168.152.62) with Microsoft SMTP Server (TLS) id 14.3.174.1; Thu, 10 Apr 2014 08:46:07 +0100 Message-ID: <53464C52.2060004@imgtec.com> Date: Thu, 10 Apr 2014 08:46:26 +0100 From: Markos Chandras User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 MIME-Version: 1.0 To: Jonas Gorski CC: MIPS Mailing List , "David S. Miller" , Subject: Re: [PATCH v2 13/14] MIPS: net: Add BPF JIT References: <1396957635-27071-14-git-send-email-markos.chandras@imgtec.com> <1397059208-27096-1-git-send-email-markos.chandras@imgtec.com> In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [192.168.154.89] Return-Path: X-Envelope-To: <"|/home/ecartis/ecartis -s linux-mips"> (uid 0) X-Orcpt: rfc822;linux-mips@linux-mips.org Original-Recipient: rfc822;linux-mips@linux-mips.org X-archive-position: 39758 X-ecartis-version: Ecartis v1.0.0 Sender: linux-mips-bounce@linux-mips.org Errors-to: linux-mips-bounce@linux-mips.org X-original-sender: Markos.Chandras@imgtec.com Precedence: bulk List-help: List-unsubscribe: List-software: Ecartis version 1.0.0 List-Id: linux-mips X-List-ID: linux-mips List-subscribe: List-owner: List-post: List-archive: X-list: linux-mips On 04/09/2014 11:28 PM, Jonas Gorski wrote: > >> +#ifdef CONFIG_CPU_LITTLE_ENDIAN >> + /* This needs little endian fixup */ >> + if (config_enabled(CPU_MIPSR1)) { > > Hm, looking at arch/mips/Kconfig, this will falsely identify CPU_BMIPS > as R2 as it does not select CPU_MIPSR1. > > How about "if (cpu_has_mips_r1)"? There are some targets that have > both R1 and R2 cores (e.g. bcm47xx), and even if we built the kernel > for R1, it does not prevent us from emitting R2 instructions because > we do this at runtime when we can check for it. Sounds about right. Let me have a look -- markos From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailapp01.imgtec.com ([195.89.28.114]:48125 "EHLO mailapp01.imgtec.com" rhost-flags-OK-OK-OK-OK) by eddie.linux-mips.org with ESMTP id S6817913AbaDJHqPGsH5N (ORCPT ); Thu, 10 Apr 2014 09:46:15 +0200 Message-ID: <53464C52.2060004@imgtec.com> Date: Thu, 10 Apr 2014 08:46:26 +0100 From: Markos Chandras MIME-Version: 1.0 Subject: Re: [PATCH v2 13/14] MIPS: net: Add BPF JIT References: <1396957635-27071-14-git-send-email-markos.chandras@imgtec.com> <1397059208-27096-1-git-send-email-markos.chandras@imgtec.com> In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit Return-Path: Sender: linux-mips-bounce@linux-mips.org Errors-to: linux-mips-bounce@linux-mips.org List-help: List-unsubscribe: List-software: Ecartis version 1.0.0 List-subscribe: List-owner: List-post: List-archive: To: Jonas Gorski Cc: MIPS Mailing List , "David S. Miller" , netdev@vger.kernel.org Message-ID: <20140410074626.zo39eZQq35v7t0vflVYPDFketqewD4o0UtC3j83S-u8@z> On 04/09/2014 11:28 PM, Jonas Gorski wrote: > >> +#ifdef CONFIG_CPU_LITTLE_ENDIAN >> + /* This needs little endian fixup */ >> + if (config_enabled(CPU_MIPSR1)) { > > Hm, looking at arch/mips/Kconfig, this will falsely identify CPU_BMIPS > as R2 as it does not select CPU_MIPSR1. > > How about "if (cpu_has_mips_r1)"? There are some targets that have > both R1 and R2 cores (e.g. bcm47xx), and even if we built the kernel > for R1, it does not prevent us from emitting R2 instructions because > we do this at runtime when we can check for it. Sounds about right. Let me have a look -- markos