Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp1096615pxa; Thu, 20 Aug 2020 02:18:38 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyzjh66SgeT+e29K4zEgluP2jRm2xmERrncCPdLHuwajF1o/y/2fl0/jAnVrZxfR6bqvJVT X-Received: by 2002:a17:906:4c46:: with SMTP id d6mr2481068ejw.14.1597915117883; Thu, 20 Aug 2020 02:18:37 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1597915117; cv=pass; d=google.com; s=arc-20160816; b=YOqwOKqOAcwdmq0f11zPRErg275fcC81dkLISr2AhjHyZwsca01HcE0vjqx+TzLbZk Lzmbbu9odXMrvDZ7KEXg97Ah/XOx6FHu+FO0CklITmKQ7DHE4xRFI4YRjrHAv5492x/x lbLGQ1umU1SQIYg/t6Q96LvzGfXfaXnxXGz+t4v59nogGZFpwZrRC5ue9zFGd/v6Hx+d GmLUpbfUfNsLrQD6YWqpwGyIouXxPWHeKq7HHij554LY8zGnAp/iuijX5oDZpjSvxSFS FU/Mjp1tXLPIQruKMLTY9SjwbI7masbd5lSFxjaXc1SKuIU3dcG+RtUXXMkQ954w7z/i 87cQ== 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 :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=kWP85sg+5B2N7GxqB5V/tlSIKHfhx9kgFns3KJl3sJ8=; b=OwhS7RshujoerbbVRGN4aukaOcxhYDjo+CoKSEoVajAFL3H55DPORbwdQ3pPTUQGbx ipG3vNiyCgXj20jIwHYT6sWvaYInHqCBL8GozfXIQN+QsZ0jpTTQ9N0K3iG2oCOZ5dae u6iO7VZ7g1SgxUFfE08ExItweZHp5Veb8D+8BRmSXTXKh1JVQQ0JucZiAxqbnj4r4U8O duULagR2e92sr+rziiNiee/3+e3p3vXr1iLkYkv/mmpvRPgIMyyR/qfomOuIy5UWwJQt aV85grA5XtnMTjqbeoFInSO4ks6u83/f8IVECAB5bSrK1+8pLr8eh5o2g+XYLhJ/QTqQ ahDA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@Synaptics.onmicrosoft.com header.s=selector2-Synaptics-onmicrosoft-com header.b=ZVXy4KY6; arc=pass (i=1 spf=pass spfdomain=synaptics.com dkim=pass dkdomain=synaptics.com dmarc=pass fromdomain=synaptics.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=synaptics.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b16si886627eja.517.2020.08.20.02.18.14; Thu, 20 Aug 2020 02:18:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@Synaptics.onmicrosoft.com header.s=selector2-Synaptics-onmicrosoft-com header.b=ZVXy4KY6; arc=pass (i=1 spf=pass spfdomain=synaptics.com dkim=pass dkdomain=synaptics.com dmarc=pass fromdomain=synaptics.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=synaptics.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726716AbgHTJRh (ORCPT + 99 others); Thu, 20 Aug 2020 05:17:37 -0400 Received: from mail-mw2nam10on2079.outbound.protection.outlook.com ([40.107.94.79]:58367 "EHLO NAM10-MW2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726819AbgHTJQS (ORCPT ); Thu, 20 Aug 2020 05:16:18 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=UMur2l4zsbE78PFb9spDhH4z0U5RPPuSOK1o/Ht+o6RBWSnu3LxX8agnis99rUR5fafuE8TYKk0DljYetU1puRswBCbgwcp5S+N2afX8viWKFQtHvTZ66W0TuWbwQJG0NEahMpeO8gFCZ7qrImqjSveDnUflrPWr/XV/L5FcIy+ojvdBk1ulIg+/MUkDhV4viAfVXnU9t60VehZSYpv6F1OfgnyHW+t9vLJo082UM9hAW+pFa0/EyNl9RCDkXRLINc+oA1y+lJrWVdGNAv1gVyht0BarZwloM0IXI4hA1EAlBWXQwHao6SVfA5hG2ke8o88RMmuWiGjdvHtgF+vEsA== 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=kWP85sg+5B2N7GxqB5V/tlSIKHfhx9kgFns3KJl3sJ8=; b=jvTnRiMRtZ0Nc4YjAmJyWwpcYDp3NZ/j/95brK1SAtYZFar6E6IZi4DCla7vJYtzKnykdR5Q90nvM9ZWJvxRFNTi72tL7caiewRGE3JkFqIeh0NZiZGxp35mwmqKzm9To+zscEZqRkUYA+YC7sx/BnSlNhTdKKV0E7oGIRRly+3Mkny3SfSMCnPDSw7SEiznXp0sdBUO565yojIM9Ue4D+MHFpEI3ZFcHTRbFjuchgOJ+yceW6JPsYKQa61GgZnLTsgyD5EUeUF21OubJg4PsT9o9VXN8E/R/lm8P6YP7NnX6c3JMFBNAHwwYOHMgJsjwNRR87cRL4j0oqZDFbr8wg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=synaptics.com; dmarc=pass action=none header.from=synaptics.com; dkim=pass header.d=synaptics.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Synaptics.onmicrosoft.com; s=selector2-Synaptics-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=kWP85sg+5B2N7GxqB5V/tlSIKHfhx9kgFns3KJl3sJ8=; b=ZVXy4KY6c3rR/+PXCAjQjKKqVH44bHrFhZRhXUGIMhh8KbTG2jHwbXmrO+OLWfxC88yykrnzR/wpeiyg/IFbcyMDlfTs+DGAhwXmaT41y6z1E3hsVasvbi+2QO5KhZrNRZKWx9c5r8ZSBRQdxhZmWtypP52XuJGLYry6OTtgHLI= Authentication-Results: gmail.com; dkim=none (message not signed) header.d=none;gmail.com; dmarc=none action=none header.from=synaptics.com; Received: from BN7PR03MB4547.namprd03.prod.outlook.com (2603:10b6:408:9::22) by BN8PR03MB4738.namprd03.prod.outlook.com (2603:10b6:408:6d::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3305.24; Thu, 20 Aug 2020 09:15:45 +0000 Received: from BN7PR03MB4547.namprd03.prod.outlook.com ([fe80::3cda:7634:5802:df5f]) by BN7PR03MB4547.namprd03.prod.outlook.com ([fe80::3cda:7634:5802:df5f%7]) with mapi id 15.20.3305.024; Thu, 20 Aug 2020 09:15:45 +0000 Date: Thu, 20 Aug 2020 17:12:32 +0800 From: Jisheng Zhang To: Liam Girdwood , Mark Brown , Rob Herring , Saravanan Sekar Cc: linux-kernel@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v3 4/4] dt-bindings: regulator: Convert mp886x to json-schema Message-ID: <20200820171232.1fede9bc@xhacker.debian> In-Reply-To: <20200820171020.5df4683b@xhacker.debian> References: <20200820171020.5df4683b@xhacker.debian> X-Mailer: Claws Mail 3.17.6 (GTK+ 2.24.32; x86_64-pc-linux-gnu) Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-ClientProxiedBy: TYAPR03CA0015.apcprd03.prod.outlook.com (2603:1096:404:14::27) To BN7PR03MB4547.namprd03.prod.outlook.com (2603:10b6:408:9::22) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from 255.255.255.255 (255.255.255.255) by TYAPR03CA0015.apcprd03.prod.outlook.com (2603:1096:404:14::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3326.10 via Frontend Transport; Thu, 20 Aug 2020 09:15:43 +0000 X-Mailer: Claws Mail 3.17.6 (GTK+ 2.24.32; x86_64-pc-linux-gnu) X-Originating-IP: [124.74.246.114] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: e359bfa4-4ccd-4199-808e-08d844e99e95 X-MS-TrafficTypeDiagnostic: BN8PR03MB4738: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:7691; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: XYSLPkgKsNYDDYhvH49w8jcdZJSN5A/EuO2aSr87+DGu3l9SqdIR3Bf9+fIJAqnWWwmLzIiVFnxKwty/Qj99n4KGNDnT51ckNrFkc3K6TKeXlYqf2YKgQl2CfySu61PQ1y94fcDgFS+kOxYDMnVoBlUL8AIbuCayTxqe6MQMO9vnpqWhY8z9YVdibYuDynQH6OTuFQDeD1CD+eIP9VDE9ztyxGIHlE/LpdL0Kcnsbk1noXqVpqz0DbuID/4MovJ/vNo1lHa/8kxRkcLHiDCioexoQ+keF7HPZMIknCqDPhV5B8wfMeSdKGCGc/r9Wsbu0VO4R8gvNl/jJjc9HL+3+cKq4nQ1kefoQxcBKo7y1KtOEVxlSzEyIhT0YvOmEjmh4JWcKURB2izA0HD3hZhDslZoe32Npe6OM460ivrQgwqoITPb9EHXqjB0KcKB8fFykDMTQnO7Im/Vqype0a4iRw== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:BN7PR03MB4547.namprd03.prod.outlook.com;PTR:;CAT:NONE;SFS:(39860400002)(396003)(346002)(366004)(376002)(136003)(316002)(2906002)(110136005)(66476007)(6486002)(66556008)(66946007)(110011004)(966005)(16576012)(4326008)(8676002)(478600001)(5660300002)(26005)(86362001)(9686003)(6666004)(52116002)(956004)(186003)(1076003)(83380400001)(8936002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: vgzEO04YE4kGsNF1Apev1s7gMhSleIvhjepY6fRGEikvpjQVv+8Ay7Wgs+PBlsJDduRw2Gz4IcZzakA2WRBnCmDH7Fp+91V6SomHxXgiiF5j1nfOQuf8ZmR3ZufTdDJjX8tt8XoSpnsX3UAaffo63XXgjL1m4dwX5gGsJs6Ok1M4ToJariR+XLwPJfHmEpXXGKPfPppp1yvF/DWzoF5T75oG6MBQb5RgBcYV4IJz7TNv8jDgdTJFqS40+lXadpDF3wcj/lNaQyQAK1YGqT895nvB/qaKj8lODc9oarq+d9o8h6n6SZss64nUh+F8sS5FKv7tJBciYRZf6FM0/lhC5SEheIpJj/1sFGk9q0h6Nzob1xt9f3fITW38xIovUFU17r5xoQI49ym/gUhUzzTFXJ8gGgD60z6StEDMGbLBl71SqZx3ioGO//nohf11zU3yn7sw8m8g1cg6WBzmhfV6EDUED8DmgPMwNufn9odqJUhCaGbIgM1hpTKfsMX9PpAX+jPH0VdD93lIV/mrArbTige6P7ScfSTMOMZjeCwqBA+hzVdUDIkQFPEzVgxN1ekqp/RwAdvRmdCLMk7UubZgWuJDYcMNM8Kbc80FjGQ4bOP/2OaEbFSI9gckVnksWY+VglCFfnW2RxJP+OR1JqhvWQ== X-OriginatorOrg: synaptics.com X-MS-Exchange-CrossTenant-Network-Message-Id: e359bfa4-4ccd-4199-808e-08d844e99e95 X-MS-Exchange-CrossTenant-AuthSource: BN7PR03MB4547.namprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Aug 2020 09:15:45.5339 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 335d1fbc-2124-4173-9863-17e7051a2a0e X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: uguMyUL6ge4d1wq2zJbaQMXqQwZ2xKIvwQF9UDzG9GeDG4KKsUogcLTaTwZs71G4QtVtQ1sfc11GFtyi2+JALw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN8PR03MB4738 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Convert the mp886x binding to DT schema format using json-schema. Signed-off-by: Jisheng Zhang --- .../devicetree/bindings/regulator/mp886x.txt | 31 ---------- .../bindings/regulator/mps,mp886x.yaml | 61 +++++++++++++++++++ 2 files changed, 61 insertions(+), 31 deletions(-) delete mode 100644 Documentation/devicetree/bindings/regulator/mp886x.txt create mode 100644 Documentation/devicetree/bindings/regulator/mps,mp886x.yaml diff --git a/Documentation/devicetree/bindings/regulator/mp886x.txt b/Documentation/devicetree/bindings/regulator/mp886x.txt deleted file mode 100644 index b05307bbb0d9..000000000000 --- a/Documentation/devicetree/bindings/regulator/mp886x.txt +++ /dev/null @@ -1,31 +0,0 @@ -Monolithic Power Systems MP8867/MP8869 voltage regulator - -Required properties: -- compatible: Must be one of the following. - "mps,mp8867" - "mps,mp8869" -- reg: I2C slave address. -- enable-gpios: enable gpios. -- mps,fb-voltage-divider: An array of two integers containing the resistor - values R1 and R2 of the feedback voltage divider in kilo ohms. - -Optional properties: -- mps,switch-frequency-hz: The valid switch frequency in Hertz. Available values - are: 500000, 750000, 1000000, 1250000, 1500000 - -Any property defined as part of the core regulator binding, defined in -./regulator.txt, can also be used. - -Example: - - vcpu: regulator@62 { - compatible = "mps,mp8869"; - regulator-name = "vcpu"; - regulator-min-microvolt = <700000>; - regulator-max-microvolt = <850000>; - regulator-always-on; - regulator-boot-on; - enable-gpios = <&porta 1 GPIO_ACTIVE_LOW>; - mps,fb-voltage-divider = <80 240>; - reg = <0x62>; - }; diff --git a/Documentation/devicetree/bindings/regulator/mps,mp886x.yaml b/Documentation/devicetree/bindings/regulator/mps,mp886x.yaml new file mode 100644 index 000000000000..ba175b30f468 --- /dev/null +++ b/Documentation/devicetree/bindings/regulator/mps,mp886x.yaml @@ -0,0 +1,61 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/regulator/mps,mp886x.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Monolithic Power Systems MP8867/MP8869 voltage regulator + +maintainers: + - Jisheng Zhang + +allOf: + - $ref: regulator.yaml# + +properties: + compatible: + enum: + - mps,mp8867 + - mps,mp8869 + + reg: + maxItems: 1 + + enable-gpios: + description: GPIO to enable/disable the regulator. + maxItems: 1 + + mps,fb-voltage-divider: + description: An array of two integers containing the resistor + values R1 and R2 of the feedback voltage divider in kilo ohms. + $ref: "/schemas/types.yaml#/definitions/uint32-array" + maxItems: 2 + + mps,switch-frequency-hz: + description: The valid switch frequency in Hertz. + enum: [500000, 750000, 1000000, 1250000, 1500000] + +required: + - compatible + - reg + - enable-gpios + - mps,fb-voltage-divider + +examples: + - | + #include + i2c { + #address-cells = <1>; + #size-cells = <0>; + regulator@62 { + compatible = "mps,mp8869"; + regulator-name = "vcpu"; + regulator-min-microvolt = <800000>; + regulator-max-microvolt = <1150000>; + enable-gpios = <&porta 1 GPIO_ACTIVE_LOW>; + mps,fb-voltage-divider = <80 240>; + reg = <0x62>; + }; + }; + +... -- 2.28.0