Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp1019517imm; Wed, 8 Aug 2018 09:23:29 -0700 (PDT) X-Google-Smtp-Source: AA+uWPzeXtZNPcCPzqpz2QPXfV9SbLvuq8U4pOTZjEOA/yI6CjCaY08zmtLlXEp2H8dKRvjCvFXe X-Received: by 2002:a17:902:5481:: with SMTP id e1-v6mr3248389pli.309.1533745409316; Wed, 08 Aug 2018 09:23:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533745409; cv=none; d=google.com; s=arc-20160816; b=PeDKQJnreuBXI2AS73ueTKgt8lkg5ZZQqRvMyNvB4VyPVdZqzG0UV8BjEmrTNd+1ZS +fUdKEd6gDc/7fxR4qnmNCVWx0EFj8EEYBQ/cFEy2+A3qv1KAzjE5nk14K5RNhQspJK7 GsnMgbGciVXzCEUBKAHeIDGW/KkVe3KpAuRnTGJB8PBAe08xMEpIkfKwx36khIyo0etO A+4iDWwFw1uBIL+J4IlJNF4Itc4qrMs7MK5rbOTKfGapD3iHYK6nf918F8mJuLmnNGQb ExhsX9LKTtj0BEM08S8f8lyjOeW6738klWPKtEEfDdo8DTbH/YZFYhOG1Fq9jZN3dtP3 fXXw== 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:arc-authentication-results; bh=X5ENKrDqkl5j2afjWRMo7S68YhZdIMlBKp/TBvcxr5I=; b=EcJhirVFbQmW6F/0HJSFW88/eS+imcGqYMG/KzDk66vGBcQ9DOY/bBjJF7X+Ebs8sG 11sDh30xGnzeJt8sU7Lkts6sbuK/ocA0xnwLsxE88yZ4cHi5hMz7hKvIERc0xaHMl5jC C23EPkVvzm+oyi08IJrrmuB8NtmPSIQWkpuRb8UGMmig8t2EWbKp3X2dJeblHw916GqN ZtvBoqC8cG+fHbLaTFp+iiB8Z7JzvUlq7ZnkM+P0tke467gqYv1tit8DLmooIbUmTOeM pFlZO311iD8XohJRgG9eY/VzzKF3oMowRGuqzueq3+9/Hwr3wUms9i6u2tFAyXLeElbK dirQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b=3wHt662g; 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 u186-v6si4712300pfu.263.2018.08.08.09.23.14; Wed, 08 Aug 2018 09:23:29 -0700 (PDT) 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=@lunn.ch header.s=20171124 header.b=3wHt662g; 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 S1728400AbeHHSmZ (ORCPT + 99 others); Wed, 8 Aug 2018 14:42:25 -0400 Received: from vps0.lunn.ch ([185.16.172.187]:58683 "EHLO vps0.lunn.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727062AbeHHSmZ (ORCPT ); Wed, 8 Aug 2018 14:42:25 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date; bh=X5ENKrDqkl5j2afjWRMo7S68YhZdIMlBKp/TBvcxr5I=; b=3wHt662gGBLuWMA3O+1QdIjMsDCuniALuVYPHOXplXjmK8dXqH18E9ATzG5310vJM7dwdlD5pZxgzEk7caFR4Plp+mM5kARarFV+3HOOPOFTd2ZFKnkBNBI0h/Nej/i8kLvYMlycaTw7/uN03CBQVwFFK+vbMT42pvufsvBGynk=; Received: from andrew by vps0.lunn.ch with local (Exim 4.84_2) (envelope-from ) id 1fnRCU-0007Dd-74; Wed, 08 Aug 2018 18:20:42 +0200 Date: Wed, 8 Aug 2018 18:20:42 +0200 From: Andrew Lunn To: Bartosz Golaszewski Cc: Jonathan Corbet , Sekhar Nori , Kevin Hilman , Russell King , Arnd Bergmann , Greg Kroah-Hartman , David Woodhouse , Brian Norris , Boris Brezillon , Marek Vasut , Richard Weinberger , Grygorii Strashko , "David S . Miller" , Srinivas Kandagatla , Naren , Mauro Carvalho Chehab , Andrew Morton , Lukas Wunner , Dan Carpenter , Florian Fainelli , Ivan Khoronzhuk , Sven Van Asbroeck , Paolo Abeni , Alban Bedel , Rob Herring , David Lechner , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-i2c@vger.kernel.org, linux-mtd@lists.infradead.org, linux-omap@vger.kernel.org, netdev@vger.kernel.org, Bartosz Golaszewski Subject: Re: [PATCH 06/28] mtd: Add support for reading MTD devices via the nvmem API Message-ID: <20180808162042.GG7275@lunn.ch> References: <20180808153150.23444-1-brgl@bgdev.pl> <20180808153150.23444-7-brgl@bgdev.pl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180808153150.23444-7-brgl@bgdev.pl> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Aug 08, 2018 at 05:31:28PM +0200, Bartosz Golaszewski wrote: > From: Alban Bedel > > Allow drivers that use the nvmem API to read data stored on MTD devices. > For this the mtd devices are registered as read-only NVMEM providers. > On OF systems only devices that have the 'nvmem-provider' property > are registered, on non-OF system all MTD devices are registered. > @@ -570,6 +613,11 @@ int add_mtd_device(struct mtd_info *mtd) > if (error) > goto fail_added; > > + /* Add the nvmem provider */ > + error = mtd_nvmem_add(mtd); > + if (error) > + goto fail_nvmem_add; > + Hi Bartosz Maybe it is hiding somewhere, but i don't see any code looking into device tree looking for the 'nvmem-provider' property. Andrew