Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 316624
b: refs/heads/master
c: 9f1612d
h: refs/heads/master
v: v3
  • Loading branch information
Shawn Guo authored and Mike Turquette committed Jul 19, 2012
1 parent eead2cb commit 4fd9a48
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 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: c782c384d289a382baf4a1ab544f6f4b9e72405b
refs/heads/master: 9f1612d351a8e57d3d694e828641d3e4eeb224f8
2 changes: 1 addition & 1 deletion trunk/drivers/clk/clkdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ struct clk *clk_get(struct device *dev, const char *con_id)

if (dev) {
clk = of_clk_get_by_name(dev->of_node, con_id);
if (clk && __clk_get(clk))
if (!IS_ERR(clk) && __clk_get(clk))
return clk;
}

Expand Down
5 changes: 3 additions & 2 deletions trunk/include/linux/clk.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
#ifndef __LINUX_CLK_H
#define __LINUX_CLK_H

#include <linux/err.h>
#include <linux/kernel.h>
#include <linux/notifier.h>

Expand Down Expand Up @@ -320,12 +321,12 @@ struct clk *of_clk_get_from_provider(struct of_phandle_args *clkspec);
#else
static inline struct clk *of_clk_get(struct device_node *np, int index)
{
return NULL;
return ERR_PTR(-ENOENT);
}
static inline struct clk *of_clk_get_by_name(struct device_node *np,
const char *name)
{
return NULL;
return ERR_PTR(-ENOENT);
}
#endif

Expand Down

0 comments on commit 4fd9a48

Please sign in to comment.