From mboxrd@z Thu Jan 1 00:00:00 1970 From: Fan Du Subject: Re: [PATCH 1/1] tun: change speed from 10M to dynamically configured Date: Fri, 13 Feb 2015 11:25:48 +0800 Message-ID: <54DD6EBC.2030203@gmail.com> References: <1423719323-4667-1-git-send-email-Yanjun.Zhu@windriver.com> <1423719323-4667-2-git-send-email-Yanjun.Zhu@windriver.com> <20150212045558.5091262a@uryu.home.lan> <54DD655E.5020301@windriver.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: Stephen Hemminger , netdev@vger.kernel.org, mst@redhat.com, jasowang@redhat.com, viro@zeniv.linux.org.uk, davem@davemloft.net To: yzhu1 Return-path: Received: from mail-pa0-f45.google.com ([209.85.220.45]:52563 "EHLO mail-pa0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751273AbbBMDaX (ORCPT ); Thu, 12 Feb 2015 22:30:23 -0500 Received: by mail-pa0-f45.google.com with SMTP id rd3so9132664pab.4 for ; Thu, 12 Feb 2015 19:30:23 -0800 (PST) In-Reply-To: <54DD655E.5020301@windriver.com> Sender: netdev-owner@vger.kernel.org List-ID: =E4=BA=8E 2015=E5=B9=B402=E6=9C=8813=E6=97=A5 10:45, yzhu1 =E5=86=99=E9= =81=93: > On 02/12/2015 08:55 PM, Stephen Hemminger wrote: >> On Thu, 12 Feb 2015 13:35:23 +0800 >> Zhu Yanjun wrote: >> >>> From: Zhu Yanjun >>> >>> The default speed of normal nic is 1000M while the default speed >>> of tun is 10M. Now the default speed of tun is changed to 1000M. >>> And there are 3 options: 10M, 100M and 1000M to the speed of tun. >>> The command "ethtool -s tun0 speed 10/100/1000" can configure the >>> speed of tun dynamically. >>> >>> CC: Michael S. Tsirkin >>> CC: Jason Wang >>> CC: Al Viro >>> Signed-off-by: Zhu Yanjun >>> Signed-off-by: Zhu Yanjun >> Why limit to 10/100/1000 speed? >> Ethtool speed can be any value > Thanks for your comments. > > Yes. But the real physical nic speed often 10M, 100M and 1000M. > This simulates the physical nic. ^^^^^^^^^^^^^^^ then a speed control logical would be needed to effect the correspondin= g speed when tun/tap gets/puts packets corresponding to the speed setting. What's the benefit when changing speed from 10Mb/s to 1000Mb/s? Just xia bibi ;)