[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <48AFD48E.6050109@fr.ibm.com>
Date: Sat, 23 Aug 2008 11:12:46 +0200
From: Daniel Lezcano <dlezcano@...ibm.com>
To: Herbert Xu <herbert@...dor.apana.org.au>
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
Herbert Xu wrote:
> 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.
Obviously :)
Thanks Herbert.
--
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