Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751332AbdH1VnW (ORCPT ); Mon, 28 Aug 2017 17:43:22 -0400 Received: from esa5.hgst.iphmx.com ([216.71.153.144]:6457 "EHLO esa5.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751182AbdH1VnU (ORCPT ); Mon, 28 Aug 2017 17:43:20 -0400 X-IronPort-AV: E=Sophos;i="5.41,442,1498492800"; d="scan'208";a="45982131" From: Bart Van Assche To: "keescook@chromium.org" , "linux-kernel@vger.kernel.org" CC: "jejb@linux.vnet.ibm.com" , "linux-scsi@vger.kernel.org" , "linux-mm@kvack.org" , "kernel-hardening@lists.openwall.com" , "martin.petersen@oracle.com" , "dave@nullcore.net" Subject: Re: [PATCH v2 17/30] scsi: Define usercopy region in scsi_sense_cache slab cache Thread-Topic: [PATCH v2 17/30] scsi: Define usercopy region in scsi_sense_cache slab cache Thread-Index: AQHTIEXv7k0yim9o3EGhG//VBXu8n6KaTI6A Date: Mon, 28 Aug 2017 21:42:32 +0000 Message-ID: <1503956551.2841.70.camel@wdc.com> References: <1503956111-36652-1-git-send-email-keescook@chromium.org> <1503956111-36652-18-git-send-email-keescook@chromium.org> In-Reply-To: <1503956111-36652-18-git-send-email-keescook@chromium.org> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=Bart.VanAssche@wdc.com; x-originating-ip: [63.163.107.100] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;CY1PR0401MB1162;20:K6Qpi2WJvD3+CwGebORbEqlnqnwUBGBW6pxBqwmqJRZ7dcxW4g3uSUxHLlpSeqTcPXQhsQQwaEuWO51jN7BC2giLyYWFDmzxaxzLAWlrD5I+pg6ncSJufRqXt8pF/X7MHck4K0qqVqLdq1OxP0lz3eO3ZnvN0T+bVQyvWoQKotI= x-ms-exchange-antispam-srfa-diagnostics: SSOS; x-ms-office365-filtering-correlation-id: 174a9bcb-7f0a-4f12-f925-08d4ee5db086 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(2017030254152)(300000503095)(300135400095)(48565401081)(2017052603199)(201703131423075)(201703031133081)(201702281549075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095);SRVR:CY1PR0401MB1162; x-ms-traffictypediagnostic: CY1PR0401MB1162: wdcipoutbound: EOP-TRUE x-exchange-antispam-report-test: UriScan:; x-microsoft-antispam-prvs: x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(8121501046)(5005006)(3002001)(10201501046)(93006095)(93001095)(100000703101)(100105400095)(6055026)(6041248)(20161123560025)(20161123564025)(20161123555025)(20161123562025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123558100)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095);SRVR:CY1PR0401MB1162;BCL:0;PCL:0;RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095);SRVR:CY1PR0401MB1162; x-forefront-prvs: 0413C9F1ED x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(6009001)(39860400002)(24454002)(377424004)(189002)(199003)(68736007)(103116003)(2900100001)(3846002)(102836003)(6116002)(86362001)(36756003)(2950100002)(54356999)(76176999)(229853002)(33646002)(101416001)(50986999)(6512007)(53936002)(5660300001)(6246003)(6436002)(99286003)(54906002)(6506006)(105586002)(106356001)(77096006)(2501003)(7736002)(305945005)(6486002)(72206003)(8936002)(66066001)(8676002)(81166006)(2906002)(14454004)(81156014)(25786009)(4326008)(478600001)(189998001)(3280700002)(97736004)(3660700001);DIR:OUT;SFP:1102;SCL:1;SRVR:CY1PR0401MB1162;H:CY1PR0401MB1536.namprd04.prod.outlook.com;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="utf-8" Content-ID: <99A2AF1448B43B4DAD1BCE1FA28710ED@namprd04.prod.outlook.com> MIME-Version: 1.0 X-OriginatorOrg: wdc.com X-MS-Exchange-CrossTenant-originalarrivaltime: 28 Aug 2017 21:42:32.5993 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: b61c8803-16f3-4c35-9b17-6f65f441df86 X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY1PR0401MB1162 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by nfs id v7SLhR7x024819 Content-Length: 777 Lines: 22 On Mon, 2017-08-28 at 14:34 -0700, Kees Cook wrote: > diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c > index f6097b89d5d3..f1c6bd56dd5b 100644 > --- a/drivers/scsi/scsi_lib.c > +++ b/drivers/scsi/scsi_lib.c > @@ -77,14 +77,15 @@ int scsi_init_sense_cache(struct Scsi_Host *shost) > if (shost->unchecked_isa_dma) { > scsi_sense_isadma_cache = > kmem_cache_create("scsi_sense_cache(DMA)", > - SCSI_SENSE_BUFFERSIZE, 0, > - SLAB_HWCACHE_ALIGN | SLAB_CACHE_DMA, NULL); > + SCSI_SENSE_BUFFERSIZE, 0, > + SLAB_HWCACHE_ALIGN | SLAB_CACHE_DMA, NULL); > if (!scsi_sense_isadma_cache) > ret = -ENOMEM; All this part of this patch does is to change source code indentation. Should these changes really be included in this patch? Thanks, Bart.