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] [day] [month] [year] [list]
Message-ID: <b04eb1f8-b36a-9fce-5ae5-d4c770c36139@gmail.com>
Date: Tue, 1 Aug 2023 11:47:58 +0800
From: Leon Hwang <hffilwlqm@...il.com>
To: Jakub Kicinski <kuba@...nel.org>
Cc: ast@...nel.org, daniel@...earbox.net, john.fastabend@...il.com,
 andrii@...nel.org, martin.lau@...ux.dev, song@...nel.org,
 yonghong.song@...ux.dev, kpsingh@...nel.org, sdf@...gle.com,
 haoluo@...gle.com, jolsa@...nel.org, davem@...emloft.net,
 edumazet@...gle.com, pabeni@...hat.com, hawk@...nel.org,
 rostedt@...dmis.org, mhiramat@...nel.org, mykolal@...com, shuah@...nel.org,
 tangyeechou@...il.com, kernel-patches-bot@...com, bpf@...r.kernel.org,
 linux-kernel@...r.kernel.org, netdev@...r.kernel.org,
 linux-trace-kernel@...r.kernel.org, linux-kselftest@...r.kernel.org
Subject: Re: [PATCH bpf-next v4 1/2] bpf, xdp: Add tracepoint to xdp attaching
 failure



On 1/8/23 10:43, Jakub Kicinski wrote:
> On Sun, 30 Jul 2023 19:49:50 +0800 Leon Hwang wrote:
>> @@ -9472,6 +9473,7 @@ int bpf_xdp_link_attach(const union bpf_attr *attr, struct bpf_prog *prog)
>>  	struct bpf_link_primer link_primer;
>>  	struct bpf_xdp_link *link;
>>  	struct net_device *dev;
>> +	struct netlink_ext_ack extack;
> 
> This is not initialized. Also, while fixing that, move it up 
> to maintain the line order by decreasing line length.
> 

Thank you for your reviewing.

I'll fix it by initializing extack and moving the line to its appropriate position.

Thanks,
Leon

>>  	int err, fd;
>>  
>>  	rtnl_lock();
>> @@ -9497,12 +9499,13 @@ int bpf_xdp_link_attach(const union bpf_attr *attr, struct bpf_prog *prog)
>>  		goto unlock;
>>  	}
>>  
>> -	err = dev_xdp_attach_link(dev, NULL, link);
>> +	err = dev_xdp_attach_link(dev, &extack, link);
>>  	rtnl_unlock();
>>  
>>  	if (err) {
>>  		link->dev = NULL;
>>  		bpf_link_cleanup(&link_primer);
>> +		trace_bpf_xdp_link_attach_failed(extack._msg);

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ