From 9d77db3c730780c8ef5ccd4b66403ff5675cfe4e Mon Sep 17 00:00:00 2001 From: hc <hc@nodka.com> Date: Mon, 13 May 2024 10:30:14 +0000 Subject: [PATCH] modify sin led gpio --- kernel/drivers/scsi/arm/cumana_2.c | 27 +++++++++++++-------------- 1 files changed, 13 insertions(+), 14 deletions(-) diff --git a/kernel/drivers/scsi/arm/cumana_2.c b/kernel/drivers/scsi/arm/cumana_2.c index 93ba83e..9dcd912 100644 --- a/kernel/drivers/scsi/arm/cumana_2.c +++ b/kernel/drivers/scsi/arm/cumana_2.c @@ -1,11 +1,8 @@ +// SPDX-License-Identifier: GPL-2.0-only /* * linux/drivers/acorn/scsi/cumana_2.c * * Copyright (C) 1997-2005 Russell King - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. * * Changelog: * 30-08-1997 RMK 0.0.0 Created, READONLY version. @@ -26,11 +23,11 @@ #include <linux/interrupt.h> #include <linux/init.h> #include <linux/dma-mapping.h> +#include <linux/pgtable.h> #include <asm/dma.h> #include <asm/ecard.h> #include <asm/io.h> -#include <asm/pgtable.h> #include "../scsi.h" #include <scsi/scsi_host.h> @@ -169,14 +166,15 @@ bufs = copy_SCp_to_sg(&info->sg[0], SCp, NR_SG); - if (direction == DMA_OUT) - map_dir = DMA_TO_DEVICE, - dma_dir = DMA_MODE_WRITE, + if (direction == DMA_OUT) { + map_dir = DMA_TO_DEVICE; + dma_dir = DMA_MODE_WRITE; alatch_dir = ALATCH_DMA_OUT; - else - map_dir = DMA_FROM_DEVICE, - dma_dir = DMA_MODE_READ, + } else { + map_dir = DMA_FROM_DEVICE; + dma_dir = DMA_MODE_READ; alatch_dir = ALATCH_DMA_IN; + } dma_map_sg(dev, info->sg, bufs, map_dir); @@ -329,10 +327,12 @@ cumanascsi_2_terminator_ctl(host, 0); else ret = -EINVAL; - } else + } else { ret = -EINVAL; - } else + } + } else { ret = -EINVAL; + } return ret; } @@ -367,7 +367,6 @@ .this_id = 7, .sg_tablesize = SG_MAX_SEGMENTS, .dma_boundary = IOMD_DMA_BOUNDARY, - .use_clustering = DISABLE_CLUSTERING, .proc_name = "cumanascsi2", }; -- Gitblit v1.6.2