From patchwork Fri Apr 21 03:46:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?V2FsdGVyIENoYW5nICjlvLXntq3lk7Ip?= X-Patchwork-Id: 86131 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp794957vqo; Thu, 20 Apr 2023 20:49:16 -0700 (PDT) X-Google-Smtp-Source: AKy350Z83Z8MziJjuc3DdLZKosnV/RoucjE5OREpkCVja81z42OcTQ+M+PJZJUy2XoMscPmJBwo4 X-Received: by 2002:a17:90a:cc0b:b0:237:62f7:3106 with SMTP id b11-20020a17090acc0b00b0023762f73106mr3485735pju.17.1682048955942; Thu, 20 Apr 2023 20:49:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682048955; cv=none; d=google.com; s=arc-20160816; b=BIWUpI6+xuACJabLnEUfzUYBi2kc0OLE/K8qd83lFNfaVYGv866pqDFknIwBPCdMFA +Uh6Zos/Djvg/EeUqJm+rABq5iOZuBUNT3J+Wwp+Hq0N1Kz3XBaxnWD5fWVMQ85aTKHe FqZtjelzD5BS0YkLbqKhaj9Pk/D2eLJKL1xbXhs/gYMNRgyrdbze03rRdQlGmIpZZ/8J MsNveq8C9oltI4ufCeMZ1IjiBQQm/hJ+da0+2Z6nTSOixknP6u+cexYcZQJfW1zw+Y4l YiCS8/5/9AjrLtx3SFO0NSVCbo9sW9iLS6J/PilfdUWI+8W96DOO30unkbpAKLNAVkBv 5shg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=53j2Zr5g1CHI4OUeg0l8fF8afX2h7OOtLqGtKgBQpXk=; b=O5j1LWYXPv9XGGOuepbvfSev9jVCmNU5pVZK/mMji4yppdRQ/wCdV9T6THrQTQOgJx JSUVrVQpkY9RZp4q9rFC3RGp2weL7GK7wNIAFLMlPuQyG/bHo3si6XrMYYtYXTog2Ki6 Hgo1wtnks+bbnSk8h/HstQfKcucAvH/jGGEquvWjXCuiSdlb7RiMWzKaEN/yuGyVQ0gA tWd/dwoGjg4ovHwaJshHLZBVigGDB42DzotosJjZVQEQ8EXNBQRiLgY/8iRRWjpevX+k sTvKRuMmie3l0kDaHEKou2zKJTHG2TyCoGTDCKYEs1TuFoTQenk2n9Oh8e7pL9Ycy1hm gJTA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=FppUqMuU; 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; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w6-20020a170902e88600b001a6c524c18asi1999772plg.40.2023.04.20.20.49.01; Thu, 20 Apr 2023 20:49:15 -0700 (PDT) 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; dkim=pass header.i=@mediatek.com header.s=dk header.b=FppUqMuU; 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; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233719AbjDUDsB (ORCPT + 99 others); Thu, 20 Apr 2023 23:48:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45532 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233699AbjDUDr5 (ORCPT ); Thu, 20 Apr 2023 23:47:57 -0400 Received: from mailgw02.mediatek.com (unknown [210.61.82.184]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 71D374481 for ; Thu, 20 Apr 2023 20:47:54 -0700 (PDT) X-UUID: 4814df98dff711edb6b9f13eb10bd0fe-20230421 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=53j2Zr5g1CHI4OUeg0l8fF8afX2h7OOtLqGtKgBQpXk=; b=FppUqMuU4gcz0NMiKgDRxxsoMasocPzdOVEdDOh/ogmK0x/LBuVOGAtFYtc9FlnOBHR/oXMlC8HB8JWF+XEynP2jv42YHL3QVBFdBkjWIJIXjI6SkGrZzeuu6Poam07d6PKIB8J+mDJ/q9nWZi/1ul2hF1GRZ+O3mh4CKVjpFbk=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.22,REQID:e2c56df9-0e1e-4870-b85a-a8417bedd029,IP:0,U RL:0,TC:0,Content:-5,EDM:0,RT:0,SF:95,FILE:0,BULK:0,RULE:Release_Ham,ACTIO N:release,TS:90 X-CID-INFO: VERSION:1.1.22,REQID:e2c56df9-0e1e-4870-b85a-a8417bedd029,IP:0,URL :0,TC:0,Content:-5,EDM:0,RT:0,SF:95,FILE:0,BULK:0,RULE:Spam_GS981B3D,ACTIO N:quarantine,TS:90 X-CID-META: VersionHash:120426c,CLOUDID:b398c684-cd9c-45f5-8134-710979e3df0e,B ulkID:230421114749ZN2FUYUP,BulkQuantity:0,Recheck:0,SF:38|29|28|17|19|48,T C:nil,Content:0,EDM:-3,IP:nil,URL:0,File:nil,Bulk:nil,QS:nil,BEC:nil,COL:0 ,OSI:0,OSA:0,AV:0 X-CID-BVR: 0,NGT X-CID-BAS: 0,NGT,0,_ X-UUID: 4814df98dff711edb6b9f13eb10bd0fe-20230421 Received: from mtkmbs10n1.mediatek.inc [(172.21.101.34)] by mailgw02.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 977640144; Fri, 21 Apr 2023 11:47:47 +0800 Received: from mtkmbs13n2.mediatek.inc (172.21.101.108) by mtkmbs10n1.mediatek.inc (172.21.101.34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.25; Fri, 21 Apr 2023 11:47:46 +0800 Received: from mtksdccf07.mediatek.inc (172.21.84.99) by mtkmbs13n2.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.2.1118.25 via Frontend Transport; Fri, 21 Apr 2023 11:47:46 +0800 From: To: Daniel Lezcano , Thomas Gleixner , Matthias Brugger , AngeloGioacchino Del Regno , "Maciej W . Rozycki" , John Stultz CC: , , , , , Chun-Hung Wu , , , Subject: [PATCH linux-next v4 2/4] clocksource/drivers/mmio: Export clocksource_mmio_init() Date: Fri, 21 Apr 2023 11:46:47 +0800 Message-ID: <20230421034649.15247-3-walter.chang@mediatek.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20230421034649.15247-1-walter.chang@mediatek.com> References: <20230421034649.15247-1-walter.chang@mediatek.com> MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS, SPF_PASS,T_SCC_BODY_TEXT_LINE,UNPARSEABLE_RELAY,URIBL_BLOCKED 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?1763756166204439206?= X-GMAIL-MSGID: =?utf-8?q?1763756166204439206?= From: Chun-Hung Wu Export clocksource_mmio_init() and clocksource_mmio_readl_up() to support building clocksource driver as module, such as timer-mediatek.c. Signed-off-by: Chun-Hung Wu --- drivers/clocksource/mmio.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/clocksource/mmio.c b/drivers/clocksource/mmio.c index 9de751531831..b08b2f9d7a8b 100644 --- a/drivers/clocksource/mmio.c +++ b/drivers/clocksource/mmio.c @@ -21,6 +21,7 @@ u64 clocksource_mmio_readl_up(struct clocksource *c) { return (u64)readl_relaxed(to_mmio_clksrc(c)->reg); } +EXPORT_SYMBOL_GPL(clocksource_mmio_readl_up); u64 clocksource_mmio_readl_down(struct clocksource *c) { @@ -46,9 +47,9 @@ u64 clocksource_mmio_readw_down(struct clocksource *c) * @bits: Number of valid bits * @read: One of clocksource_mmio_read*() above */ -int __init clocksource_mmio_init(void __iomem *base, const char *name, - unsigned long hz, int rating, unsigned bits, - u64 (*read)(struct clocksource *)) +int clocksource_mmio_init(void __iomem *base, const char *name, + unsigned long hz, int rating, unsigned bits, + u64 (*read)(struct clocksource *)) { struct clocksource_mmio *cs; @@ -68,3 +69,4 @@ int __init clocksource_mmio_init(void __iomem *base, const char *name, return clocksource_register_hz(&cs->clksrc, hz); } +EXPORT_SYMBOL_GPL(clocksource_mmio_init);