All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ian Molton <ian.molton@collabora.co.uk>
To: Octavian Purdila <tavi.purdila@gmail.com>
Cc: Eric Dumazet <eric.dumazet@gmail.com>,
	netdev@vger.kernel.org, rdunlap@xenotime.net,
	isdn@linux-pingi.de, paulus@samba.org, arnd@arndb.de,
	davem@davemloft.net, herbert@gondor.apana.org.au,
	ebiederm@xmission.com, alban.crequy@collabora.co.uk,
	astanciu@ixiacom.com
Subject: Re: [PATCH] Add JMEMCMP to Berkeley Packet Filters
Date: Fri, 11 Feb 2011 02:02:11 +0000	[thread overview]
Message-ID: <4D5498A3.5070602@collabora.co.uk> (raw)
In-Reply-To: <AANLkTimOzvMx0FUaqxaa2QVV2FzsuhP8gQVX_CFmhiNR@mail.gmail.com>

On 10/02/11 15:27, Octavian Purdila wrote:
> On Thu, Feb 10, 2011 at 3:35 PM, Ian Molton<ian.molton@collabora.co.uk>  wrote:
>> On 10/02/11 13:24, Eric Dumazet wrote:
>>
>> Hi!
>>
>> Thanks for reviewing! :)
>>
>>>> * Can sk_run_filter() be called in a context where kmalloc(GFP_KERNEL) is
>>>>    not allowed (I think not)
>>>
>>> You cannot use GFP_KERNEL in sk_run_filter() : We run in {soft}irq mode,
>>> in input path.
>>
>> Ok, that can be sorted.
>>
>>>> * Data section allocated with second call to sock_kmalloc().
>>>> * Should the patch be broken into two - one to add the data uploading,
>>>>    one to add the JMEMCMP insn. ?
>>>
>>> May I ask why it is needed at all ?
>>
>> So we can match strings in packet filters... I don't think I understand the
>> question...
>>
>
> Adding a data section (some sort of persistent memory storage that the
> filter can access) is also useful for creating capture triggers, e.g.
> starting capturing after a marker packet has arrived.

Nice to see that people are thinking of more use-cases.

Eric, I think I understand what you meant now...

Our use case is experimental for now, so I wanted to see if other people 
would find this useful, as adding an experimental feature that is never 
used seems pointless.

In our case, we need to match strings in d-bus packets. if the packet is 
not intended for the recipient, it gets dropped, thus avoiding a 
pointless context switch.

-Ian

      reply	other threads:[~2011-02-11  2:02 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-10 12:31 [RFD][PATCH] Add JMEMCMP to Berkeley Packet Filters Ian Molton
2011-02-10 12:31 ` [PATCH] " Ian Molton
2011-02-10 13:24   ` Eric Dumazet
2011-02-10 13:35     ` Ian Molton
2011-02-10 15:27       ` Octavian Purdila
2011-02-11  2:02         ` Ian Molton [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4D5498A3.5070602@collabora.co.uk \
    --to=ian.molton@collabora.co.uk \
    --cc=alban.crequy@collabora.co.uk \
    --cc=arnd@arndb.de \
    --cc=astanciu@ixiacom.com \
    --cc=davem@davemloft.net \
    --cc=ebiederm@xmission.com \
    --cc=eric.dumazet@gmail.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=isdn@linux-pingi.de \
    --cc=netdev@vger.kernel.org \
    --cc=paulus@samba.org \
    --cc=rdunlap@xenotime.net \
    --cc=tavi.purdila@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.