Message ID | 20170524003420.5381-15-bart.vanassche@sandisk.com (mailing list archive) |
---|---|
State | Changes Requested, archived |
Headers | show
Return-Path: <linux-scsi-owner@kernel.org> 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 978E2602A7 for <patchwork-linux-scsi@patchwork.kernel.org>; Wed, 24 May 2017 00:35:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8B66928867 for <patchwork-linux-scsi@patchwork.kernel.org>; Wed, 24 May 2017 00:35:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7F9E12886A; Wed, 24 May 2017 00:35:24 +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.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_HI autolearn=unavailable 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 20DF028867 for <patchwork-linux-scsi@patchwork.kernel.org>; Wed, 24 May 2017 00:35:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1765686AbdEXAfW (ORCPT <rfc822;patchwork-linux-scsi@patchwork.kernel.org>); Tue, 23 May 2017 20:35:22 -0400 Received: from esa1.hgst.iphmx.com ([68.232.141.245]:63671 "EHLO esa1.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1763373AbdEXAec (ORCPT <rfc822; linux-scsi@vger.kernel.org>); Tue, 23 May 2017 20:34:32 -0400 X-IronPort-AV: E=Sophos;i="5.38,383,1491235200"; d="scan'208";a="122517435" Received: from mail-bl2nam02lp0087.outbound.protection.outlook.com (HELO NAM02-BL2-obe.outbound.protection.outlook.com) ([207.46.163.87]) by ob1.hgst.iphmx.com with ESMTP; 24 May 2017 08:34:28 +0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sharedspace.onmicrosoft.com; s=selector1-sharedspace-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=dIwtLF7a1HT3+AcJ48Qomj41N7XL803NC41ZZAxsOJQ=; b=bb1FvL6EilRQcEKxRTNP5xXbBEVCJ8P0HAgh5gTaTDNxsnkgWcEWI4UJv9waRXFE0hFDGn6AEjRLrZ0ABqRkyhKalS7CCPFcLAy+NWP+GFSjJsx8QfyoFF4RubuxcZGAuQF6NvaWNu26/ETWUUWOAgQbZvVYqgLoamZTrLuJ0ww= Received: from MWHPR04CA0037.namprd04.prod.outlook.com (10.172.163.23) by MWHPR04MB0369.namprd04.prod.outlook.com (10.173.48.10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1101.14; Wed, 24 May 2017 00:34:26 +0000 Received: from CO1NAM04FT053.eop-NAM04.prod.protection.outlook.com (2a01:111:f400:7e4d::204) by MWHPR04CA0037.outlook.office365.com (2603:10b6:300:ee::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1124.9 via Frontend Transport; Wed, 24 May 2017 00:34:27 +0000 Authentication-Results: spf=pass (sender IP is 63.163.107.225) smtp.mailfrom=sandisk.com; vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; dmarc=bestguesspass action=none header.from=sandisk.com; Received-SPF: Pass (protection.outlook.com: domain of sandisk.com designates 63.163.107.225 as permitted sender) receiver=protection.outlook.com; client-ip=63.163.107.225; helo=milsmgep14.sandisk.com; Received: from milsmgep14.sandisk.com (63.163.107.225) by CO1NAM04FT053.mail.protection.outlook.com (10.152.91.79) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.1075.5 via Frontend Transport; Wed, 24 May 2017 00:34:26 +0000 Received: from MILHUBIP03.sdcorp.global.sandisk.com (Unknown_Domain [10.201.67.162]) (using TLS with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by (Symantec Messaging Gateway) with SMTP id 75.55.19026.115D4295; Tue, 23 May 2017 17:34:25 -0700 (PDT) Received: from milsmgip12.sandisk.com (10.177.9.6) by MILHUBIP03.sdcorp.global.sandisk.com (10.177.9.96) with Microsoft SMTP Server id 14.3.319.2; Tue, 23 May 2017 17:34:23 -0700 X-AuditID: 0ac94371-41ba798000004a52-29-5924d51144a6 Received: from exp-402881.sdcorp.global.sandisk.com ( [10.177.9.6]) by (Symantec Messaging Gateway) with SMTP id 24.A3.18148.F05D4295; Tue, 23 May 2017 17:34:23 -0700 (PDT) From: Bart Van Assche <bart.vanassche@sandisk.com> To: "Martin K . Petersen" <martin.petersen@oracle.com>, James Bottomley <James.Bottomley@HansenPartnership.com> CC: <linux-scsi@vger.kernel.org>, <linux-block@vger.kernel.org>, "Bart Van Assche" <bart.vanassche@sandisk.com>, Jens Axboe <axboe@fb.com>, "Christoph Hellwig" <hch@lst.de>, Omar Sandoval <osandov@fb.com>, Hannes Reinecke <hare@suse.com> Subject: [PATCH 14/31] cdrom: Check private request size before attaching to a queue Date: Tue, 23 May 2017 17:34:03 -0700 Message-ID: <20170524003420.5381-15-bart.vanassche@sandisk.com> X-Mailer: git-send-email 2.12.2 In-Reply-To: <20170524003420.5381-1-bart.vanassche@sandisk.com> References: <20170524003420.5381-1-bart.vanassche@sandisk.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrILMWRmVeSWpSXmKPExsXCddJ5ka7QVZVIgxlSFv/3HGOzWPBmL5vF ytVHmSw29nNY7L2lbdF9fQebxfLj/5gsDt+7yuLA4TGx+R27x7RJp9g8dt9sYPP4+PQWi8f6 LVdZPD5vk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7WS87P3cQICaOoHYzXJ5ofYmTi4JRqYAwz tFnnv3+/6ec7dtm/FjKs/HV9odQP502XfL+syf/1g3X6zwm2j+7dD1yy586F/xkN5Sdrwvmc jDffDo0ymPl1ysfWy+/XqWY4WDqxxavv0t3Vmi9wv/COub7dTF7ONx/nij2btd5ww/PjeSpL ongl0j+z6Hz0eHky2GVeQFt5htBsReuC9JNKLMUZiYZazEXFiQBWKHcP0wEAAA== MIME-Version: 1.0 Content-Type: text/plain X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:63.163.107.225; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10019020)(6009001)(39410400002)(39400400002)(39850400002)(39450400003)(39840400002)(39860400002)(2980300002)(438002)(189002)(199003)(9170700003)(86362001)(4326008)(33646002)(50986999)(50226002)(478600001)(5660300001)(106466001)(2906002)(189998001)(72206003)(36756003)(1076002)(54906002)(50466002)(48376002)(2950100002)(356003)(8676002)(5003940100001)(81166006)(6666003)(76176999)(77096006)(8936002)(38730400002)(305945005)(47776003)(53936002); DIR:OUT; SFP:1102; SCL:1; SRVR:MWHPR04MB0369; H:milsmgep14.sandisk.com; FPR:; SPF:Pass; MLV:sfv; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; CO1NAM04FT053; 1:M9HSctw6La8sEf9gO3dWvIYy+wr+pHnOD3ETrMqSW+lywmI6f9ogbLjuXJPbXIne0ns7xVG5sSZ6CvLIp2k40iJ2TROjDZv+78Ulbv4BMyjakK8tjFSryzLSYiOwMZsZFJGvYMDfwRMTmRBX1wVZV51j7aXmZEmj6d9K3JghBdF0QmwhIfO/ATzofSSKOBKH0GwksCWEhGVI1eAw6sBfB1M7nlV+9sa6X5zbPYkOoPgy4zN50yYcjwKNNg6P2ipv9lBVpGflPmVuilimIaLFBJGVkWBBM+ZFBLL7oSwl2fIBOxfiegHQ+zrLyWHGRbqvOFThpEQ1X6lDeb7HHOdHKmSdeobuD0tqxp582HnttsuMJB/5VoTT7X+h0hiPqaphtpxz5/zja5sXDpDwPcjTsnUD4WoMsRwuAd1Xy76YALlZO+7cqf5QLV9OOoKYpWaO3delVDTw8zHZjh+xak6V1iGJLeUv4JgacBby9+yNHEe4B2p/NVP72LuNazzeQqxpnTULH+teURmRkYc1gnNpGww2IB2id4JnsCgz+9AHyCw= X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: MWHPR04MB0369: X-MS-Office365-Filtering-Correlation-Id: 451b4739-7ef5-4923-a9cb-08d4a23ca227 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(8251501002)(2017030254075)(201703131423075)(201703031133081); SRVR:MWHPR04MB0369; X-Microsoft-Exchange-Diagnostics: 1; MWHPR04MB0369; 3:lcXaHHllxAegRrdWAIDMJo4MMMmNuu9Q2Vw5U8kPWRBedID0nMQ7WyYM0L/gDOuIFimwnrgHj/wId3KNn44r85Mv+rMVazuiqDfWqWGwIkJoN1SBAgpmbPCfYe0JgY7pVfBkBpJAMzvlTCx/XARYiZjSFrbnWHLlnwshUDjupY9+jz362qrOeriS7JzWwzR5K0Esmnd0HuBTbJiutyr1AAGGC6ROImGOCVUcBqMs8AqjQJgsrHYYlFpaIy5vciOJEH5HmV0CbNNI0P9FZ4+t76u2+FiUQBnxGpI217mavAubOZz9vudZklReucd0taxVVYnZB9/+sEFYx75QfKCCTa1+d9bs6qPGg8QldcoIhiQqJjpsO4tx/jjFEB3t5lo9JJ7bwcOs6lceQqyEgS67tYgxalzAt/bjCimkusvrfRzeeUM56mwjmX/xSvJbL7VVuqI4dfgOo2ekgyl8HzERJJsx1x8DxTblTf+D5JkRAc9pZ8C3sQWTwP8ZzvywGP3k X-Microsoft-Exchange-Diagnostics: 1; MWHPR04MB0369; 25:12ZA3abcbbH2G2lWPQRvheGQ6vFcUNWh/xIobI2F5ryY+/Pp5VnntIKq/8F0lQakJglxEhgHwpBKLaNA7gfEarEnLnUCOKCvHpU8xL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G6Cml0OjwHwyHN7GOUy1yjP7O7LAvBJTLyQBaZesqOkD475jBGe/zG384KAmv2+yHk6Yyns8f0TQ+b+y4In6Nwbr4kxnsJ5gLQIdIqC+/RyBqpRYMfdTqW7FcEEoSuKaOyh4AhfPJVMHJZzFwC9gpMSaMCYcIT6Q24bI X-Microsoft-Antispam-PRVS: <MWHPR04MB03696EA6C1B0061A5A487C5581FE0@MWHPR04MB0369.namprd04.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:(9452136761055)(67672495146484)(42932892334569); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040450)(601004)(2401047)(13018025)(8121501046)(5005006)(13016025)(3002001)(10201501046)(93006095)(93004095)(6055026)(6041248)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123560025)(20161123562025)(20161123564025)(20161123555025)(20161123558100)(6072148); SRVR:MWHPR04MB0369; BCL:0; PCL:0; RULEID:; SRVR:MWHPR04MB0369; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; MWHPR04MB0369; 4:wd+/lzvl2UPOVKZWoiuMuJGCIHQDgJB0i7cZedqfye?= =?us-ascii?Q?ZzLjy1czpz7DF3o4NAWuURKNVIvBb2VNE6uvtJc/GH25KPO/aoO94UI1Z4VQ?= =?us-ascii?Q?GKopAZM2tnBjDnj5OHojWj01em/vxXN8OxPv2s2O8Xgwfn7QphxuHHRvAyKv?= =?us-ascii?Q?rAXaVwespAPBeZEzxLxBg2s7lpVCShEsEQu550PWvAVuCyBnSm9ZhHQ3J2vT?= =?us-ascii?Q?QlQLy2VKh3IlkW3c8SMGfTqfuyREqZj1u3I3/DWStRGIiAKnmcAeb7/y2Vui?= =?us-ascii?Q?HaYLoW7BUtRjsN0o3uRmAezwC4ahjtcan8IosRVOJY/due0azdUjdL9xezaP?= =?us-ascii?Q?KYSrat41EtRVlXIiCYr4yvZzl9+bMfMAKdAviRv04aRo2wayvtPp19Qey8qf?= =?us-ascii?Q?3+BbbAMTake3CA8cQqgj0yvEEgzc0I6gEgXU2Ww47QctzFHVSWv477JJ2M9J?= =?us-ascii?Q?5qwJrQESpJGwMjjkAQmeZtvhFpIflMMooPwKOtfQKUI0FR9VkXTFfdBQnvOp?= =?us-ascii?Q?b2W3jw/QqIRmj+at3UzHHeXgXQN7P4Jb6fqliPAaCLteY6ODuNiDfTj86MRx?= =?us-ascii?Q?aOxO2Fi2hDUSTVR2n76hoCWvMl52FTMR6P8cj4WuAcLFmpXfrywRAZTACtSW?= =?us-ascii?Q?PIybleD23MQCxaA25N3NOFCgBXaK/2X8PL77iv9dRdCablYj+iE1O6bPlbYI?= =?us-ascii?Q?NuHhUl/z4XyB9UVRhuFaghTHCLHIfzqLy0uA5sh6WbQexMAf9Dcdl6p5tmZ5?= =?us-ascii?Q?vARjRtVlKmoxhlMl9xmnIMj3xQaif1ndwMtDLUX2ndYBj1f9o5+IW2/tfQc2?= =?us-ascii?Q?aDtGZLvbZsHJFCuVr6+p2wwGGBLeJ0wfZgZaj8TSNexgKdbMZO3KtB0vFJdb?= =?us-ascii?Q?wDJd5G5bxDFG3OPA4GuU4i1Hk+G8ovDltDotw1G5G2M8y9uYXLhwCKbPqACU?= =?us-ascii?Q?SDpoXlOYJ1fuqdpFfm0Qc+OyKAFEPbE+IKbY6tKw=3D=3D?= X-Forefront-PRVS: 031763BCAF X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; MWHPR04MB0369; 23:4zwBXYe1+Qw2CYBFkwX+981CgyxgmTOPC6nkYnxPc?= =?us-ascii?Q?AhvO09jLLkWcc5NjXk9q12B30UQRU2t0F+FNHoco17lY14aLEpHFISd8iZcb?= =?us-ascii?Q?N0qc0/Lm+PhBsGeOc2mU40g14TurSP6LuCcLQL3zg4KavSQCYlaaLEcZe1jR?= =?us-ascii?Q?MG2Hh32UePxmEh2keHhw+3daCoMywDHKQi/xR+qWH7yEg6Wd+T4BS7RmOrOH?= =?us-ascii?Q?tgkjDx+uaPFip0LPUDMKEtsCO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Ua+PNDcq+SphJnCUvmwW6lPEIk6G/zzlmdzOmsHe7Blnto+SyH6zHHUxcbUuI+zSWlLshrQWzGJc4TgbQ/dbNWu62qTQaTsoNTPxRrzh3VTfW0LPqFbH4o4qrgKhcph5mqjk16Cv7iADe0pjzg/dg==; 20:N5+YYLGrMHKf10rrnBZ0bxqBjhsKLmvqH5G0JC1lnzYbFz9hKKVX9yQqlRvwrUCz6UzjsprNLsXkI0IggQSKZ8yI0/VnKbQW/GokHyFNBAVi/7K7S8Npeap1Dow2OxOq6u+sVcjp0HrxHCnEXVc4CikO9fo0lJu9rOmFRv0ruAc= X-OriginatorOrg: sandisk.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 May 2017 00:34:26.3328 (UTC) X-MS-Exchange-CrossTenant-Id: b61c8803-16f3-4c35-9b17-6f65f441df86 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=b61c8803-16f3-4c35-9b17-6f65f441df86; Ip=[63.163.107.225]; Helo=[milsmgep14.sandisk.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR04MB0369 Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: <linux-scsi.vger.kernel.org> X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP |
On 05/24/2017 02:34 AM, Bart Van Assche wrote: > Since the cdrom driver only supports request queues for which > struct scsi_request is the first member of their private request > data, refuse to register block layer queues for which this is > not the case. > > References: commit 82ed4db499b8 ("block: split scsi_request out of struct request") > Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> > Cc: Jens Axboe <axboe@fb.com> > Cc: Christoph Hellwig <hch@lst.de> > Cc: Omar Sandoval <osandov@fb.com> > Cc: Hannes Reinecke <hare@suse.com> > Cc: linux-block@vger.kernel.org > --- > drivers/cdrom/cdrom.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/drivers/cdrom/cdrom.c b/drivers/cdrom/cdrom.c > index 76c952fd9ab9..070568d496dc 100644 > --- a/drivers/cdrom/cdrom.c > +++ b/drivers/cdrom/cdrom.c > @@ -594,6 +594,10 @@ int register_cdrom(struct cdrom_device_info *cdi) > > if (cdo->open == NULL || cdo->release == NULL) > return -EINVAL; > + if (!blk_queue_scsi_sup(cdi->disk->queue)) { > + WARN_ONCE(true, "Attempt to register a non-SCSI queue\n"); > + return -EINVAL; > + } > if (!banner_printed) { > pr_info("Uniform CD-ROM driver " REVISION "\n"); > banner_printed = 1; > Reviewed-by: Hannes Reinecke <hare@suse.com> Cheers, Hannes
diff --git a/drivers/cdrom/cdrom.c b/drivers/cdrom/cdrom.c index 76c952fd9ab9..070568d496dc 100644 --- a/drivers/cdrom/cdrom.c +++ b/drivers/cdrom/cdrom.c @@ -594,6 +594,10 @@ int register_cdrom(struct cdrom_device_info *cdi) if (cdo->open == NULL || cdo->release == NULL) return -EINVAL; + if (!blk_queue_scsi_sup(cdi->disk->queue)) { + WARN_ONCE(true, "Attempt to register a non-SCSI queue\n"); + return -EINVAL; + } if (!banner_printed) { pr_info("Uniform CD-ROM driver " REVISION "\n"); banner_printed = 1;
Since the cdrom driver only supports request queues for which struct scsi_request is the first member of their private request data, refuse to register block layer queues for which this is not the case. References: commit 82ed4db499b8 ("block: split scsi_request out of struct request") Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Cc: Jens Axboe <axboe@fb.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Omar Sandoval <osandov@fb.com> Cc: Hannes Reinecke <hare@suse.com> Cc: linux-block@vger.kernel.org --- drivers/cdrom/cdrom.c | 4 ++++ 1 file changed, 4 insertions(+)