netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* relationship between ingress policer and netfilter hooks?
@ 2009-06-02 15:30 Chris Friesen
  2009-06-02 17:04 ` Patrick McHardy
  0 siblings, 1 reply; 4+ messages in thread
From: Chris Friesen @ 2009-06-02 15:30 UTC (permalink / raw)
  To: netdev


Hi all,

Can someone tell me where the hook is for incoming packets to be sent
through the ingress policer?

In particular, I'm trying to find out how the ingress traffic shaping
hook relates to the various netfilter hooks so that I can set them up to
behave nicely together.

Thanks,

Chris

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: relationship between ingress policer and netfilter hooks?
  2009-06-02 15:30 relationship between ingress policer and netfilter hooks? Chris Friesen
@ 2009-06-02 17:04 ` Patrick McHardy
  2009-06-02 18:24   ` Chris Friesen
  0 siblings, 1 reply; 4+ messages in thread
From: Patrick McHardy @ 2009-06-02 17:04 UTC (permalink / raw)
  To: Chris Friesen; +Cc: netdev

Chris Friesen wrote:
> Hi all,
> 
> Can someone tell me where the hook is for incoming packets to be sent
> through the ingress policer?
> 
> In particular, I'm trying to find out how the ingress traffic shaping
> hook relates to the various netfilter hooks so that I can set them up to
> behave nicely together.

They're not related at all. The ingress qdisc is hooked at
net/dev/core.c:handle_ing().

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: relationship between ingress policer and netfilter hooks?
  2009-06-02 17:04 ` Patrick McHardy
@ 2009-06-02 18:24   ` Chris Friesen
  2009-06-03  7:18     ` Patrick McHardy
  0 siblings, 1 reply; 4+ messages in thread
From: Chris Friesen @ 2009-06-02 18:24 UTC (permalink / raw)
  To: Patrick McHardy; +Cc: netdev

Patrick McHardy wrote:
> Chris Friesen wrote:
> 
>>Hi all,
>>
>>Can someone tell me where the hook is for incoming packets to be sent
>>through the ingress policer?
>>
>>In particular, I'm trying to find out how the ingress traffic shaping
>>hook relates to the various netfilter hooks so that I can set them up to
>>behave nicely together.

> They're not related at all. The ingress qdisc is hooked at
> net/dev/core.c:handle_ing().

Thanks.  Based on that the shaping is done before any of the netfilter
hooks, which is what I was trying to figure out.

On a related note...the deliver_skb() call right before the call to
handle_ing()--is that to allow packet sockets to receive everything that
arrives on the wire even if some of it may be dropped later?

Chris

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: relationship between ingress policer and netfilter hooks?
  2009-06-02 18:24   ` Chris Friesen
@ 2009-06-03  7:18     ` Patrick McHardy
  0 siblings, 0 replies; 4+ messages in thread
From: Patrick McHardy @ 2009-06-03  7:18 UTC (permalink / raw)
  To: Chris Friesen; +Cc: netdev

Chris Friesen wrote:
> Patrick McHardy wrote:
>> Chris Friesen wrote:
>>
>>> Hi all,
>>>
>>> Can someone tell me where the hook is for incoming packets to be sent
>>> through the ingress policer?
>>>
>>> In particular, I'm trying to find out how the ingress traffic shaping
>>> hook relates to the various netfilter hooks so that I can set them up to
>>> behave nicely together.
> 
>> They're not related at all. The ingress qdisc is hooked at
>> net/dev/core.c:handle_ing().
> 
> Thanks.  Based on that the shaping is done before any of the netfilter
> hooks, which is what I was trying to figure out.

Correct.

> On a related note...the deliver_skb() call right before the call to
> handle_ing()--is that to allow packet sockets to receive everything that
> arrives on the wire even if some of it may be dropped later?

Yes, its the final delivery for ptype_all handlers.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-06-03  7:18 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-02 15:30 relationship between ingress policer and netfilter hooks? Chris Friesen
2009-06-02 17:04 ` Patrick McHardy
2009-06-02 18:24   ` Chris Friesen
2009-06-03  7:18     ` Patrick McHardy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).