File tree 1 file changed +8
-3
lines changed
drivers/net/wireless/intel/iwlwifi/mvm
1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change 5
5
* Copyright (C) 2016-2017 Intel Deutschland GmbH
6
6
*/
7
7
#include <linux/vmalloc.h>
8
+ #include <linux/err.h>
8
9
#include <linux/ieee80211.h>
9
10
#include <linux/netdevice.h>
10
11
@@ -1857,7 +1858,6 @@ void iwl_mvm_sta_add_debugfs(struct ieee80211_hw *hw,
1857
1858
void iwl_mvm_dbgfs_register (struct iwl_mvm * mvm )
1858
1859
{
1859
1860
struct dentry * bcast_dir __maybe_unused ;
1860
- char buf [100 ];
1861
1861
1862
1862
spin_lock_init (& mvm -> drv_stats_lock );
1863
1863
@@ -1939,6 +1939,11 @@ void iwl_mvm_dbgfs_register(struct iwl_mvm *mvm)
1939
1939
* Create a symlink with mac80211. It will be removed when mac80211
1940
1940
* exists (before the opmode exists which removes the target.)
1941
1941
*/
1942
- snprintf (buf , 100 , "../../%pd2" , mvm -> debugfs_dir -> d_parent );
1943
- debugfs_create_symlink ("iwlwifi" , mvm -> hw -> wiphy -> debugfsdir , buf );
1942
+ if (!IS_ERR (mvm -> debugfs_dir )) {
1943
+ char buf [100 ];
1944
+
1945
+ snprintf (buf , 100 , "../../%pd2" , mvm -> debugfs_dir -> d_parent );
1946
+ debugfs_create_symlink ("iwlwifi" , mvm -> hw -> wiphy -> debugfsdir ,
1947
+ buf );
1948
+ }
1944
1949
}
You can’t perform that action at this time.
0 commit comments