staging: wfx: do not display functions names in logs
authorJérôme Pouiller <jerome.pouiller@silabs.com>
Thu, 13 Jan 2022 08:55:18 +0000 (09:55 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 25 Jan 2022 15:19:42 +0000 (16:19 +0100)
It is not necessary to prefix error logs with the function name when an
error message is unique in the code.

Note this patch still prefixes the message 'received event for
non-existent vif' with the function name since it is used several
times.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20220113085524.1110708-26-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/wfx/bh.c
drivers/staging/wfx/data_tx.c
drivers/staging/wfx/hif_rx.c
drivers/staging/wfx/scan.c
drivers/staging/wfx/sta.c

index 1ec4a49..4c6ba9c 100644 (file)
@@ -69,8 +69,7 @@ static int rx_helper(struct wfx_dev *wdev, size_t read_len, int *is_cnf)
        int release_count;
        int piggyback = 0;
 
-       WARN(read_len > round_down(0xFFF, 2) * sizeof(u16),
-            "%s: request exceed the chip capability", __func__);
+       WARN(read_len > round_down(0xFFF, 2) * sizeof(u16), "request exceed the chip capability");
 
        /* Add 2 to take into account piggyback size */
        alloc_len = wdev->hwbus_ops->align_size(wdev->hwbus_priv, read_len + 2);
index bfc3d44..d7bcf3b 100644 (file)
@@ -425,7 +425,7 @@ static void wfx_skb_dtor(struct wfx_vif *wvif, struct sk_buff *skb)
                              req->fc_offset;
 
        if (!wvif) {
-               pr_warn("%s: vif associated with the skb does not exist anymore\n", __func__);
+               pr_warn("vif associated with the skb does not exist anymore\n");
                return;
        }
        wfx_tx_policy_put(wvif, req->retry_policy_index);
index 5300ef5..302bdb2 100644 (file)
@@ -101,8 +101,7 @@ static int wfx_hif_receive_indication(struct wfx_dev *wdev, const struct wfx_hif
        const struct wfx_hif_ind_rx *body = buf;
 
        if (!wvif) {
-               dev_warn(wdev->dev, "%s: ignore rx data for non-existent vif %d\n",
-                        __func__, hif->interface);
+               dev_warn(wdev->dev, "%s: received event for non-existent vif\n", __func__);
                return -EIO;
        }
        skb_pull(skb, sizeof(struct wfx_hif_msg) + sizeof(struct wfx_hif_ind_rx));
index ce0ae4c..7f34f0d 100644 (file)
@@ -94,8 +94,7 @@ void wfx_hw_scan_work(struct work_struct *work)
        mutex_lock(&wvif->wdev->conf_mutex);
        mutex_lock(&wvif->scan_lock);
        if (wvif->join_in_progress) {
-               dev_info(wvif->wdev->dev, "%s: abort in-progress REQ_JOIN",
-                        __func__);
+               dev_info(wvif->wdev->dev, "abort in-progress REQ_JOIN");
                wfx_reset(wvif);
        }
        update_probe_tmpl(wvif, &hw_req->req);
index f64adba..83f1ac8 100644 (file)
@@ -513,13 +513,12 @@ void wfx_bss_info_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
                else if (!info->assoc && vif->type == NL80211_IFTYPE_STATION)
                        wfx_reset(wvif);
                else
-                       dev_warn(wdev->dev, "%s: misunderstood change: ASSOC\n",
-                                __func__);
+                       dev_warn(wdev->dev, "misunderstood change: ASSOC\n");
        }
 
        if (changed & BSS_CHANGED_BEACON_INFO) {
                if (vif->type != NL80211_IFTYPE_STATION)
-                       dev_warn(wdev->dev, "%s: misunderstood change: BEACON_INFO\n", __func__);
+                       dev_warn(wdev->dev, "misunderstood change: BEACON_INFO\n");
                wfx_hif_set_beacon_wakeup_period(wvif, info->dtim_period, info->dtim_period);
                /* We temporary forwarded beacon for join process. It is now no more necessary. */
                wfx_filter_beacon(wvif, true);