From patchwork Tue Mar 7 22:45:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ondrej Zary X-Patchwork-Id: 13164886 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 08B94C74A44 for ; Tue, 7 Mar 2023 22:47:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230037AbjCGWrC (ORCPT ); Tue, 7 Mar 2023 17:47:02 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33254 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229746AbjCGWrA (ORCPT ); Tue, 7 Mar 2023 17:47:00 -0500 Received: from hosting.gsystem.sk (hosting.gsystem.sk [212.5.213.30]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 3EB4993C8; Tue, 7 Mar 2023 14:46:49 -0800 (PST) Received: from gsql.ggedos.sk (off-20.infotel.telecom.sk [212.5.213.20]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by hosting.gsystem.sk (Postfix) with ESMTPSA id E06927A02E3; Tue, 7 Mar 2023 23:46:47 +0100 (CET) From: Ondrej Zary To: Damien Le Moal , Sudip Mukherjee Cc: Christoph Hellwig , Sergey Shtylyov , Jens Axboe , Tim Waugh , linux-block@vger.kernel.org, linux-parport@lists.infradead.org, linux-ide@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 01/32] pata_parport-bpck6: remove useless defines Date: Tue, 7 Mar 2023 23:45:56 +0100 Message-Id: <20230307224627.28011-2-linux@zary.sk> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20230307224627.28011-1-linux@zary.sk> References: <20230307224627.28011-1-linux@zary.sk> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Almost all the ATAPI_ defines are unused. Remove them and use ATA_REG_DATA instead of ATAPI_DATA. Signed-off-by: Ondrej Zary Reviewed-by: Sergey Shtylyov --- drivers/ata/pata_parport/bpck6.c | 21 ++------------------- 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/drivers/ata/pata_parport/bpck6.c b/drivers/ata/pata_parport/bpck6.c index 964bc688e280..842e8116b649 100644 --- a/drivers/ata/pata_parport/bpck6.c +++ b/drivers/ata/pata_parport/bpck6.c @@ -23,23 +23,6 @@ #define PPCSTRUCT(pi) ((Interface *)(pi->private)) -/****************************************************************/ -/* - ATAPI CDROM DRIVE REGISTERS -*/ -#define ATAPI_DATA 0 /* data port */ -#define ATAPI_ERROR 1 /* error register (read) */ -#define ATAPI_FEATURES 1 /* feature register (write) */ -#define ATAPI_INT_REASON 2 /* interrupt reason register */ -#define ATAPI_COUNT_LOW 4 /* byte count register (low) */ -#define ATAPI_COUNT_HIGH 5 /* byte count register (high) */ -#define ATAPI_DRIVE_SEL 6 /* drive select register */ -#define ATAPI_STATUS 7 /* status port (read) */ -#define ATAPI_COMMAND 7 /* command port (write) */ -#define ATAPI_ALT_STATUS 0x0e /* alternate status reg (read) */ -#define ATAPI_DEVICE_CONTROL 0x0e /* device control (write) */ -/****************************************************************/ - static int bpck6_read_regr(struct pi_adapter *pi, int cont, int reg) { unsigned int out; @@ -64,12 +47,12 @@ static void bpck6_write_regr(struct pi_adapter *pi, int cont, int reg, int val) static void bpck6_write_block(struct pi_adapter *pi, char *buf, int len) { - ppc6_wr_port16_blk(PPCSTRUCT(pi),ATAPI_DATA,buf,(u32)len>>1); + ppc6_wr_port16_blk(PPCSTRUCT(pi), ATA_REG_DATA, buf, (u32)len>>1); } static void bpck6_read_block(struct pi_adapter *pi, char *buf, int len) { - ppc6_rd_port16_blk(PPCSTRUCT(pi),ATAPI_DATA,buf,(u32)len>>1); + ppc6_rd_port16_blk(PPCSTRUCT(pi), ATA_REG_DATA, buf, (u32)len>>1); } static void bpck6_connect(struct pi_adapter *pi)