Commit 0f8bf03c authored by Luca Coelho's avatar Luca Coelho

iwlwifi: mvm: save and export regdb blob from the NVM

Sometimes we want to debug issues related to the regulatory blob in
the NVM.  To make that easier, add a debugfs entry to export it
together with the other nvm blobs we export.
Signed-off-by: default avatarLuca Coelho <luciano.coelho@intel.com>
parent e6aeeb4f
...@@ -2028,6 +2028,9 @@ int iwl_mvm_dbgfs_register(struct iwl_mvm *mvm, struct dentry *dbgfs_dir) ...@@ -2028,6 +2028,9 @@ int iwl_mvm_dbgfs_register(struct iwl_mvm *mvm, struct dentry *dbgfs_dir)
if (!debugfs_create_blob("nvm_phy_sku", 0400, if (!debugfs_create_blob("nvm_phy_sku", 0400,
mvm->debugfs_dir, &mvm->nvm_phy_sku_blob)) mvm->debugfs_dir, &mvm->nvm_phy_sku_blob))
goto err; goto err;
if (!debugfs_create_blob("nvm_reg", S_IRUSR,
mvm->debugfs_dir, &mvm->nvm_reg_blob))
goto err;
debugfs_create_file("mem", 0600, dbgfs_dir, mvm, &iwl_dbgfs_mem_ops); debugfs_create_file("mem", 0600, dbgfs_dir, mvm, &iwl_dbgfs_mem_ops);
......
...@@ -965,6 +965,7 @@ struct iwl_mvm { ...@@ -965,6 +965,7 @@ struct iwl_mvm {
struct debugfs_blob_wrapper nvm_calib_blob; struct debugfs_blob_wrapper nvm_calib_blob;
struct debugfs_blob_wrapper nvm_prod_blob; struct debugfs_blob_wrapper nvm_prod_blob;
struct debugfs_blob_wrapper nvm_phy_sku_blob; struct debugfs_blob_wrapper nvm_phy_sku_blob;
struct debugfs_blob_wrapper nvm_reg_blob;
struct iwl_mvm_frame_stats drv_rx_stats; struct iwl_mvm_frame_stats drv_rx_stats;
spinlock_t drv_stats_lock; spinlock_t drv_stats_lock;
......
...@@ -416,6 +416,11 @@ int iwl_nvm_init(struct iwl_mvm *mvm) ...@@ -416,6 +416,11 @@ int iwl_nvm_init(struct iwl_mvm *mvm)
mvm->nvm_phy_sku_blob.data = temp; mvm->nvm_phy_sku_blob.data = temp;
mvm->nvm_phy_sku_blob.size = ret; mvm->nvm_phy_sku_blob.size = ret;
break; break;
case NVM_SECTION_TYPE_REGULATORY_SDP:
case NVM_SECTION_TYPE_REGULATORY:
mvm->nvm_reg_blob.data = temp;
mvm->nvm_reg_blob.size = ret;
break;
default: default:
if (section == mvm->cfg->nvm_hw_section_num) { if (section == mvm->cfg->nvm_hw_section_num) {
mvm->nvm_hw_blob.data = temp; mvm->nvm_hw_blob.data = temp;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment