From patchwork Fri Aug 25 11:57:16 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hannes Reinecke X-Patchwork-Id: 9921877 Return-Path: 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 CAA73600C5 for ; Fri, 25 Aug 2017 11:58:57 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B9F5F27E5A for ; Fri, 25 Aug 2017 11:58:57 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id ADAD827F86; Fri, 25 Aug 2017 11:58:57 +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,RCVD_IN_DNSWL_HI autolearn=ham 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 471B227E5A for ; Fri, 25 Aug 2017 11:58:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932469AbdHYL6S (ORCPT ); Fri, 25 Aug 2017 07:58:18 -0400 Received: from mx2.suse.de ([195.135.220.15]:49649 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1756520AbdHYL6E (ORCPT ); Fri, 25 Aug 2017 07:58:04 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 8FD20AF52; Fri, 25 Aug 2017 11:57:58 +0000 (UTC) From: Hannes Reinecke To: "Martin K. Petersen" Cc: Christoph Hellwig , James Bottomley , linux-scsi@vger.kernel.org, Hannes Reinecke Subject: [PATCHv2 21/26] aha152x: drop host reset Date: Fri, 25 Aug 2017 13:57:16 +0200 Message-Id: <1503662241-127788-22-git-send-email-hare@suse.de> X-Mailer: git-send-email 1.8.5.6 In-Reply-To: <1503662241-127788-1-git-send-email-hare@suse.de> References: <1503662241-127788-1-git-send-email-hare@suse.de> Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Hannes Reinecke The driver has both a bus and a host reset, where the host reset does a bus reset followed by an attempt to reset the chip registes to a default state. However, as the bus reset always returned SUCCESS the host reset was never called, so the functionality of the register reset function was never validated. Additionally, tha AIC-6260 chip has a hard reset line, which actually should be preferred for a host reset. But I haven't found a way how this can be triggered via software, so take the safe approach and drop the host reset. Signed-off-by: Hannes Reinecke --- drivers/scsi/aha152x.c | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/drivers/scsi/aha152x.c b/drivers/scsi/aha152x.c index ce5dc73..bc0058d 100644 --- a/drivers/scsi/aha152x.c +++ b/drivers/scsi/aha152x.c @@ -1140,6 +1140,9 @@ static void free_hard_reset_SCs(struct Scsi_Host *shpnt, Scsi_Cmnd **SCs) /* * Reset the bus * + * AIC-6260 has a hard reset (MRST signal), but apparently + * one cannot trigger it via software. So live with + * a soft reset; no-one seemed to have cared. */ static int aha152x_bus_reset_host(struct Scsi_Host *shpnt) { @@ -1223,15 +1226,6 @@ int aha152x_host_reset_host(struct Scsi_Host *shpnt) } /* - * Reset the host (bus and controller) - * - */ -static int aha152x_host_reset(Scsi_Cmnd *SCpnt) -{ - return aha152x_host_reset_host(SCpnt->device->host); -} - -/* * Return the "logical geometry" * */ @@ -2917,7 +2911,6 @@ static int aha152x_adjust_queue(struct scsi_device *device) .eh_abort_handler = aha152x_abort, .eh_device_reset_handler = aha152x_device_reset, .eh_bus_reset_handler = aha152x_bus_reset, - .eh_host_reset_handler = aha152x_host_reset, .bios_param = aha152x_biosparam, .can_queue = 1, .this_id = 7,