Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 344185
b: refs/heads/master
c: 6192713
h: refs/heads/master
i:
  344183: 1e46646
v: v3
  • Loading branch information
Colin Cross authored and Kukjin Kim committed Oct 23, 2012
1 parent 562c2ef commit da9b419
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 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: 52569e2f1747703c1cc6b3b058b0ac11e4288ef5
refs/heads/master: 619271353dd60415b68779c0a87c17568037f5f8
10 changes: 9 additions & 1 deletion trunk/arch/arm/plat-samsung/clock.c
Original file line number Diff line number Diff line change
Expand Up @@ -447,6 +447,14 @@ static const struct file_operations clock_tree_fops = {
.release = single_release,
};

static int clock_rate_show(void *data, u64 *val)
{
struct clk *c = data;
*val = clk_get_rate(c);
return 0;
}
DEFINE_SIMPLE_ATTRIBUTE(clock_rate_fops, clock_rate_show, NULL, "%llu\n");

static int clk_debugfs_register_one(struct clk *c)
{
int err;
Expand All @@ -469,7 +477,7 @@ static int clk_debugfs_register_one(struct clk *c)
goto err_out;
}

d = debugfs_create_u32("rate", S_IRUGO, c->dent, (u32 *)&c->rate);
d = debugfs_create_file("rate", S_IRUGO, c->dent, c, &clock_rate_fops);
if (!d) {
err = -ENOMEM;
goto err_out;
Expand Down

0 comments on commit da9b419

Please sign in to comment.