From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ed1-f43.google.com (mail-ed1-f43.google.com [209.85.208.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4B75913AD1C for ; Sun, 3 Nov 2024 08:14:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.43 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621696; cv=none; b=YJDpQiEafCW6ei810wQWbumU2xfxz2B64bE6wB4hXGFDEmk/9Vu6777UYK7xCZtKtEKdH+n3I9QldpLwKSeFDsxWD0MbS5+29KsrG7HiywzaITNCeqVg8RHJ8zlCHcpSHLDVgu3eV9m++DGKtSGokW9nKhuaf1dh1oyYb20w+ic= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621696; c=relaxed/simple; bh=qv7bUIiaq2d6hSz6mAsLCXekBE2vtahVMxlhVFAYAWo=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=CQg9aE3pIbH6AFw7FSJZ8IvMJ3oSlESe5CejoGLUqMbzAaa6zqoF/o/6fPWoSgkfMSQyhSzViGaqTjoXDXRAF14ur5JvBrE/f2uqeIe59+q6wTZLPgFL/2WJHkF//pSMBUMU4ao9naPkGURP1+yZyeO4j0yP59jOt66f8R05soI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=IdvTciC7; arc=none smtp.client-ip=209.85.208.43 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="IdvTciC7" Received: by mail-ed1-f43.google.com with SMTP id 4fb4d7f45d1cf-5cb6ca2a776so4719063a12.0 for ; Sun, 03 Nov 2024 01:14:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621693; x=1731226493; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=dxXy904MrrPlMw4v+3cBS52GXFzaVx4wVG0zuSO1/wM=; b=IdvTciC77S4kB8rfi0QrD/24q/Vv5n4s6Qu/ifsLQXHM/XBu7pNCaMTL4gRMm0XJRL yEuQFSp3EKzUYI23drRbyd/1mJDV5ora/xSxLjy6f6T8LEEAl1vW7lfROmYgwy+vjTwT awZNjLZ00qoLfehWmeQ+DVpInG4kK9rl3azGkfxiPVZYI4EAUN+P14lae0SWd5UjsOkw NjcnpfQbqW2meUinhlRjBehKLXoyIPApSCt3x9S5Ghw7WpMTKhzFi4mkFAGLChR+FX9z HE3X5Qu8donNE6K09nucufAygBbrr5zHRq5aVK0tS8m36QsviLyEKxJoad43LwLqtvvq 7T2g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621693; x=1731226493; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=dxXy904MrrPlMw4v+3cBS52GXFzaVx4wVG0zuSO1/wM=; b=orvtPsTnv9KYWWbX1502+MWqpBWbUX58RHOvFRhctxyg3TR9h6+hUjKuCoxbJpGjdE SOfzXh90HzTNFhEJq74N4KeTo8jf6Z/PpQhERvjyhDVCOQTyx6RQcuFpsUVBQFEXvTty LcBu15Dm2sF795hHzOpv7yhqC864rtZa6NEFcO5k2fIByravCAPtDLnEWMyohdMtIQsA VpdenveigOCIzcgKrxHiJZA3ut6u1KNoEBqzriNqj+qO39DTfw8wBscJlvFb8mC65NA6 mJh9o/71JC0zgXUy/WpdH2d103a8xn+4JsHpxt6bReOE4GKw1PKN+9zIfBwFlZN5TCDL H8FQ== X-Forwarded-Encrypted: i=1; AJvYcCUIawTOyw+sTQcOitVM4HFGAuLLqvDDXcq0JG9HE+X2UC+4z5TjH3YIakCmSm/VLAJtt+oWWcwJbzAQfbQ=@vger.kernel.org X-Gm-Message-State: AOJu0YxsgZTsRWsnlmeA+dqvyh0qlDH2/ldRPtDYjeriDc+onAYqBunn XEUqcoFJDozqvf4/jrDZ1Bydr3UWXXitcsKXNyEvBcQYVkqrkfcn X-Google-Smtp-Source: AGHT+IF4nZRc+yG/Id2cJXxcIpm90HTJ+ULR7N6gzEr5j8Dy5NfJSFtPsiTljl4GcW76fwZlRV2gCg== X-Received: by 2002:a17:907:7e8c:b0:a9a:29a9:70bb with SMTP id a640c23a62f3a-a9e3a59d563mr1707138366b.14.1730621692286; Sun, 03 Nov 2024 01:14:52 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:51 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 01/13] staging: rtl8723bs: Replace function thread_enter Date: Sun, 3 Nov 2024 09:14:22 +0100 Message-ID: <6946fae41575fffff1d4718cb3a96cd53f655416.1730619982.git.philipp.g.hortmann@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Replace function thread_enter with its only called function allow_signal to increase readability. Remove resulting unused local variable thread_name as well. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8723bs/core/rtw_cmd.c | 2 +- drivers/staging/rtl8723bs/core/rtw_xmit.c | 2 +- drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c | 4 +--- drivers/staging/rtl8723bs/include/osdep_service.h | 5 ----- 4 files changed, 3 insertions(+), 10 deletions(-) diff --git a/drivers/staging/rtl8723bs/core/rtw_cmd.c b/drivers/staging/rtl= 8723bs/core/rtw_cmd.c index 68b5d8ca900f..64ce33c6fba1 100644 --- a/drivers/staging/rtl8723bs/core/rtw_cmd.c +++ b/drivers/staging/rtl8723bs/core/rtw_cmd.c @@ -382,7 +382,7 @@ int rtw_cmd_thread(void *context) struct cmd_priv *pcmdpriv =3D &padapter->cmdpriv; struct drvextra_cmd_parm *extra_parm =3D NULL; =20 - thread_enter("RTW_CMD_THREAD"); + allow_signal(SIGTERM); =20 pcmdbuf =3D pcmdpriv->cmd_buf; =20 diff --git a/drivers/staging/rtl8723bs/core/rtw_xmit.c b/drivers/staging/rt= l8723bs/core/rtw_xmit.c index 3e88f14e3bf7..699cff7b0ac9 100644 --- a/drivers/staging/rtl8723bs/core/rtw_xmit.c +++ b/drivers/staging/rtl8723bs/core/rtw_xmit.c @@ -2489,7 +2489,7 @@ int rtw_xmit_thread(void *context) err =3D _SUCCESS; padapter =3D context; =20 - thread_enter("RTW_XMIT_THREAD"); + allow_signal(SIGTERM); =20 do { err =3D rtw_hal_xmit_thread_handler(padapter); diff --git a/drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c b/drivers/stagi= ng/rtl8723bs/hal/rtl8723bs_xmit.c index 78298e63edce..5dc1c12fe03e 100644 --- a/drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c +++ b/drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c @@ -411,14 +411,12 @@ int rtl8723bs_xmit_thread(void *context) s32 ret; struct adapter *padapter; struct xmit_priv *pxmitpriv; - u8 thread_name[20]; =20 ret =3D _SUCCESS; padapter =3D context; pxmitpriv =3D &padapter->xmitpriv; =20 - rtw_sprintf(thread_name, 20, "RTWHALXT-%s", ADPT_ARG(padapter)); - thread_enter(thread_name); + allow_signal(SIGTERM); =20 do { ret =3D rtl8723bs_xmit_handler(padapter); diff --git a/drivers/staging/rtl8723bs/include/osdep_service.h b/drivers/st= aging/rtl8723bs/include/osdep_service.h index b21267d7ef72..8b1634f4091e 100644 --- a/drivers/staging/rtl8723bs/include/osdep_service.h +++ b/drivers/staging/rtl8723bs/include/osdep_service.h @@ -73,11 +73,6 @@ int _rtw_netif_rx(struct net_device *ndev, struct sk_buf= f *skb); =20 extern void _rtw_init_queue(struct __queue *pqueue); =20 -static inline void thread_enter(char *name) -{ - allow_signal(SIGTERM); -} - static inline void flush_signals_thread(void) { if (signal_pending(current)) --=20 2.43.0 From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ed1-f41.google.com (mail-ed1-f41.google.com [209.85.208.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id EF27215AAD9 for ; Sun, 3 Nov 2024 08:14:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.41 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621696; cv=none; b=ddmNQRdVTGKE2zratp3Jwq1s2JPE2noDQ87JggiWu4q1bEWjo8yeDB9QNcBtt2wOH6XGqfUOokY1xEmhk/NjvxQRFvZ5X7EkRvkn/Mx2cjmdfR0+b1PPAnIeF66/cVg42pWtDvsbsEENs1myRp0+APKeOCZofnksh20/NZavR1g= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621696; c=relaxed/simple; bh=sJQBtHHCyUD4fx57VPvGK7t1PMtZgvKNa+0f3DpKnsI=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=hKN55XS5+h803kPZloemkLoUJod0Y9/uhUzFMLeqwG5/kZ9vVrws4aTqCf8oUJuXqwb0hPeZRHfd7nWB7r4dCS6a7hzZ+iCfsw8X0hNSGjQcvbnAlfV8qW4Fwng/JFeIgADG8dRG3wyPLLFVa/Y/gTVAjcBaiBIO/WaRRHeDBmI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=SVG4BueB; arc=none smtp.client-ip=209.85.208.41 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="SVG4BueB" Received: by mail-ed1-f41.google.com with SMTP id 4fb4d7f45d1cf-5ced6a3f246so65795a12.3 for ; Sun, 03 Nov 2024 01:14:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621693; x=1731226493; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=SKRocKMvsGz4cOULrqNXkHoL0rqs+NrAAxU47zmH+UY=; b=SVG4BueBKTF+Pf0z3RfrfWDx10J9gM1ZPzJLTg9WxQiVS+Z13HjixJirTbU2LiHxwy TsJGdyQkqKkA2VkHdOOOGtGe6Cs73+jNWqRKhGj+LfwjVdIAIMWZFt4vQJf0QDRl9nIX RLKIeE6VFxsOwU8H95Et4F1LBI+69yNhlitU1aQBp/5gAwzEwkYF2yhQDxaRGx3RGr9K lQFUwA939vmgZtmGiNZ14aowocmKQ5VQ9BOn/kS7r+bwfqEkDRSXNRrzcdKWn4gvry39 QPC69Ebrk/OBcQu7dSewpdXwvlMYH5lrW1kpTgwDKD5ToZUynTsDOvnMq4ZUl5AfVaqp YRvg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621693; x=1731226493; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=SKRocKMvsGz4cOULrqNXkHoL0rqs+NrAAxU47zmH+UY=; b=gdGDfZ9mnubEjJkoHL24kTaKyqYQO+W4XU+l77uzK+lFbJz31YzP2JG6ClGGUe5RmC UVLGhkcyhypKj5lKfEuuvJRK1jiTts1dvMkBFnPCuB5IojHGIqgz6A5M3+bk2/ZeOt0Y jzFDe6FpcSzxBnMubTL2ZfKAk2zHNerPn+MgqP/PBJ7KcINpFi0frVeBOfOTmXjecgKW LfqZyy41Gd5GHTk+5Y19S/BGV1+mPHkZZx+O/siiyscZRRsUPrhlcGZfvzCNy0baGXGi oU1fA55+MUHC/sktcC1ACaVpDNci4TjE+c4vxcYPDRyRGR3V/4DDytSKcSTlEDNnTlIK 47/A== X-Forwarded-Encrypted: i=1; AJvYcCUUBZZPgou5AVpbNpHVj5xBe0NyXRbN1Pp1Mc3IeHtIA7jp1FSTtFfF4TwFxB4RMTRe7TXWo9m5WRubnK4=@vger.kernel.org X-Gm-Message-State: AOJu0YwkfdfE744vkkjke4ystvt+JKQ9lWvhkM6GeOrl31keUznUJC6k 5gdTu1Y7CFd/wDHSo8pTWy9zJujEhEMfbe4Y0Nuss87bBFbTiRl7 X-Google-Smtp-Source: AGHT+IEUdwUv9MdZb3kct+QldHfpcsuY/9p0YeIRb0fwCu+mPP3498mIgN9ACUM2AetSDqcm1a3iow== X-Received: by 2002:a05:6402:2114:b0:5ce:d028:e11 with SMTP id 4fb4d7f45d1cf-5ced0280e56mr2014148a12.17.1730621692863; Sun, 03 Nov 2024 01:14:52 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:52 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 02/13] staging: rtl8723bs: Remove #if 1 in function hal_EfusePartialWriteCheck Date: Sun, 3 Nov 2024 09:14:23 +0100 Message-ID: <2eea90fbdc2ef0ef5c8a224330558ccdefdfdf5b.1730619982.git.philipp.g.hortmann@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Remove #if 1 in function hal_EfusePartialWriteCheck to shorten code. Signed-off-by: Philipp Hortmann --- .../staging/rtl8723bs/hal/rtl8723b_hal_init.c | 53 ------------------- 1 file changed, 53 deletions(-) diff --git a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c b/drivers/st= aging/rtl8723bs/hal/rtl8723b_hal_init.c index be4cc8fc5696..2659999404a3 100644 --- a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c +++ b/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c @@ -1327,61 +1327,8 @@ static u8 hal_EfusePartialWriteCheck( } =20 if (efuse_OneByteRead(padapter, startAddr, &efuse_data, bPseudoTest) && = (efuse_data !=3D 0xFF)) { -#if 1 bRet =3D false; break; -#else - if (EXT_HEADER(efuse_data)) { - cur_header =3D efuse_data; - startAddr++; - efuse_OneByteRead(padapter, startAddr, &efuse_data, bPseudoTest); - if (ALL_WORDS_DISABLED(efuse_data)) { - bRet =3D false; - break; - } else { - curPkt.offset =3D ((cur_header & 0xE0) >> 5) | ((efuse_data & 0xF0) >= > 1); - curPkt.word_en =3D efuse_data & 0x0F; - } - } else { - cur_header =3D efuse_data; - curPkt.offset =3D (cur_header>>4) & 0x0F; - curPkt.word_en =3D cur_header & 0x0F; - } - - curPkt.word_cnts =3D Efuse_CalculateWordCnts(curPkt.word_en); - /* if same header is found but no data followed */ - /* write some part of data followed by the header. */ - if ( - (curPkt.offset =3D=3D pTargetPkt->offset) && - (hal_EfuseCheckIfDatafollowed(padapter, curPkt.word_cnts, startAddr+1,= bPseudoTest) =3D=3D false) && - wordEnMatched(pTargetPkt, &curPkt, &matched_wden) =3D=3D true - ) { - /* Here to write partial data */ - badworden =3D Efuse_WordEnableDataWrite(padapter, startAddr+1, matched= _wden, pTargetPkt->data, bPseudoTest); - if (badworden !=3D 0x0F) { - u32 PgWriteSuccess =3D 0; - /* if write fail on some words, write these bad words again */ - if (efuseType =3D=3D EFUSE_WIFI) - PgWriteSuccess =3D Efuse_PgPacketWrite(padapter, pTargetPkt->offset,= badworden, pTargetPkt->data, bPseudoTest); - else - PgWriteSuccess =3D Efuse_PgPacketWrite_BT(padapter, pTargetPkt->offs= et, badworden, pTargetPkt->data, bPseudoTest); - - if (!PgWriteSuccess) { - bRet =3D false; /* write fail, return */ - break; - } - } - /* partial write ok, update the target packet for later use */ - for (i =3D 0; i < 4; i++) { - if ((matched_wden & (0x1<word_en |=3D (0x1<word_cnts =3D Efuse_CalculateWordCnts(pTargetPkt->word_en); - } - /* read from next header */ - startAddr =3D startAddr + (curPkt.word_cnts*2) + 1; -#endif } else { /* not used header, 0xff */ *pAddr =3D startAddr; --=20 2.43.0 From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ed1-f45.google.com (mail-ed1-f45.google.com [209.85.208.45]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6124315B13D for ; Sun, 3 Nov 2024 08:14:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.45 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621697; cv=none; b=Zs2b+JKuUq2UlyHTCH+V31udSbsLLLST8HsYn5gVbRNbXaRNQtZdOQonYfxLIBF6k88UuU5yEO+XOzPesmfbanOqgZDlg1Z21Ht79qJHAmcwWHxZBZOPTR8qMvCa226f2BvG/7YMkFGNm3MLZS9YC4H8VUxsH4UZpzKFuqVjSt4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621697; c=relaxed/simple; bh=NwG1+Wj9EwKQULRNQC2RBaRfhLvBJD2j01XeEUWx0HY=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=bf/oj2FqtlBmXRSiWQfR3Ec/rgX8ajiUIPc5djbngilbKHmJ48oW2xwFJJE8sKVhiyHnDv2/vO83HmN0wQXRj+4VEVAoc4K4kT707g5YjH2tEvW4BeDQQ8R6V+OoHphFPx873ie3H2172hO+7mfdxvk3gZmVNetfLMQhLTDHdNw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=Ey8YpAVS; arc=none smtp.client-ip=209.85.208.45 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Ey8YpAVS" Received: by mail-ed1-f45.google.com with SMTP id 4fb4d7f45d1cf-5ced6a3f246so65800a12.3 for ; Sun, 03 Nov 2024 01:14:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621694; x=1731226494; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=hhrqh6evD3D/ak3hvNLHVK8bkDBFpxBe3o3ECuiVp2c=; b=Ey8YpAVS342ftRlJSblhVxX5lb9Lh9PfT95mciLmRdble/k0vjpipiWqnnq2FET51A jrL1n6Oerwk7fI2egNykI/kiMp7Us4Ayqgn2xLfe3GACd7cU5sorr+q2yW4JI4hgpZlS kVZ1lU27pWCLRuscGn/CxGxf1rbfZN5J/fjYLTi+kBLS9GPW363pHEGVK5IaMbtZmktk 8Bg6KWdetypwgMqDUa4oxKnSNjkWhsAawuMqWT4DvH79KgcDXoDUG7HOb9oGJR4GvBK+ WgQbVSgy5DRx1IMxpaV9Dky1d5D4w7Er4vAasvxRaX6XIXwmINYMmFvoNvtnSMgX6Opo b/xQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621694; x=1731226494; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=hhrqh6evD3D/ak3hvNLHVK8bkDBFpxBe3o3ECuiVp2c=; b=r3KY4h2gvsXSR4/381VKRjSpWYvcBI8weUiF9N0HNbbPnD8mDJhT9ISauWEkJ6pyV/ fhX6c4KAfG8xMZvh3KF2i0YBhkmMETOHAkPTm+JMytIuOzszBMzqGSgbUxZ7znIlReVS +fTs30J56sUsPAYTrGkZp3j87ctRP5C16MLZ1zRO5KhduZM7aRQqFkhqMSR9gKVvyLz4 Rmiqiy9xKO79NUqOfK3qiOuscSJ9MkkiK94VlDvvLCsuNO46ZDWE6/moqBeD8CD5ZwMB 510sv97KeTOeqyzdal/IbbBxJxjy+QTzRcPYdY3ocCNjppEGjAIXrAaJh3uut2c1d2tV nS8g== X-Forwarded-Encrypted: i=1; AJvYcCV6+/aTuUyF5hS2axv0/5v2TjJrfCDW9RU0OSt39JFo9BLISANGVYWox076L9AS4QlESo/IaT1Lu8/ieIc=@vger.kernel.org X-Gm-Message-State: AOJu0YzISCHLDBNWh66RFAOyD26FS7iIEWhm9MXTQftajdj13oGdkXWE TFeJG/aihue0hGFvM99UeANp8xJkubGYn8gXS7Phrk4yHbH8WvHB X-Google-Smtp-Source: AGHT+IFrII9FEvZRo5zbQYZe/IbDfG8BuKA5hR8Ye5W9KT3hoFXbU5FmwNTOB6bH14GaPocg7JnF6A== X-Received: by 2002:a05:6402:84f:b0:5ce:c7ca:70ca with SMTP id 4fb4d7f45d1cf-5cec7ca71a0mr3751445a12.34.1730621693485; Sun, 03 Nov 2024 01:14:53 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:53 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 03/13] staging: rtl8723bs: Remove #if 1 in function hal_EfuseGetCurrentSize_BT Date: Sun, 3 Nov 2024 09:14:24 +0100 Message-ID: <9259ce43226333a4ab4ba400bbfcaa2eead3f5d1.1730619982.git.philipp.g.hortmann@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Remove #if 1 in function hal_EfuseGetCurrentSize_BT to shorten code. Signed-off-by: Philipp Hortmann --- .../staging/rtl8723bs/hal/rtl8723b_hal_init.c | 28 ------------------- 1 file changed, 28 deletions(-) diff --git a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c b/drivers/st= aging/rtl8723bs/hal/rtl8723b_hal_init.c index 2659999404a3..49b6507f991c 100644 --- a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c +++ b/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c @@ -1028,7 +1028,6 @@ static u16 hal_EfuseGetCurrentSize_BT(struct adapter = *padapter, u8 bPseudoTest) /* only when bank is switched we have to reset the efuse_addr. */ if (bank !=3D startBank) efuse_addr =3D 0; -#if 1 =20 while (AVAILABLE_EFUSE_ADDR(efuse_addr)) { if (efuse_OneByteRead(padapter, efuse_addr, @@ -1057,33 +1056,6 @@ static u16 hal_EfuseGetCurrentSize_BT(struct adapter= *padapter, u8 bPseudoTest) /* read next header */ efuse_addr +=3D (word_cnts*2)+1; } -#else - while ( - bContinual && - efuse_OneByteRead(padapter, efuse_addr, &efuse_data, bPseudoTest) && - AVAILABLE_EFUSE_ADDR(efuse_addr) - ) { - if (efuse_data !=3D 0xFF) { - if ((efuse_data&0x1F) =3D=3D 0x0F) { /* extended header */ - efuse_addr++; - efuse_OneByteRead(padapter, efuse_addr, &efuse_data, bPseudoTest); - if ((efuse_data & 0x0F) =3D=3D 0x0F) { - efuse_addr++; - continue; - } else { - hworden =3D efuse_data & 0x0F; - } - } else { - hworden =3D efuse_data & 0x0F; - } - word_cnts =3D Efuse_CalculateWordCnts(hworden); - /* read next header */ - efuse_addr =3D efuse_addr + (word_cnts*2)+1; - } else - bContinual =3D false; - } -#endif - =20 /* Check if we need to check next bank efuse */ if (efuse_addr < retU2) --=20 2.43.0 From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ed1-f46.google.com (mail-ed1-f46.google.com [209.85.208.46]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DBA0C15C145 for ; Sun, 3 Nov 2024 08:14:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.46 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621697; cv=none; b=tX1zf8psAfL5aBnVlrIC8X/wT0LKl7ZrnAJmNf3hYlHJSa6mbkk0cWyjvIRs2btbzdMQY1u+YaGIQGIYfpg5e821FAU5L3yMRwhn1XU2UmCKD4PxiclmXtvzsxsczr3yGc+i0pcQr22CV3Fi8va2B8UhSLHXkr981ZIgL/4bBUk= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621697; c=relaxed/simple; bh=7sKe1Pl+7CwfWdmhfNJ2WxpGLVatbPVCfDOtU3av8aY=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=qR++Sys8ZgTdUEDkVireftoiOEQ4tmx+YZGAaZSmVQXB/bXePkUS7rN8gfbdNLf9umZTSY1XTlvgbViDQCa8xpUf4LVXkfyY6PKcII/G8un6x3ThggXE4hMBDSFccJ21CF8ZHEkrXm1U3qiUJif+67pnvFY1FgfAXPQHTbpBQBE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=bDT80obb; arc=none smtp.client-ip=209.85.208.46 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="bDT80obb" Received: by mail-ed1-f46.google.com with SMTP id 4fb4d7f45d1cf-5c9454f3bfaso4005736a12.2 for ; Sun, 03 Nov 2024 01:14:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621694; x=1731226494; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=u9L6U0Gk8YZHjTkzBekNSagvpm2LJGcdztz/F1h/LBM=; b=bDT80obbw+yz64RXhI94we2DAARE5deDSotF4gbxjkTA3WUMTURhT9JyAIy97vj2zb VnfbPuvZptXUe+v4cZwVMfK6ZmNFWmQLhgG2yEz09KpCtfLwUZ+VoDTvB8wH/EYuXyps skQ70Kp9/xuKn7I2IGaJPzQXfXnEJBU+LhNWKxiYVNnXR8S6p7hKPCHsl9jvtPuWbz1L Xyqq5X75H++tydL8nP05uYHSbh6bJRbONTaAed45a19IeEm9Df9KYjzuVIvX60jY5Y+Q 9II3vAghSQ35/TU52l26uIgH8gJeOwfAkwkz0LJLvF8vb6SinTmcug5LnZrJSZtEjSPn sV0A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621694; x=1731226494; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=u9L6U0Gk8YZHjTkzBekNSagvpm2LJGcdztz/F1h/LBM=; b=alrE3T2ORSxmlru9LQQccfJNQtyb0kzWZ8Qo/VxGvZyv5bWEUtF1Uqw2RTs+f/Vzf7 fmwzNjbpBbzYwZl08lMSuwqYB7HlN7ahRMIzdzA2byS9fM0eqjp9P/wAjfPu6EsgJYz7 5Hp4B8GPHOcD0yaFU1pFkURiFHqcdKRcXAuTznd84PV/na/AQo4TWER2/oVMJmTXY18L Nef7sCjr9pZXZ7Dr9AjhCyTmLX2u39nhzxPHVuf3IvVX5S5Q2mWpZb8Y/sk4IeI+tDUj Z4TnkM3tRycFkuMukpFJabERwT5QOBmshz/yvDiHLAylfF7zymiy/gM774QQQiwYQKbP LooQ== X-Forwarded-Encrypted: i=1; AJvYcCUShCtqPECqXfQe2jK/02yhl+IOXgm/qjFFxKfh3wc9Y5YaI/ySERAdK6/xDhLQc8x94q30Cm8RCc/YCCw=@vger.kernel.org X-Gm-Message-State: AOJu0Yz+ZyLDjhrM63eixQ6CtOr2Bp0sC/VAd3i4kQxO4FCHVNib7K6u Ozr8qfPP/MW74vLELX53XlmbAUeMWa/pTMVoYFuuTVbmYFwAyNrV X-Google-Smtp-Source: AGHT+IFP9igqQElEcdzfvpQCH6ScPEFlcCIEAR+RwKIMPWuu5+OsQEWo9ibchlb+P/6X2aqbLxooIw== X-Received: by 2002:a50:ee98:0:b0:5ce:c8ee:7e41 with SMTP id 4fb4d7f45d1cf-5cec8ee80a3mr3127174a12.22.1730621694098; Sun, 03 Nov 2024 01:14:54 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:53 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 04/13] staging: rtl8723bs: Remove #if 1 in function ReadChipVersion8723B Date: Sun, 3 Nov 2024 09:14:25 +0100 Message-ID: <637bc9cfb1188fd0112998aea5d22241e965a50e.1730619982.git.philipp.g.hortmann@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Remove #if 1 in function ReadChipVersion8723B as it is useless. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c b/drivers/st= aging/rtl8723bs/hal/rtl8723b_hal_init.c index 49b6507f991c..c3fcadc634f9 100644 --- a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c +++ b/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c @@ -1523,9 +1523,9 @@ static struct hal_version ReadChipVersion8723B(struct= adapter *padapter) pHalData->MultiFunc |=3D ((value32 & BT_FUNC_EN) ? RT_MULTI_FUNC_BT : 0); pHalData->MultiFunc |=3D ((value32 & GPS_FUNC_EN) ? RT_MULTI_FUNC_GPS : 0= ); pHalData->PolarityCtl =3D ((value32 & WL_HWPDN_SL) ? RT_POLARITY_HIGH_ACT= : RT_POLARITY_LOW_ACT); -#if 1 + dump_chip_info(ChipVersion); -#endif + pHalData->VersionID =3D ChipVersion; =20 return ChipVersion; --=20 2.43.0 From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ed1-f54.google.com (mail-ed1-f54.google.com [209.85.208.54]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A9FD61632C9 for ; Sun, 3 Nov 2024 08:14:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.54 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621698; cv=none; b=qzL6Ce43RQppRfq20/aLFnuVNlEwnxEomY/Irre/mdN8/Y4lkTBFYG54DNp9qgcmbnV58lDoMXMa4xRDjm6t20CK4XMobwVhTJjCZgfiCr3eHanROCX2JK9ceBZo7vlrmdrWkHltlk6qR58IH3nzeryojMijeNwflqqMWi/Qnms= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621698; c=relaxed/simple; bh=TXNUYX1G4d7X/z31PaSM8Wlw23ty1yqTqroUAgdDSDI=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=iv47g0xOxQhneZZ50JIj9zo1d79v+87dtS5KdEi31LW0c8G+XZaZ463EQzLfBqOdrLf2oWG2/tA3SUprp7G0pQn3rwdNgHkir9dCwJ4I2fDcWPPEaZV8G9H20zKLAB1xXblE+PLqFMlsysTQyrmQO+oRpULAZw7jpz7+BdBi54o= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=DN8UVv2+; arc=none smtp.client-ip=209.85.208.54 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="DN8UVv2+" Received: by mail-ed1-f54.google.com with SMTP id 4fb4d7f45d1cf-5c95a962c2bso4340502a12.2 for ; Sun, 03 Nov 2024 01:14:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621695; x=1731226495; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=BhludfnkOdE6Bkm5V0G70lBT/zEk61Bs7bh9/fZXf1g=; b=DN8UVv2+hSVd3AFRyvItOAB6C8FZhW0aDRjozMCfBK39rSsLcswb+caVVbebajqTDJ 0Q0NQgzLMDX/SBAAitQjP3oCZ4/1i8UlhBXZ7dBc9e9Ea3s06hiAXvUxsIy1dkq91SDR GRSZ30cdAgVQu2t54lp5lQKpSdJkABt29QIXTBQkoavPxcBGTjf5Q7Wgh+2NxCPWo0j4 8n3kWQSqZ44xHZN0PEk3o+7E/EH6VYqMDxDHq1C9C1wt/k8JGJtzsWPLoaZiSQ2hzSF1 e1B3GEs7ORVwjPx9fAEfL9GGl16Z8yFctbSLWcuLnLz24FdGWh4wW5y71wP76UsgE2JC E+3g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621695; x=1731226495; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=BhludfnkOdE6Bkm5V0G70lBT/zEk61Bs7bh9/fZXf1g=; b=pYSOjKPtTxvH3AT4WGBb/g/F1KijlNfqIAVaeqVnNY4toK4bycRGbj4JD6L4kwdgS3 TJFobSRUW0TJDqbI/bdINv8JpFZAxPh6R2aT5tSrhgsY+bHxUaQODEhUUg44o9tdJxsU 4iKupZZxN9aAJyCJYJ9wkxB9rthOPwpTOIIx7gpTwuR0z+ZugC43pVXr2+RNoiUX2dr+ KAEaip160LnBkl+tP8hyskRzQNWHri32F2/mZPCD3gEYm7hEUXUxA8RKClMrxzwjk+v/ 44hvMsNydJcX8I2tli9yY0Pb23zDLOBTqlM1uK8hB1tYmZg+77ggstJwsE/5BOCqNPTs pxXQ== X-Forwarded-Encrypted: i=1; AJvYcCXtk1e6toAL4a4slXWCsCQ5YZsqShpETyVr3+ieBzIV2OH1KPMIDN89mEGpJiMEYhIcYurt/NqCjPjYzp4=@vger.kernel.org X-Gm-Message-State: AOJu0YxokSQbUpHw/0XswXUm6Kkhd9Rvt0AgU7dcsv2k4nQt2H7zVA1Q Crq0N5ZkZVoEVMdGkoqe5Jadz8cTkmzN26DaFF3KfMKoo+zShX3x X-Google-Smtp-Source: AGHT+IF8rnO8fnO6ZDQKo2UpprEIvwcqWdLz4SsAM0c0LR/KMS1faKOQaWR/OqQWTObMB70VSR/+qA== X-Received: by 2002:a05:6402:5109:b0:5ce:d264:3b75 with SMTP id 4fb4d7f45d1cf-5ced2643bbcmr1666147a12.1.1730621694716; Sun, 03 Nov 2024 01:14:54 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:54 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 05/13] staging: rtl8723bs: Remove function pointer check_ips_status Date: Sun, 3 Nov 2024 09:14:26 +0100 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Remove function pointer check_ips_status and use CheckIPSStatus directly to increase readability. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8723bs/hal/hal_intf.c | 7 +------ drivers/staging/rtl8723bs/hal/sdio_halinit.c | 1 - drivers/staging/rtl8723bs/include/hal_intf.h | 1 - 3 files changed, 1 insertion(+), 8 deletions(-) diff --git a/drivers/staging/rtl8723bs/hal/hal_intf.c b/drivers/staging/rtl= 8723bs/hal/hal_intf.c index 11d75b1b1ea9..44fab4eecb5e 100644 --- a/drivers/staging/rtl8723bs/hal/hal_intf.c +++ b/drivers/staging/rtl8723bs/hal/hal_intf.c @@ -156,12 +156,7 @@ void rtw_hal_disable_interrupt(struct adapter *padapte= r) =20 u8 rtw_hal_check_ips_status(struct adapter *padapter) { - u8 val =3D false; - - if (padapter->HalFunc.check_ips_status) - val =3D padapter->HalFunc.check_ips_status(padapter); - - return val; + return CheckIPSStatus(padapter); } =20 s32 rtw_hal_xmitframe_enqueue(struct adapter *padapter, struct xmit_frame = *pxmitframe) diff --git a/drivers/staging/rtl8723bs/hal/sdio_halinit.c b/drivers/staging= /rtl8723bs/hal/sdio_halinit.c index a64b28bee019..1211b7b440cf 100644 --- a/drivers/staging/rtl8723bs/hal/sdio_halinit.c +++ b/drivers/staging/rtl8723bs/hal/sdio_halinit.c @@ -1259,7 +1259,6 @@ void rtl8723bs_set_hal_ops(struct adapter *padapter) =20 rtl8723b_set_hal_ops(pHalFunc); =20 - pHalFunc->check_ips_status =3D &CheckIPSStatus; pHalFunc->SetHwRegHandler =3D &SetHwReg8723BS; pHalFunc->GetHwRegHandler =3D &GetHwReg8723BS; pHalFunc->SetHwRegHandlerWithBuf =3D &SetHwRegWithBuf8723B; diff --git a/drivers/staging/rtl8723bs/include/hal_intf.h b/drivers/staging= /rtl8723bs/include/hal_intf.h index 5b52b0fd95f0..e6f4c398f35f 100644 --- a/drivers/staging/rtl8723bs/include/hal_intf.h +++ b/drivers/staging/rtl8723bs/include/hal_intf.h @@ -162,7 +162,6 @@ enum hal_intf_ps_func { typedef s32 (*c2h_id_filter)(u8 *c2h_evt); =20 struct hal_ops { - u8 (*check_ips_status)(struct adapter *padapter); void (*set_channel_handler)(struct adapter *padapter, u8 channel); void (*set_chnl_bw_handler)(struct adapter *padapter, u8 channel, enum ch= annel_width Bandwidth, u8 Offset40, u8 Offset80); =20 --=20 2.43.0 From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ed1-f52.google.com (mail-ed1-f52.google.com [209.85.208.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2D7C91632E0 for ; Sun, 3 Nov 2024 08:14:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.52 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621699; cv=none; b=aOLACnWid/DUKwSLf/NUVv1rwbL8kXqt/C/JO4SsY3Lh1zjsCHVFQ137mbez3do5HpXsVRQNEuWHsO0VeWsCDaB815FTWp1lJ2RhzC0+J5U99CXE3M94stPSwXFYo7kNrtscUz/AywiJs92s70tIQc3J35BiK3ynirpQaedEKLs= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621699; c=relaxed/simple; bh=/SthlVcCaUJCfyv9+5To30Pjd+tIyLw75lQr01QO6V4=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=A0it0xKzGuwdRy20kwrZsDIM/ZKH0cILqxeCNu9+5cgrYHLbupUmIzemu7GFRYnQpHyI6klULxeovxHAuoDTaIoe6Ly5BfOwdmYp940x10NEjYVW9jeD3DJbetGv392A7Q5w9Gcv/acVhXxImu3ozzt5KNf77BIb2wSzK/hGc58= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=HUMf6SGP; arc=none smtp.client-ip=209.85.208.52 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="HUMf6SGP" Received: by mail-ed1-f52.google.com with SMTP id 4fb4d7f45d1cf-5cec9609303so1324070a12.1 for ; Sun, 03 Nov 2024 01:14:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621695; x=1731226495; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=GdwTYTJsNURbKgGhx9XimSyfQDHw9X3ulBGYRri9afA=; b=HUMf6SGPBTpYczMKnVpDfpRNIbTIcf70HtktWs4IBegx+ohonYW7HaS6vvuhh2ANrO t4Hrbmobri19hW4hepnCkaRAEpi8kKjDZGaSGLKDXPmW4TlxFqSJbTN6S9SPaj+rMRml luh8jDGgWxn790dok2Ar7Mn+ZJRXssoOo3bp/ytfwocsV9RPRNCieOCl0F8bWMY17gT7 mA36C8Q/FhaeN3jrgg2wETXZIBS4mgQoIA0uFo9n8iYzWZG5U2RDi9d7fY5oPXfoMa5i CmVE74lkdDVoM2pg5axElrOecLSHtNCgSrZ8GIvaGflu0APVGT89QZC54+CZY0msL2Q/ yjuA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621695; x=1731226495; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=GdwTYTJsNURbKgGhx9XimSyfQDHw9X3ulBGYRri9afA=; b=CkoNEeZNZr6skHQsPHg7ADH7eDrhl9862MqlObobroY4pkKZP3lyd0ULvqPRng5f0S 9F14C1zS+zHds6u/2LY1T66vyeX/Sq6cKYVzd9uQDT4zigf1yBTly9wi0QQuccKULIBb 3MtsydO0ENB9XBcN6jap4CJjRaPQIulgbGTF+kuMWQ5YQILCLaMocpI/tZ8HFnUc0/Lg b6CWGK2fGL8qB8gQpCuiB6L33vG2DLKeavOAhxfmJSpy8L/jOOP15xUT988jvUnkuzFP rZAYnf5jzkvwTpy/Xb0+dK15p6g/TyN4LeUvOh2d9yalhWdXuNYmjYQ8SKS3R04r2gQK N0YA== X-Forwarded-Encrypted: i=1; AJvYcCWUO0LM1v6fH5rXx1uceIgeqdXPW8kBhkSfYm7kZapJol+MIWiTVc4JgFYIoVz4CQOdhcrStY5wqRegKwE=@vger.kernel.org X-Gm-Message-State: AOJu0YwNwTBkWf4FbwV1v/ZVkHyMdfuDpXAFdayS/w5KOTdOHJFWuO7p oBAaE/fYvDF8sqqtcMLt2sraq3poLr+it1KSPQ7VR0mMWiWUVB1E X-Google-Smtp-Source: AGHT+IE5MjUKB3SHBPEkKomjFhpIPecx86bNYfO3WeGkQFpShnXPn6Av+fqOT/PVGW9653s09ii90A== X-Received: by 2002:a05:6402:50d0:b0:5ce:d69f:ca1 with SMTP id 4fb4d7f45d1cf-5ced69f0dcamr219094a12.20.1730621695342; Sun, 03 Nov 2024 01:14:55 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:55 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 06/13] staging: rtl8723bs: Remove function pointer SetHwRegHandler Date: Sun, 3 Nov 2024 09:14:27 +0100 Message-ID: <5682bb8d6951e903d23c98615e2fc6bd463b0ba4.1730619982.git.philipp.g.hortmann@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Remove function pointer SetHwRegHandler and use SetHwReg8723BS directly to increase readability. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8723bs/core/rtw_mlme_ext.c | 2 +- drivers/staging/rtl8723bs/core/rtw_wlan_util.c | 4 ++-- drivers/staging/rtl8723bs/hal/hal_intf.c | 3 +-- drivers/staging/rtl8723bs/hal/sdio_halinit.c | 3 +-- drivers/staging/rtl8723bs/include/hal_intf.h | 4 ++-- 5 files changed, 7 insertions(+), 9 deletions(-) diff --git a/drivers/staging/rtl8723bs/core/rtw_mlme_ext.c b/drivers/stagin= g/rtl8723bs/core/rtw_mlme_ext.c index bb639ce49431..317f3db19397 100644 --- a/drivers/staging/rtl8723bs/core/rtw_mlme_ext.c +++ b/drivers/staging/rtl8723bs/core/rtw_mlme_ext.c @@ -5637,7 +5637,7 @@ u8 setkey_hdl(struct adapter *padapter, u8 *pbuf) rtw_hal_set_hwreg(padapter, HW_VAR_SEC_DK_CFG, (u8 *)true); =20 /* allow multicast packets to driver */ - padapter->HalFunc.SetHwRegHandler(padapter, HW_VAR_ON_RCR_AM, null_addr); + SetHwReg8723BS(padapter, HW_VAR_ON_RCR_AM, null_addr); =20 return H2C_SUCCESS; } diff --git a/drivers/staging/rtl8723bs/core/rtw_wlan_util.c b/drivers/stagi= ng/rtl8723bs/core/rtw_wlan_util.c index 9bef4b9e2aca..73c70b016f00 100644 --- a/drivers/staging/rtl8723bs/core/rtw_wlan_util.c +++ b/drivers/staging/rtl8723bs/core/rtw_wlan_util.c @@ -1575,9 +1575,9 @@ void update_wireless_mode(struct adapter *padapter) SIFS_Timer =3D 0x0a0a0808; /* 0x0808 -> for CCK, 0x0a0a -> for OFDM */ /* change this value if having IOT issues. */ =20 - padapter->HalFunc.SetHwRegHandler(padapter, HW_VAR_RESP_SIFS, (u8 *)&SIF= S_Timer); + SetHwReg8723BS(padapter, HW_VAR_RESP_SIFS, (u8 *)&SIFS_Timer); =20 - padapter->HalFunc.SetHwRegHandler(padapter, HW_VAR_WIRELESS_MODE, (u8 *)= &(pmlmeext->cur_wireless_mode)); + SetHwReg8723BS(padapter, HW_VAR_WIRELESS_MODE, (u8 *)&(pmlmeext->cur_wir= eless_mode)); =20 if (pmlmeext->cur_wireless_mode & WIRELESS_11B) update_mgnt_tx_rate(padapter, IEEE80211_CCK_RATE_1MB); diff --git a/drivers/staging/rtl8723bs/hal/hal_intf.c b/drivers/staging/rtl= 8723bs/hal/hal_intf.c index 44fab4eecb5e..756d6ed9232d 100644 --- a/drivers/staging/rtl8723bs/hal/hal_intf.c +++ b/drivers/staging/rtl8723bs/hal/hal_intf.c @@ -108,8 +108,7 @@ uint rtw_hal_deinit(struct adapter *padapter) =20 void rtw_hal_set_hwreg(struct adapter *padapter, u8 variable, u8 *val) { - if (padapter->HalFunc.SetHwRegHandler) - padapter->HalFunc.SetHwRegHandler(padapter, variable, val); + SetHwReg8723BS(padapter, variable, val); } =20 void rtw_hal_get_hwreg(struct adapter *padapter, u8 variable, u8 *val) diff --git a/drivers/staging/rtl8723bs/hal/sdio_halinit.c b/drivers/staging= /rtl8723bs/hal/sdio_halinit.c index 1211b7b440cf..6333a0d23d43 100644 --- a/drivers/staging/rtl8723bs/hal/sdio_halinit.c +++ b/drivers/staging/rtl8723bs/hal/sdio_halinit.c @@ -1144,7 +1144,7 @@ void ReadAdapterInfo8723BS(struct adapter *padapter) * If variable not handled here, * some variables will be processed in SetHwReg8723B() */ -static void SetHwReg8723BS(struct adapter *padapter, u8 variable, u8 *val) +void SetHwReg8723BS(struct adapter *padapter, u8 variable, u8 *val) { u8 val8; =20 @@ -1259,7 +1259,6 @@ void rtl8723bs_set_hal_ops(struct adapter *padapter) =20 rtl8723b_set_hal_ops(pHalFunc); =20 - pHalFunc->SetHwRegHandler =3D &SetHwReg8723BS; pHalFunc->GetHwRegHandler =3D &GetHwReg8723BS; pHalFunc->SetHwRegHandlerWithBuf =3D &SetHwRegWithBuf8723B; pHalFunc->GetHalDefVarHandler =3D &GetHalDefVar8723BSDIO; diff --git a/drivers/staging/rtl8723bs/include/hal_intf.h b/drivers/staging= /rtl8723bs/include/hal_intf.h index e6f4c398f35f..439639f6616c 100644 --- a/drivers/staging/rtl8723bs/include/hal_intf.h +++ b/drivers/staging/rtl8723bs/include/hal_intf.h @@ -170,8 +170,6 @@ struct hal_ops { void (*hal_dm_watchdog)(struct adapter *padapter); void (*hal_dm_watchdog_in_lps)(struct adapter *padapter); =20 - - void (*SetHwRegHandler)(struct adapter *padapter, u8 variable, u8 *val); void (*GetHwRegHandler)(struct adapter *padapter, u8 variable, u8 *val); =20 void (*SetHwRegHandlerWithBuf)(struct adapter *padapter, u8 variable, u8 = *pbuf, int len); @@ -319,4 +317,6 @@ s32 rtw_hal_macid_wakeup(struct adapter *padapter, u32 = macid); =20 s32 rtw_hal_fill_h2c_cmd(struct adapter *, u8 ElementID, u32 CmdLen, u8 *p= CmdBuffer); =20 +void SetHwReg8723BS(struct adapter *padapter, u8 variable, u8 *val); + #endif /* __HAL_INTF_H__ */ --=20 2.43.0 From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ed1-f48.google.com (mail-ed1-f48.google.com [209.85.208.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C4140165F04 for ; Sun, 3 Nov 2024 08:14:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.48 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621699; cv=none; b=NV5gD8HuBaEMVF66mZhbYxK2R6ujvOgm/P8DbouJvvYM7mtDDmNu/h1oRE/vs7F7kLFH6YonBXiYzFAocSvBKa/wirKkJQxxF1zCv9xXK1Ve0406ZvbaXnq9W/VuMRUAxWddKWYOZu3gDdU6lLYIyEFYjw9p80oKxn+niKiJiYY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621699; c=relaxed/simple; bh=JwNgZndBBybwNcb1/UDOUG8ljerV5WFPQzgfwNxTMOQ=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=sRqkPMRLATsk/o+0vCQHCKWyHL4EcdQa6M1KQyR6zAT/Xa5rZglwHVznkgAuLeqqgmBgTHlzODSwaRGqj9cisUWIOA5EANFxr07BxMCORBvHnjMbDc0HNrsuD6Zgq6awCuCLhrZAOwfYuAMEycGtDULcBxQa2Vw5c/wYX5dvsKg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=E9jw99Ga; arc=none smtp.client-ip=209.85.208.48 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="E9jw99Ga" Received: by mail-ed1-f48.google.com with SMTP id 4fb4d7f45d1cf-5c9634c9160so3764198a12.2 for ; Sun, 03 Nov 2024 01:14:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621696; x=1731226496; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Kki66qAN31IwWCYVmn/Vdq65sFoOxq/7bNbZORHqbvk=; b=E9jw99Gab34ROn4lpWL8lH/OOCywtH7U8ZGo5JdPI/LJy2qpvLchACrzZ8NJG9BCT7 oOmbuYyFZIpBfYGfGMTQLJOOnK/Qz0WdXV62EknZVM86kZ+MI+13iNKqRXvg07Dccevn rpfHCvywmzD5D7CquSyrHCuzp9zxlMbh5rhBLzzNu5U/7dZAe0cICfkS3PyOARoYgxm+ VihAhjvYXJF0P1WiI8GVNUp2h9uistjqmTA7tvdNACqSqBEoCK2YVvdMf+LIiLjls3Hs OTSJkrmpXB5oSTRcz31yPj3mn0wr6OPjBksYSC5W4yx8BJ8tcM8M2oqc5OSy0VJOVnqn FMpw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621696; x=1731226496; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Kki66qAN31IwWCYVmn/Vdq65sFoOxq/7bNbZORHqbvk=; b=kK4iKJXHtFHVCX8Dmin5q9vWFgFk3gmogSj3rdscUfsa5dfLHciOZuTqOQcQTqvh01 Ol6JWgRn31l54BphSRHDipSEwZO9sOrXwxa6ObVUapZFhK2zGOHPxZsiUnk5btl0GLcP b4vWv64vlZlrQbbOBPshoCAY9rU1LdvPb5D6UW6gO5uMK/s3vsYnX1jlC3YXqtuLAzH1 ATThnk+IwRU2NDibYAkr+6/S+/6rokp3Nzz7m3D6Cl/o5hJFdgPQGurom+EQWbf7AU0P x1fhTS+ycB1MdlfUMBtqcv6VEBCFIYtBC7IIpXx1BRLk50tWCsZDwtmzON1ltzPW5QlC GJ3w== X-Forwarded-Encrypted: i=1; AJvYcCVDTA7MC5kYp+SbX1oXSpv+m1b0KewEyxyFqnDwAZeFo7bExjdzoI0v0dhuDxwEj5YEsx0M4EfU9RhiL4o=@vger.kernel.org X-Gm-Message-State: AOJu0YwI4fZsyDfZBcMKd36qkFeRcWh36mWviY4Ndz4ZOonGrSLAQtPZ +rpoQqBn438F/0ZACDDtC+WM2u9FZt7oFackH7dD0etM70klKqkF X-Google-Smtp-Source: AGHT+IEutGTvnHY4bCjiFrE4H1xZ8yIGb4jNQJJNNuTsKy4xB1VWWw5eqMeYKupDc6meov/4Mz4/TQ== X-Received: by 2002:a05:6402:3202:b0:5c4:14fe:971e with SMTP id 4fb4d7f45d1cf-5cbbf920567mr20974555a12.23.1730621695976; Sun, 03 Nov 2024 01:14:55 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:55 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 07/13] staging: rtl8723bs: Remove function pointer GetHwRegHandler Date: Sun, 3 Nov 2024 09:14:28 +0100 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Remove function pointer GetHwRegHandler and use GetHwReg8723BS directly to increase readability. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8723bs/hal/hal_intf.c | 3 +-- drivers/staging/rtl8723bs/hal/sdio_halinit.c | 3 +-- drivers/staging/rtl8723bs/include/hal_intf.h | 3 +-- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/drivers/staging/rtl8723bs/hal/hal_intf.c b/drivers/staging/rtl= 8723bs/hal/hal_intf.c index 756d6ed9232d..d7b29d08ff15 100644 --- a/drivers/staging/rtl8723bs/hal/hal_intf.c +++ b/drivers/staging/rtl8723bs/hal/hal_intf.c @@ -113,8 +113,7 @@ void rtw_hal_set_hwreg(struct adapter *padapter, u8 var= iable, u8 *val) =20 void rtw_hal_get_hwreg(struct adapter *padapter, u8 variable, u8 *val) { - if (padapter->HalFunc.GetHwRegHandler) - padapter->HalFunc.GetHwRegHandler(padapter, variable, val); + GetHwReg8723BS(padapter, variable, val); } =20 void rtw_hal_set_hwreg_with_buf(struct adapter *padapter, u8 variable, u8 = *pbuf, int len) diff --git a/drivers/staging/rtl8723bs/hal/sdio_halinit.c b/drivers/staging= /rtl8723bs/hal/sdio_halinit.c index 6333a0d23d43..d3f86d811879 100644 --- a/drivers/staging/rtl8723bs/hal/sdio_halinit.c +++ b/drivers/staging/rtl8723bs/hal/sdio_halinit.c @@ -1185,7 +1185,7 @@ void SetHwReg8723BS(struct adapter *padapter, u8 vari= able, u8 *val) * If variable not handled here, * some variables will be processed in GetHwReg8723B() */ -static void GetHwReg8723BS(struct adapter *padapter, u8 variable, u8 *val) +void GetHwReg8723BS(struct adapter *padapter, u8 variable, u8 *val) { switch (variable) { case HW_VAR_CPWM: @@ -1259,7 +1259,6 @@ void rtl8723bs_set_hal_ops(struct adapter *padapter) =20 rtl8723b_set_hal_ops(pHalFunc); =20 - pHalFunc->GetHwRegHandler =3D &GetHwReg8723BS; pHalFunc->SetHwRegHandlerWithBuf =3D &SetHwRegWithBuf8723B; pHalFunc->GetHalDefVarHandler =3D &GetHalDefVar8723BSDIO; pHalFunc->SetHalDefVarHandler =3D &SetHalDefVar8723BSDIO; diff --git a/drivers/staging/rtl8723bs/include/hal_intf.h b/drivers/staging= /rtl8723bs/include/hal_intf.h index 439639f6616c..b53804fb186d 100644 --- a/drivers/staging/rtl8723bs/include/hal_intf.h +++ b/drivers/staging/rtl8723bs/include/hal_intf.h @@ -170,8 +170,6 @@ struct hal_ops { void (*hal_dm_watchdog)(struct adapter *padapter); void (*hal_dm_watchdog_in_lps)(struct adapter *padapter); =20 - void (*GetHwRegHandler)(struct adapter *padapter, u8 variable, u8 *val); - void (*SetHwRegHandlerWithBuf)(struct adapter *padapter, u8 variable, u8 = *pbuf, int len); =20 u8 (*GetHalDefVarHandler)(struct adapter *padapter, enum hal_def_variable= eVariable, void *pValue); @@ -318,5 +316,6 @@ s32 rtw_hal_macid_wakeup(struct adapter *padapter, u32 = macid); s32 rtw_hal_fill_h2c_cmd(struct adapter *, u8 ElementID, u32 CmdLen, u8 *p= CmdBuffer); =20 void SetHwReg8723BS(struct adapter *padapter, u8 variable, u8 *val); +void GetHwReg8723BS(struct adapter *padapter, u8 variable, u8 *val); =20 #endif /* __HAL_INTF_H__ */ --=20 2.43.0 From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ed1-f41.google.com (mail-ed1-f41.google.com [209.85.208.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 61D6D16A94A for ; Sun, 3 Nov 2024 08:14:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.41 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621700; cv=none; b=Kb6zX3Ndcnt6xJxVRF0xpUs/3bAOKrcf/RzaSmh7L/4VhA2FnZR0XNw6amvCx0jGJ486Xv6zcF95vdpX/Z835Z2u9/MSSzscfAx5BnSznuR77KHLgOkhglVfRXEWeJU1oIxNqmn+ru3cdI672FAR9lAHlu5JZgqr59TceEhubGI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621700; c=relaxed/simple; bh=foianf5GbEjiOynU1NgnOCC5X8SQZgug1oA9qxXf6a4=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=RlVMZV5fOViZehffn7dK4atAVAbV5ZJgb0BVFckAlswqZMcXkxcCSULcll6yUSjYne0soxK1tPlGRYia2qeKeVWdyuh+aATJqL6tc8Ek4e7pprrwBBHQRk6tJxqI2e/CUUlSyiaLk8nBEurwG8KepycFtqxLhhbsjXgAmb4rjJY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=nB0EUS93; arc=none smtp.client-ip=209.85.208.41 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="nB0EUS93" Received: by mail-ed1-f41.google.com with SMTP id 4fb4d7f45d1cf-5c94a7239cfso1969130a12.3 for ; Sun, 03 Nov 2024 01:14:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621697; x=1731226497; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=8gM0cL0DTEnjbvAhRpIiouok/Vzfr6uGqtogpiF0AT4=; b=nB0EUS93fDarWhReu0Vznv/TPLuhqrtIaouSxD77GQOY+XuNnjeFh7MMjos3fbuugQ jH13uyss+jl/gMnbB+0VlyaodWINWMD8UGifZ97MvvXMtD0aIdC6WphWJPCNab7grHjj g4TUQUNYPdYE5lePM0fZjuhQzdTGixSeoB8qJAJ0GLbYA/2tuQa64ywLcXbPKqM5kV9t MQ89d1312F1gFDsNPcX2H2mpoATHLSsljW5aHMhkWKJwWdVbvgzqMzZquSDt+oMb4boF 3Iy6P+Y1DsJXIrn+4e/A6gcY+YjKceYTSa2Js6vVjKq4aXKoAQDL3+xbwOCPvKPGsyWX NDLg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621697; x=1731226497; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8gM0cL0DTEnjbvAhRpIiouok/Vzfr6uGqtogpiF0AT4=; b=r5/YaH5KxLXVXqnB7nRpJAb6mltYwISMtOBImE87QUfUHZ20KSXTLvgTNNYkkKE7lP DyazA9LD4F7b427jGDZw1XRmz/tf8Lgxh/3f6bEqF4reeeexV4XizEWlgy7YoY3nB5Lu +8HEKgEx9W2+A3go+dlSUrZMZ3eV3G47j1GHMGkxsLJE6z6nX3Gtr/ygfaiJwGqUfQzm /FiqdX4DF2cb8uN6cBBMA0zLcdjpevl1XaiD3D9lnDlDMz+6I9r9ktPYxrhBmiCt/eNh tDE8qwRIRHhoymoY6+kTIFAYB1eAnjihwdu2434YglgTZL+KK/RQ6HNw60yUFS6n+gfq nQ+w== X-Forwarded-Encrypted: i=1; AJvYcCX9eyC1IlqnHKfBiD2l0dUvXAlHrt9A7XefqDx3n9IOwIgEqdLE0Xnpeb0E4yUKXz5OoGcnvslmoUadsP0=@vger.kernel.org X-Gm-Message-State: AOJu0YyG8isZ+A3x757c5CQxcl/XcR7oDuP8T8Hs92TMx9hEFkb7zY9/ PwPWYwzb1gwB790tUdkHKs0d9qUUjxs6rKtgNejjo2Hq3w8IHeemSzra/w== X-Google-Smtp-Source: AGHT+IE16GFYIvZVlLNKzvZAYIvdHcwYwrO43A1tdLl67+tEtd2/urkRmMiGFvM/dxDBOjZCho5T2g== X-Received: by 2002:a05:6402:3584:b0:5ce:caa1:ca86 with SMTP id 4fb4d7f45d1cf-5cecaa1cf32mr6005105a12.24.1730621696613; Sun, 03 Nov 2024 01:14:56 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:56 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 08/13] staging: rtl8723bs: Remove function pointer SetHwRegHandlerWithBuf Date: Sun, 3 Nov 2024 09:14:29 +0100 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Remove function pointer SetHwRegHandlerWithBuf and use SetHwRegWithBuf8723B directly to increase readability. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8723bs/hal/hal_intf.c | 3 +-- drivers/staging/rtl8723bs/hal/sdio_halinit.c | 3 +-- drivers/staging/rtl8723bs/include/hal_intf.h | 4 +--- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/drivers/staging/rtl8723bs/hal/hal_intf.c b/drivers/staging/rtl= 8723bs/hal/hal_intf.c index d7b29d08ff15..ec567ae99f10 100644 --- a/drivers/staging/rtl8723bs/hal/hal_intf.c +++ b/drivers/staging/rtl8723bs/hal/hal_intf.c @@ -118,8 +118,7 @@ void rtw_hal_get_hwreg(struct adapter *padapter, u8 var= iable, u8 *val) =20 void rtw_hal_set_hwreg_with_buf(struct adapter *padapter, u8 variable, u8 = *pbuf, int len) { - if (padapter->HalFunc.SetHwRegHandlerWithBuf) - padapter->HalFunc.SetHwRegHandlerWithBuf(padapter, variable, pbuf, len); + SetHwRegWithBuf8723B(padapter, variable, pbuf, len); } =20 u8 rtw_hal_set_def_var(struct adapter *padapter, enum hal_def_variable eVa= riable, void *pValue) diff --git a/drivers/staging/rtl8723bs/hal/sdio_halinit.c b/drivers/staging= /rtl8723bs/hal/sdio_halinit.c index d3f86d811879..beb74a40e91e 100644 --- a/drivers/staging/rtl8723bs/hal/sdio_halinit.c +++ b/drivers/staging/rtl8723bs/hal/sdio_halinit.c @@ -1204,7 +1204,7 @@ void GetHwReg8723BS(struct adapter *padapter, u8 vari= able, u8 *val) } } =20 -static void SetHwRegWithBuf8723B(struct adapter *padapter, u8 variable, u8= *pbuf, int len) +void SetHwRegWithBuf8723B(struct adapter *padapter, u8 variable, u8 *pbuf,= int len) { switch (variable) { case HW_VAR_C2H_HANDLE: @@ -1259,7 +1259,6 @@ void rtl8723bs_set_hal_ops(struct adapter *padapter) =20 rtl8723b_set_hal_ops(pHalFunc); =20 - pHalFunc->SetHwRegHandlerWithBuf =3D &SetHwRegWithBuf8723B; pHalFunc->GetHalDefVarHandler =3D &GetHalDefVar8723BSDIO; pHalFunc->SetHalDefVarHandler =3D &SetHalDefVar8723BSDIO; =20 diff --git a/drivers/staging/rtl8723bs/include/hal_intf.h b/drivers/staging= /rtl8723bs/include/hal_intf.h index b53804fb186d..d6e8eb95d391 100644 --- a/drivers/staging/rtl8723bs/include/hal_intf.h +++ b/drivers/staging/rtl8723bs/include/hal_intf.h @@ -170,8 +170,6 @@ struct hal_ops { void (*hal_dm_watchdog)(struct adapter *padapter); void (*hal_dm_watchdog_in_lps)(struct adapter *padapter); =20 - void (*SetHwRegHandlerWithBuf)(struct adapter *padapter, u8 variable, u8 = *pbuf, int len); - u8 (*GetHalDefVarHandler)(struct adapter *padapter, enum hal_def_variable= eVariable, void *pValue); u8 (*SetHalDefVarHandler)(struct adapter *padapter, enum hal_def_variable= eVariable, void *pValue); =20 @@ -317,5 +315,5 @@ s32 rtw_hal_fill_h2c_cmd(struct adapter *, u8 ElementID= , u32 CmdLen, u8 *pCmdBuf =20 void SetHwReg8723BS(struct adapter *padapter, u8 variable, u8 *val); void GetHwReg8723BS(struct adapter *padapter, u8 variable, u8 *val); - +void SetHwRegWithBuf8723B(struct adapter *padapter, u8 variable, u8 *pbuf,= int len); #endif /* __HAL_INTF_H__ */ --=20 2.43.0 From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ed1-f49.google.com (mail-ed1-f49.google.com [209.85.208.49]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6E299158DC0 for ; Sun, 3 Nov 2024 08:14:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.49 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621702; cv=none; b=Eh9GYiaCG6cKdP8LEJESZ3v1+eEo16VWOyaLRi6DWYPvaXHGu4WjuEVrJcJcsVg3rPf0qJOqrzTx4A0V4O/T/hJwL63KLJ9yf7HedFHapL6knrllkyfehWgF5muFp8t5oTvZCvgjmDQm10148+Jl3TgpHtJuPqxHow7gisEIh2g= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621702; c=relaxed/simple; bh=iQqcpC8l3446T4k+RFti+09L/H09762bBP37GsGZh6k=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=gsaX2uer0Vkz1PYfWfy7o2fSxmKhQUHCMAds/81AvOIRWJIDSZblEF2KxggiFwb4Ipi8EI7eFJlBzHf0Xz2qaK3Eiznkpkd3TX/P3NNdALX1O09iWAK3AtF0zrVXEM6Kwc8OgAjrq5tB2vmh8ue1lrh8xGevrXYENiE+o1QbsBQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=XWWRB5oE; arc=none smtp.client-ip=209.85.208.49 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="XWWRB5oE" Received: by mail-ed1-f49.google.com with SMTP id 4fb4d7f45d1cf-5cec93719ccso1314007a12.2 for ; Sun, 03 Nov 2024 01:14:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621698; x=1731226498; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=UMZjBc+r0kNLu2PVzUZXnU+/3Ibb4mXMOKZIEO1uavY=; b=XWWRB5oERFzStEUjd0NIQNOnS2dfziVw6Q+y8XOb99u/9dIZuAzcSGd04G0Wr6tmH7 bSo3MJkcrDu67YQWmdQJQL3qQEfiEHHkYL5s8n56xSVDWbwYQuP+6KR3pJGV3l959wva ZiFpyyCjTAgc5CgS4AhpdCwgi/RCxPgJ5v1LTy/+eLk9Zocehqoiu1XrmopyZLo0JU54 2R9usHnzzL8Jcsev0KphnJm3ExFvgRH0FVk6AoVfoeDOqYj4qbiB+Cj/YSWZ0/KEUXdX TEVUuqUGI3FbZNmSS+qwhaBf0o9eE0d6dC1SrmBKsELpKq7R6Cjb4lIoT30itHj6yWfW 7RGg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621698; x=1731226498; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=UMZjBc+r0kNLu2PVzUZXnU+/3Ibb4mXMOKZIEO1uavY=; b=ftTqEtu9x345cZuNywZ9l0PvU0wTklSs1XWC72X7z3POx+XabSEvF1IhJhd/arntFz l07VQVPyNCr/gFNIL/o8D5wznL+4jmRTpZxep1CZzZPswNlR5APaMk3izbRL2LtsQcT8 ln4xfBxkP5AEA1THrx01qy0kKJ8n++dLjGwFswBRgZppTQULfzd7pK5V7Vv00qWVlutu NZ5yEXi+XY0lzws7SfsPh6s/iG1oDoLQACJcqLG0oB9hhDtTm/XLyjBJVSBxIkljjy7u de704gLS8WT9BieOFQ6v4M43TZEaXuK3whq75cPF2RraegAehAOp+2q2Ucboci/Zmvv4 dlkg== X-Forwarded-Encrypted: i=1; AJvYcCUjufUJr/aTOSXR6UyYCXxTzUnfUpevkqpSSWN52oTe03EKbtZzpaLZ7x2EQg4OmGBEP/QVBp2uwfkM4ng=@vger.kernel.org X-Gm-Message-State: AOJu0YzVXVzqG21nqVXEOjhXfLCOnfKQFXW0VRUBeebqr6+7ki9Cbm1Y MYVjJgbU2XBEPRyavKK1FLDRNq443wwdWuYR1O2sLMFXeKbC1AsJ X-Google-Smtp-Source: AGHT+IGBy5duJ5lWb9Veb++sGyBb25th7PMvpJRjzpYSIRWDR/8RFcPdBnPT+/FIEiMz7zIosTuNDw== X-Received: by 2002:a05:6402:518a:b0:5c9:76ca:705b with SMTP id 4fb4d7f45d1cf-5cd54afde73mr12042972a12.34.1730621697209; Sun, 03 Nov 2024 01:14:57 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:56 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 09/13] staging: rtl8723bs: Remove function pointer GetHalDefVarHandler Date: Sun, 3 Nov 2024 09:14:30 +0100 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Remove function pointer GetHalDefVarHandler and use GetHalDefVar8723BSDIO directly to increase readability. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8723bs/hal/hal_intf.c | 4 +--- drivers/staging/rtl8723bs/hal/sdio_halinit.c | 3 +-- drivers/staging/rtl8723bs/include/hal_intf.h | 2 +- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/drivers/staging/rtl8723bs/hal/hal_intf.c b/drivers/staging/rtl= 8723bs/hal/hal_intf.c index ec567ae99f10..e8b31b80917e 100644 --- a/drivers/staging/rtl8723bs/hal/hal_intf.c +++ b/drivers/staging/rtl8723bs/hal/hal_intf.c @@ -130,9 +130,7 @@ u8 rtw_hal_set_def_var(struct adapter *padapter, enum h= al_def_variable eVariable =20 u8 rtw_hal_get_def_var(struct adapter *padapter, enum hal_def_variable eVa= riable, void *pValue) { - if (padapter->HalFunc.GetHalDefVarHandler) - return padapter->HalFunc.GetHalDefVarHandler(padapter, eVariable, pValue= ); - return _FAIL; + return GetHalDefVar8723BSDIO(padapter, eVariable, pValue); } =20 void rtw_hal_set_odm_var(struct adapter *padapter, enum hal_odm_variable e= Variable, void *pValue1, bool bSet) diff --git a/drivers/staging/rtl8723bs/hal/sdio_halinit.c b/drivers/staging= /rtl8723bs/hal/sdio_halinit.c index beb74a40e91e..b1b40f6077fe 100644 --- a/drivers/staging/rtl8723bs/hal/sdio_halinit.c +++ b/drivers/staging/rtl8723bs/hal/sdio_halinit.c @@ -1219,7 +1219,7 @@ void SetHwRegWithBuf8723B(struct adapter *padapter, u= 8 variable, u8 *pbuf, int l /* Description: */ /* Query setting of specified variable. */ /* */ -static u8 GetHalDefVar8723BSDIO( +u8 GetHalDefVar8723BSDIO( struct adapter *Adapter, enum hal_def_variable eVariable, void *pValue ) { @@ -1259,7 +1259,6 @@ void rtl8723bs_set_hal_ops(struct adapter *padapter) =20 rtl8723b_set_hal_ops(pHalFunc); =20 - pHalFunc->GetHalDefVarHandler =3D &GetHalDefVar8723BSDIO; pHalFunc->SetHalDefVarHandler =3D &SetHalDefVar8723BSDIO; =20 pHalFunc->hal_xmit =3D &rtl8723bs_hal_xmit; diff --git a/drivers/staging/rtl8723bs/include/hal_intf.h b/drivers/staging= /rtl8723bs/include/hal_intf.h index d6e8eb95d391..19aae9b0d400 100644 --- a/drivers/staging/rtl8723bs/include/hal_intf.h +++ b/drivers/staging/rtl8723bs/include/hal_intf.h @@ -170,7 +170,6 @@ struct hal_ops { void (*hal_dm_watchdog)(struct adapter *padapter); void (*hal_dm_watchdog_in_lps)(struct adapter *padapter); =20 - u8 (*GetHalDefVarHandler)(struct adapter *padapter, enum hal_def_variable= eVariable, void *pValue); u8 (*SetHalDefVarHandler)(struct adapter *padapter, enum hal_def_variable= eVariable, void *pValue); =20 void (*SetHalODMVarHandler)(struct adapter *padapter, enum hal_odm_variab= le eVariable, void *pValue1, bool bSet); @@ -316,4 +315,5 @@ s32 rtw_hal_fill_h2c_cmd(struct adapter *, u8 ElementID= , u32 CmdLen, u8 *pCmdBuf void SetHwReg8723BS(struct adapter *padapter, u8 variable, u8 *val); void GetHwReg8723BS(struct adapter *padapter, u8 variable, u8 *val); void SetHwRegWithBuf8723B(struct adapter *padapter, u8 variable, u8 *pbuf,= int len); +u8 GetHalDefVar8723BSDIO(struct adapter *Adapter, enum hal_def_variable eV= ariable, void *pValue); #endif /* __HAL_INTF_H__ */ --=20 2.43.0 From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ej1-f44.google.com (mail-ej1-f44.google.com [209.85.218.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 834201714D7 for ; Sun, 3 Nov 2024 08:14:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.44 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621701; cv=none; b=GbOVc7gUuBWRWnRkfmWjlVtD3ikzt1gEe9dA3yPvTJ0SixMu0tbMNvEbW9FwVnCyPMPzr/IXAlyWGz4BWdGe14nkkJaDxYKQfG5HfrWo3PZIVBbdrlk2uXfOZjmWDb6/zmO8Nw88x/I9w0AsBx5hJNAG0dr8Dfe9JbtExcSAD4g= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621701; c=relaxed/simple; bh=WvdiGCaxVVUYEgBqSVJnMlolDTeNPErLovjLDKdb43E=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=gj4QmHlGOlEn/4QmKS+5MrB9H5PuN1GIm9aovW5pnvTfo+augaEK+j78jITXbQC62ttOy0mHAnHDM0rQjvb+8XGh1UylAbdYwYnuiS2b8S17e9yyvJSDJKYfPhAIZ7+Ll+0y9td6Op/rYC1yJgt3n2NPQkzcvckintjNjAp31cA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=Rcdl7QW0; arc=none smtp.client-ip=209.85.218.44 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Rcdl7QW0" Received: by mail-ej1-f44.google.com with SMTP id a640c23a62f3a-a9aa8895facso561895666b.2 for ; Sun, 03 Nov 2024 01:14:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621698; x=1731226498; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=IWg7e149C7FsdITnlVLLumGagoPJ2vVxsltogaRDfow=; b=Rcdl7QW0dfFFgFzHi/6PKMoa26DgebdbRHtvtInJXdyOhbuvSjt9k5i5iaz287Grt6 cKMmRiGwuMMNDaxHqyrCLfCeCwU0O0PzrtmSywA9/6BLOBkzV2zx99brTYVLWEUawxQ7 fLpkcDeEdMFyiQ/x26NnnR0P0yUqU9vdf7ercCQ2jF6OGmYLfOSKZEMkxdmaqfIEDrUs scj+BvW8LqH2LrZ1qHRa6GEkdGqTgKSHloiDacuUnFNxUbnXKU/F3Ac2zDblJ9v2H7Hh Dgk7AikHbD7Ur0bhosjQBAReZwMSvZolpbJ+R6mzZxlXFz+0iXL8ly62fWJNWQRFE6WT T96w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621698; x=1731226498; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=IWg7e149C7FsdITnlVLLumGagoPJ2vVxsltogaRDfow=; b=NcmXZlkhGaiS/RJlefZNQV5p7YsrNuRSkfQWVR4GnGGltne210+rgJH6leB+75e0hV G6hZlwmZ0NcuJ3VG+00NlEQTeIFBYFWCP/8uGhFatVexjHT3Tmh6vyVLofysid0ALynm coFrP1/YJ3lBtEKekqopMM+g1a5zQXSX2sHRZur19epJt21wN4Ts2zpEy2nZ6jYFPPSY ILud9/D2RX/qOlPFitPFOrfCUwKccWu7WG3VbBsey1O2xcf3oRhcrfmnCheURfJyu5ei UeSKqvhkweiIEZ2hn7CmeJDJ01beuyD3/p9iJH6HhcweHyfF6glG3JrHqvAw2uy7y90z K4VQ== X-Forwarded-Encrypted: i=1; AJvYcCXPhLBzX3fIuhhjH00VeE8h4F0tvWNwLNJZepl3DUk7IZ7of0edSqTm2E7gzpA7+wtkGeBG0AIwuSYsb/g=@vger.kernel.org X-Gm-Message-State: AOJu0YyROiSFO1adDTgw/n3iOK7+dbsoIe/NDtzvOFPuoC6y7VZnBAnL GLq3FJ9b1hykfuAsg8ApNajM9F52OUEXhs1OvfATcZeCBeWiblUn X-Google-Smtp-Source: AGHT+IEuxr1oj7dC/XJZuFzAE/uA20NlwaalxktRYv2bsG3PFA+4Xepe5F/VipkNkkxteyrz4TnHAw== X-Received: by 2002:a17:906:6a09:b0:a99:ffdb:6fef with SMTP id a640c23a62f3a-a9de61cef8amr3051400266b.46.1730621697851; Sun, 03 Nov 2024 01:14:57 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:57 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 10/13] staging: rtl8723bs: Remove function pointer SetHalDefVarHandler Date: Sun, 3 Nov 2024 09:14:31 +0100 Message-ID: <7a6c87ca6b746392517275eb4f6837c0ccaabff1.1730619982.git.philipp.g.hortmann@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Remove function pointer SetHalDefVarHandler and use SetHalDefVar8723BSDIO directly to increase readability. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8723bs/hal/hal_intf.c | 4 +--- drivers/staging/rtl8723bs/hal/sdio_halinit.c | 5 +---- drivers/staging/rtl8723bs/include/hal_intf.h | 3 +-- 3 files changed, 3 insertions(+), 9 deletions(-) diff --git a/drivers/staging/rtl8723bs/hal/hal_intf.c b/drivers/staging/rtl= 8723bs/hal/hal_intf.c index e8b31b80917e..d45dfa8e638e 100644 --- a/drivers/staging/rtl8723bs/hal/hal_intf.c +++ b/drivers/staging/rtl8723bs/hal/hal_intf.c @@ -123,9 +123,7 @@ void rtw_hal_set_hwreg_with_buf(struct adapter *padapte= r, u8 variable, u8 *pbuf, =20 u8 rtw_hal_set_def_var(struct adapter *padapter, enum hal_def_variable eVa= riable, void *pValue) { - if (padapter->HalFunc.SetHalDefVarHandler) - return padapter->HalFunc.SetHalDefVarHandler(padapter, eVariable, pValue= ); - return _FAIL; + return SetHalDefVar8723BSDIO(padapter, eVariable, pValue); } =20 u8 rtw_hal_get_def_var(struct adapter *padapter, enum hal_def_variable eVa= riable, void *pValue) diff --git a/drivers/staging/rtl8723bs/hal/sdio_halinit.c b/drivers/staging= /rtl8723bs/hal/sdio_halinit.c index b1b40f6077fe..ccf1e9727846 100644 --- a/drivers/staging/rtl8723bs/hal/sdio_halinit.c +++ b/drivers/staging/rtl8723bs/hal/sdio_halinit.c @@ -1247,8 +1247,7 @@ u8 GetHalDefVar8723BSDIO( /* Description: */ /* Change default setting of specified variable. */ /* */ -static u8 SetHalDefVar8723BSDIO(struct adapter *Adapter, - enum hal_def_variable eVariable, void *pValue) +u8 SetHalDefVar8723BSDIO(struct adapter *Adapter, enum hal_def_variable eV= ariable, void *pValue) { return SetHalDefVar8723B(Adapter, eVariable, pValue); } @@ -1259,8 +1258,6 @@ void rtl8723bs_set_hal_ops(struct adapter *padapter) =20 rtl8723b_set_hal_ops(pHalFunc); =20 - pHalFunc->SetHalDefVarHandler =3D &SetHalDefVar8723BSDIO; - pHalFunc->hal_xmit =3D &rtl8723bs_hal_xmit; pHalFunc->mgnt_xmit =3D &rtl8723bs_mgnt_xmit; pHalFunc->hal_xmitframe_enqueue =3D &rtl8723bs_hal_xmitframe_enqueue; diff --git a/drivers/staging/rtl8723bs/include/hal_intf.h b/drivers/staging= /rtl8723bs/include/hal_intf.h index 19aae9b0d400..b69d201b6826 100644 --- a/drivers/staging/rtl8723bs/include/hal_intf.h +++ b/drivers/staging/rtl8723bs/include/hal_intf.h @@ -170,8 +170,6 @@ struct hal_ops { void (*hal_dm_watchdog)(struct adapter *padapter); void (*hal_dm_watchdog_in_lps)(struct adapter *padapter); =20 - u8 (*SetHalDefVarHandler)(struct adapter *padapter, enum hal_def_variable= eVariable, void *pValue); - void (*SetHalODMVarHandler)(struct adapter *padapter, enum hal_odm_variab= le eVariable, void *pValue1, bool bSet); =20 void (*UpdateRAMaskHandler)(struct adapter *padapter, u32 mac_id, u8 rssi= _level); @@ -316,4 +314,5 @@ void SetHwReg8723BS(struct adapter *padapter, u8 variab= le, u8 *val); void GetHwReg8723BS(struct adapter *padapter, u8 variable, u8 *val); void SetHwRegWithBuf8723B(struct adapter *padapter, u8 variable, u8 *pbuf,= int len); u8 GetHalDefVar8723BSDIO(struct adapter *Adapter, enum hal_def_variable eV= ariable, void *pValue); +u8 SetHalDefVar8723BSDIO(struct adapter *Adapter, enum hal_def_variable eV= ariable, void *pValue); #endif /* __HAL_INTF_H__ */ --=20 2.43.0 From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ed1-f48.google.com (mail-ed1-f48.google.com [209.85.208.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 35184176AA1 for ; Sun, 3 Nov 2024 08:15:00 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.48 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621702; cv=none; b=poKyRbxueNEC/z5IndaqUKaeTbDzssMvHzYu7I9PjRL/WPSfAcAw78lgaSFDeeeAptUvfHUsJwsZENDIhQuTGQPPIYHPrkANZHVcAoW/kx1hh4vy9JTyz+Rs//IJhzPySlP+MfCz5z6ngJsf//qSmxzAGN3pj0XyqR/4y0QlYx0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621702; c=relaxed/simple; bh=ZUHmg1t1sdjL0rwN8lgvvUeLmAvJpXjUgQkUh98C/dY=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=as+WEOfKYdXa3Ie6d2H+DwqdlmTScCr88StTPk2EEe8qq+dKovqy7YmaErd+xVQm6XGb8VuWUcmOEbIg3nwZClAjyj/wKvSZ/F6UVMfoss6TuWWTQqZmAazgZUTLpliws9msXBRg8jwUnZXX0P9SzQdfNm/3bOnFBcZgFVLRRmI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=VgpJs8Y3; arc=none smtp.client-ip=209.85.208.48 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="VgpJs8Y3" Received: by mail-ed1-f48.google.com with SMTP id 4fb4d7f45d1cf-5c9c28c1ecbso4101920a12.0 for ; Sun, 03 Nov 2024 01:15:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621698; x=1731226498; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=yutS8FymNTV5ezMq6BbpbrCC9fB498yl7otFEg03rmA=; b=VgpJs8Y3jyKQz9oV+Tiv/Vk2Ij6q0593SLDVHNs+mhDpcHCYzSD2wML9rfL7wCYbq9 aLyyReFRRF9odb9AECu7dbDnnHsuC9R4yTFhsiw06iPPIod3klRc6A1/o4qRkk8uZ2fy 5KgFdCxxbnnJ7D5cwKQOWUNgyetWtXQmazidd/h6P/2dxNVKQ4s4gBUC0MRDcI1+/lo9 Cx+lrBTwR3qDcALwwZeJ6pO7/AMb6veRlXsPv08CFYF42TK7xNwFdDd0ystjkv5IxL/A 2t7Cx2GDaFUMmAO6YbrzGLIOOynO6LhVQwEm/sM8HGcscXGksLYwT/D/vIVF7h4cgb0f /sCQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621698; x=1731226498; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=yutS8FymNTV5ezMq6BbpbrCC9fB498yl7otFEg03rmA=; b=P3jdxVuicBkjgj1PoSAG7MhBQXlqv8t2RQ425pfWN/ovTHR0ENyaSh5DycmQ0zAJYN mDoHoWJ8fqNM5c0FaVcv9G5FJgrPgwSKrDB5t27kVbSkzDdsTTpxTawbei2Fgufv75dR 188GEsmBLrvt3Bi7TVvvFVY7Koox10HskKEa6mJ+ZTV8dF2lHIZqVxYXLtTwN2wUjyyt BLrHUA2sC6JYAhtltYFqeCmHiaHeO5qqfvJaLwACmXzUShQAE93sMckdTlDJ0Tn9WaxI T8+rA8geV8chZbGC5B01Tjk0RH0iX4nHNgbBZASk7nDon1OAWOTCP0we7Inr8I2+RlMb 8oDA== X-Forwarded-Encrypted: i=1; AJvYcCWN8PUi2evY5WMVCkchk1jvMKSrI/nDORmcGooAC0ci4TVPrMby0JhegZS28pURyJjfc9c2m0Pom/lttnU=@vger.kernel.org X-Gm-Message-State: AOJu0YxsECbzJOjOqkuB72y9Yi93fGn66F9nTKsORwvOD9mKL6H0Wdpq H3DvZgcQCmJtWYn3DkY+GH685XPgl2GNiPlyumQU7rNYCzDAeLIF X-Google-Smtp-Source: AGHT+IGAavjs6n08K+rKhBuGeAYl7JC3gaA1uuJISRnq0n/PI7gHwkPTiaQMeYSgovWc2IOJCUFEQA== X-Received: by 2002:a05:6402:1eca:b0:5cb:69de:2bca with SMTP id 4fb4d7f45d1cf-5cbbf7295b7mr22286929a12.0.1730621698441; Sun, 03 Nov 2024 01:14:58 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:58 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 11/13] staging: rtl8723bs: Remove function pointer hal_xmit Date: Sun, 3 Nov 2024 09:14:32 +0100 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Remove function pointer hal_xmit and use rtl8723bs_hal_xmit directly to increase readability. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8723bs/hal/hal_intf.c | 5 +---- drivers/staging/rtl8723bs/hal/sdio_halinit.c | 1 - drivers/staging/rtl8723bs/include/hal_intf.h | 1 - 3 files changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/staging/rtl8723bs/hal/hal_intf.c b/drivers/staging/rtl= 8723bs/hal/hal_intf.c index d45dfa8e638e..914d4b24d49d 100644 --- a/drivers/staging/rtl8723bs/hal/hal_intf.c +++ b/drivers/staging/rtl8723bs/hal/hal_intf.c @@ -162,10 +162,7 @@ s32 rtw_hal_xmitframe_enqueue(struct adapter *padapter= , struct xmit_frame *pxmit =20 s32 rtw_hal_xmit(struct adapter *padapter, struct xmit_frame *pxmitframe) { - if (padapter->HalFunc.hal_xmit) - return padapter->HalFunc.hal_xmit(padapter, pxmitframe); - - return false; + return rtl8723bs_hal_xmit(padapter, pxmitframe); } =20 /* diff --git a/drivers/staging/rtl8723bs/hal/sdio_halinit.c b/drivers/staging= /rtl8723bs/hal/sdio_halinit.c index ccf1e9727846..563ebf8e7fdb 100644 --- a/drivers/staging/rtl8723bs/hal/sdio_halinit.c +++ b/drivers/staging/rtl8723bs/hal/sdio_halinit.c @@ -1258,7 +1258,6 @@ void rtl8723bs_set_hal_ops(struct adapter *padapter) =20 rtl8723b_set_hal_ops(pHalFunc); =20 - pHalFunc->hal_xmit =3D &rtl8723bs_hal_xmit; pHalFunc->mgnt_xmit =3D &rtl8723bs_mgnt_xmit; pHalFunc->hal_xmitframe_enqueue =3D &rtl8723bs_hal_xmitframe_enqueue; } diff --git a/drivers/staging/rtl8723bs/include/hal_intf.h b/drivers/staging= /rtl8723bs/include/hal_intf.h index b69d201b6826..dfb973018e4e 100644 --- a/drivers/staging/rtl8723bs/include/hal_intf.h +++ b/drivers/staging/rtl8723bs/include/hal_intf.h @@ -180,7 +180,6 @@ struct hal_ops { void (*run_thread)(struct adapter *padapter); void (*cancel_thread)(struct adapter *padapter); =20 - s32 (*hal_xmit)(struct adapter *padapter, struct xmit_frame *pxmitframe); /* * mgnt_xmit should be implemented to run in interrupt context */ --=20 2.43.0 From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ed1-f52.google.com (mail-ed1-f52.google.com [209.85.208.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CC122183CBE for ; Sun, 3 Nov 2024 08:15:00 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.52 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621702; cv=none; b=KMivMjRrwuZ/miZW5Eex+nFQ3e5nt01kaYQWlStjIxtasVKzwXiN9/vM32PefWPiP+WaqJBTOuQr5AZW2NGkEgTw8FHF4LgkLEEyXZWJICe6n1NCAgGSTeM3OdMdTVRLG/mGMJVkYXTTCqYdxDJRVijXHimUJEhoA2wuToWupWA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621702; c=relaxed/simple; bh=u3S584myOAyZhc+GjEJWB++ki18Rk5KFE7Km+HtHP5s=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=QEeNC+tA6CUkMpF9U9mKbuMbaaNhFpso++XZZnfbRmi7GQStqDiiIzVCAoVLeMCybB2oPD37ZtUEpe0t+AqQp47ioMQ2zTJ261Sf8ZTlLNDCeFxtYNUPC6Wczvlm0gHSnTxkEKwH6/qZ/ID20+gWftCyy2yCuYSHjNh2fWsPqCQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=ORSnN5RP; arc=none smtp.client-ip=209.85.208.52 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="ORSnN5RP" Received: by mail-ed1-f52.google.com with SMTP id 4fb4d7f45d1cf-5cec8c4e2f6so1339546a12.1 for ; Sun, 03 Nov 2024 01:15:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621699; x=1731226499; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=PO6/NrbVeY70kEhJHr00qbdaCGFc5cjzkA6rnNaB7TI=; b=ORSnN5RPa+VBkMdEs4oSRD/oTd/MAEoFoit3oZYPU/JlGMEXPg2JptHkm4/AfsV1zZ tgKoTh59Ep2aDvIWuKn6T7bSyKzuL1+6/8lZIFfu16zlSu72kbBNXCcjLkpN+7jRd2wx mrlf8drFJAeFit4/ka7VS2UagGKOhadbvGXiowsJE0L1YEISdkN7M5ukmPI1ZBU7A3Be dlq8wxjA23cacCRfGEpqBj3FSD+ylJSdfn5ETkag8JbPcBgpN0br+k3sYUfIn66zvnM/ SL+InvjuJrY6mqf3YixzMVEh8/a8A8wV6YM5Wg6Yqmd7us5gXf4Rle+wx2VrMpWLRww/ S2lQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621699; x=1731226499; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=PO6/NrbVeY70kEhJHr00qbdaCGFc5cjzkA6rnNaB7TI=; b=at6ldvEs6uc07QzZQzrpVTKRGmvt635o/fCy6f8Sbwa1ckY4Zpxkqpa9/3sfhvKxkY f05QPMpjnQLlTORt4fq2C+UazCyIb83QjMCTt70AVfvwAFDjGEsd5l5WpHM2t0kT0UAA MjdIHyaQDIdteuXbfCg1I2dJ7ZT7B9jWjAyosUnaSHsqjANuDOfYxAvDybKCPm/M2aa1 mW/a82ZCnfbpnJlsk8e4hAxYzwhqFrxoZ8EdfPNCze5FzoT7WF+LSM/k52WeeoSZIl5r WgLxpSSgYTiTfDJoDhKK9csZcJ15qoihmtd/ZXkAu3qr+LXfJbQ4ECfy6bK0bAe4Yv25 nnFQ== X-Forwarded-Encrypted: i=1; AJvYcCXq3+1nw45KS03bR9ILkiHXnsaj/f2CNEpATs7wkCZ4gWRpJCvDy3OEN3LlgKIOUFee8d+g+WEY1x/21Ek=@vger.kernel.org X-Gm-Message-State: AOJu0YyxO3e7lWyYTJ0nqo12cNXmocMDFFPmqFT1Jg7nNuq7Ke4ApSYd A5btTlv59ItUKO797P+0mhVmpUfpFSc1SGRjN2j6lQ2TCgOVHNDo X-Google-Smtp-Source: AGHT+IHQKaD9j1aO4FHVRnQgsf6wIR7yxAUzxJrwvhoJYvojcAlIiW546/x5OofagafKml4hlZyUkQ== X-Received: by 2002:a05:6402:1e92:b0:5ce:d03f:68ad with SMTP id 4fb4d7f45d1cf-5ced03f6926mr1520321a12.9.1730621699020; Sun, 03 Nov 2024 01:14:59 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:58 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 12/13] staging: rtl8723bs: Remove function pointer mgnt_xmit Date: Sun, 3 Nov 2024 09:14:33 +0100 Message-ID: <59988d60701a6f83a6a83b6c813e58c4484c7d3e.1730619982.git.philipp.g.hortmann@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Remove function pointer mgnt_xmit and use rtl8723bs_mgnt_xmit directly to increase readability. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8723bs/hal/hal_intf.c | 6 +----- drivers/staging/rtl8723bs/hal/sdio_halinit.c | 1 - drivers/staging/rtl8723bs/include/hal_intf.h | 4 ---- 3 files changed, 1 insertion(+), 10 deletions(-) diff --git a/drivers/staging/rtl8723bs/hal/hal_intf.c b/drivers/staging/rtl= 8723bs/hal/hal_intf.c index 914d4b24d49d..7462b10fdc94 100644 --- a/drivers/staging/rtl8723bs/hal/hal_intf.c +++ b/drivers/staging/rtl8723bs/hal/hal_intf.c @@ -170,8 +170,6 @@ s32 rtw_hal_xmit(struct adapter *padapter, struct xmit_= frame *pxmitframe) */ s32 rtw_hal_mgnt_xmit(struct adapter *padapter, struct xmit_frame *pmgntfr= ame) { - s32 ret =3D _FAIL; - update_mgntframe_attrib_addr(padapter, pmgntframe); /* pframe =3D (u8 *)(pmgntframe->buf_addr) + TXDESC_OFFSET; */ /* pwlanhdr =3D (struct rtw_ieee80211_hdr *)pframe; */ @@ -188,9 +186,7 @@ s32 rtw_hal_mgnt_xmit(struct adapter *padapter, struct = xmit_frame *pmgntframe) rtw_mgmt_xmitframe_coalesce(padapter, pmgntframe->pkt, pmgntframe); } =20 - if (padapter->HalFunc.mgnt_xmit) - ret =3D padapter->HalFunc.mgnt_xmit(padapter, pmgntframe); - return ret; + return rtl8723bs_mgnt_xmit(padapter, pmgntframe); } =20 s32 rtw_hal_init_xmit_priv(struct adapter *padapter) diff --git a/drivers/staging/rtl8723bs/hal/sdio_halinit.c b/drivers/staging= /rtl8723bs/hal/sdio_halinit.c index 563ebf8e7fdb..20dbaa995498 100644 --- a/drivers/staging/rtl8723bs/hal/sdio_halinit.c +++ b/drivers/staging/rtl8723bs/hal/sdio_halinit.c @@ -1258,6 +1258,5 @@ void rtl8723bs_set_hal_ops(struct adapter *padapter) =20 rtl8723b_set_hal_ops(pHalFunc); =20 - pHalFunc->mgnt_xmit =3D &rtl8723bs_mgnt_xmit; pHalFunc->hal_xmitframe_enqueue =3D &rtl8723bs_hal_xmitframe_enqueue; } diff --git a/drivers/staging/rtl8723bs/include/hal_intf.h b/drivers/staging= /rtl8723bs/include/hal_intf.h index dfb973018e4e..697e22d1e535 100644 --- a/drivers/staging/rtl8723bs/include/hal_intf.h +++ b/drivers/staging/rtl8723bs/include/hal_intf.h @@ -180,10 +180,6 @@ struct hal_ops { void (*run_thread)(struct adapter *padapter); void (*cancel_thread)(struct adapter *padapter); =20 - /* - * mgnt_xmit should be implemented to run in interrupt context - */ - s32 (*mgnt_xmit)(struct adapter *padapter, struct xmit_frame *pmgntframe); s32 (*hal_xmitframe_enqueue)(struct adapter *padapter, struct xmit_frame = *pxmitframe); =20 u32 (*read_bbreg)(struct adapter *padapter, u32 RegAddr, u32 BitMask); --=20 2.43.0 From nobody Sun Nov 24 20:09:05 2024 Received: from mail-ej1-f45.google.com (mail-ej1-f45.google.com [209.85.218.45]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5F0481865E7 for ; Sun, 3 Nov 2024 08:15:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.45 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621703; cv=none; b=AydAd+qfWd68GmMafQHN1GaIS7ePp21Tm6Yeu7K/Mym7q9mV/D4Ix6n6wM92bVMY22KwG9LMrmQrMVlx3NYOWYb5r+g44VHobAOcPWbjLxQeOjKMtIikuvGLH1L71n6maRhTCI/pNxhSel8JmPVT/2DW4QTBXBAahXvSLJH5uvM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730621703; c=relaxed/simple; bh=jkK8jOTPw4ceO2WyllAi7vTxuRvpVOG1mCqa8/gQJ2g=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=kL8rEm02/jqceShimTUYLvCBW7wDMrKzmTqRzx38DOiUEr8PxqEO5CQ4upw+eotKY5EsAZfO8IenFry+zzPmoWdP5fgYGdQslyjQ4TC3c3Zp6bhP8jcPrB1RX/3JsR05aXIuQdsvsIMVSw4sA6cDTwhdXQ9hBmGoUz2wcIHai4c= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=miLRTZ5c; arc=none smtp.client-ip=209.85.218.45 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="miLRTZ5c" Received: by mail-ej1-f45.google.com with SMTP id a640c23a62f3a-a9a977d6cc7so247183066b.3 for ; Sun, 03 Nov 2024 01:15:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730621700; x=1731226500; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=kKAdswjmHcute+NZI8i4OymPZIsBGcO1QIhXFS046nc=; b=miLRTZ5cyUqlzLuxG2ovPH5FAS2oGNjFmjJxi84ISuQzD1dKtmSpnha/xEDaLALzAr OupkNa4t6rc+n2xSBtaVCx3HNnzH0HixW/2PF7fKU3IhEef4tOj2HZAuxuluZ4RxCll4 k6gf3w9fFuTNWHjA92AF6G+krxSW5ohx7yBU45VbTN1HD27C4HlHFm0NeCX1bvXBfxeD HBQdWu/QJ1AzOUqTp/CipNlfcEWAv6YjoqiiJjaYggCJPjs3PCJkv6alzXAEBqlsc67i yauOGAHbyqimysbLN5roNZjJTFfSGEN6HJ79tccV/DkPWxX4P+d+j6ZC58FsxJLM1uCL 2XnA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730621700; x=1731226500; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=kKAdswjmHcute+NZI8i4OymPZIsBGcO1QIhXFS046nc=; b=dJm3r85Wh52pLcFUKsUuV4CQ5glPRjw5oIn8ltI443ngJ5asmHkgz8bb62BG5kLlR4 uojaens1yxkBQ6/jPE3VKisoadn4PqHXnzPHU1LI1dATtETFh2pGdkSJWqETZglaQqEZ 54x4ziUPNwmYFdD4d4D32mkjijGdqiQxrAuTMlmsAklnVcb9IikSXc2q4GDUDOnhrBpO NbBjWnwAr5CHPf+PUo8SJz5Gy2I5EPsHTLUKFZ/5/WUns+VePisYYXsiU2IdSAuhmBZr qmbyY1RavM5d8B1c0kc2DAzH5IrKCxnNYf5A0o7V7yG79brldDykU3yq89FLCzMZCLpA ya3g== X-Forwarded-Encrypted: i=1; AJvYcCUEiK/spiQUeo9+4ipUAC2b05OSAuVxf7/DdDv2FGtF+EjwjXXHtwS/K+kIMkgFmRWhWRG9pJ7tK/Nt3M4=@vger.kernel.org X-Gm-Message-State: AOJu0Yy2EXplrF3lCgw6Ct9eGuYgXZx1eds2vMcj8C8jfLNJwt4erDxR nthGpRbWOYRZcMim+lNUAKeKxGFag4TIBPIInuOJ2ISFACuFdAHee9R8Fg== X-Google-Smtp-Source: AGHT+IHAGZc+jJdciJW90mbaXsaA9+aX6wbsgFfRGCPVMrIq5s9KIscNPootxVjfas+RADlB9Bsh9Q== X-Received: by 2002:a05:6402:5c9:b0:5ca:efe:10de with SMTP id 4fb4d7f45d1cf-5ceb9382a40mr10610643a12.30.1730621699641; Sun, 03 Nov 2024 01:14:59 -0700 (PDT) Received: from kernel-710.speedport.ip (p54a0712c.dip0.t-ipconnect.de. [84.160.113.44]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5ceac789152sm3097882a12.43.2024.11.03.01.14.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Nov 2024 01:14:59 -0700 (PDT) From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Philipp Hortmann Subject: [PATCH 13/13] staging: rtl8723bs: Remove function pointer hal_xmitframe_enqueue Date: Sun, 3 Nov 2024 09:14:34 +0100 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Remove function pointer hal_xmitframe_enqueue and use rtl8723bs_hal_xmitframe_enqueue directly to increase readability. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8723bs/hal/hal_intf.c | 5 +---- drivers/staging/rtl8723bs/hal/sdio_halinit.c | 1 - drivers/staging/rtl8723bs/include/hal_intf.h | 2 -- 3 files changed, 1 insertion(+), 7 deletions(-) diff --git a/drivers/staging/rtl8723bs/hal/hal_intf.c b/drivers/staging/rtl= 8723bs/hal/hal_intf.c index 7462b10fdc94..8b924961789e 100644 --- a/drivers/staging/rtl8723bs/hal/hal_intf.c +++ b/drivers/staging/rtl8723bs/hal/hal_intf.c @@ -154,10 +154,7 @@ u8 rtw_hal_check_ips_status(struct adapter *padapter) =20 s32 rtw_hal_xmitframe_enqueue(struct adapter *padapter, struct xmit_frame = *pxmitframe) { - if (padapter->HalFunc.hal_xmitframe_enqueue) - return padapter->HalFunc.hal_xmitframe_enqueue(padapter, pxmitframe); - - return false; + return rtl8723bs_hal_xmitframe_enqueue(padapter, pxmitframe); } =20 s32 rtw_hal_xmit(struct adapter *padapter, struct xmit_frame *pxmitframe) diff --git a/drivers/staging/rtl8723bs/hal/sdio_halinit.c b/drivers/staging= /rtl8723bs/hal/sdio_halinit.c index 20dbaa995498..af9a2b068796 100644 --- a/drivers/staging/rtl8723bs/hal/sdio_halinit.c +++ b/drivers/staging/rtl8723bs/hal/sdio_halinit.c @@ -1258,5 +1258,4 @@ void rtl8723bs_set_hal_ops(struct adapter *padapter) =20 rtl8723b_set_hal_ops(pHalFunc); =20 - pHalFunc->hal_xmitframe_enqueue =3D &rtl8723bs_hal_xmitframe_enqueue; } diff --git a/drivers/staging/rtl8723bs/include/hal_intf.h b/drivers/staging= /rtl8723bs/include/hal_intf.h index 697e22d1e535..7050520224ff 100644 --- a/drivers/staging/rtl8723bs/include/hal_intf.h +++ b/drivers/staging/rtl8723bs/include/hal_intf.h @@ -180,8 +180,6 @@ struct hal_ops { void (*run_thread)(struct adapter *padapter); void (*cancel_thread)(struct adapter *padapter); =20 - s32 (*hal_xmitframe_enqueue)(struct adapter *padapter, struct xmit_frame = *pxmitframe); - u32 (*read_bbreg)(struct adapter *padapter, u32 RegAddr, u32 BitMask); void (*write_bbreg)(struct adapter *padapter, u32 RegAddr, u32 BitMask, u= 32 Data); u32 (*read_rfreg)(struct adapter *padapter, u8 eRFPath, u32 RegAddr, u32 = BitMask); --=20 2.43.0