Skip to content

Commit 6584b9d

Browse files
egrumbachjmberg-intel
authored andcommitted
wifi: iwlwifi: move code from iwl-eeprom-parse to dvm
Move code that is DVM only to dvm. Signed-off-by: Emmanuel Grumbach <[email protected]> Signed-off-by: Miri Korenblit <[email protected]> Link: https://msgid.link/20240512152312.9a1b6ef116e0.I217a513f544d5288a7760d265f51419e81abfd9d@changeid Signed-off-by: Johannes Berg <[email protected]>
1 parent b476564 commit 6584b9d

File tree

16 files changed

+903
-910
lines changed

16 files changed

+903
-910
lines changed

drivers/net/wireless/intel/iwlwifi/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ obj-$(CONFIG_IWLWIFI) += iwlwifi.o
44
iwlwifi-objs += iwl-io.o
55
iwlwifi-objs += iwl-drv.o
66
iwlwifi-objs += iwl-debug.o
7-
iwlwifi-objs += iwl-eeprom-parse.o
7+
iwlwifi-objs += iwl-nvm-utils.o
88
iwlwifi-objs += iwl-phy-db.o iwl-nvm-parse.o
99
iwlwifi-objs += pcie/drv.o pcie/rx.o pcie/tx.o pcie/trans.o
1010
iwlwifi-objs += pcie/ctxt-info.o pcie/ctxt-info-gen3.o

drivers/net/wireless/intel/iwlwifi/dvm/agn.h

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -385,6 +385,23 @@ static inline void iwl_dvm_set_pmi(struct iwl_priv *priv, bool state)
385385
iwl_trans_set_pmi(priv->trans, state);
386386
}
387387

388+
/**
389+
* iwl_parse_eeprom_data - parse EEPROM data and return values
390+
*
391+
* @trans: ransport we're parsing for, for debug only
392+
* @cfg: device configuration for parsing and overrides
393+
* @eeprom: the EEPROM data
394+
* @eeprom_size: length of the EEPROM data
395+
*
396+
* This function parses all EEPROM values we need and then
397+
* returns a (newly allocated) struct containing all the
398+
* relevant values for driver use. The struct must be freed
399+
* later with iwl_free_nvm_data().
400+
*/
401+
struct iwl_nvm_data *
402+
iwl_parse_eeprom_data(struct iwl_trans *trans, const struct iwl_cfg *cfg,
403+
const u8 *eeprom, size_t eeprom_size);
404+
388405
int iwl_read_eeprom(struct iwl_trans *trans, u8 **eeprom, size_t *eeprom_size);
389406

390407
#ifdef CONFIG_IWLWIFI_DEBUGFS

drivers/net/wireless/intel/iwlwifi/dvm/dev.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
#include <linux/mutex.h>
2020

2121
#include "fw/img.h"
22-
#include "iwl-eeprom-parse.h"
22+
#include "iwl-nvm-utils.h"
2323
#include "iwl-csr.h"
2424
#include "iwl-debug.h"
2525
#include "iwl-agn-hw.h"

drivers/net/wireless/intel/iwlwifi/dvm/devices.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
*/
1313
#include "iwl-io.h"
1414
#include "iwl-prph.h"
15-
#include "iwl-eeprom-parse.h"
15+
#include "iwl-nvm-utils.h"
1616

1717
#include "agn.h"
1818
#include "dev.h"

0 commit comments

Comments
 (0)