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:	Fri, 1 Aug 2014 05:35:52 -0700
From:	Christoph Hellwig <hch@...radead.org>
To:	Ching Huang <ching2048@...ca.com.tw>
Cc:	hch@...radead.org, jbottomley@...allels.com,
	dan.carpenter@...cle.com, thenzl@...hat.com, agordeev@...hat.com,
	linux-scsi@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v1.3 4/18] arcmsr: limit max. number of SCSI command
 request

> @@ -2220,8 +2220,7 @@ static int arcmsr_queue_command_lck(stru
>  		arcmsr_handle_virtual_command(acb, cmd);
>  		return 0;
>  	}
> -	if (atomic_read(&acb->ccboutstandingcount) >=
> -			ARCMSR_MAX_OUTSTANDING_CMD)
> +	if (atomic_read(&acb->ccboutstandingcount) >= acb->maxOutstanding)
>  		return SCSI_MLQUEUE_HOST_BUSY;

The scsi midlayer already takes care of this check for you.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ