Re: [PATCH RFC v5 04/10] tun: Unify vnet implementation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Akihiko Odaki wrote:
> Both tun and tap exposes the same set of virtio-net-related features.
> Unify their implementations to ease future changes.
> 
> Signed-off-by: Akihiko Odaki <akihiko.odaki@xxxxxxxxxx>
> ---
>  MAINTAINERS            |   1 +
>  drivers/net/tap.c      | 172 ++++++----------------------------------
>  drivers/net/tun.c      | 208 ++++++++-----------------------------------------
>  drivers/net/tun_vnet.h | 181 ++++++++++++++++++++++++++++++++++++++++++

Same point: should not be in a header.

Also: I've looked into deduplicating code between the various tun, tap
and packet socket code as well.

In general it's a good idea. The main counter arguments is that such a
break in continuity also breaks backporting fixes to stable. So the
benefit must outweight that cost.

In this case, the benefits in terms of LoC are rather modest. Not sure
it's worth it.

Even more importantly: are the two code paths that you deduplicate
exactly identical? Often in the past the two subtly diverged over
time, e.g., due to new features added only to one of the two.

If so, call out any behavioral changes to either as a result of
deduplicating explicitly.




[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux