From patchwork Thu Sep 19 14:21:30 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Umang Jain X-Patchwork-Id: 13807792 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 015A2CF3943 for ; Thu, 19 Sep 2024 14:26:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From: Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=ytOHOtitYKjfzH6JrzwRjFKL1+KTG9Ye23/woSo9ubY=; b=2e/tBk5WfNc3bgknm0qh/bs6xH SYRE3tfcU4PZrPJS7YhziGPplX3mOjJc/9qnMG/hO4A/68W36cysuE/Ld1CRHOQVkLV6Tvs/xgwqd jTk54mSKq8P3hmh//9MyxeF1qqr4us5xGORs1kngX2WzP++f5zrK6muDmDeAvWnc2RPmR25UonHm3 pqXm5w0ZMAUatOgpruvfH+Vo2vZiRZwbrsSSzzGbNUWvvcccWFi7w3bk+Oz0OxJxRCiDxzrEAQfNr lSVukZ88M3jFoCpI+HyZS30yOEVEDX+Ds6PIM8Ys97kqF/Ccom9Wpq2fMYLyOutU87KxEdlqZ9KKL /2FBv3Xg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1srI6r-0000000ARzk-0tQn; Thu, 19 Sep 2024 14:26:17 +0000 Received: from perceval.ideasonboard.com ([213.167.242.64]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1srI2Y-0000000ARB3-0uWA; Thu, 19 Sep 2024 14:21:51 +0000 Received: from umang.jain (unknown [IPv6:2405:201:2015:f873:55d7:c02e:b2eb:ee3f]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 57076FF6; Thu, 19 Sep 2024 16:20:24 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1726755625; bh=+G1ALUjL+2EMlZ/KTTRa4nLLszzAdAcmC+aiCIRahjg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=lCPwC6O79Dn3Zym20FK7+k1qE0vlzxuiNYt8sjl/ePObMZCVGIzEdHpYghik0oV8W h/vRnBqrFFyZSmkvv1gWtFm6Mn1woScpk2P9UuNZxv1/UMbCW77qbBbqNQeAtv2M5W 5TWSgDBvLsjTCNWep/4i5KDKEHUj1igoGH1ESNro= From: Umang Jain To: Greg Kroah-Hartman , Broadcom internal kernel review list Cc: linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, Kieran Bingham , Stefan Wahren , Umang Jain Subject: [PATCH 3/3] staging: vchiq_core: Drop vchiq_pagelist.h Date: Thu, 19 Sep 2024 19:51:30 +0530 Message-ID: <20240919142130.1331495-4-umang.jain@ideasonboard.com> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20240919142130.1331495-1-umang.jain@ideasonboard.com> References: <20240919142130.1331495-1-umang.jain@ideasonboard.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240919_072150_425268_DDBF2B7A X-CRM114-Status: GOOD ( 13.16 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org vchiq_pagelist.h only defines one struct and a couple of macros. It can be merged with vchiq_core since all the pagelist related function helpers are now in vchiq_core for bulk transfers. Move the struct and related macros to vchiq_core header and drop vchiq_pagelist.h. Signed-off-by: Umang Jain --- .../interface/vchiq_arm/vchiq_core.c | 4 ++++ .../interface/vchiq_arm/vchiq_core.h | 11 +++++++++- .../interface/vchiq_arm/vchiq_pagelist.h | 21 ------------------- 3 files changed, 14 insertions(+), 22 deletions(-) delete mode 100644 drivers/staging/vc04_services/interface/vchiq_arm/vchiq_pagelist.h diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c index 586c41cd1ed5..1281f3bc5548 100644 --- a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c +++ b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c @@ -63,6 +63,10 @@ #define MAKE_REMOTE_USE (VCHIQ_MSG_REMOTE_USE << TYPE_SHIFT) #define MAKE_REMOTE_USE_ACTIVE (VCHIQ_MSG_REMOTE_USE_ACTIVE << TYPE_SHIFT) +#define PAGELIST_WRITE 0 +#define PAGELIST_READ 1 +#define PAGELIST_READ_WITH_FRAGMENTS 2 + #define BELL2 0x08 /* Ensure the fields are wide enough */ diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.h b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.h index 6662dd21e827..400472f1aa06 100644 --- a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.h +++ b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.h @@ -17,7 +17,6 @@ #include "../../include/linux/raspberrypi/vchiq.h" #include "vchiq_cfg.h" -#include "vchiq_pagelist.h" /* Do this so that we can test-build the code on non-rpi systems */ #if IS_ENABLED(CONFIG_RASPBERRYPI_FIRMWARE) @@ -411,6 +410,16 @@ struct vchiq_state { struct opaque_platform_state *platform_state; }; +struct pagelist { + u32 length; + u16 type; + u16 offset; + u32 addrs[1]; /* N.B. 12 LSBs hold the number + * of following pages at consecutive + * addresses. + */ +}; + struct vchiq_pagelist_info { struct pagelist *pagelist; size_t pagelist_buffer_size; diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_pagelist.h b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_pagelist.h deleted file mode 100644 index ebd12bfabb63..000000000000 --- a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_pagelist.h +++ /dev/null @@ -1,21 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */ -/* Copyright (c) 2010-2012 Broadcom. All rights reserved. */ - -#ifndef VCHIQ_PAGELIST_H -#define VCHIQ_PAGELIST_H - -#define PAGELIST_WRITE 0 -#define PAGELIST_READ 1 -#define PAGELIST_READ_WITH_FRAGMENTS 2 - -struct pagelist { - u32 length; - u16 type; - u16 offset; - u32 addrs[1]; /* N.B. 12 LSBs hold the number - * of following pages at consecutive - * addresses. - */ -}; - -#endif /* VCHIQ_PAGELIST_H */