From patchwork Thu Dec 28 21:29:51 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mathieu Malaterre X-Patchwork-Id: 853568 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=devicetree-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="BWcW9smK"; dkim-atps=neutral Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 3z72ty1J0Pz9sPt for ; Fri, 29 Dec 2017 08:30:18 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751220AbdL1VaQ (ORCPT ); Thu, 28 Dec 2017 16:30:16 -0500 Received: from mail-wr0-f196.google.com ([209.85.128.196]:46359 "EHLO mail-wr0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751199AbdL1VaP (ORCPT ); Thu, 28 Dec 2017 16:30:15 -0500 Received: by mail-wr0-f196.google.com with SMTP id g17so31012613wrd.13; Thu, 28 Dec 2017 13:30:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id; bh=PCeqksEvtJzi8IRN3Tr9ndQQSSlncjM5YKxT7M90uuE=; b=BWcW9smKYkEthMMzYmlmiHhcQPfk9eNwZhRjHoz392kBvmPYucreY2x2V7QGn9OBSn 0wHmLD8+brQaiOJCPB9bCpegXb4R4p3Rrr9d7Lz+IsDE4qG7VUd3RaS2rKAKc0PubJqz pDhD825X1pS78T+uRNsv5nUplQSExs7uF17qvdBCl1XUu8QFJnekMY576DxmLwttqpyR V3DEV4j+0VTGi0Xwj90jYjF/xcMvdkRbDEYvfFzoPahsWtCpb6Pvas52ldn0hUIAd9ei Fm2oBbuATAm0rjHKsHu7jCxpRWt5mGPz2loeKeETkmorUAed4kxB4UmbmalIRkKTIjqa 9e+A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id; bh=PCeqksEvtJzi8IRN3Tr9ndQQSSlncjM5YKxT7M90uuE=; b=E0ANwgQaxWceBpz0O5mhSvk6YeigVRUrM9c3HcHAzoam7blelk53nBjgYdflzGRzD7 EpiNE/ckDz+YN932HJ6gm/AnHu+0wUapQgGHOn/E4G9L6roumy6+GAVw0jExCq/Q8XvL h5/bVYLboBaAFzIaS4p3jiEDP66Uz/yiOXCkxjTMiX7oX6dkKTA6YhX2QrU2O3ZmQKfF DqnNmnVAWx08rdjUbPljlWuewVHmsStRHSjlyf09ktCyFKIc9IGwXsUCVwOPVIH/miMn yL5snMO8mT3+DVKl4i9a5AtLU1e5SyNhw2E6+9jgVv9QqIRwM8KhDH3hpcJ1qAwQJ6nY Nhfw== X-Gm-Message-State: AKGB3mI/tC+2sdjzR/O/aDBv2VLHKbZjgFY23Mc/zKE2EE9d+MOES7tA NjrU2Jm4Z2SVtCNsZBP7N+U= X-Google-Smtp-Source: ACJfBot1fMAm5/1eMom8S0hIgdB0nTS9st1QY3DdcbogpROVtXSDXWULMkT5sGechyXJW58tiCA6Hg== X-Received: by 10.223.133.162 with SMTP id 31mr28507612wrt.251.1514496613689; Thu, 28 Dec 2017 13:30:13 -0800 (PST) Received: from macbookpro.malat.net (bru31-1-78-225-226-121.fbx.proxad.net. [78.225.226.121]) by smtp.gmail.com with ESMTPSA id m68sm41002635wmi.28.2017.12.28.13.30.12 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 28 Dec 2017 13:30:13 -0800 (PST) Received: by macbookpro.malat.net (Postfix, from userid 1000) id CC3A510C32F6; Thu, 28 Dec 2017 22:30:11 +0100 (CET) From: Mathieu Malaterre To: Marcin Nowakowski Cc: Greg Kroah-Hartman , Zubair.Kakakhel@mips.com, Mathieu Malaterre , Srinivas Kandagatla , Rob Herring , Mark Rutland , Ralf Baechle , PrasannaKumar Muralidharan , linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-mips@linux-mips.org Subject: [PATCH v2 0/2] Add efuse driver for Ingenic JZ4780 SoC Date: Thu, 28 Dec 2017 22:29:51 +0100 Message-Id: <20171228212954.2922-1-malat@debian.org> X-Mailer: git-send-email 2.11.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org This patchset bring support for read-only access to the JZ4780 efuse as found on MIPS Creator CI20. To keep the driver as simple as possible, it was not possible to re-use most of the nvmem core functionalities. This driver is not compatible with the original efuse driver as found in the custom linux kernel from upstream (1), in particular it does not expose to the users neither: `/sys/devices/platform/*/chip_id` nor `/sys/devices/platform/*/user_id`. The goal of this driver is to provide access to the MAC address to the dm9000 driver. (1) https://github.com/ZubairLK/CI20_linux/commit/6efd4ffca7dcfaff0794ab60cd6922ce96c60419 Changes in v2: Properly handle offset and byte value from the main entry point. Also add a commit message in patch #2. Mathieu Malaterre (1): dts: Probe efuse for CI20 PrasannaKumar Muralidharan (1): nvmem: add driver for JZ4780 efuse .../ABI/testing/sysfs-driver-jz4780-efuse | 16 ++ .../bindings/nvmem/ingenic,jz4780-efuse.txt | 17 ++ MAINTAINERS | 5 + arch/mips/boot/dts/ingenic/jz4780.dtsi | 40 ++- arch/mips/configs/ci20_defconfig | 2 + drivers/nvmem/Kconfig | 10 + drivers/nvmem/Makefile | 2 + drivers/nvmem/jz4780-efuse.c | 305 +++++++++++++++++++++ 8 files changed, 385 insertions(+), 12 deletions(-) create mode 100644 Documentation/ABI/testing/sysfs-driver-jz4780-efuse create mode 100644 Documentation/devicetree/bindings/nvmem/ingenic,jz4780-efuse.txt create mode 100644 drivers/nvmem/jz4780-efuse.c