mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Rodrigo Gobbi <rodrigo.gobbi.7@gmail.com>
To: dan.carpenter@linaro.org
Cc: gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org,
	linux-staging@lists.linux.dev, philipp.g.hortmann@gmail.com,
	rodrigo.gobbi.7@gmail.com, ~lkcamp/patches@lists.sr.ht
Subject: staging: rtl8723bs: change remaining printk to proper api
Date: Thu, 24 Oct 2024 19:55:12 -0300	[thread overview]
Message-ID: <20241024225512.7464-1-rodrigo.gobbi.7@gmail.com> (raw)
In-Reply-To: <f61d8272-4af3-40d6-a333-e7731c3fc5ae@stanley.mountain>

First, tks for the answer, Dan.

> little broken with -DDBG_RX_SIGNAL_DISPLAY_RAW_DATA, maybe we can 
> fix that in a next patch. 
> How is it broken?

make -j<> ./drivers/staging/rtl8723bs/r8723bs.ko EXTRA_CFLAGS="-DDBG_RX_SIGNAL_DISPLAY_RAW_DATA"

drivers/staging/rtl8723bs/hal/hal_com.c: In function ‘rtw_store_phy_info’:
drivers/staging/rtl8723bs/hal/hal_com.c:927:43: error: ‘PODM_PHY_INFO_T’ undeclared (first use in this function)
  927 |         struct odm_phy_info *pPhyInfo  = (PODM_PHY_INFO_T)(&pattrib->phy_info);
      |                                           ^~~~~~~~~~~~~~~
drivers/staging/rtl8723bs/hal/hal_com.c:927:43: note: each undeclared identifier is reported only once for each function it appears in
drivers/staging/rtl8723bs/hal/hal_com.c:940:73: error: ‘struct odm_phy_info’ has no member named ‘RxPwr’; did you mean ‘rx_pwr’?
  940 |                         psample_pkt_rssi->ofdm_pwr[rf_path] = pPhyInfo->RxPwr[rf_path];
      |                                                                         ^~~~~
      |                                                                         rx_pwr
drivers/staging/rtl8723bs/hal/hal_com.c:941:71: error: ‘struct odm_phy_info’ has no member named ‘RxSNR’
  941 |                         psample_pkt_rssi->ofdm_snr[rf_path] = pPhyInfo->RxSNR[rf_path];

Actually it's not exaclty in the same line of pr_debug/netdev_dbg replacement. Do you think
we can do the replacement at:

> +			pr_debug(", rx_ofdm_pwr:%d(dBm), rx_ofdm_snr:%d(dB)\n",...

regardless of this build errors? I mean, fixing it here in this patch
would not be related to the purpose of this simple patch.

> Just delete this line.
Ok.

> -		printk(KERN_CRIT "%s: sdio_claim_irq FAIL(%d)!\n", __func__, err);
> +		pr_crit("%s: sdio_claim_irq FAIL(%d)!\n", __func__, err);
>                ^^^^^^^?

Originally, I didn't replace this because at dvobj of sdio_alloc_irq(struct dvobj_priv *dvobj)  
there are two adapter fields:

struct dvobj_priv {
	struct adapter *if1; /* PRIMARY_ADAPTER */
...
	struct adapter *padapters;
...
}

Checking the "counter part" function of sdio_alloc_irq(), the sdio_free_irq() (which is not used), 
the if1 (primary) is used for debug purpose:

netdev_err(dvobj->if1->pnetdev...

And checking the initialization path, if1 should be ok at this point.
But since I can't test this, do you suggest to replace anyway?

Tks and regards.

  reply	other threads:[~2024-10-24 22:55 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-23 23:11 [PATCH v3] " Rodrigo Gobbi
2024-10-24  7:28 ` Dan Carpenter
2024-10-24 22:55   ` Rodrigo Gobbi [this message]
2024-10-25  7:19     ` Dan Carpenter
2024-10-29 22:02       ` Rodrigo Gobbi
  -- strict thread matches above, loose matches on Subject: below --
2024-10-22  3:18 [PATCH v2] " Rodrigo Gobbi
2024-10-23 22:48 ` Rodrigo Gobbi

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=20241024225512.7464-1-rodrigo.gobbi.7@gmail.com \
    --to=rodrigo.gobbi.7@gmail.com \
    --cc=dan.carpenter@linaro.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-staging@lists.linux.dev \
    --cc=philipp.g.hortmann@gmail.com \
    --cc=~lkcamp/patches@lists.sr.ht \
    /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

all inboxes | Powered by JetHome®