From patchwork Fri Sep 25 09:27:42 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Bonzini X-Patchwork-Id: 7263111 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 840FFBEEC1 for ; Fri, 25 Sep 2015 09:28:38 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id A064520B2E for ; Fri, 25 Sep 2015 09:28:37 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id A2FEA20B35 for ; Fri, 25 Sep 2015 09:28:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755760AbbIYJ22 (ORCPT ); Fri, 25 Sep 2015 05:28:28 -0400 Received: from mx1.redhat.com ([209.132.183.28]:50958 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755804AbbIYJ1y (ORCPT ); Fri, 25 Sep 2015 05:27:54 -0400 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (Postfix) with ESMTPS id 4ED6B2FAA61; Fri, 25 Sep 2015 09:27:54 +0000 (UTC) Received: from donizetti.redhat.com (ovpn-112-83.ams2.redhat.com [10.36.112.83]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t8P9Rj6M028310; Fri, 25 Sep 2015 05:27:51 -0400 From: Paolo Bonzini To: linux-kernel@vger.kernel.org, kvm@vger.kernel.org Cc: bart.vanassche@sandisk.com, James Bottomley , Christoph Hellwig , linux-scsi@vger.kernel.org Subject: [PATCH v3 2/4] scsi: cleanup scsi/scsi_ioctl.h Date: Fri, 25 Sep 2015 11:27:42 +0200 Message-Id: <1443173264-4105-3-git-send-email-pbonzini@redhat.com> In-Reply-To: <1443173264-4105-1-git-send-email-pbonzini@redhat.com> References: <1443173264-4105-1-git-send-email-pbonzini@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.24 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.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable 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 SCSI_REMOVAL_* goes together with other SCSI command constants in include/scsi/scsi.h. It is also used outside the implementation of the ioctls (and it is not part of the user API). scsi_fctargaddress/Scsi_FCTargAddress has had no in-tree use since commit ca61f10ab2b8 ("[SCSI] remove broken driver cpqfc", 2005-10-29). Remove it, just in time for the the tenth anniversary of its demise. Cc: James Bottomley Cc: Christoph Hellwig Cc: linux-scsi@vger.kernel.org Reviewed-by: Bart Van Assche Signed-off-by: Paolo Bonzini Reviewed-by: Hannes Reinecke Acked-by: Douglas Gilbert --- include/scsi/scsi.h | 6 ++++++ include/scsi/scsi_ioctl.h | 8 -------- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/include/scsi/scsi.h b/include/scsi/scsi.h index e0a3398b1547..5e2bafdbd96f 100644 --- a/include/scsi/scsi.h +++ b/include/scsi/scsi.h @@ -279,6 +279,12 @@ static inline int scsi_is_wlun(u64 lun) #define SCSI_INQ_PQ_NOT_CON 0x01 #define SCSI_INQ_PQ_NOT_CAP 0x03 +/* + * PREVENT/ALLOW MEDIUM REMOVAL + */ +#define SCSI_REMOVAL_PREVENT 1 +#define SCSI_REMOVAL_ALLOW 0 + /* * Here are some scsi specific ioctl commands which are sometimes useful. diff --git a/include/scsi/scsi_ioctl.h b/include/scsi/scsi_ioctl.h index 8d19d1d233c3..c81962bef7a0 100644 --- a/include/scsi/scsi_ioctl.h +++ b/include/scsi/scsi_ioctl.h @@ -12,9 +12,6 @@ #define SCSI_IOCTL_DOORLOCK 0x5380 /* lock the eject mechanism */ #define SCSI_IOCTL_DOORUNLOCK 0x5381 /* unlock the mechanism */ -#define SCSI_REMOVAL_PREVENT 1 -#define SCSI_REMOVAL_ALLOW 0 - #ifdef __KERNEL__ struct scsi_device; @@ -34,11 +31,6 @@ typedef struct scsi_idlun { __u32 host_unique_id; } Scsi_Idlun; -/* Fibre Channel WWN, port_id struct */ -typedef struct scsi_fctargaddress { - __u32 host_port_id; - unsigned char host_wwn[8]; // include NULL term. -} Scsi_FCTargAddress; int scsi_ioctl_block_when_processing_errors(struct scsi_device *sdev, int cmd, bool ndelay);