mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Arend van Spriel <arend.vanspriel@broadcom.com>
To: Ragul Balaji <ragulbaby@gmail.com>
Cc: linux-wireless@vger.kernel.org,
	Arend van Spriel <arend.vanspriel@broadcom.com>,
	Johannes Berg <johannes@sipsolutions.net>,
	brcm80211@lists.linux.dev, Ho Jie Feng <hjf3108@gmail.com>,
	brcm80211-dev-list.pdl@broadcom.com,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH wireless-next v2 09/11] wifi: brcm80211: move the rate helpers of brcmsmac to brcmutil
Date: Thu,  3 Dec 2026 10:14:44 +0100	[thread overview]
Message-ID: <20261203091446.3360602-10-arend.vanspriel@broadcom.com> (raw)
In-Reply-To: <20261127061147.506129-10-ragulbaby@gmail.com>

On Fri, 27 Nov 2026 14:11:39 +0800, Ragul Balaji <ragulbaby@gmail.com> wrote:
> Move rate.c to brcmutil in preparation for the new driver.
>
> PHYTYPE_IS() depends on the PHY configuration of brcmsmac, so
> brcmu_rateset_default() compares the PHY types directly, which is the
> same for the N and LCN PHYs that brcmsmac attaches. brcmu_ofdm_rates
> is only used in rate.c and becomes static.
>
> Signed-off-by: Ragul Balaji <ragulbaby@gmail.com>
> Signed-off-by: Ho Jie Feng <hjf3108@gmail.com>
> ---
>  .../broadcom/brcm80211/brcmsmac/Makefile      |   1 -
>  .../broadcom/brcm80211/brcmsmac/ampdu.c       |   2 +-
>  .../broadcom/brcm80211/brcmsmac/main.c        |   2 +-
>  .../broadcom/brcm80211/brcmsmac/pub.h         |  25 +--
>  .../broadcom/brcm80211/brcmsmac/stf.c         |   2 +-
>  .../broadcom/brcm80211/brcmutil/Makefile      |   2 +-
>  .../brcm80211/{brcmsmac => brcmutil}/rate.c   | 142 +++++++++++-------
>  .../{brcmsmac/rate.h => include/brcmu_rate.h} |  38 +++--
>  8 files changed, 118 insertions(+), 96 deletions(-)
>  rename drivers/net/wireless/broadcom/brcm80211/{brcmsmac => brcmutil}/rate.c (85%)
>  rename drivers/net/wireless/broadcom/brcm80211/{brcmsmac/rate.h => include/brcmu_rate.h} (89%)

Besides the move this patch converts CEIL() to DIV_ROUND_UP(), changes
several conditions, makes symbols static and adds exports. Please do the
conversions in brcmsmac before the move so the move is easier to review,
or at least list all of them in the commit message.

The shared header also retains names such as struct brcms_c_rateset,
struct brcms_mcs_info and BRCMS_* rate macros. Please complete the
brcms-to-brcmu naming conversion for the shared API.

[...]

> @@ -7,4 +7,4 @@
>  ccflags-y := -I $(src)/../include
>  
>  obj-$(CONFIG_BRCMUTIL)	+= brcmutil.o
> -brcmutil-objs	= utils.o d11.o
> +brcmutil-objs	= utils.o d11.o rate.o

brcmfmac also selects BRCMUTIL, so brcmfmac-only configurations now carry
rate.o and, after patch 10, band.o without using them. Please make these
objects conditional on a driver that needs the shared helpers.

Regards,
Arend

  reply	other threads:[~2026-12-03  9:15 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20261127061147.506129-1-ragulbaby@gmail.com>
2026-11-27  6:11 ` [PATCH wireless-next v2 01/11] wifi: brcmsmac: make d11.h self-contained Ragul Balaji
2026-12-03  9:14   ` Arend van Spriel
2026-11-27  6:11 ` [PATCH wireless-next v2 02/11] wifi: brcm80211: move d11.h to the shared include directory Ragul Balaji
2026-12-03  9:14   ` Arend van Spriel
2026-11-27  6:11 ` [PATCH wireless-next v2 03/11] wifi: brcmsmac: look up OFDM rates in rate.c Ragul Balaji
2026-12-03  9:14   ` Arend van Spriel
2026-11-27  6:11 ` [PATCH wireless-next v2 04/11] wifi: brcmsmac: give the rate tables and helpers a brcmu_ prefix Ragul Balaji
2026-12-03  9:14   ` Arend van Spriel
2026-11-27  6:11 ` [PATCH wireless-next v2 05/11] wifi: brcmsmac: round short-GI L-SIG lengths up to whole symbols Ragul Balaji
2026-12-03  9:14   ` Arend van Spriel
2026-11-27  6:11 ` [PATCH wireless-next v2 06/11] wifi: brcmsmac: pass the band to the PLCP and frame timing helpers Ragul Balaji
2026-12-03  9:14   ` Arend van Spriel
2026-11-27  6:11 ` [PATCH wireless-next v2 07/11] wifi: brcmsmac: move the PLCP and frame timing helpers to rate.c Ragul Balaji
2026-12-03  9:14   ` Arend van Spriel
2026-11-27  6:11 ` [PATCH wireless-next v2 08/11] wifi: brcmsmac: move the RTS rate selection " Ragul Balaji
2026-12-03  9:14   ` Arend van Spriel
2026-11-27  6:11 ` [PATCH wireless-next v2 09/11] wifi: brcm80211: move the rate helpers of brcmsmac to brcmutil Ragul Balaji
2026-12-03  9:14   ` Arend van Spriel [this message]
2026-11-27  6:11 ` [PATCH wireless-next v2 10/11] wifi: brcm80211: move the channel and rate tables " Ragul Balaji
2026-12-03  9:14   ` Arend van Spriel
2026-11-27  6:11 ` [PATCH wireless-next v2 11/11] wifi: brcm80211: move the USB bootloader definitions to a shared header Ragul Balaji
2026-12-03  9:14   ` Arend van Spriel

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=20261203091446.3360602-10-arend.vanspriel@broadcom.com \
    --to=arend.vanspriel@broadcom.com \
    --cc=brcm80211-dev-list.pdl@broadcom.com \
    --cc=brcm80211@lists.linux.dev \
    --cc=hjf3108@gmail.com \
    --cc=johannes@sipsolutions.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=ragulbaby@gmail.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

all inboxes | Powered by JetHome®