Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp4619166yba; Wed, 10 Apr 2019 01:02:21 -0700 (PDT) X-Google-Smtp-Source: APXvYqzo0GmhmckDYiK10dgjCG7G9mR1AwKYl5Me0o0VOE62Pgz0/WZuyG6vX2lvqrbQZb4A67un X-Received: by 2002:a17:902:968b:: with SMTP id n11mr40498576plp.118.1554883341530; Wed, 10 Apr 2019 01:02:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554883341; cv=none; d=google.com; s=arc-20160816; b=WUSg6eM3j0DFAGoucNXsXRgTs7dJTakLLTeGEjmPxqq8Y02/anDGrRtKOEnNhqoUWZ 1zTBnLw7Y5J9yxP5WvjyK+MXLsILYe6nPGcZuCz/0VZ9dXF8yfZ+fMJGdOvX1UD9fSBp bZVpWjp+j51DElTknnVKsuV1foHScD9I1thsB7Oc9sGxGNMwOev9MHKHSZ8wg59o3R3Q 1IYKPE1a4zEQhN4I2px/aL/GlWUn0MnVY/nkN+GuuZI2pHnd3Tvj3zGAgRKXmSoIvRat hMmSp7u7IZvO0JTk0ZuOQkN2IOkOozW9RiHo7k7oOmN2RS4CmOmMMuW+Tuse3Z/Kv7eQ /uvg== ARC-Message-Signature: i=1; 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=orjKlCVHXrwxafKzAP89ZK1y6z3BVga/JXa6K4sY+wY=; b=bCsYguGpe2flcSoH4BmZvy7RuZCZAY4Tpg5xONg30XBeEyEwWYG4JoEk3aUvCAj0al FdjQUivfZTXu4M8w81dygU9vAw5kKJo6LG7e3aRI9B04pJoBlHIvQaahW/Dof16f1gAD vYJIIpFujUGqhKL0V8goCBsoE+jF79ZRYi0jNiXZi6F9bzR3+BTr8ZoAF4Kfi1lwXB0c BvSODzBZfLo1O7lSi8T0LXVFRd+SCUVjZO5KubbmLi45d9Dx+MoFF0q+N/1iYgzzXCfz hQrQ2zeMVO2cFWB+X6dISqyUDjS7Ycc0S/KnsNKPsjcLhl99mv8XNrPSaJBeSeT4Po94 7hzA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nxp.com header.s=selector1 header.b=HTn2ShmA; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l77si14668154pfb.34.2019.04.10.01.02.05; Wed, 10 Apr 2019 01:02:21 -0700 (PDT) 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=@nxp.com header.s=selector1 header.b=HTn2ShmA; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729021AbfDJHnT (ORCPT + 99 others); Wed, 10 Apr 2019 03:43:19 -0400 Received: from mail-eopbgr140081.outbound.protection.outlook.com ([40.107.14.81]:54302 "EHLO EUR01-VE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726577AbfDJHnS (ORCPT ); Wed, 10 Apr 2019 03:43:18 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=orjKlCVHXrwxafKzAP89ZK1y6z3BVga/JXa6K4sY+wY=; b=HTn2ShmAYGN5+w1mDG4EvtmAY5EGyEoXha5enGxnPQE/M9qpfAZaQa2u0fpYXilLTP78LIzHy0RnLFz96+7/PnVG1uUUt5bVne/8pN2NsfrTrJVmN9GPrGAjZM4nQGaCdHUoHEuPii/gvfAJWUtWg3fT8MEva+fg/Jg1pfpCKnY= Received: from DB3PR0402MB3916.eurprd04.prod.outlook.com (52.134.72.18) by DB3PR0402MB3770.eurprd04.prod.outlook.com (52.134.73.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1771.18; Wed, 10 Apr 2019 07:43:13 +0000 Received: from DB3PR0402MB3916.eurprd04.prod.outlook.com ([fe80::e8ca:4f6b:e43:c170]) by DB3PR0402MB3916.eurprd04.prod.outlook.com ([fe80::e8ca:4f6b:e43:c170%3]) with mapi id 15.20.1771.016; Wed, 10 Apr 2019 07:43:13 +0000 From: Anson Huang To: "robh+dt@kernel.org" , "mark.rutland@arm.com" , "shawnguo@kernel.org" , "s.hauer@pengutronix.de" , "kernel@pengutronix.de" , "festevam@gmail.com" , "catalin.marinas@arm.com" , "will.deacon@arm.com" , "rui.zhang@intel.com" , "edubezval@gmail.com" , "daniel.lezcano@linaro.org" , Aisheng Dong , "ulf.hansson@linaro.org" , Peng Fan , Daniel Baluta , "horms+renesas@verge.net.au" , "heiko@sntech.de" , Andy Gross , "maxime.ripard@bootlin.com" , "bjorn.andersson@linaro.org" , "jagan@amarulasolutions.com" , "enric.balletbo@collabora.com" , "ezequiel@collabora.com" , "stefan.wahren@i2se.com" , "marc.w.gonzalez@free.fr" , "olof@lixom.net" , "devicetree@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-pm@vger.kernel.org" CC: dl-linux-imx Subject: [PATCH RESEND V11 2/4] thermal: imx_sc: add i.MX system controller thermal support Thread-Topic: [PATCH RESEND V11 2/4] thermal: imx_sc: add i.MX system controller thermal support Thread-Index: AQHU73ENqQHtRU602k6XLq6MLOET1A== Date: Wed, 10 Apr 2019 07:43:13 +0000 Message-ID: <1554881866-26333-2-git-send-email-Anson.Huang@nxp.com> References: <1554881866-26333-1-git-send-email-Anson.Huang@nxp.com> In-Reply-To: <1554881866-26333-1-git-send-email-Anson.Huang@nxp.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-mailer: git-send-email 2.7.4 x-clientproxiedby: HK2PR02CA0155.apcprd02.prod.outlook.com (10.171.30.15) To DB3PR0402MB3916.eurprd04.prod.outlook.com (52.134.72.18) authentication-results: spf=none (sender IP is ) smtp.mailfrom=anson.huang@nxp.com; x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [119.31.174.66] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: a660c5a7-077e-4e7b-f93d-08d6bd882f8d x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600139)(711020)(4605104)(4618075)(2017052603328)(7193020);SRVR:DB3PR0402MB3770; x-ms-traffictypediagnostic: DB3PR0402MB3770: x-ld-processed: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635,ExtAddr x-microsoft-antispam-prvs: x-forefront-prvs: 00032065B2 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(366004)(346002)(39860400002)(396003)(136003)(376002)(189003)(199004)(86362001)(478600001)(7416002)(52116002)(97736004)(110136005)(76176011)(386003)(6506007)(2501003)(316002)(102836004)(186003)(2201001)(81156014)(81166006)(14454004)(2906002)(66066001)(8676002)(26005)(256004)(305945005)(6116002)(3846002)(7736002)(71190400001)(446003)(71200400001)(11346002)(68736007)(5660300002)(476003)(2616005)(6512007)(53936002)(36756003)(99286004)(106356001)(6436002)(105586002)(6486002)(8936002)(50226002)(25786009)(486006)(4326008)(921003)(1121003);DIR:OUT;SFP:1101;SCL:1;SRVR:DB3PR0402MB3770;H:DB3PR0402MB3916.eurprd04.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: ay5DO8pRYqOXgwfLqFlFF8z4cDGmnwjyyAwrDNH3wAwZ3x2miboHhq07BStCKPulODNFMtQBGB96BIxQTSIWNBvWtf1yk2a9XCXZrxP3wpOo7oSzSeRoaq3x2QnSlCmqTY8upzt4t2Z7VK8z0EoXKTqd1icf9RpvaB/LvpbT1PwMrYnTiXdGplN4dqwdso/BvIcwi0pQ14vHopwFy+tGZIWxPuJZLdwMSpdrKYouFd2Z0xMM8rOksdUrpwczgt/bbQ0t96iRT6r5a8dDycdnb/SI+mr2hJn2CesApvHz4+xmEynL06ujb6C8NgWs+4uN81P83B5nNcrFQovpaoMn7XIk9sq2dcpxybocYZNZtoe295NRJuUipXWk4P3Bl/WXXGG8M6rZH9RrDdjOMkwQxmHIpdWh9E2WUN4j4s+thgI= Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: a660c5a7-077e-4e7b-f93d-08d6bd882f8d X-MS-Exchange-CrossTenant-originalarrivaltime: 10 Apr 2019 07:43:13.4171 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB3PR0402MB3770 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org aS5NWDhRWFAgaXMgYW4gQVJNdjggU29DIHdoaWNoIGhhcyBhIENvcnRleC1NNCBzeXN0ZW0gY29u dHJvbGxlcg0KaW5zaWRlLCB0aGUgc3lzdGVtIGNvbnRyb2xsZX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