summaryrefslogtreecommitdiffstats
path: root/drivers/staging/vt6655/card.c
diff options
context:
space:
mode:
authorPhilipp Hortmann <philipp.g.hortmann@gmail.com>2022-08-28 08:53:29 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2022-08-30 17:17:48 +0200
commit52b735c96aab0e1753fe268f2985633608502bce (patch)
tree7e0599e445b00e26609d9de369a64f542ee86658 /drivers/staging/vt6655/card.c
parent87dec3259afb1d821db5deea6ea273ea41951af3 (diff)
downloadlinux-stable-52b735c96aab0e1753fe268f2985633608502bce.tar.gz
linux-stable-52b735c96aab0e1753fe268f2985633608502bce.tar.bz2
linux-stable-52b735c96aab0e1753fe268f2985633608502bce.zip
staging: vt6655: Convert macro MACvSetBBType to function
Convert macro to static function. Multiline macros are not liked by kernel community. Rename variable dwOrgValue to reg_value and byTyp to mask to avoid CamelCase which is not accepted by checkpatch.pl. Change variable declaration to u32 as this improves readability. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/bd512f940427615ed4b134dd04f14095875eec5b.1661666677.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/vt6655/card.c')
-rw-r--r--drivers/staging/vt6655/card.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/staging/vt6655/card.c b/drivers/staging/vt6655/card.c
index bbe05d9538a1..6711743dcf4a 100644
--- a/drivers/staging/vt6655/card.c
+++ b/drivers/staging/vt6655/card.c
@@ -55,6 +55,16 @@ static const unsigned short cwRXBCNTSFOff[MAX_RATE] = {
/*--------------------- Static Functions --------------------------*/
+static void MACvSetBBType(void __iomem *iobase, u32 mask)
+{
+ u32 reg_value;
+
+ reg_value = ioread32(iobase + MAC_REG_ENCFG);
+ reg_value = reg_value & ~ENCFG_BBTYPE_MASK;
+ reg_value = reg_value | mask;
+ iowrite32(reg_value, iobase + MAC_REG_ENCFG);
+}
+
/*--------------------- Export Functions --------------------------*/
/*