Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp4155252ybc; Tue, 26 Nov 2019 04:48:29 -0800 (PST) X-Google-Smtp-Source: APXvYqxW8THsWqxQx5CdO9R3VQ1NJShqXZUBjkXjZSyEM/c2pSe0LhhKMO0gKppqpftsQMhdsCWK X-Received: by 2002:a17:906:374d:: with SMTP id e13mr1144978ejc.129.1574772509778; Tue, 26 Nov 2019 04:48:29 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1574772509; cv=pass; d=google.com; s=arc-20160816; b=lnU6b5MszrloU40+0P21Yst/KIrD7TgLf2yyiTBux34E/QOxF3SmFjW0XH1KjUQRFM lJn1Rbwynl2Kd8ONo4x9Vn/Po7HA6bvj9opCGHjVj+aev+RBLEcrsErBV38sJbPi8WCU BJSIy+Kotf3zsrab+nfs6XGsPigBRPwSnsCuZcMC3f91aAs9HBpHaqVAma6Qt1ib0YyV zRscWEaYWssE7JVKKNkWgBivG6nnunSeUPjYMPI92hjfoQypY8FbPynUM3dIG2tPZguO ocrpMpnexOUYfh4DVSfH1yLkZWKdIAojb/NHM79rzgGz9TR5oB+nFTLqIJyYjGxWHsIs uZIw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from:dkim-signature; bh=uoz0kP7TlyyO8x7+RhU2QNe28uAYxMWtipV31PkCT0k=; b=L89EaxgGhQnLh3rTORw93hWKOksN73911gCPzZUOZuJEVh1/d2282hHvKoJLCqqMY0 2YozNbGfn2uifefST/rTBDOnUcQtMUp1f8huli+a0rLJekS7j+Lt7tJ6q1u4lP22qV/j i24MYYOz1CavsMit8C21D4xsbEs9lwFpVO21oxS5o1D0ZcaBpv/aj0U3Mwmfwh8xZDjX jvWmNQiiIZnksPqNuzJS7mHN2pbVNiTdcrzMtZkG8xJ18rlQIaRBQtBTrUnWPeUKg7W0 uaDCU9oyKmfR40lCBLd/S7FHDD9tf5TcQo/oZzgoxI4CWKauET3Vr8NexXfgItgpi0et yoBA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@xilinx.onmicrosoft.com header.s=selector2-xilinx-onmicrosoft-com header.b=Y8HjHE2Y; arc=pass (i=1 spf=pass spfdomain=xilinx.com dkim=pass dkdomain=xilinx.com dmarc=pass fromdomain=xilinx.com); spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id gx24si6984802ejb.429.2019.11.26.04.48.05; Tue, 26 Nov 2019 04:48:29 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@xilinx.onmicrosoft.com header.s=selector2-xilinx-onmicrosoft-com header.b=Y8HjHE2Y; arc=pass (i=1 spf=pass spfdomain=xilinx.com dkim=pass dkdomain=xilinx.com dmarc=pass fromdomain=xilinx.com); spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728212AbfKZL5V (ORCPT + 99 others); Tue, 26 Nov 2019 06:57:21 -0500 Received: from mail-eopbgr790055.outbound.protection.outlook.com ([40.107.79.55]:59808 "EHLO NAM03-CO1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727250AbfKZL5U (ORCPT ); Tue, 26 Nov 2019 06:57:20 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=h5RUw7q0ndUpTWrrrcdCwgmEtGPUxIUI189c4GaJDHSVzRSPt0PLHMRXdiWMw95O3+D+rbvlypj+gcZxDo0O1GfHj+/MnD1CXZHSd5v8SLk/3Q9UJt0npIW+VoP9bRTV6bcveU8UGD5HOwc3eVTmrmcMVn/oWhVDKiOQ3+O9DkiBA8YgWO1Onyi9qnZ80++nUN99yS8sM73wsCGF/rrAJbxWHYWgv+PcFNzDXfrFbir280brBkQtkVV0GCCbpo6DZRhObLe4bN8TEbOrxn3JXrRkdzpusVNuypCwnV18qpW4/qor5F1e9F0TZLfTZWh8MERfcTY+KF/zAuwiDqB/rQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=uoz0kP7TlyyO8x7+RhU2QNe28uAYxMWtipV31PkCT0k=; b=bHx6hKpoutKIkx1wk+nFTYJE+SjAQFRiEACe/bdSsh2YXE1yiTggKcAHXeRdEDqvWvkq+JW2rCd2YFLxd1B+pkGDKI/L7gJ3OJdcY0f88rVMUx3mDej57csBzKvFSfzhT9YjnOBbP8D+4HuapdL7I3BbWHIPaWzOQHgXBNvqJP5eyCEz9XXoMxxRn5bNS4lEmPkQwJLwXw6FBB4s4+nReRB8fXIPUFrFIFI8rB9vsgZKNTrZLjjJGT7ZmlRCUF1P6FhNsf04opLE9S4FRq+iiOSP/amA+exPSSXx2jd3KySOPVkFS6kzoyD+Tj6Lhe9WcpsStWzadnavor9xmQNG7w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=xilinx.com; dmarc=pass action=none header.from=xilinx.com; dkim=pass header.d=xilinx.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xilinx.onmicrosoft.com; s=selector2-xilinx-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=uoz0kP7TlyyO8x7+RhU2QNe28uAYxMWtipV31PkCT0k=; b=Y8HjHE2YaJE3kYJyDQhY3ki4AKAgZrlMd/wgufzTjZNNffRsKfTfLblagSj+ID7M800/Y0zwlO+BIVRVqiMbF/jObEfq5ytKZML8RLhcxw5EQLfJ/9CdH+tEyWhN1x9/NN2iloPNqXWF9q/6jUHkVB5ueTnaY78DFzsXPV7UWPw= Received: from BYAPR02MB4055.namprd02.prod.outlook.com (52.135.202.143) by BYAPR02MB4696.namprd02.prod.outlook.com (52.135.235.209) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2474.17; Tue, 26 Nov 2019 11:56:37 +0000 Received: from BYAPR02MB4055.namprd02.prod.outlook.com ([fe80::fccc:d399:e650:9a9e]) by BYAPR02MB4055.namprd02.prod.outlook.com ([fe80::fccc:d399:e650:9a9e%5]) with mapi id 15.20.2474.023; Tue, 26 Nov 2019 11:56:36 +0000 From: Rajan Vaja To: "daniel.lezcano@linaro.org" , "tglx@linutronix.de" CC: "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" Subject: RE: [PATCH] drivers: clocksource: Use ttc driver as platform driver Thread-Topic: [PATCH] drivers: clocksource: Use ttc driver as platform driver Thread-Index: AQHVlVaOW+EHQwVffUWJv7WplPkHr6edcAHggAAGWTA= Date: Tue, 26 Nov 2019 11:56:36 +0000 Message-ID: References: <1573122659-13947-1-git-send-email-rajan.vaja@xilinx.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=RAJANV@xilinx.com; x-originating-ip: [14.142.15.114] x-ms-publictraffictype: Email x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: 8258dc0f-0f8f-4d65-4eea-08d77267b0ce x-ms-traffictypediagnostic: BYAPR02MB4696: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:4941; x-forefront-prvs: 0233768B38 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(4636009)(346002)(136003)(39860400002)(396003)(366004)(376002)(189003)(13464003)(199004)(478600001)(14454004)(8936002)(86362001)(66946007)(66476007)(66556008)(64756008)(55236004)(2501003)(76176011)(316002)(7696005)(6506007)(5660300002)(55016002)(66446008)(229853002)(256004)(14444005)(2906002)(33656002)(7736002)(305945005)(102836004)(74316002)(3846002)(26005)(186003)(71190400001)(6116002)(4326008)(71200400001)(52536014)(110136005)(53546011)(54906003)(99286004)(25786009)(76116006)(2940100002)(81156014)(9686003)(8676002)(66066001)(446003)(6436002)(6246003)(81166006)(11346002);DIR:OUT;SFP:1101;SCL:1;SRVR:BYAPR02MB4696;H:BYAPR02MB4055.namprd02.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: xilinx.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: Cd09L+3NHlOri9vCPQS1U+EVyakNttCHioqctZRvSWN8AJeYde/E4cxohZ+DmqFysmaPGCv+wU/YPKyx/0JZMjwggtWaQZStm5ZQGjWXNTF7ST7I8nhBA8eambNwUKfwqIdKz0LdofjE0KYKwhgzPdl5jp+vR3bO5YjFX7LRkJZS6TeHyheIY1WYHPE04jx4lm0o+5khTMIdj7BRsAia8nEmbFwNcfymOLFHUduOdg+r3eAEtLFg986DeQdZMxk28p/1b69Isa7cGiusgTx1qO32TIgiC8xQ7UYpwp4MpDv0SAHH3dygKPs08ASbR68tCzOo73mtaEses5zKKY3l8MBnwSBWNubw1q2cCNBOyDzZe7KYGMpDXYqbV89RCF9ogkUnnXyF7qzsarrdnA7/m27H2W+41nO2SKgrr6JS8WPYS5BhOZKQgLpSxSKc90VZ x-ms-exchange-transport-forked: True Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: xilinx.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8258dc0f-0f8f-4d65-4eea-08d77267b0ce X-MS-Exchange-CrossTenant-originalarrivaltime: 26 Nov 2019 11:56:36.8853 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 657af505-d5df-48d0-8300-c31994686c5c X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: +cGXQUABB1zs/9WRWPHSHi3m0HtnNJ8v1acP01rgR6tL4LWUaAqe7hp+mrZOL9M5ap+wQyrbsHahhLCsNvP2Nw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR02MB4696 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Please ignore this request. Thanks, Rajan > -----Original Message----- > From: Rajan Vaja > Sent: 26 November 2019 05:06 PM > To: Rajan Vaja ; ichal.simek@xilinx.com; > daniel.lezcano@linaro.org; tglx@linutronix.de > Cc: linux-arm-kernel@lists.infradead.org; linux-kernel@vger.kernel.org > Subject: RE: [PATCH] drivers: clocksource: Use ttc driver as platform dri= ver >=20 > Request for review. >=20 > Thanks, > Rajan >=20 > > -----Original Message----- > > From: Rajan Vaja > > Sent: 07 November 2019 04:01 PM > > To: ichal.simek@xilinx.com; daniel.lezcano@linaro.org; tglx@linutronix.= de > > Cc: linux-arm-kernel@lists.infradead.org; linux-kernel@vger.kernel.org;= Rajan > Vaja > > > > Subject: [PATCH] drivers: clocksource: Use ttc driver as platform drive= r > > > > Currently TTC driver is TIMER_OF_DECLARE type driver. Because of > > that, TTC driver may be initialized before other clock drivers. If > > TTC driver is dependent on that clock driver then initialization of > > TTC driver will failed. > > > > So use TTC driver as platform driver instead of using > > TIMER_OF_DECLARE. > > > > Signed-off-by: Rajan Vaja > > --- > > drivers/clocksource/timer-cadence-ttc.c | 26 ++++++++++++++++++-------= - > > 1 file changed, 18 insertions(+), 8 deletions(-) > > > > diff --git a/drivers/clocksource/timer-cadence-ttc.c b/drivers/clocksou= rce/timer- > > cadence-ttc.c > > index 88fe2e9..38858e1 100644 > > --- a/drivers/clocksource/timer-cadence-ttc.c > > +++ b/drivers/clocksource/timer-cadence-ttc.c > > @@ -15,6 +15,8 @@ > > #include > > #include > > #include > > +#include > > +#include > > > > /* > > * This driver configures the 2 16/32-bit count-up timers as follows: > > @@ -464,13 +466,7 @@ static int __init ttc_setup_clockevent(struct clk = *clk, > > return 0; > > } > > > > -/** > > - * ttc_timer_init - Initialize the timer > > - * > > - * Initializes the timer hardware and register the clock source and cl= ock event > > - * timers with Linux kernal timer framework > > - */ > > -static int __init ttc_timer_init(struct device_node *timer) > > +static int __init ttc_timer_probe(struct platform_device *pdev) > > { > > unsigned int irq; > > void __iomem *timer_baseaddr; > > @@ -478,6 +474,7 @@ static int __init ttc_timer_init(struct device_node= *timer) > > static int initialized; > > int clksel, ret; > > u32 timer_width =3D 16; > > + struct device_node *timer =3D pdev->dev.of_node; > > > > if (initialized) > > return 0; > > @@ -532,4 +529,17 @@ static int __init ttc_timer_init(struct device_nod= e > *timer) > > return 0; > > } > > > > -TIMER_OF_DECLARE(ttc, "cdns,ttc", ttc_timer_init); > > +static const struct of_device_id ttc_timer_of_match[] =3D { > > + {.compatible =3D "cdns,ttc"}, > > + {}, > > +}; > > + > > +MODULE_DEVICE_TABLE(of, ttc_timer_of_match); > > + > > +static struct platform_driver ttc_timer_driver =3D { > > + .driver =3D { > > + .name =3D "cdns_ttc_timer", > > + .of_match_table =3D ttc_timer_of_match, > > + }, > > +}; > > +builtin_platform_driver_probe(ttc_timer_driver, ttc_timer_probe); > > -- > > 2.7.4