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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 302DACCA47F for ; Mon, 13 Jun 2022 18:39:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237618AbiFMSjD (ORCPT ); Mon, 13 Jun 2022 14:39:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37222 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343761AbiFMSiY (ORCPT ); Mon, 13 Jun 2022 14:38:24 -0400 Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5C5BD37A1A; Mon, 13 Jun 2022 08:35:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1655134529; x=1686670529; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=VaArXUZWlGkR+Rg5TxqlTrvxLQWmF66TsY0IDaHvDJU=; b=i7tyoT18uRl6ySPsqGZst7te157jclRIvZKMGTMh1TS4sZZrECxYpygY +ZXwA7kT+ctDiUX3sPHxLJzo259MFPlaY7UFHQA28Eg2YwkgAi38LeTYw O80v9068dP90hPDwDiv2vCA6HdKM3kMNigzjYk88JuQ84TR3QKoTe3CB3 QpLVcOF9VNnGVOCF66TFwcFZEqMspgH8ZVk552FaY8+mogb2/x7JEeq7x 3TbF/MlwTzX36pYfC6/t2jhLGMZOYKaVr8KXO2wUVr1VRG5YP8NB7Tsyy zfCnuMmlh/JaHpckjv+PNulW9M6nczdRNyhkevR1bw7WODy0CB2Fr1gq9 Q==; X-IronPort-AV: E=McAfee;i="6400,9594,10377"; a="261357223" X-IronPort-AV: E=Sophos;i="5.91,297,1647327600"; d="scan'208";a="261357223" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jun 2022 08:35:28 -0700 X-IronPort-AV: E=Sophos;i="5.91,297,1647327600"; d="scan'208";a="582283738" Received: from smile.fi.intel.com ([10.237.72.54]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jun 2022 08:35:24 -0700 Received: from andy by smile.fi.intel.com with local (Exim 4.95) (envelope-from ) id 1o0m64-000b8T-6V; Mon, 13 Jun 2022 18:35:20 +0300 Date: Mon, 13 Jun 2022 18:35:19 +0300 From: "andriy.shevchenko@linux.intel.com" To: Dominik Kierner Cc: Javier Martinez Canillas , "airlied@linux.ie" , "daniel.vetter@ffwll.ch" , "dri-devel@lists.freedesktop.org" , "geert@linux-m68k.org" , "lee.jones@linaro.org" , "linux-fbdev@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-pwm@vger.kernel.org" , "maxime@cerno.tech" , "noralf@tronnes.org" , "sam@ravnborg.org" , "thierry.reding@gmail.com" , "tzimmermann@suse.de" , "u.kleine-koenig@pengutronix.de" Subject: Re: [PATCH v6 3/6] drm: Add driver for Solomon SSD130x OLED displays Message-ID: References: <7a78d57342754a5d9bd3ce7c7bf3fa47@dh-electronics.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <7a78d57342754a5d9bd3ce7c7bf3fa47@dh-electronics.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org On Mon, Jun 13, 2022 at 11:39:30AM +0000, Dominik Kierner wrote: > On 5/25/2022 21:46, Javier Martinez Canillas wrote: ... > > Thanks, I looked at the code briefly and think that there are things there that we > > could use. I.e the 3-wire SPI support that's in panel-solomon-ssd130x-spi-3wire.c. > > When writing my driver code, I wasn't even considering using regmaps, > like You did in Your I2C-Code. If that's applicable for 3-wire-SPI, > it would likely be the better, more generic option. Your SPI-code > reuses these parts to some extent. For that case, > ssd130x_spi_regmap_config.reg_bits would need be changed to 1, > as the "register address" has a length of 1 bit and we are sending > 9 bits over the line and not 16. > Since we still have 2 bytes of host memory, > it should still be compatible with the 4-wire write, right? > Or would 3-wire SPI require a second regmap? I believe the cleanest solution is to have different regmap configurations. -- With Best Regards, Andy Shevchenko