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=-1.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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 D7273C433E0 for ; Tue, 9 Jun 2020 17:15:25 +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 A8C3A20734 for ; Tue, 9 Jun 2020 17:15:25 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="onLtMiwW" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A8C3A20734 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=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=0j31ZbtGkUdVAWX+5HBItHYLaD8cRsCkv7Jv9wYj3Ag=; b=onLtMiwWKzhjS/ qRgqj8uFbaa+6ied51r5nbgautgIAynMxjzQUMYxPU2k1tV3tRayOlTnJeuIQu/biikfFeETT5G7Z khhVwZGrFYQOFx3wq0VqUQLa79QL5IVRaOyGVeGDcFVRDdD3uOQmPC3GB4slZ3UTyBklbmIbQrBB2 ij8vVBcJ0z3giFz2BL0G3LB2swZUXhDqbu47eWdaHaGDmfZkHXTeFu0j0qaFOxBW8GODyRCQzKuWq m4m3Sd6kNQ+NO3QwO99Ut72u7sBg9dd3Aox/Q0kvwSTfXkju1cuOfB7291uOzDC18hWess8TPY6eL 4/gefOeUDrkNZ7wpPGaw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jihqP-00023F-DG; Tue, 09 Jun 2020 17:15:25 +0000 Received: from mail-io1-f68.google.com ([209.85.166.68]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jihqN-00022l-6N for linux-arm-kernel@lists.infradead.org; Tue, 09 Jun 2020 17:15:24 +0000 Received: by mail-io1-f68.google.com with SMTP id i25so9005338iog.0 for ; Tue, 09 Jun 2020 10:15:22 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=JGLI/jshAv4UOtJl5rWJiq7REK+PfEQZi+2RrLn3IFA=; b=nk9KhM1aSEHpRzJXTgvHW/fkrgpkMSTSIR7Bns2FYC616DMiK4fkwfbAJrVCiZirpM tbF3GInJobBssrdViXoL8AnzPusDMqomwX6z13RJfM34YUHCM22rNDuEKinMbbJ7fo+R SW0KG7TyO9sK2arsDIAfzihRiKiXlngmPUqp1QIujMtKYQyhbfbHvBXCCbkZ8Eq/ih8c eXmMaT/AtTgVMGz2QXM4Uo6/4ETia72EmwYA/1H3sPvwXaQpu/HmaTDssrHIbKCz9otf UWuK8mVaSOKjecj2CIp81JhDT3AdkmaGk3iHuwBX/3idV4USOj7W8G9LXhLi3A9yezGU 9X1w== X-Gm-Message-State: AOAM533IsyVWtESzKbS+8lfSlPCm71298g7WYQiGxF0AJzs36s08NcVR AvBCLmZcY+87MYNaNwahlQ== X-Google-Smtp-Source: ABdhPJyom2HW81zaEPBo0bO0otJQ7le36pAHDKSbZIdASMosYcxXzc1o/KabAiMefhklBHue5cmzqQ== X-Received: by 2002:a5d:8e14:: with SMTP id e20mr28764204iod.156.1591722922294; Tue, 09 Jun 2020 10:15:22 -0700 (PDT) Received: from xps15 ([64.188.179.251]) by smtp.gmail.com with ESMTPSA id k5sm9534836ili.80.2020.06.09.10.15.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 09 Jun 2020 10:15:21 -0700 (PDT) Received: (nullmailer pid 1093153 invoked by uid 1000); Tue, 09 Jun 2020 17:15:20 -0000 Date: Tue, 9 Jun 2020 11:15:20 -0600 From: Rob Herring To: Michael Walle Subject: Re: [PATCH v4 02/11] mfd: Add support for Kontron sl28cpld management controller Message-ID: <20200609171520.GC1019634@bogus> References: <20200608082827.GB3567@dell> <7d7feb374cbf5a587dc1ce65fc3ad672@walle.cc> <20200608185651.GD4106@dell> <32231f26f7028d62aeda8fdb3364faf1@walle.cc> <20200609064735.GH4106@dell> <32287ac0488f7cbd5a7d1259c284e554@walle.cc> <20200609144201.GK4583@sirena.org.uk> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200609_101523_234616_1DD6B84F X-CRM114-Status: GOOD ( 18.42 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-pwm@vger.kernel.org, Linus Walleij , Thierry Reding , Lee Jones , Jason Cooper , Andy Shevchenko , Marc Zyngier , Ranjani Sridharan , Bartosz Golaszewski , Andy Shevchenko , =?UTF-8?Q?Uwe_Kleine=2DK=C3=B6nig?= , david.m.ertman@intel.com, Guenter Roeck , devicetree , Jean Delvare , linux-watchdog@vger.kernel.org, "open list:GPIO SUBSYSTEM" , Mark Brown , Thomas Gleixner , Wim Van Sebroeck , shiraz.saleem@intel.com, linux-arm Mailing List , linux-hwmon@vger.kernel.org, Greg Kroah-Hartman , Linux Kernel Mailing List , Li Yang , Shawn Guo Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Tue, Jun 09, 2020 at 05:01:17PM +0200, Michael Walle wrote: > Am 2020-06-09 16:42, schrieb Mark Brown: > > On Tue, Jun 09, 2020 at 04:38:31PM +0200, Michael Walle wrote: > > > > > mfd-device@10 { > > > compatible = "simple-regmap", "simple-mfd"; > > > reg = <10>; > > > regmap,reg-bits = <8>; > > > regmap,val-bits = <8>; > > > sub-device@0 { > > > compatible = "vendor,sub-device0"; > > > reg = <0>; > > > }; > > > > A DT binding like this is not a good idea, encoding the details of the > > register map into the DT binding makes it an ABI which is begging for > > trouble. I'd also suggest that any device using a generic driver like > > this should have a specific compatible string for the device so we can > > go back and add quirks later if we need them. > > Like in the spidev case, yes. But OTOH if I _just_ encode the parameters > for the regmap a MFD, Lee don't agree because its just a shim. So either > way I seem to be stuck here. > > Where should I put the code to create an i2c driver, init a regmap and > populate its childen? Find another driver doing this already and rename it 'simple-mfd' (no relation to the DT binding) and add your compatible string to it. 'Generic' or 'simple' drivers don't require generic/simple DT bindings. Or extend the existing syscon driver to look up the bus_type and create the regmap based on the bus type? Rob _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel