From patchwork Sun Jan 8 18:57:31 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Kaiser X-Patchwork-Id: 40547 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp1818968wrt; Sun, 8 Jan 2023 11:08:49 -0800 (PST) X-Google-Smtp-Source: AMrXdXu9RHFlQwbnLmFsfWDTOJRWmpnSLQGzH0Z4Dr4pocliduM1MmO4rz683qgA7075KmCss2dG X-Received: by 2002:a05:6a20:b297:b0:9d:efbf:7880 with SMTP id ei23-20020a056a20b29700b0009defbf7880mr64673688pzb.53.1673204928735; Sun, 08 Jan 2023 11:08:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673204928; cv=none; d=google.com; s=arc-20160816; b=fTFfAVUIdXf7EZruCD6LKgy/FRJYe2V1cT6x8CZ46nOEyog2fNImJIrRifp+IDiJrF kimhsCV8pEOSlPwfI/lhAwAE8DkDjHp1bTCGGmML34xfnvjin9CRyuD+tp/pEffK2GmI LuN6tYXJJTMr0DJRZKYB1QqQTyRCMPMFa/YBpviQklfLRh1sIBTgnrav86+ZxhSppwdz eO+t7vTO3eGDzryLlcIhKjO+Rf2ZuQ+9LeEFijZWmoO7oZGCQewlI2pLR2RUCB+kGazz 2RlDbepFf7oX2R8sjPZayfrGNIu74iNIgUxY2d3/aYzKIunzw+1iMb0N+9aNDFL4XViA sjpA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=PY0VlsgrVl/sK6zaC477MUVyc2aqp4UHobjVkHm/JGY=; b=Y6/8TEg3hsUR4l9QG95ziTfTfZxlo2QE2/Qx5gAhNqEZsvIHSTcH+B2QrynLm6I3+N E/CpDoPRUI6USH5c8LbZcL1nzYvAm1AxImrxXxNLeZQNoeUMNo2f9QqW8f2Mkpes7GRG phMA9pns+Q2SoTQEuCbAlfoWguyVheojzYP1w0tkgS1skryx5UbxfLdvzlmhMSEU39DY agwSUTfRm1Q+FEsj0TdCN9+19/Oik5cN+l9iv3lcFlY9A3lYYhXcJHMLfdX84Txp5F5Y Fc/DplvLDPamLT73YcxbXbJ7rfEAh9WQ44bYmY54zpvRnZpN6+uEBp1pVcJQ5szyvIVT cR2w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w62-20020a638241000000b004b3b04315cbsi1033698pgd.365.2023.01.08.11.08.36; Sun, 08 Jan 2023 11:08:48 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236573AbjAHS6b (ORCPT + 99 others); Sun, 8 Jan 2023 13:58:31 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35496 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235956AbjAHS6C (ORCPT ); Sun, 8 Jan 2023 13:58:02 -0500 Received: from viti.kaiser.cx (viti.kaiser.cx [IPv6:2a01:238:43fe:e600:cd0c:bd4a:7a3:8e9f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 51601E00C for ; Sun, 8 Jan 2023 10:58:02 -0800 (PST) Received: from dslb-188-096-147-053.188.096.pools.vodafone-ip.de ([188.96.147.53] helo=martin-debian-2.paytec.ch) by viti.kaiser.cx with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.89) (envelope-from ) id 1pEari-0003b8-UQ; Sun, 08 Jan 2023 19:57:55 +0100 From: Martin Kaiser To: Greg Kroah-Hartman Cc: Larry Finger , Phillip Potter , Michael Straube , Pavel Skripkin , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, Martin Kaiser Subject: [PATCH 06/13] staging: r8188eu: make rtl8188eu_inirp_init a void function Date: Sun, 8 Jan 2023 19:57:31 +0100 Message-Id: <20230108185738.597105-7-martin@kaiser.cx> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20230108185738.597105-1-martin@kaiser.cx> References: <20230108185738.597105-1-martin@kaiser.cx> MIME-Version: 1.0 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1754482531385588032?= X-GMAIL-MSGID: =?utf-8?q?1754482531385588032?= rtl8188eu_inirp_init's return value is not checked by its caller. Make rtl8188eu_inirp_init a void function. Signed-off-by: Martin Kaiser --- drivers/staging/r8188eu/hal/usb_halinit.c | 14 +++----------- drivers/staging/r8188eu/include/hal_intf.h | 2 +- 2 files changed, 4 insertions(+), 12 deletions(-) diff --git a/drivers/staging/r8188eu/hal/usb_halinit.c b/drivers/staging/r8188eu/hal/usb_halinit.c index d28b4dc2a767..afa24a59fbb3 100644 --- a/drivers/staging/r8188eu/hal/usb_halinit.c +++ b/drivers/staging/r8188eu/hal/usb_halinit.c @@ -851,29 +851,21 @@ u32 rtl8188eu_hal_deinit(struct adapter *Adapter) return _SUCCESS; } -unsigned int rtl8188eu_inirp_init(struct adapter *Adapter) +void rtl8188eu_inirp_init(struct adapter *Adapter) { u8 i; struct recv_buf *precvbuf; - uint status; struct recv_priv *precvpriv = &Adapter->recvpriv; - status = _SUCCESS; - /* issue Rx irp to receive data */ precvbuf = (struct recv_buf *)precvpriv->precv_buf; for (i = 0; i < NR_RECVBUFF; i++) { - if (!rtw_read_port(Adapter, (unsigned char *)precvbuf)) { - status = _FAIL; - goto exit; - } + if (!rtw_read_port(Adapter, (unsigned char *)precvbuf)) + return; precvbuf++; precvpriv->free_recv_buf_queue_cnt--; } - -exit: - return status; } /* */ diff --git a/drivers/staging/r8188eu/include/hal_intf.h b/drivers/staging/r8188eu/include/hal_intf.h index ac6e3f95c5b7..767f97c5f85d 100644 --- a/drivers/staging/r8188eu/include/hal_intf.h +++ b/drivers/staging/r8188eu/include/hal_intf.h @@ -26,7 +26,7 @@ void UpdateHalRAMask8188EUsb(struct adapter *adapt, u32 mac_id, u8 rssi_level); int rtl8188e_IOL_exec_cmds_sync(struct adapter *adapter, struct xmit_frame *xmit_frame, u32 max_wating_ms, u32 bndy_cnt); -unsigned int rtl8188eu_inirp_init(struct adapter *Adapter); +void rtl8188eu_inirp_init(struct adapter *Adapter); uint rtw_hal_init(struct adapter *padapter); uint rtw_hal_deinit(struct adapter *padapter);