hc
2023-12-11 d2ccde1c8e90d38cee87a1b0309ad2827f3fd30d
kernel/drivers/scsi/arm/cumana_2.c
....@@ -1,11 +1,8 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * linux/drivers/acorn/scsi/cumana_2.c
34 *
45 * Copyright (C) 1997-2005 Russell King
5
- *
6
- * This program is free software; you can redistribute it and/or modify
7
- * it under the terms of the GNU General Public License version 2 as
8
- * published by the Free Software Foundation.
96 *
107 * Changelog:
118 * 30-08-1997 RMK 0.0.0 Created, READONLY version.
....@@ -26,11 +23,11 @@
2623 #include <linux/interrupt.h>
2724 #include <linux/init.h>
2825 #include <linux/dma-mapping.h>
26
+#include <linux/pgtable.h>
2927
3028 #include <asm/dma.h>
3129 #include <asm/ecard.h>
3230 #include <asm/io.h>
33
-#include <asm/pgtable.h>
3431
3532 #include "../scsi.h"
3633 #include <scsi/scsi_host.h>
....@@ -169,14 +166,15 @@
169166
170167 bufs = copy_SCp_to_sg(&info->sg[0], SCp, NR_SG);
171168
172
- if (direction == DMA_OUT)
173
- map_dir = DMA_TO_DEVICE,
174
- dma_dir = DMA_MODE_WRITE,
169
+ if (direction == DMA_OUT) {
170
+ map_dir = DMA_TO_DEVICE;
171
+ dma_dir = DMA_MODE_WRITE;
175172 alatch_dir = ALATCH_DMA_OUT;
176
- else
177
- map_dir = DMA_FROM_DEVICE,
178
- dma_dir = DMA_MODE_READ,
173
+ } else {
174
+ map_dir = DMA_FROM_DEVICE;
175
+ dma_dir = DMA_MODE_READ;
179176 alatch_dir = ALATCH_DMA_IN;
177
+ }
180178
181179 dma_map_sg(dev, info->sg, bufs, map_dir);
182180
....@@ -329,10 +327,12 @@
329327 cumanascsi_2_terminator_ctl(host, 0);
330328 else
331329 ret = -EINVAL;
332
- } else
330
+ } else {
333331 ret = -EINVAL;
334
- } else
332
+ }
333
+ } else {
335334 ret = -EINVAL;
335
+ }
336336
337337 return ret;
338338 }
....@@ -367,7 +367,6 @@
367367 .this_id = 7,
368368 .sg_tablesize = SG_MAX_SEGMENTS,
369369 .dma_boundary = IOMD_DMA_BOUNDARY,
370
- .use_clustering = DISABLE_CLUSTERING,
371370 .proc_name = "cumanascsi2",
372371 };
373372