From patchwork Tue Feb 8 12:40:23 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chen-Yu Tsai X-Patchwork-Id: 12738649 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 97FDCC433F5 for ; Tue, 8 Feb 2022 12:55:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=GPHbC4S+7VKaXNDQs12MFxEQS/cQ6jAb9CI9T2WZSsw=; b=dQmE0J83p8gr/C OiP6aNQ+wVOkjVFXQTpUyKqIjqGZ2W9O1QTH70DSJsF1e8K59tGNGSAWNljIJ3tyx+yme6OHw37vk NRLkoPebvMeP6DZYxELR5NGkBpceRVB6u9lwz828NEORMTHo6akbiJw7u1mZiV1COF1lfx677s31R KJYPUSaq/LIYmfo8FiB/4DNhv2ky7JH1ZQFGyjYspolawneAha/Nkn4fr9MuOHFpkWzcRkxqTjrwu qd+2cozu8XJQw6/hRi/b6MEi8AuW8CgIxcBG0GXyB29VG4BuWt4ogC9fWLmByk18igP6RC7cZ3qzr epdksu5g4uwgYyCPm2sw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nHQ0A-00DtKk-M0; Tue, 08 Feb 2022 12:53:47 +0000 Received: from mail-pj1-x1033.google.com ([2607:f8b0:4864:20::1033]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nHPoL-00Dnaf-I8 for linux-arm-kernel@lists.infradead.org; Tue, 08 Feb 2022 12:41:35 +0000 Received: by mail-pj1-x1033.google.com with SMTP id d9-20020a17090a498900b001b8bb1d00e7so2597901pjh.3 for ; Tue, 08 Feb 2022 04:41:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=VlKtM6FjYA2dZO07upzgd9Pj04Wu97J4dVvK+jUNEck=; b=OrSsQvFFXKSurEYBIMXb9+NOJkRn42Oayov78oivR7/II3RzfciYs9zq3TiYOFrMzf 3SFpboZilv9rJrVtd6Mqd+OI2aCWZyLByJAU36g2KxT8SNQmX4c40+48wnG5jbzXE7Yp XwQ3RYW83qUfjx5/1bULaTZ4NuYSzeASJdaqY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=VlKtM6FjYA2dZO07upzgd9Pj04Wu97J4dVvK+jUNEck=; b=zK+T5Rhe1/leGvL2mIuJPhrZlf6iMT4eq25NF+ewe494Zua0LV5pZVDMvO3lhoexDj l3JrlQU3/kBw0n0aAooRXyURkb0s1fkYfaNcdQP7vivQdVoxMdFNgITyDc5WiDItQE46 lWqNsP5VUPlCzi9XdmOLlv+ok0VqVIkoK4dtPVa2oCq8Qh2UWXSSopqPrg8fMth1AwmO DjLTTPEQ+9uVLEDB45hlftPe4pqdpXg/0XbOk9r1sN6w9e8eUDOMOxcIF0mTc6qD9Xsz ApQCKHmA9n/LItImGG/Xc46jn7luZlMY0tjMzp+vsbYi2sF7exDLXw6pPvGxq54aGvry 0s7g== X-Gm-Message-State: AOAM5334W1r1bcq3/lCTE1YElwnonhGARFLS2Y8l15b44yu/RttQQS2V i6fxlhmtifcrGrKqsFONONuPAQ== X-Google-Smtp-Source: ABdhPJyZtnIS5wvMBJfJ1PfBAFwhwCamW3QkOJc8pTKF0a7UI+1Dj2KYovaMuZBY9GlrF4L1rpycuQ== X-Received: by 2002:a17:902:a603:: with SMTP id u3mr4462853plq.113.1644324092333; Tue, 08 Feb 2022 04:41:32 -0800 (PST) Received: from wenstp920.tpe.corp.google.com ([2401:fa00:1:10:41b6:813e:c823:609c]) by smtp.gmail.com with ESMTPSA id h11sm15056939pfe.214.2022.02.08.04.41.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Feb 2022 04:41:32 -0800 (PST) From: Chen-Yu Tsai To: Stephen Boyd , Michael Turquette , Matthias Brugger Cc: Chen-Yu Tsai , Chun-Jie Chen , AngeloGioacchino Del Regno , Miles Chen , linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 20/31] clk: mediatek: mtk: Clean up included headers Date: Tue, 8 Feb 2022 20:40:23 +0800 Message-Id: <20220208124034.414635-21-wenst@chromium.org> X-Mailer: git-send-email 2.35.0.263.gb82422642f-goog In-Reply-To: <20220208124034.414635-1-wenst@chromium.org> References: <20220208124034.414635-1-wenst@chromium.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220208_044133_634589_B8B808FE X-CRM114-Status: GOOD ( 12.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 Some included headers aren't actually used anywhere, while other headers with the declaration of functions and structures aren't directly included. Get rid of the unused ones, and add the ones that should be included directly. On the header side, replace headers that are included purely for data structure definitions with forward declarations. This decreases the amount of preprocessing and compilation effort required for each inclusion. Signed-off-by: Chen-Yu Tsai Reviewed-by: Miles Chen Reviewed-by: AngeloGioacchino Del Regno Reviewed-by: Chun-Jie Chen --- drivers/clk/mediatek/clk-mtk.c | 13 ++++++------- drivers/clk/mediatek/clk-mtk.h | 12 ++++++------ 2 files changed, 12 insertions(+), 13 deletions(-) diff --git a/drivers/clk/mediatek/clk-mtk.c b/drivers/clk/mediatek/clk-mtk.c index f108786caeda..5618c84e4e08 100644 --- a/drivers/clk/mediatek/clk-mtk.c +++ b/drivers/clk/mediatek/clk-mtk.c @@ -4,17 +4,16 @@ * Author: James Liao */ -#include -#include +#include +#include #include #include -#include -#include -#include -#include #include -#include +#include +#include #include +#include +#include #include "clk-mtk.h" #include "clk-gate.h" diff --git a/drivers/clk/mediatek/clk-mtk.h b/drivers/clk/mediatek/clk-mtk.h index 4fa658f5d934..7f902581a115 100644 --- a/drivers/clk/mediatek/clk-mtk.h +++ b/drivers/clk/mediatek/clk-mtk.h @@ -7,19 +7,19 @@ #ifndef __DRV_CLK_MTK_H #define __DRV_CLK_MTK_H -#include -#include #include -#include - -struct clk; -struct clk_onecell_data; +#include +#include +#include +#include #define MAX_MUX_GATE_BIT 31 #define INVALID_MUX_GATE_BIT (MAX_MUX_GATE_BIT + 1) #define MHZ (1000 * 1000) +struct platform_device; + struct mtk_fixed_clk { int id; const char *name;