aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/fmc/fmc-core.c
diff options
context:
space:
mode:
authorFederico Vaga <federico.vaga@cern.ch>2017-07-18 08:33:03 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-08-28 16:24:21 +0200
commit2071a3e94abd34d65bd40f1ff845f9cea300dfa6 (patch)
tree7b115bbaf53ff854af74bc6b907bdd39688adc28 /drivers/fmc/fmc-core.c
parent9f757f415210a7c85e2784e4a1733ea78b2e4e88 (diff)
drivers/fmc: The only way to dump the SDB is from debugfs
Driver should not call fmc_sdb_dump() anymore. (actually they can but the operation is not supported, so it will print an error message) Signed-off-by: Federico Vaga <federico.vaga@cern.ch> Tested-by: Pat Riehecky <riehecky@fnal.gov> Acked-by: Alessandro Rubini <rubini@gnudd.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/fmc/fmc-core.c')
-rw-r--r--drivers/fmc/fmc-core.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/fmc/fmc-core.c b/drivers/fmc/fmc-core.c
index 5263d0607b64..ef6d8acb0a81 100644
--- a/drivers/fmc/fmc-core.c
+++ b/drivers/fmc/fmc-core.c
@@ -13,6 +13,9 @@
#include <linux/init.h>
#include <linux/device.h>
#include <linux/fmc.h>
+#include <linux/fmc-sdb.h>
+
+#include "fmc-private.h"
static int fmc_check_version(unsigned long version, const char *name)
{
@@ -289,7 +292,7 @@ int fmc_device_register_n(struct fmc_device **devs, int n)
}
/* This device went well, give information to the user */
fmc_dump_eeprom(fmc);
- fmc_dump_sdb(fmc);
+ fmc_debug_init(fmc);
}
return 0;
@@ -301,6 +304,7 @@ out:
kfree(devarray);
for (i--; i >= 0; i--) {
+ fmc_debug_exit(devs[i]);
sysfs_remove_bin_file(&devs[i]->dev.kobj, &fmc_eeprom_attr);
device_del(&devs[i]->dev);
fmc_free_id_info(devs[i]);
@@ -328,6 +332,7 @@ void fmc_device_unregister_n(struct fmc_device **devs, int n)
kfree(devs[0]->devarray);
for (i = 0; i < n; i++) {
+ fmc_debug_exit(devs[i]);
sysfs_remove_bin_file(&devs[i]->dev.kobj, &fmc_eeprom_attr);
device_del(&devs[i]->dev);
fmc_free_id_info(devs[i]);

Privacy Policy