From patchwork Thu Jun 20 09:17:06 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vasanthakumar Thiagarajan X-Patchwork-Id: 11006239 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B58D114BB for ; Thu, 20 Jun 2019 09:17:36 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A40AB285F0 for ; Thu, 20 Jun 2019 09:17:36 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 97E82285FD; Thu, 20 Jun 2019 09:17:36 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 3DE32285F0 for ; Thu, 20 Jun 2019 09:17:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:List-Subscribe:List-Help: List-Post:List-Archive:List-Unsubscribe:List-Id:Message-Id:Date:Subject:To: From:Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=PEPdOpvMMXs3bxnGVlp70XLp/nStGzRe+iE57zZKVtg=; b=P/ToN7nlXyrZS4 5sg4WQwsDaVSynniA2drYszT9xnyP6OItX6Ctg1FBeAc2rHmiWFsPJIYT32n/OaT43XbhCkg9jLJh OjmXDFasSjWNSgMu8XUpZwCC1tRhSXlDCgmjgv076n8ybsV94W4/pKxzOjjBDYntzXm7ePrihSL14 AwHHyDRqvFkX+vOToU9CS77lNzzpXALTECC7DVxIbqZGhXf3N6983otsCz44ksAuFcI0R12cNTI88 D0XPmZhiGcz2535uVH+IEQtUDDx4CsgZApTFDr4e1E7rWC7id7xQI743nqQFyz6VBXaxdA2F+6hhr V9LptE4k67DL2baTkZHg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1hdtCH-0000tj-WB; Thu, 20 Jun 2019 09:17:34 +0000 Received: from smtp.codeaurora.org ([198.145.29.96]) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1hdtCE-0000sI-Ks for ath11k@lists.infradead.org; Thu, 20 Jun 2019 09:17:31 +0000 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id A2AF260C60; Thu, 20 Jun 2019 09:17:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1561022249; bh=AIHZJbDEVgWSJ7cP16II83IQDv7S0lnpQT8K8UAU87g=; h=From:To:Subject:Date:From; b=Q399Uw9tIFhTdyvyv0mhp7U1coCVT5y/a66QdbDvlLTG+XtZ+OEIZ9aDbU0T1Qwre iqJRDueHXIANNT2LTPZeVjtoWZtOM0Wu+zQWUMcyn1mKzvLi5TegbyoMWbFvyThXx6 FsaJncWiM88aTU8GGkgaXb04fEmXthTcDrm0ULW8= Received: from vasanth-lnx.qca.qualcomm.com (blr-c-bdr-fw-01_globalnat_allzones-outside.qualcomm.com [103.229.19.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: vthiagar@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 9733060254 for ; Thu, 20 Jun 2019 09:17:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1561022249; bh=AIHZJbDEVgWSJ7cP16II83IQDv7S0lnpQT8K8UAU87g=; h=From:To:Subject:Date:From; b=Q399Uw9tIFhTdyvyv0mhp7U1coCVT5y/a66QdbDvlLTG+XtZ+OEIZ9aDbU0T1Qwre iqJRDueHXIANNT2LTPZeVjtoWZtOM0Wu+zQWUMcyn1mKzvLi5TegbyoMWbFvyThXx6 FsaJncWiM88aTU8GGkgaXb04fEmXthTcDrm0ULW8= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 9733060254 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=vthiagar@codeaurora.org From: Vasanthakumar Thiagarajan To: ath11k@lists.infradead.org Subject: [PATCH V2 1/4] ath11k: Clean up void *per_transfer_context[] in ce Date: Thu, 20 Jun 2019 14:47:06 +0530 Message-Id: <1561022229-854-1-git-send-email-vthiagar@codeaurora.org> X-Mailer: git-send-email 1.9.1 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190620_021730_724530_4B658B22 X-CRM114-Status: GOOD ( 10.23 ) X-BeenThere: ath11k@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "ath11k" Errors-To: ath11k-bounces+patchwork-ath11k=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Since per_transfer_context is used as an array of skb pointer always no need that to be an array of void *. Signed-off-by: Vasanthakumar Thiagarajan --- V2: - Dropped "[PATCH 4/5] ath11k: Clean up link_desc_addr buffer typecast" from the series. This will be addressed later. drivers/net/wireless/ath/ath11k/ce.c | 9 ++++----- drivers/net/wireless/ath/ath11k/ce.h | 2 +- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/drivers/net/wireless/ath/ath11k/ce.c b/drivers/net/wireless/ath/ath11k/ce.c index b9a57ec..048adc1 100644 --- a/drivers/net/wireless/ath/ath11k/ce.c +++ b/drivers/net/wireless/ath/ath11k/ce.c @@ -212,7 +212,7 @@ static int ath11k_ce_rx_post_pipe(struct ath11k_ce_pipe *pipe) } static int ath11k_ce_completed_recv_next(struct ath11k_ce_pipe *pipe, - void **context, int *nbytes) + struct sk_buff **context, int *nbytes) { struct ath11k_base *ab = pipe->sc; struct hal_srng *srng; @@ -270,8 +270,7 @@ static void ath11k_ce_recv_process_cb(struct ath11k_ce_pipe *pipe) int ret; __skb_queue_head_init(&list); - while (ath11k_ce_completed_recv_next(pipe, (void **)&skb, - &nbytes) == 0) { + while (ath11k_ce_completed_recv_next(pipe, &skb, &nbytes) == 0) { max_nbytes = skb->len + skb_tailroom(skb); dma_unmap_single(ab->dev, ATH11K_SKB_RXCB(skb)->paddr, max_nbytes, DMA_FROM_DEVICE); @@ -303,7 +302,7 @@ static void ath11k_ce_recv_process_cb(struct ath11k_ce_pipe *pipe) } static int ath11k_ce_completed_send_next(struct ath11k_ce_pipe *pipe, - void **transfer_contextp) + struct sk_buff **transfer_contextp) { struct ath11k_base *ab = pipe->sc; struct hal_srng *srng; @@ -349,7 +348,7 @@ static void ath11k_ce_send_done_cb(struct ath11k_ce_pipe *pipe) struct ath11k_base *ab = pipe->sc; struct sk_buff *skb; - while (ath11k_ce_completed_send_next(pipe, (void **)&skb) == 0) { + while (ath11k_ce_completed_send_next(pipe, &skb) == 0) { if (!skb) continue; diff --git a/drivers/net/wireless/ath/ath11k/ce.h b/drivers/net/wireless/ath/ath11k/ce.h index f9b5a0e..9f25bad 100644 --- a/drivers/net/wireless/ath/ath11k/ce.h +++ b/drivers/net/wireless/ath/ath11k/ce.h @@ -139,7 +139,7 @@ struct ath11k_ce_ring { u32 hal_ring_id; /* keep last */ - void *per_transfer_context[0]; + struct sk_buff *per_transfer_context[0]; }; struct ath11k_ce_pipe {