From patchwork Thu May 18 13:17:59 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 9734341 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id BDEBD600CC for ; Thu, 18 May 2017 13:24:57 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AB57628692 for ; Thu, 18 May 2017 13:24:57 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A0324286B0; Thu, 18 May 2017 13:24:57 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5553028692 for ; Thu, 18 May 2017 13:24:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933887AbdERNYT (ORCPT ); Thu, 18 May 2017 09:24:19 -0400 Received: from bombadil.infradead.org ([65.50.211.133]:50813 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933853AbdERNSa (ORCPT ); Thu, 18 May 2017 09:18:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=References:In-Reply-To:Message-Id: Date:Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=oHeTDcwdR8ii5CYzy5ma+/pRMYp4EnYLdytqHVK2Y3c=; b=WeUpmoSQNBhoqSZb7cDZFrsmj c+wc+LumO21KEHRmgKE8nek2ZlGPmymb076FIJOr+4a/+wq6VuIFCrBtMu14SWFKG6enRZ/wUdUYb ic/uJS3rhxQdVe0jTMWAl1LoajIQNF52bStaH1JRuH/QS0vEh4jhGN+FMAuyZGf7yTrCDTK69E5/u br2SxUt56LVviW1k8o14+37Mp5wCnG170mUwdJvIyIDcWcqKI3OsoYZq8pVpSOAQX3qiBFdFBgM07 MXHKxX+wyHI6VCkrg3tJ4E/EwG/ou0NlgzUz5QEb3w6QO3vAuqz7OA2EIdXzkTN4jNmtKMe6CPqr9 B9rG6hzog==; Received: from clnet-p099-196.ikbnet.co.at ([83.175.99.196] helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.87 #1 (Red Hat Linux)) id 1dBLJv-0000ep-Nl; Thu, 18 May 2017 13:18:24 +0000 From: Christoph Hellwig To: axboe@kernel.dk Cc: linux-block@vger.kernel.org, dm-devel@redhat.com, linux-btrfs@vger.kernel.org Subject: [PATCH 02/15] scsi/osd: don't save block errors into req_results Date: Thu, 18 May 2017 15:17:59 +0200 Message-Id: <20170518131812.22956-3-hch@lst.de> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170518131812.22956-1-hch@lst.de> References: <20170518131812.22956-1-hch@lst.de> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP We will only have sense data if the command exectured and got a SCSI result, so this is pointless. Signed-off-by: Christoph Hellwig --- drivers/scsi/osd/osd_initiator.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/scsi/osd/osd_initiator.c b/drivers/scsi/osd/osd_initiator.c index 8a1b94816419..14785177ce7b 100644 --- a/drivers/scsi/osd/osd_initiator.c +++ b/drivers/scsi/osd/osd_initiator.c @@ -477,7 +477,7 @@ static void _set_error_resid(struct osd_request *or, struct request *req, int error) { or->async_error = error; - or->req_errors = scsi_req(req)->result ? : error; + or->req_errors = scsi_req(req)->result; or->sense_len = scsi_req(req)->sense_len; if (or->sense_len) memcpy(or->sense, scsi_req(req)->sense, or->sense_len);