[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1040d742-35b3-443d-bcb4-5df0eeb42f93@ovn.org>
Date: Wed, 2 Jul 2025 10:10:33 +0200
From: Ilya Maximets <i.maximets@....org>
To: Jakub Kicinski <kuba@...nel.org>
Cc: i.maximets@....org, netdev@...r.kernel.org,
"David S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>,
Paolo Abeni <pabeni@...hat.com>, Simon Horman <horms@...nel.org>,
dev@...nvswitch.org, linux-kernel@...r.kernel.org,
Eelco Chaudron <echaudro@...hat.com>, Aaron Conole <aconole@...hat.com>
Subject: Re: [PATCH net-next] net: openvswitch: allow providing upcall pid for
the 'execute' command
On 7/2/25 4:21 AM, Jakub Kicinski wrote:
> On Sat, 28 Jun 2025 00:01:33 +0200 Ilya Maximets wrote:
>> @@ -616,6 +618,7 @@ static int ovs_packet_cmd_execute(struct sk_buff *skb, struct genl_info *info)
>> struct sw_flow_actions *sf_acts;
>> struct datapath *dp;
>> struct vport *input_vport;
>> + u32 upcall_pid = 0;
>> u16 mru = 0;
>> u64 hash;
>> int len;
>> @@ -651,6 +654,10 @@ static int ovs_packet_cmd_execute(struct sk_buff *skb, struct genl_info *info)
>> !!(hash & OVS_PACKET_HASH_L4_BIT));
>> }
>>
>> + if (a[OVS_PACKET_ATTR_UPCALL_PID])
>> + upcall_pid = nla_get_u32(a[OVS_PACKET_ATTR_UPCALL_PID]);
>> + OVS_CB(packet)->upcall_pid = upcall_pid;
>
> sorry for a late nit:
>
> OVS_CB(packet)->upcall_pid =
> nla_get_u32_default(a[OVS_PACKET_ATTR_UPCALL_PID], 0);
>
> ?
No worries. I was actually looking for ways to collapse this
block, but somehow missed these "new" accessors. I'll send a
v2 a bit later today in case there will be no further feedback.
Best regards, Ilya Maximets.
Powered by blists - more mailing lists