Message ID | 20230517022557.24388-1-walter.chang@mediatek.com |
---|---|
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp849125vqo; Tue, 16 May 2023 20:22:57 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6XVwKpQl3UsuD8nzJyisfxXftMU7U6ZImFDf/EwowA94MHz3qmaRkRhKSNqRdY5el+3XsK X-Received: by 2002:a05:6a21:7896:b0:101:1951:d4ae with SMTP id bf22-20020a056a21789600b001011951d4aemr37209674pzc.14.1684293777365; Tue, 16 May 2023 20:22:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684293777; cv=none; d=google.com; s=arc-20160816; b=OqDAXYH6UsQaoqtp4rIlpbhZnzCa48V3bUxfXllzJkjCQmsw2R+z4zOqqTlQ8OaGKt DMF8M7DHUqGVeqGJ0XT2k/RsZGj/XP0bwEUTJXBBf5GpxN+QatQvuliMmBeNZ+BvQ1v9 Y4tXm6Bn6xdLgma+9VVoLBdsngz8+6TvlSft1Tim1DXIhKZlvlFnT0o0QRhVtd3h5VIO h5E4olu+Tqw88BAVli4ByXyrwOhLXjQmXih9GBRAgqRGd77DS1c0eZ7ehQ0aYhze4n1R Hy1EPCZFzL8Nw0aaKr3BLE99FVQMYy0c4uv5Liv6JVszVSbUpU7OUrJEAEAzdNhbhj84 JNpw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from :dkim-signature; bh=XT0aWLrHFibG11Unqwd1/RdVtuvwg1ngn+cr6gZ0zko=; b=yYpXoUuMSjklOk+9yqInDyFQBjqHNMOPPYK8nNt5O/116OXcqFfpnXQK83VyLG8hHm 5rDYWOX7NNgTIqFJPqzetIETlK/MZUVTUA/sS5J7L7InEv8W59YyXGtaTNKagetmUrQA QTbRqhRH81RB3WyL9Mk/Ww2GYUx0nfVQOzrwOJDEBV0MHqX3E2MiI16e4x0UhOadjInc Uuqisz5tspBt7CBmzNReEYBp4mD0i84lLamlG32FrYSKIJ8mciI4j2t9uNSSVZO6+s5b rqVgHGr1cB//36Hra+yNnMfl6FEqFtQvwcohLWOfCRzVQqVJJe+2z33RZcB3j86jv2+8 XsTw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b="LnTYq/QK"; 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 c19-20020a637253000000b00525025dfa5fsi19832090pgn.377.2023.05.16.20.22.43; Tue, 16 May 2023 20:22:57 -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="LnTYq/QK"; 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 S231954AbjEQC2A (ORCPT <rfc822;abdi.embedded@gmail.com> + 99 others); Tue, 16 May 2023 22:28:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50936 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232025AbjEQC1s (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 16 May 2023 22:27:48 -0400 Received: from mailgw01.mediatek.com (unknown [60.244.123.138]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 88C7F5246 for <linux-kernel@vger.kernel.org>; Tue, 16 May 2023 19:27:22 -0700 (PDT) X-UUID: 3b633390f45a11ed9cb5633481061a41-20230517 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Type:MIME-Version:Message-ID:Date:Subject:CC:To:From; bh=XT0aWLrHFibG11Unqwd1/RdVtuvwg1ngn+cr6gZ0zko=; b=LnTYq/QK+Mnx4P9JaLjilrHtv1j3T6N3ULhkDlQwREQskdmi7a+2viNAF6RUnUURF9P7DtroO1JkqffhrLTeqTAmvzyf6E82ffhykxYsXXhccPxdS9rc/U47WJg4te2y/CVeTryQGzg6x282bubNMHBnBM9H6QSQOjoVg3CQAX0=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.25,REQID:bb6c198b-15dd-494d-b0d7-29d755afec7d,IP:0,U RL:0,TC:0,Content:-25,EDM:0,RT:0,SF:0,FILE:0,BULK:0,RULE:Release_Ham,ACTIO N:release,TS:-25 X-CID-META: VersionHash:d5b0ae3,CLOUDID:6cbc673b-de1e-4348-bc35-c96f92f1dcbb,B ulkID:nil,BulkQuantity:0,Recheck:0,SF:102,TC:nil,Content:0,EDM:-3,IP:nil,U RL:1,File:nil,Bulk:nil,QS:nil,BEC:nil,COL:0,OSI:0,OSA:0,AV:0 X-CID-BVR: 0 X-CID-BAS: 0,_,0,_ X-UUID: 3b633390f45a11ed9cb5633481061a41-20230517 Received: from mtkmbs13n2.mediatek.inc [(172.21.101.108)] by mailgw01.mediatek.com (envelope-from <walter.chang@mediatek.com>) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 2010033819; Wed, 17 May 2023 10:26:29 +0800 Received: from mtkmbs13n2.mediatek.inc (172.21.101.194) by mtkmbs10n2.mediatek.inc (172.21.101.183) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.26; Wed, 17 May 2023 10:26:28 +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.26 via Frontend Transport; Wed, 17 May 2023 10:26:28 +0800 From: <walter.chang@mediatek.com> To: Daniel Lezcano <daniel.lezcano@linaro.org>, Thomas Gleixner <tglx@linutronix.de>, Matthias Brugger <matthias.bgg@gmail.com>, AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>, "Maciej W . Rozycki" <macro@orcam.me.uk>, John Stultz <jstultz@google.com> CC: <wsd_upstream@mediatek.com>, <stanley.chu@mediatek.com>, <Chun-hung.Wu@mediatek.com>, <Freddy.Hsin@mediatek.com>, <walter.chang@mediatek.com>, <linux-kernel@vger.kernel.org>, <linux-arm-kernel@lists.infradead.org>, <linux-mediatek@lists.infradead.org> Subject: [PATCH v5 0/4] Support timer drivers as loadable modules Date: Wed, 17 May 2023 10:25:44 +0800 Message-ID: <20230517022557.24388-1-walter.chang@mediatek.com> X-Mailer: git-send-email 2.18.0 MIME-Version: 1.0 Content-Type: text/plain 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1766110031801615155?= X-GMAIL-MSGID: =?utf-8?q?1766110031801615155?= |
Series |
Support timer drivers as loadable modules
|
|
Message
Walter Chang (張維哲)
May 17, 2023, 2:25 a.m. UTC
From: Walter Chang <walter.chang@mediatek.com>
This set of patches aims to make SoC related timer drivers, such as
timer-mediatek.c become loadable modules for the Generic Kernel Image
(GKI).
This driver registers an always-on timer as tick_broadcast_device on
MediaTek SoCs. If the system does not load this module at startup,
system will also boot normally by using built-in `bc_hrtimer` instead.
Besides, the previous experiment [1] indicates that the SYST/GPT, in
combination with a loadable module, is fully operational.
The first three patches export functions and remove __init markings to
support loadable timer modules.
The fourth patch makes timer-mediatek.c become loadable module for GKI.
[1]
https://lore.kernel.org/all/32777456f8e0f98e4cd5b950f421d21f71b149cf.camel@mediatek.com/#t
[v5]
- Add Signed-off-by tags in all patches
- Add Acked-by tags and Reviewed-by tags
[v4]
- Fix review comments pointed by Angelo
[v3]
- Rebase on linux-next
[v2]
- Convert timer-mediatek.c driver to loadable module
Chun-Hung Wu (4):
time/sched_clock: Export sched_clock_register()
clocksource/drivers/mmio: Export clocksource_mmio_init()
clocksource/drivers/timer-of: Remove __init markings
clocksource/drivers/timer-mediatek: Make timer-mediatek become
loadable module
drivers/clocksource/Kconfig | 2 +-
drivers/clocksource/mmio.c | 8 ++++---
drivers/clocksource/timer-mediatek.c | 33 ++++++++++++++++++++++++++++
drivers/clocksource/timer-of.c | 23 +++++++++----------
drivers/clocksource/timer-of.h | 6 ++---
kernel/time/sched_clock.c | 4 ++--
6 files changed, 56 insertions(+), 20 deletions(-)
Comments
On Wed, 2023-05-17 at 10:25 +0800, walter.chang@mediatek.com wrote: > From: Walter Chang <walter.chang@mediatek.com> > > This set of patches aims to make SoC related timer drivers, such as > timer-mediatek.c become loadable modules for the Generic Kernel Image > (GKI). > > This driver registers an always-on timer as tick_broadcast_device on > MediaTek SoCs. If the system does not load this module at startup, > system will also boot normally by using built-in `bc_hrtimer` > instead. > Besides, the previous experiment [1] indicates that the SYST/GPT, in > combination with a loadable module, is fully operational. > > The first three patches export functions and remove __init markings > to > support loadable timer modules. > > The fourth patch makes timer-mediatek.c become loadable module for > GKI. > > [1] > https://lore.kernel.org/all/32777456f8e0f98e4cd5b950f421d21f71b149cf.camel@mediatek.com/#t > > [v5] > - Add Signed-off-by tags in all patches > - Add Acked-by tags and Reviewed-by tags > > [v4] > - Fix review comments pointed by Angelo > > [v3] > - Rebase on linux-next > > [v2] > - Convert timer-mediatek.c driver to loadable module > > Chun-Hung Wu (4): > time/sched_clock: Export sched_clock_register() > clocksource/drivers/mmio: Export clocksource_mmio_init() > clocksource/drivers/timer-of: Remove __init markings > clocksource/drivers/timer-mediatek: Make timer-mediatek become > loadable module > > drivers/clocksource/Kconfig | 2 +- > drivers/clocksource/mmio.c | 8 ++++--- > drivers/clocksource/timer-mediatek.c | 33 > ++++++++++++++++++++++++++++ > drivers/clocksource/timer-of.c | 23 +++++++++---------- > drivers/clocksource/timer-of.h | 6 ++--- > kernel/time/sched_clock.c | 4 ++-- > 6 files changed, 56 insertions(+), 20 deletions(-) > Gentle ping for this series. Thanks, Walter Chang
As I already said, I'm not very comfortable with these changes and the potential impact it can have on the overall time framework. I will pick the series if Thomas gives its Acked-by Thanks On 17/05/2023 04:25, walter.chang@mediatek.com wrote: > From: Walter Chang <walter.chang@mediatek.com> > > This set of patches aims to make SoC related timer drivers, such as > timer-mediatek.c become loadable modules for the Generic Kernel Image > (GKI). > > This driver registers an always-on timer as tick_broadcast_device on > MediaTek SoCs. If the system does not load this module at startup, > system will also boot normally by using built-in `bc_hrtimer` instead. > Besides, the previous experiment [1] indicates that the SYST/GPT, in > combination with a loadable module, is fully operational. > > The first three patches export functions and remove __init markings to > support loadable timer modules. > > The fourth patch makes timer-mediatek.c become loadable module for GKI. > > [1] > https://lore.kernel.org/all/32777456f8e0f98e4cd5b950f421d21f71b149cf.camel@mediatek.com/#t > > [v5] > - Add Signed-off-by tags in all patches > - Add Acked-by tags and Reviewed-by tags > > [v4] > - Fix review comments pointed by Angelo > > [v3] > - Rebase on linux-next > > [v2] > - Convert timer-mediatek.c driver to loadable module > > Chun-Hung Wu (4): > time/sched_clock: Export sched_clock_register() > clocksource/drivers/mmio: Export clocksource_mmio_init() > clocksource/drivers/timer-of: Remove __init markings > clocksource/drivers/timer-mediatek: Make timer-mediatek become > loadable module > > drivers/clocksource/Kconfig | 2 +- > drivers/clocksource/mmio.c | 8 ++++--- > drivers/clocksource/timer-mediatek.c | 33 ++++++++++++++++++++++++++++ > drivers/clocksource/timer-of.c | 23 +++++++++---------- > drivers/clocksource/timer-of.h | 6 ++--- > kernel/time/sched_clock.c | 4 ++-- > 6 files changed, 56 insertions(+), 20 deletions(-) >
On Mon, 2023-06-19 at 18:44 +0200, Daniel Lezcano wrote: > > External email : Please do not click links or open attachments until > you have verified the sender or the content. > > As I already said, I'm not very comfortable with these changes and > the > potential impact it can have on the overall time framework. > > I will pick the series if Thomas gives its Acked-by > > Thanks > > Thanks for letting me know. I will wait for Thomas's response. Thanks, Walter Chang
On Mon, 2023-06-19 at 18:44 +0200, Daniel Lezcano wrote: > > External email : Please do not click links or open attachments until > you have verified the sender or the content. > > As I already said, I'm not very comfortable with these changes and > the > potential impact it can have on the overall time framework. > > I will pick the series if Thomas gives its Acked-by > > Thanks > Hi Thomas, Gentle ping for this series. We would like to know your opinion on the time framework changes we've discussed. Thanks, Walter Chang