lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <7e54d23c-caa6-4bbd-aef6-26ed6a9dd889@linux.alibaba.com>
Date: Fri, 29 Mar 2024 16:56:12 +0800
From: Heng Qi <hengqi@...ux.alibaba.com>
To: Jakub Kicinski <kuba@...nel.org>
Cc: netdev@...r.kernel.org, Eric Dumazet <edumazet@...gle.com>,
 Paolo Abeni <pabeni@...hat.com>, Vladimir Oltean <vladimir.oltean@....com>,
 "David S. Miller" <davem@...emloft.net>, Jason Wang <jasowang@...hat.com>,
 "Michael S. Tsirkin" <mst@...hat.com>, vadim.fedorenko@...ux.dev,
 Alexander Lobakin <aleksander.lobakin@...el.com>,
 Xuan Zhuo <xuanzhuo@...ux.alibaba.com>
Subject: Re: [PATCH net-next v2 2/2] virtio-net: support dim profile
 fine-tuning



在 2024/3/29 上午12:48, Jakub Kicinski 写道:
> On Thu, 28 Mar 2024 10:12:10 +0800 Xuan Zhuo wrote:
>> For netdim, I think profiles are an aspect. In many cases, this can solve many
>> problems.
> Okay, but then you should try harder to hide all the config in the core.
> The driver should be blissfully unaware that the user is changing
> the settings. It should just continue calling net_dim_get_*moderation().
>
> You can create proper dim_init(), dim_destroy() functions for drivers
> to call, instead of doing
>
> 	INIT_WORK(&bla->dim.work, my_driver_do_dim_work);
>
> directly. In dim_init() you can hook the dim structure to net_device
> and then ethtool code can operation on it without driver involvement.

Ok. Will try this.

>
> About the uAPI - please make sure you add the new stuff to
> Documentation/netlink/specs/ethtool.yaml
> see: https://docs.kernel.org/next/userspace-api/netlink/specs.html
>
> And break up the attributes, please, no raw C structs of this nature:
>
> +	return nla_put(skb, attr_type, sizeof(struct dim_cq_moder) *
> +		       NET_DIM_PARAMS_NUM_PROFILES, profs);
>
> They are hard to extend.

Sorry, I don't seem to get your point, why does this make extending hard?

Are you referring to specifying ETHTOOL_A_COALESCE_RX_EQE_PROFILE
as a nested array, i.e. having each element explicitly have an attr 
name? or passing the
u16 pointer and length as arguments?

Thanks.


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ