diff options
author | Kevin Hilman <khilman@ti.com> | 2011-04-05 14:39:11 -0700 |
---|---|---|
committer | Kevin Hilman <khilman@ti.com> | 2011-09-15 12:09:07 -0700 |
commit | 633ef8b7475a224b6be662d7c698cd705157064f (patch) | |
tree | 03b219463824f61398fd358e84bc6d9c80fda951 /arch/arm/mach-omap2/voltage.c | |
parent | b7ea803e55769768d1eff3b32e4f99837fa6ddb5 (diff) |
OMAP3+: voltage: remove unneeded debugfs interface
Remove read-only debugfs interface to VP values. Most of the values
are init-time only and never change. Current voltage value should be
retreived from the (eventual) regulator framework interface to the
voltage domain.
Fixes to original version provided by Nishanth Menon <nm@ti.com>
Signed-off-by: Kevin Hilman <khilman@ti.com>
Diffstat (limited to 'arch/arm/mach-omap2/voltage.c')
-rw-r--r-- | arch/arm/mach-omap2/voltage.c | 78 |
1 files changed, 0 insertions, 78 deletions
diff --git a/arch/arm/mach-omap2/voltage.c b/arch/arm/mach-omap2/voltage.c index c22b53c42193..eaa5f93021ae 100644 --- a/arch/arm/mach-omap2/voltage.c +++ b/arch/arm/mach-omap2/voltage.c @@ -43,9 +43,6 @@ static LIST_HEAD(voltdm_list); -#define VOLTAGE_DIR_SIZE 16 -static struct dentry *voltage_dir; - static int __init _config_common_vdd_data(struct voltagedomain *voltdm) { char *sys_ck_name; @@ -102,51 +99,6 @@ static int __init _config_common_vdd_data(struct voltagedomain *voltdm) return 0; } -static int nom_volt_debug_get(void *data, u64 *val) -{ - struct voltagedomain *voltdm = (struct voltagedomain *)data; - - if (!voltdm) { - pr_warning("Wrong paramater passed\n"); - return -EINVAL; - } - - *val = omap_voltage_get_nom_volt(voltdm); - - return 0; -} - -DEFINE_SIMPLE_ATTRIBUTE(nom_volt_debug_fops, nom_volt_debug_get, NULL, - "%llu\n"); -static void __init vdd_debugfs_init(struct voltagedomain *voltdm) -{ - char *name; - struct omap_vdd_info *vdd = voltdm->vdd; - - name = kzalloc(VOLTAGE_DIR_SIZE, GFP_KERNEL); - if (!name) { - pr_warning("%s: Unable to allocate memory for debugfs" - " directory name for vdd_%s", - __func__, voltdm->name); - return; - } - strcpy(name, "vdd_"); - strcat(name, voltdm->name); - - vdd->debug_dir = debugfs_create_dir(name, voltage_dir); - kfree(name); - if (IS_ERR(vdd->debug_dir)) { - pr_warning("%s: Unable to create debugfs directory for" - " vdd_%s\n", __func__, voltdm->name); - vdd->debug_dir = NULL; - return; - } - - (void) debugfs_create_file("curr_nominal_volt", S_IRUGO, - vdd->debug_dir, (void *) voltdm, - &nom_volt_debug_fops); -} - static int __init omap_vdd_data_configure(struct voltagedomain *voltdm) { int ret = -EINVAL; @@ -342,31 +294,6 @@ int omap_voltage_register_pmic(struct voltagedomain *voltdm, } /** - * omap_voltage_get_dbgdir() - API to get pointer to the debugfs directory - * corresponding to a voltage domain. - * - * @voltdm: pointer to the VDD whose debug directory is required. - * - * This API returns pointer to the debugfs directory corresponding - * to the voltage domain. Should be used by drivers requiring to - * add any debug entry for a particular voltage domain. Returns NULL - * in case of error. - */ -struct dentry *omap_voltage_get_dbgdir(struct voltagedomain *voltdm) -{ - struct omap_vdd_info *vdd; - - if (!voltdm || IS_ERR(voltdm)) { - pr_warning("%s: VDD specified does not exist!\n", __func__); - return NULL; - } - - vdd = voltdm->vdd; - - return vdd->debug_dir; -} - -/** * omap_change_voltscale_method() - API to change the voltage scaling method. * @voltdm: pointer to the VDD whose voltage scaling method * has to be changed. @@ -418,10 +345,6 @@ int __init omap_voltage_late_init(void) return -EINVAL; } - voltage_dir = debugfs_create_dir("voltage", NULL); - if (IS_ERR(voltage_dir)) - pr_err("%s: Unable to create voltage debugfs main dir\n", - __func__); list_for_each_entry(voltdm, &voltdm_list, node) { if (!voltdm->scalable) continue; @@ -434,7 +357,6 @@ int __init omap_voltage_late_init(void) if (voltdm->vdd) { if (omap_vdd_data_configure(voltdm)) continue; - vdd_debugfs_init(voltdm); omap_vp_init(voltdm); } } |