Re: [PATCH net-next] net: mana: Enable MANA driver on ARM64 with 4K page size

2024-05-13 Thread Jakub Kicinski
On Mon, 13 May 2024 20:50:37 + Haiyang Zhang wrote: > From the document, it can be: > "ARM cores support both modes, but are most commonly used in, and typically > default to little-endian mode. Most Linux distributions for ARM tend to be > little-endian only." >

Re: [PATCH net-next] net: mana: Enable MANA driver on ARM64 with 4K page size

2024-05-13 Thread Jakub Kicinski
On Mon, 13 May 2024 13:29:01 -0700 Haiyang Zhang wrote: > - depends on PCI_MSI && X86_64 > + depends on PCI_MSI > + depends on X86_64 || (ARM64 && !CPU_BIG_ENDIAN && ARM64_4K_PAGES) Can ARM64 be big endian?

Re: [PATCH net-next v2 1/2] net: Add sysfs atttributes for max_mtu min_mtu

2024-04-24 Thread Jakub Kicinski
On Wed, 24 Apr 2024 03:33:37 -0700 Shradha Gupta wrote: > Add sysfs attributes to read max_mtu and min_mtu value for > network devices Absolutely pointless. You posted v1, dumping this as a driver specific value, even tho it's already reported by the core... And you can't even produce a

Re: [PATCH net] net: mana: Fix Rx DMA datasize and skb_over_panic

2024-04-01 Thread Jakub Kicinski
On Tue, 2 Apr 2024 01:23:08 + Dexuan Cui wrote: > > > I suggest the Fixes tag should be updated. Otherwise the fix > > > looks good to me. > > > > Thanks for the suggestion. I actually thought about this before > > submission. > > I was worried about someone back ports the jumbo frame

Re: [PATCH] net :mana : Add per-cpu stats for MANA device

2024-03-14 Thread Jakub Kicinski
On Thu, 14 Mar 2024 18:54:31 + Haiyang Zhang wrote: > We understand irqbalance may be a "bad idea", and recommended some > customers to disable it when having problems with it... But it's > still enabled by default, and we cannot let all distro vendors > and custom image makers to disable

Re: [PATCH] net :mana : Add per-cpu stats for MANA device

2024-03-14 Thread Jakub Kicinski
On Wed, 13 Mar 2024 19:57:20 -0700 Shradha Gupta wrote: > Default interrupts affinity for each queue: > > 25: 1103 02989138 Hyper-V PCIe MSI > 4138200989697-edge mana_q0@pci:7870:00:00.0 > 26: 0 14005360 0 Hyper-V PCIe MSI >

Re: [PATCH] net :mana : Add per-cpu stats for MANA device

2024-03-11 Thread Jakub Kicinski
On Sun, 10 Mar 2024 21:19:50 -0700 Shradha Gupta wrote: > > Seems unlikely, but if it does work we should enable it for all > > devices, no driver by driver. > You mean, if the usecase seems valid we should try to extend the framework > mentioned by Rahul >

Re: [PATCH] net :mana : Add per-cpu stats for MANA device

2024-03-08 Thread Jakub Kicinski
On Fri, 8 Mar 2024 19:43:57 + Haiyang Zhang wrote: > > Seems unlikely, but if it does work we should enable it for all > > devices, no driver by driver. > There are some existing drivers, like mlx, rmnet, netvsc, etc. using percpu > counters. Are you suggesting we add a common API for all

Re: [PATCH] net :mana : Add per-cpu stats for MANA device

2024-03-08 Thread Jakub Kicinski
On Fri, 8 Mar 2024 18:51:58 + Haiyang Zhang wrote: > > Dynamic is a bit of an exaggeration, right? On a well-configured system > > each CPU should use a single queue assigned thru XPS. And for manual > > debug bpftrace should serve the purpose quite well. > > Some programs, like irqbalancer

Re: [PATCH v2] net :mana : Add per-cpu stats for MANA device

2024-03-08 Thread Jakub Kicinski
On Fri, 8 Mar 2024 02:44:31 -0800 Shradha Gupta wrote: > Extend 'ethtool -S' output for mana devices to include per-CPU packet > stats You haven't answered the questions on v1 and haven't addressed all the feedback. -- pw-bot: cr pv-bot: feedback

Re: [PATCH] net :mana : Add per-cpu stats for MANA device

2024-03-07 Thread Jakub Kicinski
On Thu, 7 Mar 2024 15:49:15 + Haiyang Zhang wrote: > > > Extend 'ethtool -S' output for mana devices to include per-CPU packet > > > stats > > > > But why? You already have per queue stats. > Yes. But the q to cpu binding is dynamic, we also want the per-CPU stat > to analyze the CPU

Re: [PATCH] net :mana : Add per-cpu stats for MANA device

2024-03-07 Thread Jakub Kicinski
On Thu, 7 Mar 2024 06:52:12 -0800 Shradha Gupta wrote: > Extend 'ethtool -S' output for mana devices to include per-CPU packet > stats But why? You already have per queue stats. > Built-on: Ubuntu22 > Tested-on: Ubuntu22 I understand when people mention testing driver changes on particular

Re: [PATCH] hv_netvsc:Register VF in netvsc_probe if NET_DEVICE_REGISTER missed

2024-01-31 Thread Jakub Kicinski
On Tue, 30 Jan 2024 22:09:57 -0800 Shradha Gupta wrote: > This patch applies to net, which is missed in the subject. I will fix > this in the new version of the patch. Thanks $ git checkout net/main [...] $ git am raw Applying: hv_netvsc:Register VF in netvsc_probe if NET_DEVICE_REGISTER missed

Re: [PATCH] hv_netvsc:Register VF in netvsc_probe if NET_DEVICE_REGISTER missed

2024-01-30 Thread Jakub Kicinski
On Mon, 29 Jan 2024 23:18:55 -0800 Shradha Gupta wrote: > If hv_netvsc driver is removed and reloaded, the NET_DEVICE_REGISTER > handler cannot perform VF register successfully as the register call > is received before netvsc_probe is finished. This is because we > register

Re: [PATCH 4/4 V2 net-next] net: mana: Assigning IRQ affinity on HT cores

2024-01-23 Thread Jakub Kicinski
On Mon, 22 Jan 2024 08:00:59 -0800 Souradeep Chakrabarti wrote: > IRQ node-numcore-num CPUperformance(%) > 1 0 | 0 0 | 0 0 | 0-1 0 > 2 0 | 0 0 | 1 1 | 2-3 3 > 3 0 | 0 1 | 2 2 | 4-5 10 > 4 0 | 0 1 | 3 3 | 6-7

Re: [EXTERNAL] Re: [PATCH V2 net-next] net: mana: Assigning IRQ affinity on HT cores

2023-11-29 Thread Jakub Kicinski
On Wed, 29 Nov 2023 14:17:39 -0800 Souradeep Chakrabarti wrote: > On Mon, Nov 27, 2023 at 10:06:39AM -0800, Jakub Kicinski wrote: > > On Mon, 27 Nov 2023 09:36:38 + Souradeep Chakrabarti wrote: > > > easier to keep things inside the mana driver code here > > >

Re: [EXTERNAL] Re: [PATCH V2 net-next] net: mana: Assigning IRQ affinity on HT cores

2023-11-27 Thread Jakub Kicinski
On Mon, 27 Nov 2023 09:36:38 + Souradeep Chakrabarti wrote: > easier to keep things inside the mana driver code here Easier for who? Upstream we care about consistency and maintainability across all drivers.

Re: [PATCH V2 net-next] net: mana: Assigning IRQ affinity on HT cores

2023-11-21 Thread Jakub Kicinski
On Tue, 21 Nov 2023 05:54:37 -0800 Souradeep Chakrabarti wrote: > Existing MANA design assigns IRQ to every CPUs, including sibling > hyper-threads > in a core. This causes multiple IRQs to work on same CPU and may reduce the > network > performance with RSS. > > Improve the performance by

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

2023-11-18 Thread Jakub Kicinski
On Wed, 15 Nov 2023 08:14:06 -0800 Stephen Hemminger wrote: > Jakub is right that in an ideal world, this could all be managed by > userspace. But the management of network devices in Linux is a > dumpster fire! Every distro invents there own solution, last time > I counted there were six

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

2023-11-10 Thread Jakub Kicinski
On Fri, 10 Nov 2023 00:43:55 + Long Li wrote: > The code above needs to work with and without netvsc (the possible > master device) present. I don't think that's a reasonable requirement for the kernel code. The auto-bonding already puts the kernel into business of guessing policy, which

Re: [PATCH net,v3, 2/2] hv_netvsc: Fix race of register_netdevice_notifier and VF register

2023-11-08 Thread Jakub Kicinski
On Tue, 7 Nov 2023 13:05:32 -0800 Haiyang Zhang wrote: > If VF NIC is registered earlier, NETDEV_REGISTER event is replayed, > but NETDEV_POST_INIT is not. But Long Li sent the patch which starts to use POST_INIT against the net-next tree. If we apply this to net and Long Li's patch to net-next

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

2023-11-08 Thread Jakub Kicinski
On Wed, 8 Nov 2023 14:56:52 -0800 lon...@linuxonhyperv.com wrote: > 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

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

2023-11-01 Thread Jakub Kicinski
On Thu, 26 Oct 2023 14:22:34 -0700 Haiyang Zhang wrote: > And, move register_netdevice_notifier() earlier, so the call back > function is set before probing. Are you sure you need this? I thought the netdev notifier "replays" registration events (i.e. sends "fake" events for already present

Re: [Patch v2] hv_netvsc: Mark VF as slave before exposing it to user-mode

2023-10-30 Thread Jakub Kicinski
On Fri, 27 Oct 2023 13:59:50 -0700 lon...@linuxonhyperv.com wrote: > 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.

Re: [PATCH net-next] Use xdp_set_features_flag instead of direct assignment

2023-10-27 Thread Jakub Kicinski
On Fri, 27 Oct 2023 11:06:51 -0700 Haiyang Zhang wrote: > From: Konstantin Taranov > > This patch uses a helper function for assignment of xdp_features. > This change simplifies backports. Generally making backports is not a strong enough reason to change upstream code, but using the helper

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

2023-10-26 Thread Jakub Kicinski
On Thu, 26 Oct 2023 11:23:37 +0200 Przemek Kitszel wrote: > this would now fit into one line > (perhaps it's the same in other cases, I just checked this one manually) I think cocci would fold lines automatically? Could be worth trying spatch to do the conversion for that reason, if you aren't