From patchwork Fri Feb 26 20:07:30 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Yan X-Patchwork-Id: 8441621 Return-Path: X-Original-To: patchwork-linux-scsi@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id F2587C0553 for ; Fri, 26 Feb 2016 20:07:43 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 3AA5A203AB for ; Fri, 26 Feb 2016 20:07:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 6939220270 for ; Fri, 26 Feb 2016 20:07:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753495AbcBZUHm (ORCPT ); Fri, 26 Feb 2016 15:07:42 -0500 Received: from mail-pf0-f196.google.com ([209.85.192.196]:35851 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750893AbcBZUHl (ORCPT ); Fri, 26 Feb 2016 15:07:41 -0500 Received: by mail-pf0-f196.google.com with SMTP id e127so5166403pfe.3 for ; Fri, 26 Feb 2016 12:07:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:from:to:cc:subject:date:in-reply-to:references; bh=eHQox1MG9b5CwgkU8vGwc4favfd8ps4llaZGa1EUkvc=; b=BkBleOFU+GoRlTap1pY621yo15LifukpWn5dq7uSrSbwvUF8nCsX0ggs+fQVadI0G8 BHJMB9HsnvVfASqFqvBVGzChPduyzMEFFzTOzbceEG9gtprrod6+L57vmErXh2R1wSYs jEcJhH/Uz4Z6v5b6z/lnEpd8N5XGIjUc4ZbzWPzDjV35v3H4VPpg+2YBAt3ke9JraGl4 wgjZ1uIIkJ2cnT4S8tqp7tAsgqO3rP+OW1oNbJ28x1RMYcWxXMyYPQEiKUbaq/a4J7Ay B1ppA7u2wmUZq8FMX4JEHdL94AsIAnGNH8RlGAxHV1G1g+ytxhqvaPjhERed4MAo72xp HFXg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:from:to:cc:subject:date:in-reply-to :references; bh=eHQox1MG9b5CwgkU8vGwc4favfd8ps4llaZGa1EUkvc=; b=YQPzrxyEpg/JfteK6pfoVnFKpouw91Gtlog50vmn+E9eWBI/OVaWNhSFVD+0FQjsk2 KajvFeOLCl6OLnGMNKVn3FEUGF4rm4Owlx6yVnobzeiakUUbNvDs9l8d8Q28nzucrxDU YgOK0DFJ8roCbv+7gWQsE+ZJG9J4SQmNmf1NGAt5w4ejDSp4PvPCBHYir5zDlfmE1JnV pFKMf586vvAlmm1ZdInfv9qj5DKh45UkciLny31XWPjg7tt5vdUm3w/jvYrCWxDYX7+2 l/YnDC9hAMB6ccn9Tne9R5eHsa9TfuKMwb3E53NA3FA9nhDqMlznDNSTLxsWsdDhAr2m zApA== X-Gm-Message-State: AD7BkJKq52RTxpn+5gia0Syl627lW1htepCnFOc817u3dULXN9cI8JT6J2XQy+QibTgbHg== X-Received: by 10.98.80.80 with SMTP id e77mr4739006pfb.126.1456517260741; Fri, 26 Feb 2016 12:07:40 -0800 (PST) Received: from localhost.localdomain (123202047244.ctinets.com. [123.202.47.244]) by smtp.gmail.com with ESMTPSA id wh9sm21243313pab.8.2016.02.26.12.07.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 26 Feb 2016 12:07:40 -0800 (PST) Message-ID: <56d0b08c.e99c420a.dbca1.0415@mx.google.com> X-Google-Original-Message-ID: <1456517250-2713-2-git-send-email-me> From: tom.ty89@gmail.com X-Google-Original-From: me To: linux-scsi@vger.kernel.org Cc: Tom Yan Subject: [PATCH 2/2] sd: disable write same for SAT as per the comment Date: Sat, 27 Feb 2016 04:07:30 +0800 X-Mailer: git-send-email 2.7.1 In-Reply-To: <1456517250-2713-1-git-send-email-me> References: <1456517250-2713-1-git-send-email-me> Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Tom Yan Signed-off-by: Tom Yan diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c index 1179ec1..9eeee51 100644 --- a/drivers/scsi/sd.c +++ b/drivers/scsi/sd.c @@ -2786,7 +2786,7 @@ static void sd_read_write_same(struct scsi_disk *sdkp, unsigned char *buffer) * CODES is unsupported and the device has an ATA * Information VPD page (SAT). */ - if (!scsi_get_vpd_page(sdev, 0x89, buffer, vpd_buf_len)) + if (scsi_get_vpd_page(sdev, 0x89, buffer, vpd_buf_len)) sdev->no_write_same = 1; }