linux-mips
[Top] [All Lists]

Re: [PATCH 05/17] MIPS: bpf: Return error code if the offset is a negati

To: Alexei Starovoitov <ast@plumgrid.com>
Subject: Re: [PATCH 05/17] MIPS: bpf: Return error code if the offset is a negative number
From: Markos Chandras <Markos.Chandras@imgtec.com>
Date: Wed, 25 Jun 2014 09:12:53 +0100
Cc: Linux MIPS Mailing List <linux-mips@linux-mips.org>, "David S. Miller" <davem@davemloft.net>, Daniel Borkmann <dborkman@redhat.com>, "Network Development" <netdev@vger.kernel.org>
In-reply-to: <CAMEtUuyL8EV3UxS7yaD_ufiAywr7hkgPSC-3etMEYfbAZ_rRew@mail.gmail.com>
List-archive: <http://www.linux-mips.org/archives/linux-mips/>
List-help: <mailto:ecartis@linux-mips.org?Subject=help>
List-id: linux-mips <linux-mips.eddie.linux-mips.org>
List-owner: <mailto:ralf@linux-mips.org>
List-post: <mailto:linux-mips@linux-mips.org>
List-software: Ecartis version 1.0.0
List-subscribe: <mailto:ecartis@linux-mips.org?subject=subscribe%20linux-mips>
List-unsubscribe: <mailto:ecartis@linux-mips.org?subject=unsubscribe%20linux-mips>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <1403516340-22997-1-git-send-email-markos.chandras@imgtec.com> <1403516340-22997-6-git-send-email-markos.chandras@imgtec.com> <CAMEtUuyL8EV3UxS7yaD_ufiAywr7hkgPSC-3etMEYfbAZ_rRew@mail.gmail.com>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0
On 06/23/2014 11:09 PM, Alexei Starovoitov wrote:
> On Mon, Jun 23, 2014 at 2:38 AM, Markos Chandras
> <markos.chandras@imgtec.com> wrote:
>> Previously, the negative offset was not checked leading to failures
>> due to trying to load data beyond the skb struct boundaries. Until we
>> have proper asm helpers in place, it's best if we return ENOSUPP if K
>> is negative when trying to JIT the filter or 0 during runtime if we
>> do an indirect load where the value of X is unknown during build time.
>>
>> Cc: "David S. Miller" <davem@davemloft.net>
>> Cc: Daniel Borkmann <dborkman@redhat.com>
>> Cc: Alexei Starovoitov <ast@plumgrid.com>
>> Cc: netdev@vger.kernel.org
>> Signed-off-by: Markos Chandras <markos.chandras@imgtec.com>
> 
> Hi Markos,
> 
> thank you for addressing all of my earlier comments.
> Looks like test_bpf was quite useful in finding all of these bugs :)
> For the patches that reached netdev:
> 
> Acked-by: Alexei Starovoitov <ast@plumgrid.com>
> 

Thank you for the review and your constructive comments in your previous
emails.

-- 
markos

<Prev in Thread] Current Thread [Next in Thread>