From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Michael S. Tsirkin" Subject: Re: [PATCH net-next v2 4/4] virtio-net: initial debugfs support, export mergeable rx buffer size Date: Tue, 14 Jan 2014 23:53:01 +0200 Message-ID: <20140114215301.GA31555@redhat.com> References: <52CCF177.7020500@redhat.com> <20140108192109.GC18312@redhat.com> <20140112170939.GA17202@redhat.com> <20140113094018.GA22726@redhat.com> <1389627488.2025.134.camel@bwh-desktop.uk.level5networks.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: netdev@vger.kernel.org, lf-virt , Eric Dumazet , Ben Hutchings , "David S. Miller" To: Michael Dalton Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: virtualization-bounces@lists.linux-foundation.org Errors-To: virtualization-bounces@lists.linux-foundation.org List-Id: netdev.vger.kernel.org On Tue, Jan 14, 2014 at 01:45:42PM -0800, Michael Dalton wrote: > I'd like to confirm the preferred sysfs path structure for mergeable > receive buffers. Is 'mergeable_rx_buffer_size' the right attribute name > to use or is there a strong preference for a different name? > > I believe the current approach proposed for the next patchset is to use a > per-netdev attribute group which we will add to the receive > queue kobj (struct netdev_rx_queue). That leaves us with at > least two options: > (1) Name the attribute group something, e.g., 'virtio-net', in which > case all virtio-net attributes for eth0 queue N will be of > the form: > /sys/class/net/eth0/queues/rx-N/virtio-net/ > > (2) Do not name the attribute group (leave the name NULL), in which > case AFAICT virtio-net and device-independent attributes would be > mixed without any indication. For example, all virtio-net > attributes for netdev eth0 queue N would be of the form: > /sys/class/net/eth0/queues/rx-N/ > > FWIW, the bonding netdev has a similar sysfs issue and uses a per-netdev > attribute group (stored in the 'sysfs_groups' field of struct netdevice) > In the case of bonding, the attribute group is named, so > device-independent netdev attributes are found in > /sys/class/net/eth0/ while bonding attributes are placed > in /sys/class/net/eth0/bonding/. > > So it seems like there is some precedent for using an attribute group > name corresponding to the driver name. Does using an attribute group > name of 'virtio-net' sound good or would an empty or different attribute > group name be preferred? > > Best, > > Mike I'm guessing we should follow the bonding example. What do others think?