| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * Copyright (C) 2006-2009 DENX Software Engineering. |
|---|
| 3 | 4 | * |
|---|
| .. | .. |
|---|
| 5 | 6 | * |
|---|
| 6 | 7 | * Further porting to arch/powerpc by |
|---|
| 7 | 8 | * Anatolij Gustschin <agust@denx.de> |
|---|
| 8 | | - * |
|---|
| 9 | | - * This program is free software; you can redistribute it and/or modify it |
|---|
| 10 | | - * under the terms of the GNU General Public License as published by the Free |
|---|
| 11 | | - * Software Foundation; either version 2 of the License, or (at your option) |
|---|
| 12 | | - * any later version. |
|---|
| 13 | | - * |
|---|
| 14 | | - * This program is distributed in the hope that it will be useful, but WITHOUT |
|---|
| 15 | | - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|---|
| 16 | | - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for |
|---|
| 17 | | - * more details. |
|---|
| 18 | | - * |
|---|
| 19 | | - * The full GNU General Public License is included in this distribution in the |
|---|
| 20 | | - * file called COPYING. |
|---|
| 21 | 9 | */ |
|---|
| 22 | 10 | |
|---|
| 23 | 11 | /* |
|---|
| .. | .. |
|---|
| 1672 | 1660 | /** |
|---|
| 1673 | 1661 | * ppc440spe_adma_tasklet - clean up watch-dog initiator |
|---|
| 1674 | 1662 | */ |
|---|
| 1675 | | -static void ppc440spe_adma_tasklet(unsigned long data) |
|---|
| 1663 | +static void ppc440spe_adma_tasklet(struct tasklet_struct *t) |
|---|
| 1676 | 1664 | { |
|---|
| 1677 | | - struct ppc440spe_adma_chan *chan = (struct ppc440spe_adma_chan *) data; |
|---|
| 1665 | + struct ppc440spe_adma_chan *chan = from_tasklet(chan, t, irq_tasklet); |
|---|
| 1678 | 1666 | |
|---|
| 1679 | 1667 | spin_lock_nested(&chan->lock, SINGLE_DEPTH_NESTING); |
|---|
| 1680 | 1668 | __ppc440spe_adma_slot_cleanup(chan); |
|---|
| .. | .. |
|---|
| 4153 | 4141 | chan->common.device = &adev->common; |
|---|
| 4154 | 4142 | dma_cookie_init(&chan->common); |
|---|
| 4155 | 4143 | list_add_tail(&chan->common.device_node, &adev->common.channels); |
|---|
| 4156 | | - tasklet_init(&chan->irq_tasklet, ppc440spe_adma_tasklet, |
|---|
| 4157 | | - (unsigned long)chan); |
|---|
| 4144 | + tasklet_setup(&chan->irq_tasklet, ppc440spe_adma_tasklet); |
|---|
| 4158 | 4145 | |
|---|
| 4159 | 4146 | /* allocate and map helper pages for async validation or |
|---|
| 4160 | 4147 | * async_mult/async_sum_product operations on DMA0/1. |
|---|
| .. | .. |
|---|
| 4315 | 4302 | for (i = 0; i < PPC440SPE_ADMA_ENGINES_NUM; i++) { |
|---|
| 4316 | 4303 | if (ppc440spe_adma_devices[i] == -1) |
|---|
| 4317 | 4304 | continue; |
|---|
| 4318 | | - size += snprintf(buf + size, PAGE_SIZE - size, |
|---|
| 4305 | + size += scnprintf(buf + size, PAGE_SIZE - size, |
|---|
| 4319 | 4306 | "PPC440SP(E)-ADMA.%d: %s\n", i, |
|---|
| 4320 | 4307 | ppc_adma_errors[ppc440spe_adma_devices[i]]); |
|---|
| 4321 | 4308 | } |
|---|