From patchwork Wed May 18 04:25:32 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Yan X-Patchwork-Id: 9116201 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 EE7BDBF29F for ; Wed, 18 May 2016 04:25:45 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 18A5420279 for ; Wed, 18 May 2016 04:25:45 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 3B0CB2022A for ; Wed, 18 May 2016 04:25:44 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751248AbcEREZl (ORCPT ); Wed, 18 May 2016 00:25:41 -0400 Received: from mail-pa0-f68.google.com ([209.85.220.68]:35886 "EHLO mail-pa0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751068AbcEREZl (ORCPT ); Wed, 18 May 2016 00:25:41 -0400 Received: by mail-pa0-f68.google.com with SMTP id xm6so3684981pab.3 for ; Tue, 17 May 2016 21:25:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:from:to:cc:subject:date; bh=QE+MJBVVMVAhF4ZY6npaTFC7dfn7V/Ms1W+Z0xnqCC8=; b=ktSP5/GZ1YcAyTBu6U7PwOIPC2qunzNr4i5UFglOxQraJz9zquS6p22qvsoyw3nBDV hwjnQ+mkxvDl+pvPldb8PphHyfphpyeAxncPvODKwgGaRaqnobePa8WmWG7Rwxnvc9E0 HAGA9SQzkrlTnWp9svrz0eCtvC7rLrsQb+lMel9VzG823rxf9j22hJgbw5pYSQOLrZsG za2TWH8olG77WAi9mcxzp7kOD7JXGk16tPRw/hlqupJ1wRS1bTIByo4lHGpQOkRnvKQB TjZCYEK5HhLTwgFy7bCPu3dxPKaK+t3GVWboyghX6dvIPBGsUZ71MGrnN18sEBpMFIx8 OtKg== 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; bh=QE+MJBVVMVAhF4ZY6npaTFC7dfn7V/Ms1W+Z0xnqCC8=; b=Lkbr6yLGp+iUu5AaJZ5VsiEp/TFCvIfTaPE6piQ0TEIh2XA3ryQpfdZZG6DlyxB97v l/lw6MYhJYHI86u0Bp8XqJ6xDC2gltwIlmy8zykGLJ2xV6L/qyta9aMftxXzvhvK1T0S 3w62rq9rsqG014DYvc/XRWYRrfRRgAFu4iTz6ERfPN3ZtzM4gL0fWsotYZTMNNLAEVO1 SlOBZflExEmJmOmC0ZAPL6LhJP+Lq8xZrszMRl498hGXx1kt/ABwZ3nhqWoeOAn3Y8FI waaDtOeSPIsa8Ekiu62tEWMKktY2n6gZc2NzEwWG7cmNHrGAVFTsLFLrRN9KOJT2gWDW 00Jg== X-Gm-Message-State: AOPr4FU/X0pZVCE6Q6A9wlezE5MHN7U39QgW84t8dbuONzfRaY/cs195wCvprDFgTqgd3Q== X-Received: by 10.66.222.39 with SMTP id qj7mr7566038pac.7.1463545540084; Tue, 17 May 2016 21:25:40 -0700 (PDT) Received: from localhost.localdomain ([2404:c805:e00:5500:ae22:bff:fe29:e60c]) by smtp.gmail.com with ESMTPSA id 19sm8204867pfu.83.2016.05.17.21.25.38 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 17 May 2016 21:25:39 -0700 (PDT) Message-ID: <573beec3.1314620a.54ed4.4ad4@mx.google.com> X-Google-Original-Message-ID: <1463545532-2363-1-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 1/1] scsi: bump SCSI_DEFAULT_MAX_SECTORS to SD_DEF_XFER_BLOCKS Date: Wed, 18 May 2016 12:25:32 +0800 X-Mailer: git-send-email 2.8.2 Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Spam-Status: No, score=-8.2 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 As of commit ca369d51b3e1649be4a72addd6d6a168cfb3f537, max_sectors (rw_max) of a scsi disk can be as high as SD_DEF_XFER_BLOCKS. Therefore, bump SCSI_DEFAULT_MAX_SECTORS to 65535 to make hosts that do not have max_sectors set in their templates benefit from the commit. Hosts that are not capable of handling SCSI_DEFAULT_MAX_SECTORS should have max_sectors set in their templates (like usb-storage does in scsiglue.c). Signed-off-by: Tom Yan diff --git a/include/scsi/scsi_host.h b/include/scsi/scsi_host.h index fcfa3d7..f3c43bd 100644 --- a/include/scsi/scsi_host.h +++ b/include/scsi/scsi_host.h @@ -383,7 +383,7 @@ struct scsi_host_template { * maximum, and may be over the transfer limits allowed for * individual devices (e.g. 256 for SCSI-1). */ -#define SCSI_DEFAULT_MAX_SECTORS 1024 +#define SCSI_DEFAULT_MAX_SECTORS 65535 /* * True if this host adapter can make good use of linked commands.