From patchwork Fri Dec 9 14:22:03 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Tejun Heo X-Patchwork-Id: 704583 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 3tZvZ85GfWz9vG0 for ; Sat, 10 Dec 2016 01:22:08 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="PTNp2zZY"; dkim-atps=neutral Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752625AbcLIOWH (ORCPT ); Fri, 9 Dec 2016 09:22:07 -0500 Received: from mail-pg0-f65.google.com ([74.125.83.65]:34538 "EHLO mail-pg0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751783AbcLIOWG (ORCPT ); Fri, 9 Dec 2016 09:22:06 -0500 Received: by mail-pg0-f65.google.com with SMTP id e9so2477427pgc.1; Fri, 09 Dec 2016 06:22:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:mime-version :content-disposition:content-transfer-encoding:user-agent; bh=a0GE6JBaDWlKl2LvJINUzReB8EtioUh6E/0biV68k/0=; b=PTNp2zZY8h7FSdI2jeXFRc0adgE+w5YQJ/8jBY7jjNg+qR1p7te2h1mfpkW5LkhE2P v5KHtC9XyiT5PgVTxl6qgk8Nc9dhDTJE4juhJKPOhFCxKlHDTP9ZqcvfMukQRGxHTutW W0Fb1fw6kZre2RCu7vrmjFyjtdg9SxzbaJy35f5FMzjXoirIedICCUGbInf5x5vrhGuF FMIzlklmFYi8Nf5DScoJLRXn1w3B4z6ydhj2PEW1taptNN9a93xQq1XphaV7YXAbyDmy lrUdp8B1CL2c3A3Ht9/Qo4Yi42pPtgTjIZyAG0cxV+lRf7fQHnThWOSbvwtLCEC1d4gW Mo8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :mime-version:content-disposition:content-transfer-encoding :user-agent; bh=a0GE6JBaDWlKl2LvJINUzReB8EtioUh6E/0biV68k/0=; b=PxX3Vkkrka2EoHvDvuCigvV5/XieM6mOZLtgkCYxfjs4FP9IAWleKTrQ/KhHcp0q7T X+qVZqIjKM9ejcUVUGVPF48stlhqdLGksb5ZH9lh6nXtW36aGY58O3GV29H9J4+Sqhmj 1Q4fBNEsG2cCoCW9cDZ4Y+4h41gXRx07p4+vL/0WXT18F/0IQrmAVvbChpj6SJyMya63 EjlRp901f2MI43w8d+jTAGqsD2qmMJ84TQMm8UqxTG2j5Qr5BOadsDmHMqy4OjG9qYz/ adsP28mmx0L64cWVmDhS8QaLUIRsEwPpiz8Bxqi8+Kcl3ucWd6JR6Wls1WVucS/38N6Z yYog== X-Gm-Message-State: AKaTC01Hu9zTLks45LQbUudqHZ1uPnvD14yxcPsdGtzvnTjdfV2rG7Ql9tzGWIjZ/TBOIg== X-Received: by 10.99.143.90 with SMTP id r26mr144828345pgn.164.1481293325602; Fri, 09 Dec 2016 06:22:05 -0800 (PST) Received: from localhost ([2620:10d:c090:180::1:db95]) by smtp.gmail.com with ESMTPSA id n17sm58056973pfg.80.2016.12.09.06.22.04 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 09 Dec 2016 06:22:05 -0800 (PST) Date: Fri, 9 Dec 2016 09:22:03 -0500 From: Tejun Heo To: Linus Torvalds Cc: linux-kernel@vger.kernel.org, linux-ide@vger.kernel.org Subject: [GIT PULL] libata fixes for v4.9-rc8 Message-ID: <20161209142203.GA738@mtj.duckdns.org> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.7.1 (2016-10-04) Sender: linux-ide-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ide@vger.kernel.org Hello, Linus. This is quite late but SCT Write Same support added during this cycle is broken subtly but seriously and it'd be best to disable it before v4.9 gets released. This pull request contains two commits - one low impact sata_mv fix and the mentioned disabling of SCT Write Same. Thanks. The following changes since commit 6929ef385e09c0065b87fda3e7b872a5070ac783: ahci: always fall back to single-MSI mode (2016-11-21 11:06:57 -0500) are available in the git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata.git for-4.9-fixes for you to fetch changes up to e185934ff94466b4a449165e5f1c164a44d005f2: libata-scsi: disable SCT Write Same for the moment (2016-12-07 16:29:09 -0500) ---------------------------------------------------------------- Nicolai Stange (1): libata-scsi: disable SCT Write Same for the moment Uwe Kleine-König (1): ata: sata_mv: check for errors when parsing nr-ports from dt drivers/ata/libata-scsi.c | 1 + drivers/ata/sata_mv.c | 15 ++++++++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) --- To unsubscribe from this list: send the line "unsubscribe linux-ide" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/ata/libata-scsi.c b/drivers/ata/libata-scsi.c index c4eb4ae..8e575fb 100644 --- a/drivers/ata/libata-scsi.c +++ b/drivers/ata/libata-scsi.c @@ -1159,6 +1159,7 @@ static void ata_scsi_sdev_config(struct scsi_device *sdev) { sdev->use_10_for_rw = 1; sdev->use_10_for_ms = 1; + sdev->no_write_same = 1; /* Schedule policy is determined by ->qc_defer() callback and * it needs to see every deferred qc. Set dev_blocked to 1 to diff --git a/drivers/ata/sata_mv.c b/drivers/ata/sata_mv.c index efc48bf..823e938 100644 --- a/drivers/ata/sata_mv.c +++ b/drivers/ata/sata_mv.c @@ -4090,7 +4090,20 @@ static int mv_platform_probe(struct platform_device *pdev) /* allocate host */ if (pdev->dev.of_node) { - of_property_read_u32(pdev->dev.of_node, "nr-ports", &n_ports); + rc = of_property_read_u32(pdev->dev.of_node, "nr-ports", + &n_ports); + if (rc) { + dev_err(&pdev->dev, + "error parsing nr-ports property: %d\n", rc); + return rc; + } + + if (n_ports <= 0) { + dev_err(&pdev->dev, "nr-ports must be positive: %d\n", + n_ports); + return -EINVAL; + } + irq = irq_of_parse_and_map(pdev->dev.of_node, 0); } else { mv_platform_data = dev_get_platdata(&pdev->dev);