Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp1174507pxa; Thu, 20 Aug 2020 04:47:09 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwL2CGQ/KDkXl3eFW31lwcjwm+RItYp9JvB3PTTQ6kKmHPzeEPVfH6NNeo1j2EO7uw+yjiK X-Received: by 2002:a17:906:b082:: with SMTP id x2mr2955969ejy.349.1597924028865; Thu, 20 Aug 2020 04:47:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597924028; cv=none; d=google.com; s=arc-20160816; b=rNRNHsTRHDF/MJvUxW9ylvnxQhuKCNvsMYqQjkHGdLj9criYq7F7oJdjhhGrG/BNM7 UiXByWSUpCT4OyinkKrWqSVQUuOiYv8kmLnt3E7yblTw7AGavY7AvLCzmPdL5Ih7HnlR FkUYJYRx6XFaGZonkbOaH6DwaqLfKILf4TN8TwZq7BKgC0Mdrn8Kh+O7RZjVtPZYuSsl 3QZF4raWXFWNxvjTDN7Bcs5yKWteOe1N5cCAXEk4IgsoaZ7BYHUyjVq8YYuE4pn1xsPX Tq06S8xp4Nro5GUF52Z+ORx/oF2sV2AZ1Rr7tThgEblBHwL6m6kV4VPlNWzDzWH4Zp3H 03YA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=BQSyYxupgqjS22G4bgKdlwMJIDhvIeQRU0/1jOPz4LI=; b=yjBPzFk/JZYKHkMnHAppTbAWzM8wdeWJdUSmAym2IhREgUtby97HvqEdFcARSBag/U XmsNH4ZLToJ24t29bD3kx+V197u0ZKYGe4eFIo91/7zgsK77UzePEBWP9Jur7q32b3Un O/aAUnVVGOP7ttWGnHrp+P5sNGY6NpwL/W/odGa+kMRIlsNK6MD65fRPVNDkokx6Jv28 WbVdm1GZS6CYb3omdcuh3h3osEazzK9z19g1+8gaORe2xbggyv6XAlecpxIsNKYQK2V6 mkabsu8v6gif8qWyVK35uFAuqSBsKWbo/jfp4ifsaKHoKGtdlw3MxaeFmOtg6TtPusoJ RLjQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=SiXurh7h; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y19si525785eje.478.2020.08.20.04.46.45; Thu, 20 Aug 2020 04:47:08 -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=@kernel.org header.s=default header.b=SiXurh7h; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730590AbgHTLqN (ORCPT + 99 others); Thu, 20 Aug 2020 07:46:13 -0400 Received: from mail.kernel.org ([198.145.29.99]:59066 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729582AbgHTLp5 (ORCPT ); Thu, 20 Aug 2020 07:45:57 -0400 Received: from localhost (cpc102320-sgyl38-2-0-cust46.18-2.cable.virginm.net [82.37.168.47]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id E4CF12078B; Thu, 20 Aug 2020 11:45:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1597923957; bh=EmpcpyWUq8w0WNjTx0pP0rrQmAkwNgLkN1Z/MnuebcI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=SiXurh7hS5kaPGz83qRaQPFIa3c10EcxMdG7VqJpmcAvQ1Kr2uVTFkz5T+BxZkuGc Qud9WfkBlOnTh1eiEAJ+5+R7ke09jeNewuXlamTAN4LdniF9WirwON/WrYfCYGezDu yuD0BvTXq5D151EW8HkiDvG8ChfiRGSL50q4s7+k= Date: Thu, 20 Aug 2020 12:45:24 +0100 From: Mark Brown To: Gene Chen Cc: matthias.bgg@gmail.com, robh+dt@kernel.org, lgirdwood@gmail.com, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, Gene Chen Subject: Re: [PATCH v3 1/2] regulator: mt6360: Add support for MT6360 regulator Message-ID: <20200820114524.GC5854@sirena.org.uk> References: <1597910022-22617-1-git-send-email-gene.chen.richtek@gmail.com> <1597910022-22617-2-git-send-email-gene.chen.richtek@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="jousvV0MzM2p6OtC" Content-Disposition: inline In-Reply-To: <1597910022-22617-2-git-send-email-gene.chen.richtek@gmail.com> X-Cookie: Dead? No excuse for laying off work. User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --jousvV0MzM2p6OtC Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, Aug 20, 2020 at 03:53:41PM +0800, Gene Chen wrote: > + mrd->regmap = dev_get_regmap(pdev->dev.parent, NULL); > + if (!mrd->regmap) { > + dev_err(&pdev->dev, "Failed to get parent regmap\n"); > + return -ENODEV; > + } > +static const struct of_device_id __maybe_unused mt6360_regulator_of_id[] = { > + { .compatible = "mediatek,mt6360-regulator", }, > + {}, > +}; > +MODULE_DEVICE_TABLE(of, mt6360_regulator_of_id); This device only exists in the context of a single parent device, there should be no need for a compatible string here - this is just a detail of how Linux does things. The MFD should just instntiate the platform device. --jousvV0MzM2p6OtC Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAl8+YlMACgkQJNaLcl1U h9DIKwf/ev1phumPNeX6i1SQql+DSte48x9dcwfsdVGdcUYYk9q6H6T5tUIKpzF7 htv0KnJWujWXk9eYft25GnJTOdpzdkihP+bqHsc86o+2wfuI/9NGr2z6Al6sFwjf 5neoBb9H3XMIHkkiAk/f8d4q5i9HDJA+5Gqe82/m7TV3qM7AYjeQH8X0BRnlGPTw +H9wDCDmg/BkT4jq1spi0++fua58EtL58ex8OBPZpxFeG3ZPHZMLknJikpbEj3sG L2I+4nITn7sB4zrTbIZDcdZYJCcubV/rZ0lO7+K6a1SGDxw98eOOfy21ht4qM6RV R2n7uxfo+TjXqHqkdBGwQoqJdf2yJA== =7oEp -----END PGP SIGNATURE----- --jousvV0MzM2p6OtC--