netdev
[Top] [All Lists]

Re: [PATCH] tun

To: Stephen Hemminger <shemminger@xxxxxxxx>
Subject: Re: [PATCH] tun
From: "David S. Miller" <davem@xxxxxxxxxx>
Date: Mon, 15 Mar 2004 12:47:51 -0800
Cc: maxk@xxxxxxxxxxxx, vtun@xxxxxxxxxxxxxxxxxxxxxxxx, netdev@xxxxxxxxxxx
In-reply-to: <20040315102810.2111a5d7@dell_ss3.pdx.osdl.net>
References: <20040315102810.2111a5d7@dell_ss3.pdx.osdl.net>
Sender: netdev-bounce@xxxxxxxxxxx
On Mon, 15 Mar 2004 10:28:10 -0800
Stephen Hemminger <shemminger@xxxxxxxx> wrote:

> Tun verifies the user address before doing memcpy_from/toiovec.  There are
> two problems with this strategy.  First, it is possible on an SMP machine
> to construct cases where a page is unmmapped between the verify and the copy,
> and it is also faster to do the verification only once.

Yes, those verify_area calls are superfluous and racy.

Applied, thanks Stephen.

<Prev in Thread] Current Thread [Next in Thread>
  • [PATCH] tun, Stephen Hemminger
    • Re: [PATCH] tun, David S. Miller <=