Re: [PATCH 2/3] treewide: Convert some ethtool_sprintf() to ethtool_puts()

2023-10-25 Thread Joe Perches
On Wed, 2023-10-25 at 23:40 +, Justin Stitt wrote: > This patch converts some basic cases of ethtool_sprintf() to > ethtool_puts(). > > The conversions are used in cases where ethtool_sprintf() was being used > with just two arguments: > > ethtool_sprintf(, buffer[i].name); OK. > or

Re: [PATCH 2/3] treewide: Convert some ethtool_sprintf() to ethtool_puts()

2023-10-25 Thread Justin Stitt
On Wed, Oct 25, 2023 at 4:51 PM Joe Perches wrote: > > On Wed, 2023-10-25 at 23:40 +, Justin Stitt wrote: > > This patch converts some basic cases of ethtool_sprintf() to > > ethtool_puts(). > > > > The conversions are used in cases where ethtool_sprintf() was being used > > with just two

Re: [PATCH 3/3] checkpatch: add ethtool_sprintf rules

2023-10-25 Thread Joe Perches
On Wed, 2023-10-25 at 23:40 +, Justin Stitt wrote: > Add some warnings for using ethtool_sprintf() where a simple > ethtool_puts() would suffice. > > The two cases are: > > 1) Use ethtool_sprintf() with just two arguments: > > ethtool_sprintf(, driver[i].name); OK. > or > 2) Use

[PATCH 3/3] checkpatch: add ethtool_sprintf rules

2023-10-25 Thread Justin Stitt
Add some warnings for using ethtool_sprintf() where a simple ethtool_puts() would suffice. The two cases are: 1) Use ethtool_sprintf() with just two arguments: | ethtool_sprintf(, driver[i].name); or 2) Use ethtool_sprintf() with a standalone "%s" fmt string: | ethtool_sprintf(,

[PATCH 2/3] treewide: Convert some ethtool_sprintf() to ethtool_puts()

2023-10-25 Thread Justin Stitt
This patch converts some basic cases of ethtool_sprintf() to ethtool_puts(). The conversions are used in cases where ethtool_sprintf() was being used with just two arguments: | ethtool_sprintf(, buffer[i].name); or when it's used with format string: "%s" | ethtool_sprintf(, "%s",

[PATCH 1/3] ethtool: Implement ethtool_puts()

2023-10-25 Thread Justin Stitt
Use strscpy() to implement ethtool_puts(). Functionally the same as ethtool_sprintf() when it's used with two arguments or with just "%s" format specifier. Signed-off-by: Justin Stitt --- include/linux/ethtool.h | 13 + net/ethtool/ioctl.c | 7 +++ 2 files changed, 20

[PATCH 0/3] ethtool: Add ethtool_puts()

2023-10-25 Thread Justin Stitt
ts/checkpatch.pl | 13 + 18 files changed, 120 insertions(+), 90 deletions(-) --- base-commit: d88520ad73b79e71e3ddf08de335b8520ae41c5c change-id: 20231025-ethtool_puts_impl-a1479ffbc7e0 Best regards, -- Justin Stitt

[PATCH] hv_netvsc: Mark VF as slave before exposing it to user-mode

2023-10-25 Thread longli
From: Long Li When a VF is being exposed form the kernel, it should be marked as "slave" before exposing to the user-mode. The VF is not usable without netvsc running as master. The user-mode should never see a VF without the "slave" flag. This commit moves the code of setting the slave flag to

[PATCH net] hv_netvsc: fix race of netvsc and VF register_netdevice

2023-10-25 Thread Haiyang Zhang
The rtnl lock also needs to be held before rndis_filter_device_add() which advertises nvsp_2_vsc_capability / sriov bit, and triggers VF NIC offering and registering. If VF NIC finished register_netdev() earlier it may cause name based config failure. To fix this issue, move the call to

RE: [EXTERNAL] Re: [Patch v7 5/5] RDMA/mana_ib: Send event to qp

2023-10-25 Thread Ajay Sharma
> -Original Message- > From: Jason Gunthorpe > Sent: Monday, October 23, 2023 11:24 AM > To: sharmaa...@linuxonhyperv.com > Cc: Long Li ; Leon Romanovsky ; > Dexuan Cui ; Wei Liu ; David S. > Miller ; Eric Dumazet ; > Jakub Kicinski ; Paolo Abeni ; linux- > r...@vger.kernel.org;