Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7a3a51ab authored by Dan Carpenter's avatar Dan Carpenter Committed by Darren Hart (VMware)
Browse files

platform/x86: intel_telemetry_debugfs: fix some error codes in init



There are bunch of "goto out;" paths where we don't set the error code.

Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
parent 74a1eb56
Loading
Loading
Loading
Loading
+3 −4
Original line number Diff line number Diff line
@@ -938,7 +938,7 @@ static struct notifier_block pm_notifier = {
static int __init telemetry_debugfs_init(void)
{
	const struct x86_cpu_id *id;
	int err = -ENOMEM;
	int err;
	struct dentry *f;

	/* Only APL supported for now */
@@ -958,11 +958,10 @@ static int __init telemetry_debugfs_init(void)

	register_pm_notifier(&pm_notifier);

	debugfs_conf->telemetry_dbg_dir = debugfs_create_dir("telemetry", NULL);
	if (!debugfs_conf->telemetry_dbg_dir) {
	err = -ENOMEM;
	debugfs_conf->telemetry_dbg_dir = debugfs_create_dir("telemetry", NULL);
	if (!debugfs_conf->telemetry_dbg_dir)
		goto out_pm;
	}

	f = debugfs_create_file("pss_info", S_IFREG | S_IRUGO,
				debugfs_conf->telemetry_dbg_dir, NULL,