Commit a182dfab authored by Luca Coelho's avatar Luca Coelho Committed by Kalle Valo
Browse files

iwlwifi: add trans op to set PNVM

parent b3e4c0f3
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -568,6 +568,8 @@ struct iwl_trans_rxq_dma_data {
 *	Note that the transport must fill in the proper file headers.
 * @debugfs_cleanup: used in the driver unload flow to make a proper cleanup
 *	of the trans debugfs
 * @set_pnvm: set the pnvm data in the prph scratch buffer, inside the
 *	context info.
 */
struct iwl_trans_ops {

@@ -640,6 +642,7 @@ struct iwl_trans_ops {
						 u32 dump_mask);
	void (*debugfs_cleanup)(struct iwl_trans *trans);
	void (*sync_nmi)(struct iwl_trans *trans);
	int (*set_pnvm)(struct iwl_trans *trans, const void *data, u32 len);
};

/**
@@ -1449,6 +1452,15 @@ static inline void iwl_trans_sync_nmi(struct iwl_trans *trans)
		trans->ops->sync_nmi(trans);
}

static inline int iwl_trans_set_pnvm(struct iwl_trans *trans,
				     const void *data, u32 len)
{
	if (trans->ops->set_pnvm)
		return trans->ops->set_pnvm(trans, data, len);

	return 0;
}

static inline bool iwl_trans_dbg_ini_valid(struct iwl_trans *trans)
{
	return trans->dbg.internal_ini_cfg != IWL_INI_CFG_STATE_NOT_LOADED ||