2 * Ralink SoC ethernet driver debugfs code
4 * Copyright (C) 2011-2012 Gabor Juhos <juhosg@openwrt.org>
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License version 2 as published
8 * by the Free Software Foundation.
11 #include <linux/debugfs.h>
12 #include <linux/phy.h>
14 #include "ramips_eth.h"
16 static struct dentry *raeth_debugfs_root;
18 void raeth_debugfs_exit(struct raeth_priv *re)
20 debugfs_remove_recursive(re->debug.debugfs_dir);
23 int raeth_debugfs_init(struct raeth_priv *re)
25 re->debug.debugfs_dir = debugfs_create_dir(re->netdev->name,
27 if (!re->debug.debugfs_dir)
33 int raeth_debugfs_root_init(void)
35 if (raeth_debugfs_root)
38 raeth_debugfs_root = debugfs_create_dir("raeth", NULL);
39 if (!raeth_debugfs_root)
45 void raeth_debugfs_root_exit(void)
47 debugfs_remove(raeth_debugfs_root);
48 raeth_debugfs_root = NULL;