From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751587AbdFAKlH (ORCPT ); Thu, 1 Jun 2017 06:41:07 -0400 Received: from szxga03-in.huawei.com ([45.249.212.189]:6934 "EHLO szxga03-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751346AbdFAKlF (ORCPT ); Thu, 1 Jun 2017 06:41:05 -0400 Subject: Re: [PATCH v3 14/23] scsi: hisi_sas: add v3 cq interrupt handler To: Christoph Hellwig References: <1496241195-217678-1-git-send-email-john.garry@huawei.com> <1496241195-217678-15-git-send-email-john.garry@huawei.com> <20170601054147.GB4743@infradead.org> CC: , , , , , , , Xiang Chen From: John Garry Message-ID: <04821e06-7541-1861-d52b-4df869570ca7@huawei.com> Date: Thu, 1 Jun 2017 11:36:55 +0100 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0 MIME-Version: 1.0 In-Reply-To: <20170601054147.GB4743@infradead.org> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.203.181.155] X-CFilter-Loop: Reflected X-Mirapoint-Virus-RAPID-Raw: score=unknown(0), refid=str=0001.0A020202.592FEE56.00E7,ss=1,re=0.000,recu=0.000,reip=0.000,cl=1,cld=1,fgs=0, ip=0.0.0.0, so=2014-11-16 11:51:01, dmn=2013-03-21 17:37:32 X-Mirapoint-Loop-Id: cf3dcd4f118727ba3d093abf5d9a5ecb Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 01/06/2017 06:41, Christoph Hellwig wrote: >> + case SAS_PROTOCOL_SSP: >> + { >> + unsigned char op = task->ssp_task.cmd->cmnd[0]; >> + >> + if (op == READ_6 || op == WRITE_6 || >> + op == READ_10 || op == WRITE_10 || >> + op == READ_12 || op == WRITE_12 || >> + op == READ_16 || op == WRITE_16) >> + return true; >> + break; >> + } > > Wee. why do you care? > In the command completion code we need to check for abnormal completion due to underflow, but ignore it when it occurs in some commands, like inquiry. This is why we check for rw command - it is equivalent to !inquiry. I'll see if we can change the check to explicitly ignore certain commands which complete abnormally with underflow. >What about 32-byte CDs or things like Write Same? > You're talking about VARIABLE_LENGTH_CMD (opcode 0x7f) for 32-byte CDs, right? I need to check on WRITE SAME. > . > Thanks, John