mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Bart Van Assche <bvanassche@acm.org>
To: WangYuli <wangyuli@uniontech.com>,
	James.Bottomley@HansenPartnership.com,
	martin.petersen@oracle.com
Cc: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org,
	stern@rowland.harvard.edu, zhanjun@uniontech.com,
	niecheng1@uniontech.com, guanwentao@uniontech.com,
	chenlinxuan@uniontech.com, Xinwei Zhou <zhouxinwei@uniontech.com>,
	Xu Rao <raoxu@uniontech.com>,
	Yujing Ming <mingyujing@uniontech.com>
Subject: Re: [RESEND PATCH v3] scsi: Bypass certain SCSI commands on disks with "use_192_bytes_for_3f" attribute
Date: Tue, 25 Feb 2025 12:54:01 -0800	[thread overview]
Message-ID: <3b6cca0d-7aa5-43b6-8f4a-429f17558121@acm.org> (raw)
In-Reply-To: <0A01BD2F489C764A+647ab6a7-35e5-4aa4-b8d1-c177be1724c6@uniontech.com>


On 2/25/25 5:11 AM, WangYuli wrote:
> Disks have the attribute use_192_bytes_for_3f, which means that disks
 > only accept MODE SENSE transfer lengths of 192 bytes>
> However, when lshw sends MODE SENSE command to disks,
> use_192_bytes_for_3f will not be considered, which will cause some
> disks with use_192_bytes_for_3f to be unusable
> 
> To solve this problem, it is necessary to determine whether the
> device has the use_192_bytes_for_3f attribute at the scsi level. If
> the device has use_192_bytes_for_3f, when lshw or other applications
 > send MODE SENSE command through ioctl, the command with the data
 > length field of 0xff needs to be filtered out to avoid device
 > abnormality.
Has it been considered to truncate the MODE SENSE buffer to 192 bytes
instead of rejecting the MODE SENSE command?

Thanks,

Bart.

  reply	other threads:[~2025-02-25 20:54 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-24  3:48 WangYuli
2025-02-24 18:11 ` Bart Van Assche
2025-02-25 13:11   ` WangYuli
2025-02-25 20:54     ` Bart Van Assche [this message]
2025-02-26  2:31       ` WangYuli
2025-03-18  6:11 WangYuli
2025-03-21  1:08 ` Martin K. Petersen
2025-03-26 16:51   ` WangYuli

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3b6cca0d-7aa5-43b6-8f4a-429f17558121@acm.org \
    --to=bvanassche@acm.org \
    --cc=James.Bottomley@HansenPartnership.com \
    --cc=chenlinxuan@uniontech.com \
    --cc=guanwentao@uniontech.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    --cc=mingyujing@uniontech.com \
    --cc=niecheng1@uniontech.com \
    --cc=raoxu@uniontech.com \
    --cc=stern@rowland.harvard.edu \
    --cc=wangyuli@uniontech.com \
    --cc=zhanjun@uniontech.com \
    --cc=zhouxinwei@uniontech.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®