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]
Date: Sat, 21 Oct 2023 09:01:58 +0200
From: Jiri Pirko <jiri@...nulli.us>
To: Jakub Kicinski <kuba@...nel.org>
Cc: davem@...emloft.net, netdev@...r.kernel.org, edumazet@...gle.com,
	pabeni@...hat.com, johannes.berg@...el.com, mpe@...erman.id.au,
	j@...fi
Subject: Re: [PATCH net-next 2/6] net: make dev_alloc_name() call
 dev_prep_valid_name()

Fri, Oct 20, 2023 at 09:01:49PM CEST, kuba@...nel.org wrote:
>On Fri, 20 Oct 2023 12:24:57 +0200 Jiri Pirko wrote:
>> > static int dev_get_valid_name(struct net *net, struct net_device *dev,
>> > 			      const char *name)
>> > {
>> >-	return dev_prep_valid_name(net, dev, name, dev->name);
>> >+	int ret;
>> >+
>> >+	ret = dev_prep_valid_name(net, dev, name, dev->name, EEXIST);
>> >+	return ret < 0 ? ret : 0;  
>> 
>> Why can't you just return dev_prep_valid_name() ?
>> 
>> No caller seems to care about ret > 0
>
>AFACT dev_change_name() has some weird code that ends up return 
>the value all the way to the ioctl and user space. Note that it
>has both err and ret variables :S

Ah, blah. Guess we are stick to this crap :/

Reviewed-by: Jiri Pirko <jiri@...dia.com>


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ