gpu: nvgpu: Remove bios_blob debugfs

linux/debugfs.h was included in gk20a.h because of the debugfs entry
bios_blob, which can be used for checking contents of VBIOS. That
has never been used, so instead of abstracting it, this patch removes
the feature altogether.

Two files were using debugfs but did not #include <linux/debugfs.h>.
They failed to build now that gk20a.h no longer #includes it, so
added explit #include.

JIRA NVGPU-259

Change-Id: Ie1ea9be1a8920441b1616f34e64e505e6e10e38c
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1570404
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
Terje Bergstrom
2017-09-28 10:49:06 -07:00
committed by mobile promotions
parent 7685f60d9d
commit 30b9cbe35a
4 changed files with 6 additions and 31 deletions

View File

@@ -28,6 +28,9 @@
#include <linux/llist.h>
#include <linux/uaccess.h>
#include <linux/poll.h>
#ifdef CONFIG_DEBUG_FS
#include <linux/debugfs.h>
#endif
#include <nvgpu/bitops.h>
#include <nvgpu/lock.h>

View File

@@ -45,9 +45,6 @@ struct nvgpu_mem_sgt;
#include <nvgpu/lock.h>
#include <nvgpu/thread.h>
#include <nvgpu/io.h>
#ifdef CONFIG_DEBUG_FS
#include <linux/debugfs.h>
#endif
#include <nvgpu/as.h>
#include <nvgpu/log.h>
@@ -1239,9 +1236,6 @@ struct gk20a {
u32 tpc_fs_mask_user;
struct nvgpu_bios bios;
#ifdef CONFIG_DEBUG_FS
struct debugfs_blob_wrapper bios_blob;
#endif
bool bios_is_init;
struct nvgpu_clk_arb *clk_arb;

View File

@@ -31,9 +31,6 @@
#include "gm20b/fifo_gm20b.h"
#include "bios_gp106.h"
#include "gp106/mclk_gp106.h"
#ifdef CONFIG_DEBUG_FS
#include "common/linux/os_linux.h"
#endif
#include <nvgpu/hw/gp106/hw_pwr_gp106.h>
#include <nvgpu/hw/gp106/hw_mc_gp106.h>
@@ -187,10 +184,6 @@ out:
int gp106_bios_init(struct gk20a *g)
{
unsigned int i;
#ifdef CONFIG_DEBUG_FS
struct nvgpu_os_linux *l = nvgpu_os_linux_from_gk20a(g);
struct dentry *d;
#endif
int err;
gk20a_dbg_fn("");
@@ -232,40 +225,24 @@ int gp106_bios_init(struct gk20a *g)
g->power_sensor_missing = true;
}
#ifdef CONFIG_DEBUG_FS
g->bios_blob.data = g->bios.data;
g->bios_blob.size = g->bios.size;
d = debugfs_create_blob("bios", S_IRUGO, l->debugfs,
&g->bios_blob);
if (!d) {
err = -EINVAL;
nvgpu_err(g, "No debugfs?");
goto free_firmware;
}
#endif
gk20a_dbg_fn("done");
err = gp106_bios_devinit(g);
if (err) {
nvgpu_err(g, "devinit failed");
goto free_debugfs;
goto free_firmware;
}
if (nvgpu_is_enabled(g, NVGPU_PMU_RUN_PREOS)) {
err = gp106_bios_preos(g);
if (err) {
nvgpu_err(g, "pre-os failed");
goto free_debugfs;
goto free_firmware;
}
}
g->bios_is_init = true;
return 0;
free_debugfs:
#ifdef CONFIG_DEBUG_FS
debugfs_remove(d);
#endif
free_firmware:
if (g->bios.data)
nvgpu_vfree(g, g->bios.data);

View File

@@ -27,6 +27,7 @@
#include "gk20a/gk20a.h"
#ifdef CONFIG_DEBUG_FS
#include <linux/debugfs.h>
#include "common/linux/os_linux.h"
#endif
#include "gp106/mclk_gp106.h"