Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 353668
b: refs/heads/master
c: c7c9e1c
h: refs/heads/master
v: v3
  • Loading branch information
Thierry Reding authored and Greg Kroah-Hartman committed Jan 22, 2013
1 parent a41238a commit 29c30b3
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 75096579c3ac39ddc2f8b0d9a8924eba31f4d920
refs/heads/master: c7c9e1c372452688f0ef2af794789bbd00f9fa51
9 changes: 5 additions & 4 deletions trunk/drivers/char/hw_random/exynos-rng.c
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ static int exynos_read(struct hwrng *rng, void *buf,
static int exynos_rng_probe(struct platform_device *pdev)
{
struct exynos_rng *exynos_rng;
struct resource *res;

exynos_rng = devm_kzalloc(&pdev->dev, sizeof(struct exynos_rng),
GFP_KERNEL);
Expand All @@ -120,10 +121,10 @@ static int exynos_rng_probe(struct platform_device *pdev)
return -ENOENT;
}

exynos_rng->mem = devm_request_and_ioremap(&pdev->dev,
platform_get_resource(pdev, IORESOURCE_MEM, 0));
if (!exynos_rng->mem)
return -EBUSY;
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
exynos_rng->mem = devm_ioremap_resource(&pdev->dev, res);
if (IS_ERR(exynos_rng->mem))
return PTR_ERR(exynos_rng->mem);

platform_set_drvdata(pdev, exynos_rng);

Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/char/hw_random/omap-rng.c
Original file line number Diff line number Diff line change
Expand Up @@ -124,9 +124,9 @@ static int omap_rng_probe(struct platform_device *pdev)
goto err_ioremap;
}

priv->base = devm_request_and_ioremap(&pdev->dev, priv->mem_res);
if (!priv->base) {
ret = -ENOMEM;
priv->base = devm_ioremap_resource(&pdev->dev, priv->mem_res);
if (IS_ERR(priv->base)) {
ret = PTR_ERR(priv->base);
goto err_ioremap;
}
dev_set_drvdata(&pdev->dev, priv);
Expand Down
7 changes: 4 additions & 3 deletions trunk/drivers/char/hw_random/tx4939-rng.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
* License. See the file "COPYING" in the main directory of this archive
* for more details.
*/
#include <linux/err.h>
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/init.h>
Expand Down Expand Up @@ -115,9 +116,9 @@ static int __init tx4939_rng_probe(struct platform_device *dev)
rngdev = devm_kzalloc(&dev->dev, sizeof(*rngdev), GFP_KERNEL);
if (!rngdev)
return -ENOMEM;
rngdev->base = devm_request_and_ioremap(&dev->dev, r);
if (!rngdev->base)
return -EBUSY;
rngdev->base = devm_ioremap_resource(&dev->dev, r);
if (IS_ERR(rngdev->base))
return PTR_ERR(rngdev->base);

rngdev->rng.name = dev_name(&dev->dev);
rngdev->rng.data_present = tx4939_rng_data_present;
Expand Down

0 comments on commit 29c30b3

Please sign in to comment.