netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tom Herbert <therbert@google.com>
To: Eric Dumazet <eric.dumazet@gmail.com>
Cc: Eric Paris <eparis@redhat.com>,
	netdev@vger.kernel.org, David Miller <davem@davemloft.net>
Subject: Re: BUG: using smp_processor_id() in preemptible [00000000] code: avahi-daemon: caller is netif_rx
Date: Mon, 12 Apr 2010 13:54:28 -0700	[thread overview]
Message-ID: <m2m65634d661004121354ta0189542l80473b82911e43f4@mail.gmail.com> (raw)
In-Reply-To: <1271101251.16881.135.camel@edumazet-laptop>

> I would change ip_dev_loopback_xmit() to call netif_rx_ni() instead...
>
> David, Tom ?
>

Would it be better to disable preemption in netif_rx?  Also note that
with RFS we would be taking rcu_read_lock in netif_rx anyway and that
could cover all the instances of smp_processor_id().

> diff --git a/net/ipv4/ip_output.c b/net/ipv4/ip_output.c
> index c65f18e..d1bcc9f 100644
> --- a/net/ipv4/ip_output.c
> +++ b/net/ipv4/ip_output.c
> @@ -120,7 +120,7 @@ static int ip_dev_loopback_xmit(struct sk_buff *newskb)
>        newskb->pkt_type = PACKET_LOOPBACK;
>        newskb->ip_summed = CHECKSUM_UNNECESSARY;
>        WARN_ON(!skb_dst(newskb));
> -       netif_rx(newskb);
> +       netif_rx_ni(newskb);
>        return 0;
>  }
>
>
>
>
>

  reply	other threads:[~2010-04-12 20:54 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-12 19:20 BUG: using smp_processor_id() in preemptible [00000000] code: avahi-daemon: caller is netif_rx Eric Paris
2010-04-12 19:40 ` Eric Dumazet
2010-04-12 20:54   ` Tom Herbert [this message]
2010-04-13  7:14     ` Eric Dumazet
2010-04-15  7:14       ` David Miller
2010-04-15  7:30         ` Changli Gao
2010-04-15  7:37           ` David Miller
2010-04-15  7:47             ` Changli Gao
2010-04-15  7:57               ` David Miller
2010-04-15  8:27                 ` Changli Gao
2010-04-15  8:33                   ` David Miller
2010-04-15  8:58                     ` Eric Dumazet
2010-04-15  8:49               ` Eric Dumazet
2010-04-15  9:02                 ` David Miller
2010-04-15 10:29                   ` Eric Dumazet
2010-04-15 13:16   ` Eric Dumazet
2010-04-15 19:07     ` Eric Dumazet
2010-04-15 19:13     ` [PATCH] ip: Fix ip_dev_loopback_xmit() Eric Dumazet
2010-04-15 21:26       ` David Miller
2010-04-16  0:03         ` Changli Gao
2010-04-16  0:15           ` David Miller
2010-04-16  0:19             ` Changli Gao

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=m2m65634d661004121354ta0189542l80473b82911e43f4@mail.gmail.com \
    --to=therbert@google.com \
    --cc=davem@davemloft.net \
    --cc=eparis@redhat.com \
    --cc=eric.dumazet@gmail.com \
    --cc=netdev@vger.kernel.org \
    /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 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).