Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp6270297imu; Wed, 30 Jan 2019 11:43:16 -0800 (PST) X-Google-Smtp-Source: ALg8bN4P8xDQpt5Z6Iwu/m94NulPBpIyn+bISS3xIx4SlH7aUUe3A5oRersNV2SXLzGX75WRyL/J X-Received: by 2002:a17:902:6b87:: with SMTP id p7mr32179616plk.282.1548877396332; Wed, 30 Jan 2019 11:43:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548877396; cv=none; d=google.com; s=arc-20160816; b=HZXEcUmpamWBYY5wqWZ4YVOPVmZu9dUUXccxOLO+c4FUVi3U37FuUv1UEeWj1rQssD 4Gp6jFspGuTnv/xGbueBmiJN6gyVO41RwJg0t/e0J+aV4vudQqbjP2dhG6FI97ctWi30 SE80um61IMvImSQX5sKgtkjL9rPVd6uDEHilG7dDGZjblo9Q9GrTIxDGO33EjWBQhtco j1E+6j4rKBLBJHvh2lLPriZtdnpICZRcoEntVu//1Lzg4iVMM4PmnPi4uCznKRJZpRzM 947yG6NAeia4oezmpFeZu0mBX/PtkZQygv8XYLK1wgkSS5uTYJgPeCnh8U2hcem6INl9 NIzg== 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=mEAxoFAp+9O4LkN8kPviFbHCxv9YepnljzxmTiZOsAI=; b=lpBhUmMjg+9Q7XAq1x8Rs6+pXGZ9MbxRQxAf7QW4XbJdTr8waKLJqrSJbiduXP3ZXn Cxft3QW477UFerFKBoRsPSAuIQJMZenCuAo1hpNDQJ4Iolh2JlOHfiQEH7oVLMpWBhWD Uba9NO8HoLmZsd63jYUAeUP1AzkS3XQt6TX5MvrTsdtYkgetVSmf2kIaHopON3mCZdAV 6vCji+uGDddZ537G+8yiclbLfmAbtPOUUg0UfaMw9EEt8VPXPMEmF9NLGsR4XdqOs33+ sv1IqezGX29GHioYmD/DqStiQLJ5gWoN4QKp3kXWLHozYu1NwnYfN2JZesHtL4krwQ3C u9gA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=GCZROYdB; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d142si2277941pfd.93.2019.01.30.11.43.00; Wed, 30 Jan 2019 11:43:16 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=GCZROYdB; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387758AbfA3TlD (ORCPT + 99 others); Wed, 30 Jan 2019 14:41:03 -0500 Received: from mail.kernel.org ([198.145.29.99]:55194 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387587AbfA3TlC (ORCPT ); Wed, 30 Jan 2019 14:41:02 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (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 8BFCD21473; Wed, 30 Jan 2019 19:41:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1548877262; bh=fF9/4EGUIy+N2ANoKElFW6gKSOdMRwW+wEjrtwpy2h8=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=GCZROYdBYUgcGe/xisVPs0TbO76M4Ecr24WZfMBWq7Vr+AKmaTDKm+bgBUeNZK/0x u9zdx8tkTqGVz4QtgJp1kKDxHHobnJhjTqFsrDt7wgCW+XBJHRtyVlhgxQWcFwNKC2 smUY74T1efkc2KEb2g2HTjWKIYoz7kpYkXKGXKE0= Date: Wed, 30 Jan 2019 20:40:59 +0100 From: Greg Kroah-Hartman To: Boris Brezillon Cc: Geert Uytterhoeven , Geert Uytterhoeven , Arnd Bergmann , MTD Maling List , Nguyen An Hoan , Linux Kernel Mailing List , linux-spi Subject: Re: [PATCH v2 0/2] eeprom: at25: SPI transfer improvements Message-ID: <20190130194059.GC21181@kroah.com> References: <20190118140525.29189-1-geert+renesas@glider.be> <20190118230740.44239fcf@bbrezillon> <20190130145054.GA990@kroah.com> <20190130160839.55f99e63@bbrezillon> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190130160839.55f99e63@bbrezillon> User-Agent: Mutt/1.11.2 (2019-01-07) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jan 30, 2019 at 04:08:39PM +0100, Boris Brezillon wrote: > Hi Greg, > > On Wed, 30 Jan 2019 15:50:54 +0100 > Greg Kroah-Hartman wrote: > > > On Tue, Jan 29, 2019 at 08:02:37PM +0100, Geert Uytterhoeven wrote: > > > Hi Boris, > > > > > > On Fri, Jan 18, 2019 at 11:07 PM Boris Brezillon wrote: > > > > Did you consider converting this driver to spimem? Looks like the > > > > protocol used to communicate with the memory resembles the one used on > > > > SPI NANDs/NORs and fits pretty well in the spi_mem_op representation. > > > > > > > > By doing this conversion you'd allow people to connect an AT25 EEPROM > > > > to an advanced SPI controller that does not support regular SPI > > > > transfers and you wouldn't have to forge SPI messages manually. > > > > > > > > Here is a patch (only compile tested) doing that. The diffstat is not in > > > > favor of this conversion, but I find the resulting code cleaner and more > > > > future proof. > > > > > > Thanks, seems to work fine, with the 512-byte 25LC040 I have! > > > > > > Tested-by: Geert Uytterhoeven > > > > > > I did notice that the first two-byte transfer (command+offset) of each > > > message is now split in two one-byte transfers, though. > > > > Ok, I'll drop this patch series and wait for the updated version to be > > sent out :) > > I'd like to further simplify the patch by using the recently introduced > devm_spi_mem_dirmap_create() function (queued to Mark's spi/for-5.1 > branch), which means I'll have to wait v5.1-rc1 before sending a new > version. I'll let you decide if it's worth applying Geert's patches in > the meantime. If you all want Geert's patches merged now, someone has to resend them please :) thanks, greg k-h