lkml.org 
[lkml]   [2022]   [Jan]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v3 3/3] scsi: Set allocation length to 255 for ATA Information VPD page
From
Date

Doug,

> sd_read_write_same() seems a strange name for a function given that
> it is checking on WRITE SAME support. How about s/read/report/ ?

It was chosen to be consistent with all the other sd_read_$VPD()
functions. sd_read_cache_type(), sd_read_block_limits(), etc.

> And calling scsi_report_opcode() on INQUIRY seems a weird time waster
> (it actually checks if the SCSI version is < SPC-3 or does the check
> on a _mandatory_ command).

The call to validate INQUIRY is really to check whether REPORT SUPPORTED
OPERATION CODES command is supported.

> And for modern disks scsi_report_opcode() is called 5 times. Why not
> call the REPORT SUPPORTED OPERATION CODES command once and cache its
> result? It would save 4 commands in every disk setup (or
> revalidation).

I have some patches that clean up discovery and start using cached
VPDs. I hadn't thought of caching the RSOC output. Will look into that.

I held this series back since I was concerned about them clashing with
Christoph's recent revalidate changes. I'll get them sent out shortly.

--
Martin K. Petersen Oracle Linux Engineering

\
 
 \ /
  Last update: 2022-01-03 22:38    [W:0.069 / U:0.776 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site