[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20080823004849.GA9678@gondor.apana.org.au>
Date: Sat, 23 Aug 2008 10:48:49 +1000
From: Herbert Xu <herbert@...dor.apana.org.au>
To: Daniel Lezcano <dlezcano@...ibm.com>
Cc: "Denis V. Lunev" <den@...nvz.org>, davem@...emloft.net,
adobriyan@...il.com, netdev@...r.kernel.org
Subject: Re: [PATCH 1/1] icmp: icmp_sk() should not use smp_processor_id() in preemptible code
On Sat, Aug 23, 2008 at 01:15:05AM +0200, Daniel Lezcano wrote:
>
> thanks for the fix. For my personal knowledge, why can we just use in
> the icmp_sk function:
> {
> struct sock *isk = net->ipv4.icmp_sk[get_cpu()];
> put_cpu();
> return isk;
> }
>
> ?
Because then you can get rescheduled to another CPU while still
using someone else's ICMP socket.
Cheers,
--
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@...dor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists