Merge tag 'driver-core-3.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core
Pull driver core patches from Greg Kroah-Hartman: "Here is the big driver core merge for 3.9-rc1 There are two major series here, both of which touch lots of drivers all over the kernel, and will cause you some merge conflicts: - add a new function called devm_ioremap_resource() to properly be able to check return values. - remove CONFIG_EXPERIMENTAL Other than those patches, there's not much here, some minor fixes and updates" Fix up trivial conflicts * tag 'driver-core-3.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (221 commits) base: memory: fix soft/hard_offline_page permissions drivercore: Fix ordering between deferred_probe and exiting initcalls backlight: fix class_find_device() arguments TTY: mark tty_get_device call with the proper const values driver-core: constify data for class_find_device() firmware: Ignore abort check when no user-helper is used firmware: Reduce ifdef CONFIG_FW_LOADER_USER_HELPER firmware: Make user-mode helper optional firmware: Refactoring for splitting user-mode helper code Driver core: treat unregistered bus_types as having no devices watchdog: Convert to devm_ioremap_resource() thermal: Convert to devm_ioremap_resource() spi: Convert to devm_ioremap_resource() power: Convert to devm_ioremap_resource() mtd: Convert to devm_ioremap_resource() mmc: Convert to devm_ioremap_resource() mfd: Convert to devm_ioremap_resource() media: Convert to devm_ioremap_resource() iommu: Convert to devm_ioremap_resource() drm: Convert to devm_ioremap_resource() ...
This commit is contained in:
@@ -143,10 +143,9 @@ static int ehci_atmel_drv_probe(struct platform_device *pdev)
|
||||
hcd->rsrc_start = res->start;
|
||||
hcd->rsrc_len = resource_size(res);
|
||||
|
||||
hcd->regs = devm_request_and_ioremap(&pdev->dev, res);
|
||||
if (hcd->regs == NULL) {
|
||||
dev_dbg(&pdev->dev, "error mapping memory\n");
|
||||
retval = -EFAULT;
|
||||
hcd->regs = devm_ioremap_resource(&pdev->dev, res);
|
||||
if (IS_ERR(hcd->regs)) {
|
||||
retval = PTR_ERR(hcd->regs);
|
||||
goto fail_request_resource;
|
||||
}
|
||||
|
||||
|
@@ -25,7 +25,7 @@
|
||||
* Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
*/
|
||||
|
||||
|
||||
#include <linux/err.h>
|
||||
#include <linux/signal.h>
|
||||
|
||||
#include <linux/of_irq.h>
|
||||
@@ -118,10 +118,9 @@ static int ehci_hcd_grlib_probe(struct platform_device *op)
|
||||
goto err_irq;
|
||||
}
|
||||
|
||||
hcd->regs = devm_request_and_ioremap(&op->dev, &res);
|
||||
if (!hcd->regs) {
|
||||
pr_err("%s: devm_request_and_ioremap failed\n", __FILE__);
|
||||
rv = -ENOMEM;
|
||||
hcd->regs = devm_ioremap_resource(&op->dev, &res);
|
||||
if (IS_ERR(hcd->regs)) {
|
||||
rv = PTR_ERR(hcd->regs);
|
||||
goto err_ioremap;
|
||||
}
|
||||
|
||||
|
@@ -85,10 +85,9 @@ static int ehci_mxc_drv_probe(struct platform_device *pdev)
|
||||
hcd->rsrc_start = res->start;
|
||||
hcd->rsrc_len = resource_size(res);
|
||||
|
||||
hcd->regs = devm_request_and_ioremap(&pdev->dev, res);
|
||||
if (!hcd->regs) {
|
||||
dev_err(dev, "error mapping memory\n");
|
||||
ret = -EFAULT;
|
||||
hcd->regs = devm_ioremap_resource(&pdev->dev, res);
|
||||
if (IS_ERR(hcd->regs)) {
|
||||
ret = PTR_ERR(hcd->regs);
|
||||
goto err_alloc;
|
||||
}
|
||||
|
||||
|
@@ -18,6 +18,7 @@
|
||||
*
|
||||
* Licensed under the GNU/GPL. See COPYING for details.
|
||||
*/
|
||||
#include <linux/err.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/hrtimer.h>
|
||||
#include <linux/io.h>
|
||||
@@ -104,9 +105,9 @@ static int ehci_platform_probe(struct platform_device *dev)
|
||||
hcd->rsrc_start = res_mem->start;
|
||||
hcd->rsrc_len = resource_size(res_mem);
|
||||
|
||||
hcd->regs = devm_request_and_ioremap(&dev->dev, res_mem);
|
||||
if (!hcd->regs) {
|
||||
err = -ENOMEM;
|
||||
hcd->regs = devm_ioremap_resource(&dev->dev, res_mem);
|
||||
if (IS_ERR(hcd->regs)) {
|
||||
err = PTR_ERR(hcd->regs);
|
||||
goto err_put_hcd;
|
||||
}
|
||||
err = usb_add_hcd(hcd, irq, IRQF_SHARED);
|
||||
|
@@ -12,6 +12,7 @@
|
||||
* This file is licenced under the GPL.
|
||||
*/
|
||||
|
||||
#include <linux/err.h>
|
||||
#include <linux/signal.h>
|
||||
|
||||
#include <linux/of.h>
|
||||
@@ -121,10 +122,9 @@ static int ehci_hcd_ppc_of_probe(struct platform_device *op)
|
||||
goto err_irq;
|
||||
}
|
||||
|
||||
hcd->regs = devm_request_and_ioremap(&op->dev, &res);
|
||||
if (!hcd->regs) {
|
||||
pr_err("%s: devm_request_and_ioremap failed\n", __FILE__);
|
||||
rv = -ENOMEM;
|
||||
hcd->regs = devm_ioremap_resource(&op->dev, &res);
|
||||
if (IS_ERR(hcd->regs)) {
|
||||
rv = PTR_ERR(hcd->regs);
|
||||
goto err_ioremap;
|
||||
}
|
||||
|
||||
|
@@ -19,6 +19,7 @@
|
||||
* Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
*/
|
||||
|
||||
#include <linux/err.h>
|
||||
#include <linux/platform_device.h>
|
||||
|
||||
static int ehci_sead3_setup(struct usb_hcd *hcd)
|
||||
@@ -112,10 +113,9 @@ static int ehci_hcd_sead3_drv_probe(struct platform_device *pdev)
|
||||
hcd->rsrc_start = res->start;
|
||||
hcd->rsrc_len = resource_size(res);
|
||||
|
||||
hcd->regs = devm_request_and_ioremap(&pdev->dev, res);
|
||||
if (!hcd->regs) {
|
||||
pr_debug("ioremap failed");
|
||||
ret = -ENOMEM;
|
||||
hcd->regs = devm_ioremap_resource(&pdev->dev, res);
|
||||
if (IS_ERR(hcd->regs)) {
|
||||
ret = PTR_ERR(hcd->regs);
|
||||
goto err1;
|
||||
}
|
||||
|
||||
|
@@ -118,10 +118,9 @@ static int ehci_hcd_sh_probe(struct platform_device *pdev)
|
||||
hcd->rsrc_start = res->start;
|
||||
hcd->rsrc_len = resource_size(res);
|
||||
|
||||
hcd->regs = devm_request_and_ioremap(&pdev->dev, res);
|
||||
if (hcd->regs == NULL) {
|
||||
dev_dbg(&pdev->dev, "error mapping memory\n");
|
||||
ret = -ENXIO;
|
||||
hcd->regs = devm_ioremap_resource(&pdev->dev, res);
|
||||
if (IS_ERR(hcd->regs)) {
|
||||
ret = PTR_ERR(hcd->regs);
|
||||
goto fail_request_resource;
|
||||
}
|
||||
|
||||
|
@@ -16,6 +16,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include <linux/err.h>
|
||||
#include <linux/of.h>
|
||||
#include <linux/platform_device.h>
|
||||
|
||||
@@ -96,10 +97,9 @@ static int vt8500_ehci_drv_probe(struct platform_device *pdev)
|
||||
hcd->rsrc_start = res->start;
|
||||
hcd->rsrc_len = resource_size(res);
|
||||
|
||||
hcd->regs = devm_request_and_ioremap(&pdev->dev, res);
|
||||
if (!hcd->regs) {
|
||||
pr_debug("ioremap failed");
|
||||
ret = -ENOMEM;
|
||||
hcd->regs = devm_ioremap_resource(&pdev->dev, res);
|
||||
if (IS_ERR(hcd->regs)) {
|
||||
ret = PTR_ERR(hcd->regs);
|
||||
goto err1;
|
||||
}
|
||||
|
||||
|
@@ -25,6 +25,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include <linux/err.h>
|
||||
#include <linux/signal.h>
|
||||
|
||||
#include <linux/of.h>
|
||||
@@ -159,10 +160,9 @@ static int ehci_hcd_xilinx_of_probe(struct platform_device *op)
|
||||
goto err_irq;
|
||||
}
|
||||
|
||||
hcd->regs = devm_request_and_ioremap(&op->dev, &res);
|
||||
if (!hcd->regs) {
|
||||
pr_err("%s: devm_request_and_ioremap failed\n", __FILE__);
|
||||
rv = -ENOMEM;
|
||||
hcd->regs = devm_ioremap_resource(&op->dev, &res);
|
||||
if (IS_ERR(hcd->regs)) {
|
||||
rv = PTR_ERR(hcd->regs);
|
||||
goto err_irq;
|
||||
}
|
||||
|
||||
|
@@ -306,10 +306,9 @@ static int usb_hcd_nxp_probe(struct platform_device *pdev)
|
||||
goto out8;
|
||||
}
|
||||
|
||||
hcd->regs = devm_request_and_ioremap(&pdev->dev, res);
|
||||
if (!hcd->regs) {
|
||||
dev_err(&pdev->dev, "Failed to devm_request_and_ioremap\n");
|
||||
ret = -ENOMEM;
|
||||
hcd->regs = devm_ioremap_resource(&pdev->dev, res);
|
||||
if (IS_ERR(hcd->regs)) {
|
||||
ret = PTR_ERR(hcd->regs);
|
||||
goto out8;
|
||||
}
|
||||
hcd->rsrc_start = res->start;
|
||||
|
@@ -13,6 +13,7 @@
|
||||
*
|
||||
* Licensed under the GNU/GPL. See COPYING for details.
|
||||
*/
|
||||
#include <linux/err.h>
|
||||
#include <linux/platform_device.h>
|
||||
#include <linux/usb/ohci_pdriver.h>
|
||||
|
||||
@@ -127,9 +128,9 @@ static int ohci_platform_probe(struct platform_device *dev)
|
||||
hcd->rsrc_start = res_mem->start;
|
||||
hcd->rsrc_len = resource_size(res_mem);
|
||||
|
||||
hcd->regs = devm_request_and_ioremap(&dev->dev, res_mem);
|
||||
if (!hcd->regs) {
|
||||
err = -ENOMEM;
|
||||
hcd->regs = devm_ioremap_resource(&dev->dev, res_mem);
|
||||
if (IS_ERR(hcd->regs)) {
|
||||
err = PTR_ERR(hcd->regs);
|
||||
goto err_put_hcd;
|
||||
}
|
||||
err = usb_add_hcd(hcd, irq, IRQF_SHARED);
|
||||
|
@@ -351,10 +351,9 @@ static int usb_hcd_s3c2410_probe(const struct hc_driver *driver,
|
||||
hcd->rsrc_start = dev->resource[0].start;
|
||||
hcd->rsrc_len = resource_size(&dev->resource[0]);
|
||||
|
||||
hcd->regs = devm_request_and_ioremap(&dev->dev, &dev->resource[0]);
|
||||
if (!hcd->regs) {
|
||||
dev_err(&dev->dev, "devm_request_and_ioremap failed\n");
|
||||
retval = -ENOMEM;
|
||||
hcd->regs = devm_ioremap_resource(&dev->dev, &dev->resource[0]);
|
||||
if (IS_ERR(hcd->regs)) {
|
||||
retval = PTR_ERR(hcd->regs);
|
||||
goto err_put;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user