diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2015-05-05 12:03:52 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2015-05-05 12:03:52 -0400 |
commit | d9cee5d4f66ef36f69b0108dedbad7f7009bb6a8 (patch) | |
tree | 14dcf7cb49a884de4b5c55c5757f935c12462719 /drivers/char | |
parent | c02d7da3dd00cb32b58d9c87240456e19eebcc42 (diff) | |
parent | f440c4ee3e53f767974fe60bcbc0b6687a5fb53f (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
Pull crypto fixes from Herbert Xu:
"This fixes a build problem with bcm63xx and yet another fix to the
memzero_explicit function to ensure that the memset is not elided"
* git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6:
hwrng: bcm63xx - Fix driver compilation
lib: make memzero_explicit more robust against dead store elimination
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/hw_random/bcm63xx-rng.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/drivers/char/hw_random/bcm63xx-rng.c b/drivers/char/hw_random/bcm63xx-rng.c index d1494ecd9e11..4b31f1387f37 100644 --- a/drivers/char/hw_random/bcm63xx-rng.c +++ b/drivers/char/hw_random/bcm63xx-rng.c | |||
@@ -57,7 +57,7 @@ static void bcm63xx_rng_cleanup(struct hwrng *rng) | |||
57 | val &= ~RNG_EN; | 57 | val &= ~RNG_EN; |
58 | __raw_writel(val, priv->regs + RNG_CTRL); | 58 | __raw_writel(val, priv->regs + RNG_CTRL); |
59 | 59 | ||
60 | clk_didsable_unprepare(prov->clk); | 60 | clk_disable_unprepare(priv->clk); |
61 | } | 61 | } |
62 | 62 | ||
63 | static int bcm63xx_rng_data_present(struct hwrng *rng, int wait) | 63 | static int bcm63xx_rng_data_present(struct hwrng *rng, int wait) |
@@ -97,14 +97,14 @@ static int bcm63xx_rng_probe(struct platform_device *pdev) | |||
97 | priv->rng.name = pdev->name; | 97 | priv->rng.name = pdev->name; |
98 | priv->rng.init = bcm63xx_rng_init; | 98 | priv->rng.init = bcm63xx_rng_init; |
99 | priv->rng.cleanup = bcm63xx_rng_cleanup; | 99 | priv->rng.cleanup = bcm63xx_rng_cleanup; |
100 | prov->rng.data_present = bcm63xx_rng_data_present; | 100 | priv->rng.data_present = bcm63xx_rng_data_present; |
101 | priv->rng.data_read = bcm63xx_rng_data_read; | 101 | priv->rng.data_read = bcm63xx_rng_data_read; |
102 | 102 | ||
103 | priv->clk = devm_clk_get(&pdev->dev, "ipsec"); | 103 | priv->clk = devm_clk_get(&pdev->dev, "ipsec"); |
104 | if (IS_ERR(priv->clk)) { | 104 | if (IS_ERR(priv->clk)) { |
105 | error = PTR_ERR(priv->clk); | 105 | ret = PTR_ERR(priv->clk); |
106 | dev_err(&pdev->dev, "no clock for device: %d\n", error); | 106 | dev_err(&pdev->dev, "no clock for device: %d\n", ret); |
107 | return error; | 107 | return ret; |
108 | } | 108 | } |
109 | 109 | ||
110 | if (!devm_request_mem_region(&pdev->dev, r->start, | 110 | if (!devm_request_mem_region(&pdev->dev, r->start, |
@@ -120,11 +120,11 @@ static int bcm63xx_rng_probe(struct platform_device *pdev) | |||
120 | return -ENOMEM; | 120 | return -ENOMEM; |
121 | } | 121 | } |
122 | 122 | ||
123 | error = devm_hwrng_register(&pdev->dev, &priv->rng); | 123 | ret = devm_hwrng_register(&pdev->dev, &priv->rng); |
124 | if (error) { | 124 | if (ret) { |
125 | dev_err(&pdev->dev, "failed to register rng device: %d\n", | 125 | dev_err(&pdev->dev, "failed to register rng device: %d\n", |
126 | error); | 126 | ret); |
127 | return error; | 127 | return ret; |
128 | } | 128 | } |
129 | 129 | ||
130 | dev_info(&pdev->dev, "registered RNG driver\n"); | 130 | dev_info(&pdev->dev, "registered RNG driver\n"); |