Re: [PATCH 2/2] ib_srp: 64bit LUN fixes

Bart Van Assche
2014-07-04T12:31:21Z

On 07/04/14 13:54, Hannes Reinecke wrote:
> SRP is capable of handling 64bit LUNs, so as we now have proper
> support for it we can modify the driver to use the standard functions.
>
> Cc: Bart van Assche <bvanassche@acm.org>
> Signed-off-by: Hannes Reinecke <hare@suse.de>
> ---
> drivers/infiniband/ulp/srp/ib_srp.c | 9 ++--
> drivers/infiniband/ulp/srpt/ib_srpt.c | 81 +----------------------------------
> 2 files changed, 7 insertions(+), 83 deletions(-)

The SRP initiator and target drivers are independent drivers so this
should be two patches instead of one. Furthermore, I do not agree with
introducing a call to int_to_scsilun() in the hot path of the initiator
driver since that causes a small but unnecessary additional overhead.
Please keep in mind that there is no need to repeat the int_to_scsilun()
conversion for every I/O request. Hence my earlier proposal to cache the
int_to_scsilun() result.

Bart.