| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * Aic94xx SAS/SATA driver hardware interface. |
|---|
| 3 | 4 | * |
|---|
| 4 | 5 | * Copyright (C) 2005 Adaptec, Inc. All rights reserved. |
|---|
| 5 | 6 | * Copyright (C) 2005 Luben Tuikov <luben_tuikov@adaptec.com> |
|---|
| 6 | | - * |
|---|
| 7 | | - * This file is licensed under GPLv2. |
|---|
| 8 | | - * |
|---|
| 9 | | - * This file is part of the aic94xx driver. |
|---|
| 10 | | - * |
|---|
| 11 | | - * The aic94xx driver is free software; you can redistribute it and/or |
|---|
| 12 | | - * modify it under the terms of the GNU General Public License as |
|---|
| 13 | | - * published by the Free Software Foundation; version 2 of the |
|---|
| 14 | | - * License. |
|---|
| 15 | | - * |
|---|
| 16 | | - * The aic94xx driver is distributed in the hope that it will be useful, |
|---|
| 17 | | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|---|
| 18 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
|---|
| 19 | | - * General Public License for more details. |
|---|
| 20 | | - * |
|---|
| 21 | | - * You should have received a copy of the GNU General Public License |
|---|
| 22 | | - * along with the aic94xx driver; if not, write to the Free Software |
|---|
| 23 | | - * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA |
|---|
| 24 | | - * |
|---|
| 25 | 7 | */ |
|---|
| 26 | 8 | |
|---|
| 27 | 9 | #include <linux/pci.h> |
|---|
| .. | .. |
|---|
| 593 | 575 | |
|---|
| 594 | 576 | /** |
|---|
| 595 | 577 | * asd_init_ctxmem -- initialize context memory |
|---|
| 596 | | - * asd_ha: pointer to host adapter structure |
|---|
| 578 | + * @asd_ha: pointer to host adapter structure |
|---|
| 597 | 579 | * |
|---|
| 598 | 580 | * This function sets the maximum number of SCBs and |
|---|
| 599 | 581 | * DDBs which can be used by the sequencer. This is normally |
|---|
| .. | .. |
|---|
| 1057 | 1039 | |
|---|
| 1058 | 1040 | if (ascb) { |
|---|
| 1059 | 1041 | ascb->dma_scb.size = sizeof(struct scb); |
|---|
| 1060 | | - ascb->dma_scb.vaddr = dma_pool_alloc(asd_ha->scb_pool, |
|---|
| 1042 | + ascb->dma_scb.vaddr = dma_pool_zalloc(asd_ha->scb_pool, |
|---|
| 1061 | 1043 | gfp_flags, |
|---|
| 1062 | 1044 | &ascb->dma_scb.dma_handle); |
|---|
| 1063 | 1045 | if (!ascb->dma_scb.vaddr) { |
|---|
| 1064 | 1046 | kmem_cache_free(asd_ascb_cache, ascb); |
|---|
| 1065 | 1047 | return NULL; |
|---|
| 1066 | 1048 | } |
|---|
| 1067 | | - memset(ascb->dma_scb.vaddr, 0, sizeof(struct scb)); |
|---|
| 1068 | 1049 | asd_init_ascb(asd_ha, ascb); |
|---|
| 1069 | 1050 | |
|---|
| 1070 | 1051 | spin_lock_irqsave(&seq->tc_index_lock, flags); |
|---|
| .. | .. |
|---|
| 1165 | 1146 | /** |
|---|
| 1166 | 1147 | * asd_start_timers -- (add and) start timers of SCBs |
|---|
| 1167 | 1148 | * @list: pointer to struct list_head of the scbs |
|---|
| 1168 | | - * @to: timeout in jiffies |
|---|
| 1169 | 1149 | * |
|---|
| 1170 | 1150 | * If an SCB in the @list has no timer function, assign the default |
|---|
| 1171 | 1151 | * one, then start the timer of the SCB. This function is |
|---|