From mboxrd@z Thu Jan 1 00:00:00 1970 From: Cong Wang Subject: Re: [PATCH] veth: Optionally pad packets to minimum Ethernet length Date: Tue, 12 Dec 2017 13:11:35 -0800 Message-ID: References: <1513095191-127313-1-git-send-email-eswierk@skyportsystems.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Cc: Linux Kernel Network Developers , Benjamin Warren , Keith Holleman To: Ed Swierk Return-path: Received: from mail-pg0-f46.google.com ([74.125.83.46]:33716 "EHLO mail-pg0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752408AbdLLVL4 (ORCPT ); Tue, 12 Dec 2017 16:11:56 -0500 Received: by mail-pg0-f46.google.com with SMTP id g7so173643pgs.0 for ; Tue, 12 Dec 2017 13:11:56 -0800 (PST) In-Reply-To: <1513095191-127313-1-git-send-email-eswierk@skyportsystems.com> Sender: netdev-owner@vger.kernel.org List-ID: On Tue, Dec 12, 2017 at 8:13 AM, Ed Swierk wrote: > Most physical Ethernet devices pad short packets to the minimum length > of 64 bytes (including FCS) on transmit. It can be useful to simulate > this behavior when debugging a problem that results from it (such as > incorrect L4 checksum calculation). > > Padding is unnecessary for most applications so leave it off by > default. Enable padding only when the otherwise unused IFF_AUTOMEDIA > flag is set (e.g. by writing 0x5003 to flags in sysfs). This doesn't make sense, why should veth hot path be punished for such an unusual flag which it doesn't care? Also, why should we allow setting this flag via sysfs for veth from the beginning?