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] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 13 Jan 2016 18:39:20 +0200
From:	Sagi Grimberg <sagig@....mellanox.co.il>
To:	Bart Van Assche <bart.vanassche@...disk.com>,
	"Nicholas A. Bellinger" <nab@...erainc.com>,
	target-devel <target-devel@...r.kernel.org>
Cc:	linux-scsi <linux-scsi@...r.kernel.org>,
	lkml <linux-kernel@...r.kernel.org>,
	Sagi Grimberg <sagig@...lanox.com>,
	Christoph Hellwig <hch@....de>, Hannes Reinecke <hare@...e.de>,
	Andy Grover <agrover@...hat.com>,
	Vasu Dev <vasu.dev@...ux.intel.com>, Vu Pham <vu@...lanox.com>,
	Nicholas Bellinger <nab@...ux-iscsi.org>
Subject: Re: [PATCH-v2 2/4] ib_srpt: Convert acl lookup to modern
 get_initiator_node_acl usage


>
> The "goto try_again" statement is executed at most once. Since the above loop
> can be unfolded with only a very minor code duplication I think it should
> be unfolded, e.g. as follows:
>
> 	se_acl = core_tpg_get_initiator_node_acl(&sport->port_tpg_1, ch->sess_name);
> 	if (!se_acl)
> 		se_acl = core_tpg_get_initiator_node_acl(&sport->port_tpg_1, ch->sess_name + strlen("0x"));
> 	if (!se_acl) {
> 		pr_info("Rejected login because no ACL has been"
> 			" configured yet for initiator %s.\n",
> 			ch->sess_name);
> 		[ ... ]
> 	}
>

I tend to agree, and it would be a bit cleaner to hide this behind
srpt_get_initiator_node_acl wrapper.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ