.. | .. |
---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only |
---|
1 | 2 | /* |
---|
2 | 3 | * Atheros AR724X PCI host controller driver |
---|
3 | 4 | * |
---|
4 | 5 | * Copyright (C) 2011 René Bolldorf <xsecute@googlemail.com> |
---|
5 | 6 | * Copyright (C) 2009-2011 Gabor Juhos <juhosg@openwrt.org> |
---|
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 version 2 as published |
---|
9 | | - * by the Free Software Foundation. |
---|
10 | 7 | */ |
---|
11 | 8 | |
---|
12 | 9 | #include <linux/irq.h> |
---|
.. | .. |
---|
375 | 372 | if (!apc) |
---|
376 | 373 | return -ENOMEM; |
---|
377 | 374 | |
---|
378 | | - res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "ctrl_base"); |
---|
379 | | - apc->ctrl_base = devm_ioremap_resource(&pdev->dev, res); |
---|
| 375 | + apc->ctrl_base = devm_platform_ioremap_resource_byname(pdev, "ctrl_base"); |
---|
380 | 376 | if (IS_ERR(apc->ctrl_base)) |
---|
381 | 377 | return PTR_ERR(apc->ctrl_base); |
---|
382 | 378 | |
---|
383 | | - res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "cfg_base"); |
---|
384 | | - apc->devcfg_base = devm_ioremap_resource(&pdev->dev, res); |
---|
| 379 | + apc->devcfg_base = devm_platform_ioremap_resource_byname(pdev, "cfg_base"); |
---|
385 | 380 | if (IS_ERR(apc->devcfg_base)) |
---|
386 | 381 | return PTR_ERR(apc->devcfg_base); |
---|
387 | 382 | |
---|
388 | | - res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "crp_base"); |
---|
389 | | - apc->crp_base = devm_ioremap_resource(&pdev->dev, res); |
---|
| 383 | + apc->crp_base = devm_platform_ioremap_resource_byname(pdev, "crp_base"); |
---|
390 | 384 | if (IS_ERR(apc->crp_base)) |
---|
391 | 385 | return PTR_ERR(apc->crp_base); |
---|
392 | 386 | |
---|