From: Michal Swiatkowski <michal.swiatkowski@linux.intel.com>
To: intel-wired-lan@lists.osuosl.org
Cc: netdev@vger.kernel.org, przemyslaw.kitszel@intel.com,
dawid.osuchowski@linux.intel.com,
Michal Swiatkowski <michal.swiatkowski@linux.intel.com>,
Larysa Zaremba <larysa.zaremba@intel.com>
Subject: [PATCH iwl-next v1 03/15] ice: drop ice_pf_fwlog_update_module()
Date: Tue, 22 Jul 2025 12:45:48 +0200 [thread overview]
Message-ID: <20250722104600.10141-4-michal.swiatkowski@linux.intel.com> (raw)
In-Reply-To: <20250722104600.10141-1-michal.swiatkowski@linux.intel.com>
Any other access to fwlog_cfg isn't done through a function. Follow
scheme that is used to access other fwlog_cfg elements from debugfs and
write to the log_level directly.
ice_pf_fwlog_update_module() is called only twice (from one function).
Remove it.
Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
Reviewed-by: Larysa Zaremba <larysa.zaremba@intel.com>
Signed-off-by: Michal Swiatkowski <michal.swiatkowski@linux.intel.com>
---
drivers/net/ethernet/intel/ice/ice.h | 1 -
drivers/net/ethernet/intel/ice/ice_debugfs.c | 5 +++--
drivers/net/ethernet/intel/ice/ice_main.c | 13 -------------
3 files changed, 3 insertions(+), 16 deletions(-)
diff --git a/drivers/net/ethernet/intel/ice/ice.h b/drivers/net/ethernet/intel/ice/ice.h
index e952d67388bf..a6803b344540 100644
--- a/drivers/net/ethernet/intel/ice/ice.h
+++ b/drivers/net/ethernet/intel/ice/ice.h
@@ -912,7 +912,6 @@ void ice_debugfs_fwlog_init(struct ice_pf *pf);
void ice_debugfs_pf_deinit(struct ice_pf *pf);
void ice_debugfs_init(void);
void ice_debugfs_exit(void);
-void ice_pf_fwlog_update_module(struct ice_pf *pf, int log_level, int module);
bool netif_is_ice(const struct net_device *dev);
int ice_vsi_setup_tx_rings(struct ice_vsi *vsi);
diff --git a/drivers/net/ethernet/intel/ice/ice_debugfs.c b/drivers/net/ethernet/intel/ice/ice_debugfs.c
index cb71eca6a85b..170050548e74 100644
--- a/drivers/net/ethernet/intel/ice/ice_debugfs.c
+++ b/drivers/net/ethernet/intel/ice/ice_debugfs.c
@@ -164,6 +164,7 @@ ice_debugfs_module_write(struct file *filp, const char __user *buf,
struct ice_pf *pf = file_inode(filp)->i_private;
struct dentry *dentry = file_dentry(filp);
struct device *dev = ice_pf_to_dev(pf);
+ struct ice_hw *hw = &pf->hw;
char user_val[16], *cmd_buf;
int module, log_level, cnt;
@@ -192,7 +193,7 @@ ice_debugfs_module_write(struct file *filp, const char __user *buf,
}
if (module != ICE_AQC_FW_LOG_ID_MAX) {
- ice_pf_fwlog_update_module(pf, log_level, module);
+ hw->fwlog_cfg.module_entries[module].log_level = log_level;
} else {
/* the module 'all' is a shortcut so that we can set
* all of the modules to the same level quickly
@@ -200,7 +201,7 @@ ice_debugfs_module_write(struct file *filp, const char __user *buf,
int i;
for (i = 0; i < ICE_AQC_FW_LOG_ID_MAX; i++)
- ice_pf_fwlog_update_module(pf, log_level, i);
+ hw->fwlog_cfg.module_entries[i].log_level = log_level;
}
return count;
diff --git a/drivers/net/ethernet/intel/ice/ice_main.c b/drivers/net/ethernet/intel/ice/ice_main.c
index c2101853adf8..7f72b8d09d79 100644
--- a/drivers/net/ethernet/intel/ice/ice_main.c
+++ b/drivers/net/ethernet/intel/ice/ice_main.c
@@ -4620,19 +4620,6 @@ static void ice_print_wake_reason(struct ice_pf *pf)
dev_info(ice_pf_to_dev(pf), "Wake reason: %s", wake_str);
}
-/**
- * ice_pf_fwlog_update_module - update 1 module
- * @pf: pointer to the PF struct
- * @log_level: log_level to use for the @module
- * @module: module to update
- */
-void ice_pf_fwlog_update_module(struct ice_pf *pf, int log_level, int module)
-{
- struct ice_hw *hw = &pf->hw;
-
- hw->fwlog_cfg.module_entries[module].log_level = log_level;
-}
-
/**
* ice_register_netdev - register netdev
* @vsi: pointer to the VSI struct
--
2.49.0
next prev parent reply other threads:[~2025-07-22 11:07 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-22 10:45 [PATCH iwl-next v1 00/15] Fwlog support in ixgbe Michal Swiatkowski
2025-07-22 10:45 ` [PATCH iwl-next v1 01/15] ice: make fwlog functions static Michal Swiatkowski
2025-07-22 11:58 ` [Intel-wired-lan] " Loktionov, Aleksandr
2025-07-22 10:45 ` [PATCH iwl-next v1 02/15] ice: move get_fwlog_data() to fwlog file Michal Swiatkowski
2025-07-22 12:02 ` [Intel-wired-lan] " Loktionov, Aleksandr
2025-07-23 4:48 ` Michal Swiatkowski
2025-07-22 10:45 ` Michal Swiatkowski [this message]
2025-07-22 12:06 ` [Intel-wired-lan] [PATCH iwl-next v1 03/15] ice: drop ice_pf_fwlog_update_module() Loktionov, Aleksandr
2025-07-22 10:45 ` [PATCH iwl-next v1 04/15] ice: introduce ice_fwlog structure Michal Swiatkowski
2025-07-22 12:17 ` [Intel-wired-lan] " Loktionov, Aleksandr
2025-07-22 10:45 ` [PATCH iwl-next v1 05/15] ice: add pdev into fwlog structure and use it for logging Michal Swiatkowski
2025-07-23 10:36 ` [Intel-wired-lan] " Loktionov, Aleksandr
2025-07-22 10:45 ` [PATCH iwl-next v1 06/15] ice: allow calling custom send function in fwlog Michal Swiatkowski
2025-07-22 10:45 ` [PATCH iwl-next v1 07/15] ice: move out debugfs init from fwlog Michal Swiatkowski
2025-07-22 10:45 ` [PATCH iwl-next v1 08/15] ice: check for PF number outside the fwlog code Michal Swiatkowski
2025-07-23 10:38 ` [Intel-wired-lan] " Loktionov, Aleksandr
2025-07-22 10:45 ` [PATCH iwl-next v1 09/15] ice: drop driver specific structure from " Michal Swiatkowski
2025-07-22 14:54 ` Simon Horman
2025-07-23 4:47 ` Michal Swiatkowski
2025-07-23 10:42 ` [Intel-wired-lan] " Loktionov, Aleksandr
2025-07-22 10:45 ` [PATCH iwl-next v1 10/15] libie, ice: move fwlog admin queue to libie Michal Swiatkowski
2025-07-22 10:45 ` [PATCH iwl-next v1 11/15] ice: move debugfs code to fwlog Michal Swiatkowski
2025-07-22 10:45 ` [PATCH iwl-next v1 12/15] ice: prepare for moving file to libie Michal Swiatkowski
2025-07-22 10:45 ` [PATCH iwl-next v1 13/15] ice: reregister fwlog after driver reinit Michal Swiatkowski
2025-07-22 10:45 ` [PATCH iwl-next v1 14/15] ice, libie: move fwlog code to libie Michal Swiatkowski
2025-07-22 10:46 ` [PATCH iwl-next v1 15/15] ixgbe: fwlog support for e610 Michal Swiatkowski
2025-07-23 0:45 ` [Intel-wired-lan] " kernel test robot
2025-07-23 12:12 ` [PATCH iwl-next v1 00/15] Fwlog support in ixgbe Jiri Pirko
2025-07-23 12:48 ` Michal Swiatkowski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250722104600.10141-4-michal.swiatkowski@linux.intel.com \
--to=michal.swiatkowski@linux.intel.com \
--cc=dawid.osuchowski@linux.intel.com \
--cc=intel-wired-lan@lists.osuosl.org \
--cc=larysa.zaremba@intel.com \
--cc=netdev@vger.kernel.org \
--cc=przemyslaw.kitszel@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).