From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D71F5C49ED8 for ; Tue, 10 Sep 2019 15:11:35 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id A9257206A5 for ; Tue, 10 Sep 2019 15:11:35 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="objIsdLO" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A9257206A5 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=bootlin.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-amlogic-bounces+linux-amlogic=archiver.kernel.org@lists.infradead.org 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:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=JnaV3xTy0EVj5UKKyQiYbqgWnL2Chl8JwB5TPNLhrXo=; b=objIsdLOdxiXrb dEAlij7og90OgqSwWvzXfGQic0PWYAwji6MTW8G9UjNFQ+Sb9bkTirbzi6ROEPsnooGsIturjLiXq /lXc0IfuEBH9dAZMC1GHlmo5S2sJSTwm68VbeBQJz6K2xvBsCGKlhJnDpFugCBGW9hT/oGTpubrPi CgmcThYtjln59hU9trKEAXCKLtNTHwSQfEfmEbS3tPh96eU/30IzdzRgabXGD83kf4P6oHuiF7yDM 5K3IcRnVVY08ZSoIqEGVkwOaNfFo8AplOpiACxKHsGMx505ga0S389mKwj8b1V8nacrrI+FvNzOCf pgjBhMLW5jFWkRuwtTNQ==; 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 1i7hnl-0008KP-Or; Tue, 10 Sep 2019 15:11:29 +0000 Received: from relay5-d.mail.gandi.net ([217.70.183.197]) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1i7hnh-0008Iz-SV; Tue, 10 Sep 2019 15:11:27 +0000 X-Originating-IP: 148.69.85.38 Received: from localhost (unknown [148.69.85.38]) (Authenticated sender: alexandre.belloni@bootlin.com) by relay5-d.mail.gandi.net (Postfix) with ESMTPSA id D0F4F1C0019; Tue, 10 Sep 2019 15:10:57 +0000 (UTC) Date: Tue, 10 Sep 2019 17:10:55 +0200 From: Alexandre Belloni To: Sudeep Holla Subject: Re: [PATCH 4/7] dt-bindings: chosen: Add clocksource and clockevent selection Message-ID: <20190910151055.GX21254@piout.net> References: <1568123236-767-1-git-send-email-claudiu.beznea@microchip.com> <1568123236-767-5-git-send-email-claudiu.beznea@microchip.com> <20190910143231.GB14966@e107533-lin.cambridge.arm.com> <20190910150826.GA18308@e107533-lin.cambridge.arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20190910150826.GA18308@e107533-lin.cambridge.arm.com> User-Agent: Mutt/1.12.1 (2019-06-15) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190910_081126_216139_9A1A9513 X-CRM114-Status: GOOD ( 16.53 ) X-BeenThere: linux-amlogic@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: tmaimon77@gmail.com, linus.walleij@linaro.org, nsekhar@ti.com, guoren@kernel.org, linux-stm32@st-md-mailman.stormreply.com, heiko@sntech.de, linux-samsung-soc@vger.kernel.org, linux-rockchip@lists.infradead.org, khilman@baylibre.com, Ludovic.Desroches@microchip.com, linux-imx@nxp.com, u.kleine-koenig@pengutronix.de, uclinux-h8-devel@lists.sourceforge.jp, marc.zyngier@arm.com, s.hauer@pengutronix.de, linux-unisoc@lists.infradead.org, khalasa@piap.pl, tglx@linutronix.de, sbranden@broadcom.com, linux-kernel@vger.kernel.org, ralf@linux-mips.org, paul.burton@mips.com, kernel@pengutronix.de, Claudiu.Beznea@microchip.com, mark.rutland@arm.com, jhogan@kernel.org, palmer@sifive.com, eric@anholt.net, thierry.reding@gmail.com, manivannan.sadhasivam@linaro.org, ysato@users.sourceforge.jp, zhang.lyra@gmail.com, daniel.lezcano@linaro.org, jonathanh@nvidia.com, bgolaszewski@baylibre.com, kgene@kernel.org, alexandre.torgue@st.com, linux-arm-msm@vger.kernel.org, f.fainelli@gmail.com, john.stultz@linaro.org, linux-rpi-kernel@lists.infradead.org, linux-amlogic@lists.infradead.org, linux-arm-kernel@lists.infradead.org, baohua@kernel.org, kaloz@openwrt.org, sboyd@kernel.org, patrice.chotard@st.com, wahrenst@gmx.net, mcoquelin.stm32@gmail.com, narmstrong@baylibre.com, linux-tegra@vger.kernel.org, festevam@gmail.com, lorenzo.pieralisi@arm.com, benjaminfair@google.com, shc_work@mail.ru, krzk@kernel.org, yuenn@google.com, wens@csie.org, bcm-kernel-feedback-list@broadcom.com, orsonzhai@gmail.com, linux-snps-arc@lists.infradead.org, rjui@broadcom.com, vz@mleia.com, john@phrozen.org, tali.perry1@gmail.com, avifishman70@gmail.com, venture@google.com, lftan@altera.com, linux-oxnas@groups.io, shawnguo@kernel.org, afaerber@suse.de, baruch@tkos.co.il, maxime.ripard@bootlin.com, liviu.dudau@arm.com, linux-mips@vger.kernel.org, linux-riscv@lists.infradead.org, openbmc@lists.ozlabs.org, linux@armlinux.org.uk, agross@kernel.org, slemieux.tyco@gmail.com, devicetree@vger.kernel.org, aou@eecs.berkeley.edu, robh+dt@kernel.org, linux-mediatek@lists.infradead.org, ssantosh@kernel.org, matthias.bgg@gmail.com, monstr@monstr.eu, baolin.wang@linaro.org, vgupta@synopsys.com, Nicolas.Ferre@microchip.com, linux@prisktech.co.nz, nios2-dev@lists.rocketboards.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-amlogic" Errors-To: linux-amlogic-bounces+linux-amlogic=archiver.kernel.org@lists.infradead.org On 10/09/2019 16:08:26+0100, Sudeep Holla wrote: > On Tue, Sep 10, 2019 at 02:51:50PM +0000, Claudiu.Beznea@microchip.com wrote: > > > > > > On 10.09.2019 17:32, Sudeep Holla wrote: > > > External E-Mail > > > > > > > > > On Tue, Sep 10, 2019 at 04:47:13PM +0300, Claudiu Beznea wrote: > > >> From: Alexandre Belloni > > >> > > >> Some timer drivers may behave either as clocksource or clockevent > > >> or both. Until now, in case of platforms with multiple hardware > > >> resources of the same type, the drivers were chosing the first > > >> registered hardware resource as clocksource/clockevent and the > > >> next one as clockevent/clocksource. Other were using different > > >> compatibles (one for each functionality, although its about the > > >> same hardware). Add DT bindings to be able to choose the > > >> functionality of a timer. > > >> > > > > > > Is the piece of hardware not capable of serving as both clocksource > > > and clockevent or is it just the platform choice ? > > > > In my case, the hardware is not capable of serving at the same time > > a clocksource device and a clockevent device. > > > > First, I published v1 for a hardware device having this behavior at > > [1] requesting 1st probed hardware device to work as clocksource and > > the 2nd one to work as clockevent. The discussion at [1] ended up with > > the idea of having a mechanism to specify which hardware device behaves > > as clocksource and which one behaves as clockevent. > > > > In that case, why can't we identify capability that with the compatibles > for this timer IP ? > > IOW, I don't like the proposal as it's hardware limitation. > To be clear, bot timers are exactly the same but can't be clocksource and clockevent at the same time. Why would we have different compatibles for the exact same IP? -- Alexandre Belloni, Bootlin Embedded Linux and Kernel engineering https://bootlin.com _______________________________________________ linux-amlogic mailing list linux-amlogic@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-amlogic From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alexandre Belloni Subject: Re: [PATCH 4/7] dt-bindings: chosen: Add clocksource and clockevent selection Date: Tue, 10 Sep 2019 17:10:55 +0200 Message-ID: <20190910151055.GX21254@piout.net> References: <1568123236-767-1-git-send-email-claudiu.beznea@microchip.com> <1568123236-767-5-git-send-email-claudiu.beznea@microchip.com> <20190910143231.GB14966@e107533-lin.cambridge.arm.com> <20190910150826.GA18308@e107533-lin.cambridge.arm.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <20190910150826.GA18308@e107533-lin.cambridge.arm.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-riscv" Errors-To: linux-riscv-bounces+glpr-linux-riscv=m.gmane.org@lists.infradead.org To: Sudeep Holla Cc: tmaimon77@gmail.com, linus.walleij@linaro.org, nsekhar@ti.com, guoren@kernel.org, linux-stm32@st-md-mailman.stormreply.com, heiko@sntech.de, linux-samsung-soc@vger.kernel.org, linux-rockchip@lists.infradead.org, khilman@baylibre.com, Ludovic.Desroches@microchip.com, linux-imx@nxp.com, u.kleine-koenig@pengutronix.de, uclinux-h8-devel@lists.sourceforge.jp, marc.zyngier@arm.com, s.hauer@pengutronix.de, linux-unisoc@lists.infradead.org, khalasa@piap.pl, tglx@linutronix.de, sbranden@broadcom.com, linux-kernel@vger.kernel.org, ralf@linux-mips.org, paul.burton@mips.com, kernel@pengutronix.de, Claudiu.Beznea@microchip.com, mark.rutland@arm.com, jhogan@kernel.org, palmer@sifive.com, eric@anholt.net, thierry.reding@gmail.com, manivannan.sadhasivam@linaro.org, ysato@users.sourceforge.jp, zhang.lyra@gmail.com, daniel.lezcano@linaro.org, jonathanh@nvidia.com, bgolaszewski@baylibre.com List-Id: linux-mediatek@lists.infradead.org On 10/09/2019 16:08:26+0100, Sudeep Holla wrote: > On Tue, Sep 10, 2019 at 02:51:50PM +0000, Claudiu.Beznea@microchip.com wrote: > > > > > > On 10.09.2019 17:32, Sudeep Holla wrote: > > > External E-Mail > > > > > > > > > On Tue, Sep 10, 2019 at 04:47:13PM +0300, Claudiu Beznea wrote: > > >> From: Alexandre Belloni > > >> > > >> Some timer drivers may behave either as clocksource or clockevent > > >> or both. Until now, in case of platforms with multiple hardware > > >> resources of the same type, the drivers were chosing the first > > >> registered hardware resource as clocksource/clockevent and the > > >> next one as clockevent/clocksource. Other were using different > > >> compatibles (one for each functionality, although its about the > > >> same hardware). Add DT bindings to be able to choose the > > >> functionality of a timer. > > >> > > > > > > Is the piece of hardware not capable of serving as both clocksource > > > and clockevent or is it just the platform choice ? > > > > In my case, the hardware is not capable of serving at the same time > > a clocksource device and a clockevent device. > > > > First, I published v1 for a hardware device having this behavior at > > [1] requesting 1st probed hardware device to work as clocksource and > > the 2nd one to work as clockevent. The discussion at [1] ended up with > > the idea of having a mechanism to specify which hardware device behaves > > as clocksource and which one behaves as clockevent. > > > > In that case, why can't we identify capability that with the compatibles > for this timer IP ? > > IOW, I don't like the proposal as it's hardware limitation. > To be clear, bot timers are exactly the same but can't be clocksource and clockevent at the same time. Why would we have different compatibles for the exact same IP? -- Alexandre Belloni, Bootlin Embedded Linux and Kernel engineering https://bootlin.com From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id BD029C49ED7 for ; Tue, 10 Sep 2019 15:11:32 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 90925206A5 for ; Tue, 10 Sep 2019 15:11:32 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="OXQxxAEP" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 90925206A5 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=bootlin.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-riscv-bounces+infradead-linux-riscv=archiver.kernel.org@lists.infradead.org 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:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=g8kaJVI/DkEcJ1VmDn2Xg0sYjJiIh2UDopkYFp8zRRE=; b=OXQxxAEPkFoEPd 3K3KpDUpBFFfTPBM56ev8GDdHA9heLsFTRQArg1UuXTq0C0jVRJjSxUJ9SaoirMgamka5k0LXMIgW ef7cNroCWacmPqgR+6fdKa+NSnyQfSLd6/vJdGkkT+O7u9ZaNViWZcEPMYF5rWRwCsUfenR969BuX /1R+zhQjAEl4uSgRRrsgztX3T/hgSN6T9cTKnWsOgQR25aICXaxtvP/OpSdB0j6r5FrB+ook+slGO bz/e1ZMQp6e/76U13584RVJUxLofOvnw97euedsYfgvkB04xjmWuhLvt9wOOee8WULDH4tGsYDeQO 3evKsIaV6hW9F5LUS+pQ==; 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 1i7hno-0008Mk-8v; Tue, 10 Sep 2019 15:11:32 +0000 Received: from relay5-d.mail.gandi.net ([217.70.183.197]) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1i7hnh-0008Iz-SV; Tue, 10 Sep 2019 15:11:27 +0000 X-Originating-IP: 148.69.85.38 Received: from localhost (unknown [148.69.85.38]) (Authenticated sender: alexandre.belloni@bootlin.com) by relay5-d.mail.gandi.net (Postfix) with ESMTPSA id D0F4F1C0019; Tue, 10 Sep 2019 15:10:57 +0000 (UTC) Date: Tue, 10 Sep 2019 17:10:55 +0200 From: Alexandre Belloni To: Sudeep Holla Subject: Re: [PATCH 4/7] dt-bindings: chosen: Add clocksource and clockevent selection Message-ID: <20190910151055.GX21254@piout.net> References: <1568123236-767-1-git-send-email-claudiu.beznea@microchip.com> <1568123236-767-5-git-send-email-claudiu.beznea@microchip.com> <20190910143231.GB14966@e107533-lin.cambridge.arm.com> <20190910150826.GA18308@e107533-lin.cambridge.arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20190910150826.GA18308@e107533-lin.cambridge.arm.com> User-Agent: Mutt/1.12.1 (2019-06-15) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190910_081126_216139_9A1A9513 X-CRM114-Status: GOOD ( 16.53 ) X-BeenThere: linux-riscv@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: tmaimon77@gmail.com, linus.walleij@linaro.org, nsekhar@ti.com, guoren@kernel.org, linux-stm32@st-md-mailman.stormreply.com, heiko@sntech.de, linux-samsung-soc@vger.kernel.org, linux-rockchip@lists.infradead.org, khilman@baylibre.com, Ludovic.Desroches@microchip.com, linux-imx@nxp.com, u.kleine-koenig@pengutronix.de, uclinux-h8-devel@lists.sourceforge.jp, marc.zyngier@arm.com, s.hauer@pengutronix.de, linux-unisoc@lists.infradead.org, khalasa@piap.pl, tglx@linutronix.de, sbranden@broadcom.com, linux-kernel@vger.kernel.org, ralf@linux-mips.org, paul.burton@mips.com, kernel@pengutronix.de, Claudiu.Beznea@microchip.com, mark.rutland@arm.com, jhogan@kernel.org, palmer@sifive.com, eric@anholt.net, thierry.reding@gmail.com, manivannan.sadhasivam@linaro.org, ysato@users.sourceforge.jp, zhang.lyra@gmail.com, daniel.lezcano@linaro.org, jonathanh@nvidia.com, bgolaszewski@baylibre.com, kgene@kernel.org, alexandre.torgue@st.com, linux-arm-msm@vger.kernel.org, f.fainelli@gmail.com, john.stultz@linaro.org, linux-rpi-kernel@lists.infradead.org, linux-amlogic@lists.infradead.org, linux-arm-kernel@lists.infradead.org, baohua@kernel.org, kaloz@openwrt.org, sboyd@kernel.org, patrice.chotard@st.com, wahrenst@gmx.net, mcoquelin.stm32@gmail.com, narmstrong@baylibre.com, linux-tegra@vger.kernel.org, festevam@gmail.com, lorenzo.pieralisi@arm.com, benjaminfair@google.com, shc_work@mail.ru, krzk@kernel.org, yuenn@google.com, wens@csie.org, bcm-kernel-feedback-list@broadcom.com, orsonzhai@gmail.com, linux-snps-arc@lists.infradead.org, rjui@broadcom.com, vz@mleia.com, john@phrozen.org, tali.perry1@gmail.com, avifishman70@gmail.com, venture@google.com, lftan@altera.com, linux-oxnas@groups.io, shawnguo@kernel.org, afaerber@suse.de, baruch@tkos.co.il, maxime.ripard@bootlin.com, liviu.dudau@arm.com, linux-mips@vger.kernel.org, linux-riscv@lists.infradead.org, openbmc@lists.ozlabs.org, linux@armlinux.org.uk, agross@kernel.org, slemieux.tyco@gmail.com, devicetree@vger.kernel.org, aou@eecs.berkeley.edu, robh+dt@kernel.org, linux-mediatek@lists.infradead.org, ssantosh@kernel.org, matthias.bgg@gmail.com, monstr@monstr.eu, baolin.wang@linaro.org, vgupta@synopsys.com, Nicolas.Ferre@microchip.com, linux@prisktech.co.nz, nios2-dev@lists.rocketboards.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-riscv" Errors-To: linux-riscv-bounces+infradead-linux-riscv=archiver.kernel.org@lists.infradead.org On 10/09/2019 16:08:26+0100, Sudeep Holla wrote: > On Tue, Sep 10, 2019 at 02:51:50PM +0000, Claudiu.Beznea@microchip.com wrote: > > > > > > On 10.09.2019 17:32, Sudeep Holla wrote: > > > External E-Mail > > > > > > > > > On Tue, Sep 10, 2019 at 04:47:13PM +0300, Claudiu Beznea wrote: > > >> From: Alexandre Belloni > > >> > > >> Some timer drivers may behave either as clocksource or clockevent > > >> or both. Until now, in case of platforms with multiple hardware > > >> resources of the same type, the drivers were chosing the first > > >> registered hardware resource as clocksource/clockevent and the > > >> next one as clockevent/clocksource. Other were using different > > >> compatibles (one for each functionality, although its about the > > >> same hardware). Add DT bindings to be able to choose the > > >> functionality of a timer. > > >> > > > > > > Is the piece of hardware not capable of serving as both clocksource > > > and clockevent or is it just the platform choice ? > > > > In my case, the hardware is not capable of serving at the same time > > a clocksource device and a clockevent device. > > > > First, I published v1 for a hardware device having this behavior at > > [1] requesting 1st probed hardware device to work as clocksource and > > the 2nd one to work as clockevent. The discussion at [1] ended up with > > the idea of having a mechanism to specify which hardware device behaves > > as clocksource and which one behaves as clockevent. > > > > In that case, why can't we identify capability that with the compatibles > for this timer IP ? > > IOW, I don't like the proposal as it's hardware limitation. > To be clear, bot timers are exactly the same but can't be clocksource and clockevent at the same time. Why would we have different compatibles for the exact same IP? -- Alexandre Belloni, Bootlin Embedded Linux and Kernel engineering https://bootlin.com _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv From mboxrd@z Thu Jan 1 00:00:00 1970 From: alexandre.belloni@bootlin.com (Alexandre Belloni) Date: Tue, 10 Sep 2019 17:10:55 +0200 Subject: [PATCH 4/7] dt-bindings: chosen: Add clocksource and clockevent selection In-Reply-To: <20190910150826.GA18308@e107533-lin.cambridge.arm.com> References: <1568123236-767-1-git-send-email-claudiu.beznea@microchip.com> <1568123236-767-5-git-send-email-claudiu.beznea@microchip.com> <20190910143231.GB14966@e107533-lin.cambridge.arm.com> <20190910150826.GA18308@e107533-lin.cambridge.arm.com> List-ID: Message-ID: <20190910151055.GX21254@piout.net> To: linux-snps-arc@lists.infradead.org On 10/09/2019 16:08:26+0100, Sudeep Holla wrote: > On Tue, Sep 10, 2019@02:51:50PM +0000, Claudiu.Beznea@microchip.com wrote: > > > > > > On 10.09.2019 17:32, Sudeep Holla wrote: > > > External E-Mail > > > > > > > > > On Tue, Sep 10, 2019@04:47:13PM +0300, Claudiu Beznea wrote: > > >> From: Alexandre Belloni > > >> > > >> Some timer drivers may behave either as clocksource or clockevent > > >> or both. Until now, in case of platforms with multiple hardware > > >> resources of the same type, the drivers were chosing the first > > >> registered hardware resource as clocksource/clockevent and the > > >> next one as clockevent/clocksource. Other were using different > > >> compatibles (one for each functionality, although its about the > > >> same hardware). Add DT bindings to be able to choose the > > >> functionality of a timer. > > >> > > > > > > Is the piece of hardware not capable of serving as both clocksource > > > and clockevent or is it just the platform choice ? > > > > In my case, the hardware is not capable of serving at the same time > > a clocksource device and a clockevent device. > > > > First, I published v1 for a hardware device having this behavior at > > [1] requesting 1st probed hardware device to work as clocksource and > > the 2nd one to work as clockevent. The discussion at [1] ended up with > > the idea of having a mechanism to specify which hardware device behaves > > as clocksource and which one behaves as clockevent. > > > > In that case, why can't we identify capability that with the compatibles > for this timer IP ? > > IOW, I don't like the proposal as it's hardware limitation. > To be clear, bot timers are exactly the same but can't be clocksource and clockevent at the same time. Why would we have different compatibles for the exact same IP? -- Alexandre Belloni, Bootlin Embedded Linux and Kernel engineering https://bootlin.com