From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756638AbaICPib (ORCPT ); Wed, 3 Sep 2014 11:38:31 -0400 Received: from mail-lb0-f174.google.com ([209.85.217.174]:50743 "EHLO mail-lb0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756172AbaICPi3 (ORCPT ); Wed, 3 Sep 2014 11:38:29 -0400 X-Google-Original-Sender: Date: Wed, 3 Sep 2014 17:37:07 +0200 From: Johan Hovold To: Octavian Purdila Cc: Johan Hovold , Lee Jones , Greg Kroah-Hartman , Linus Walleij , Alexandre Courbot , wsa@the-dreams.de, Samuel Ortiz , Arnd Bergmann , linux-usb@vger.kernel.org, lkml , linux-gpio@vger.kernel.org, linux-i2c@vger.kernel.org, Daniel Baluta , Laurentiu Palcu Subject: Re: [PATCH v2 1/3] mfd: add support for Diolan DLN-2 devices Message-ID: <20140903153707.GC4894@localhost> References: <20140901113949.GP7374@lee--X1> <20140901154626.GH8796@lee--X1> <20140901175453.GR4894@localhost> <20140902080010.GD17117@lee--X1> <20140902152311.GY4894@localhost> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.22 (2013-10-16) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Sep 03, 2014 at 04:39:48PM +0300, Octavian Purdila wrote: > On Tue, Sep 2, 2014 at 6:23 PM, Johan Hovold wrote: > > That should be possible using the regmap bus read and write operations. > > I took a closer look on the regmap bus read/write operations and I > think they are not fit for what we need in the driver. The driver uses > a request/response model which, IMHO, does not fit well with a > register read/write API. Yes, maybe we can emulate it, but why do > that? > > >> (Also creating a regmap class for a particular device seems over > >> engineering since nobody else is going to use it) > > > > Possibly, but it would allow subdrivers to be implemented using a > > standard interface and also provide register caching for free. > > Using a standard interface is nice, but I think that using the right > interface type is more important. This hardware does not use registers > but a messages to communicate with the OS. You might be right, and as I mentioned, I haven't looked that closely at the protocol yet. I'll take a look at your updated I/O interface and how you use it. Johan