hc
2023-12-11 d2ccde1c8e90d38cee87a1b0309ad2827f3fd30d
kernel/drivers/rapidio/devices/tsi721_dma.c
....@@ -1,21 +1,9 @@
1
+// SPDX-License-Identifier: GPL-2.0-or-later
12 /*
23 * DMA Engine support for Tsi721 PCIExpress-to-SRIO bridge
34 *
45 * Copyright (c) 2011-2014 Integrated Device Technology, Inc.
56 * Alexandre Bounine <alexandre.bounine@idt.com>
6
- *
7
- * This program is free software; you can redistribute it and/or modify it
8
- * under the terms of the GNU General Public License as published by the Free
9
- * Software Foundation; either version 2 of the License, or (at your option)
10
- * any later version.
11
- *
12
- * This program is distributed in the hope that it will be useful, but WITHOUT
13
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
14
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
15
- * more details.
16
- *
17
- * The full GNU General Public License is included in this distribution in the
18
- * file called COPYING.
197 */
208
219 #include <linux/io.h>
....@@ -90,9 +78,9 @@
9078 * Allocate space for DMA descriptors
9179 * (add an extra element for link descriptor)
9280 */
93
- bd_ptr = dma_zalloc_coherent(dev,
94
- (bd_num + 1) * sizeof(struct tsi721_dma_desc),
95
- &bd_phys, GFP_ATOMIC);
81
+ bd_ptr = dma_alloc_coherent(dev,
82
+ (bd_num + 1) * sizeof(struct tsi721_dma_desc),
83
+ &bd_phys, GFP_ATOMIC);
9684 if (!bd_ptr)
9785 return -ENOMEM;
9886
....@@ -108,7 +96,7 @@
10896 sts_size = ((bd_num + 1) >= TSI721_DMA_MINSTSSZ) ?
10997 (bd_num + 1) : TSI721_DMA_MINSTSSZ;
11098 sts_size = roundup_pow_of_two(sts_size);
111
- sts_ptr = dma_zalloc_coherent(dev,
99
+ sts_ptr = dma_alloc_coherent(dev,
112100 sts_size * sizeof(struct tsi721_dma_sts),
113101 &sts_phys, GFP_ATOMIC);
114102 if (!sts_ptr) {