Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp2962996imm; Fri, 10 Aug 2018 01:07:12 -0700 (PDT) X-Google-Smtp-Source: AA+uWPzR5eqWG9SuwR3B8k+3Mhm+FfOdDP6chaUh2vMQ7xkN80hq+dDpOgf7YNJ3uBXpsRUU0iGZ X-Received: by 2002:a62:25c5:: with SMTP id l188-v6mr5912490pfl.179.1533888432219; Fri, 10 Aug 2018 01:07:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533888432; cv=none; d=google.com; s=arc-20160816; b=bNH7Jss3TmRdiArEvbUGDgS+F0/xNrF6Slk/SAbmKaMQyPfluatVQKa2UrH4dnu1Gj vgEE0x+Qf9E2u1uREiyBhd2vuUpHrxd+9nB7WfcHQXy0mw3arwngiQw5/22Y2oda0Bju M8OO/p0atvvkimYQbt+ECJCvwBqQK9yVHWwpOWAL6AdZYDmaCCs5yCi3BwfLSDYQBCpo QJH6QsdhDm6ZZDNPGHUfN73O4d1XkxjCi0lK8UV990fmKSHRQ4J+no43RNPShkKZARdp EVhoZPnmI7iedIXqbkA9yPCxjvlT9SoxeZY/Vc3Yj0LfnoVNRiyHKYsif2PZ4nFa6FzD Aeeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=XaPQ4DQ6E4mkvE8/vjM2arlDkF10+DPHDgPAjo5lV1o=; b=BOg2HHWlEIWHiXqSUL3zAxNgJxNxK9MrdX58eJh+Ny6uwA/vgRzmNOY4HrQtmuKY8x Ind1HGilv7pSca3/MmxF30bQ3F/GelLlnP9O/IQRrGrJyK7c9ZeOIZ/gOP8ReV1KBSRc OoCRYlxuOq8qSPq8TEOCYmZjtoLkBBV4rkNcRSC+NLgNna8+8Ss1/xCQmwbsyDBlZsOr ECXKKCS7NL+aYh9hU2fG9g93j57OzL6aMuTfuMmmWptbTwua53SoirSK66WQcH8omE30 iSpWfyjdUmu8C+yVlw0ilkKiZJLrfclhxJFowejXXQxvoXDnqIm0Y2jfp4RnH7O44j72 QbaA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bgdev-pl.20150623.gappssmtp.com header.s=20150623 header.b=d8jmMSS0; 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 u26-v6si7727699pge.590.2018.08.10.01.06.57; Fri, 10 Aug 2018 01:07:12 -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=@bgdev-pl.20150623.gappssmtp.com header.s=20150623 header.b=d8jmMSS0; 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 S1728102AbeHJKee (ORCPT + 99 others); Fri, 10 Aug 2018 06:34:34 -0400 Received: from mail-wr1-f65.google.com ([209.85.221.65]:37998 "EHLO mail-wr1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728049AbeHJKee (ORCPT ); Fri, 10 Aug 2018 06:34:34 -0400 Received: by mail-wr1-f65.google.com with SMTP id v14-v6so7466457wro.5 for ; Fri, 10 Aug 2018 01:05:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=XaPQ4DQ6E4mkvE8/vjM2arlDkF10+DPHDgPAjo5lV1o=; b=d8jmMSS0r7+bNNo9YTWkd0N3UUg9gNZCUwkFuspa7Gad0bgKdmW/SeArVPVrICkkua FQqpNjEcVPxQySfOunIGiXl6cz7TL6ZiMji570BUqzEEsKx5rA4G0H6bN4HQgEDubpfj 3zWoapKg2/vI+/i/ahfY/KQmexgSBloSnXPmIHK5zcelobeGazNfZqbb+frzVRqE5pbS 8vB8HQt41QuBYNax/SCdrX0x2nl6TKXU80Z+3iyHk18vtYyVDbuI2bOlNAvNBQypGXbt Om6P0IJxqvIHvT2a+7TsLHhZxOkdHD3smm7hy7Ft9aJtqmHUvQj7C43je8QxC9mH4p+r 9qlg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=XaPQ4DQ6E4mkvE8/vjM2arlDkF10+DPHDgPAjo5lV1o=; b=FQ7sjOLWvjzkIb4XtIsf9ieGKKyfzPttleFWBW79RWFhNQ8z2xnwz4nSnpwrO4NNxS eT9tWrf6i3cgE+Do3DGz8FS9L4nG8/nBk4Q/2sCcec5CyTbzjqYYjuyiPaYhhKXZZStl Z9H0p3zUhtCgiWXyfdxFvDhmGQkvfPp95KkQrsCyrpDNPoNHLWtGrFT5qnEyK59qz01g wXX3k9GNYzW8YtEkxszludqffa2OloadPoSmebb1/o4FE+q28wyKTpQWjKN4fl73dmwW q4U5BXvAHqaRbtFRU4APKMhHoxH1w2MR6uZYBGVlLxqvw45+rNJALwv2+Fbo+pH55XWU TmYQ== X-Gm-Message-State: AOUpUlEqN5OwGWSm00xk6JidVRvzZbvUFwd9epluE4/IiQb4fkrLYKsM hJpBddsbn0lGOB1ioGhMvfmhoA== X-Received: by 2002:adf:ecc6:: with SMTP id s6-v6mr3665670wro.160.1533888348097; Fri, 10 Aug 2018 01:05:48 -0700 (PDT) Received: from brgl-bgdev.lan (LFbn-MAR-1-609-89.w90-118.abo.wanadoo.fr. [90.118.185.89]) by smtp.gmail.com with ESMTPSA id h7-v6sm9546405wrs.8.2018.08.10.01.05.45 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 10 Aug 2018 01:05:47 -0700 (PDT) From: Bartosz Golaszewski To: 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 , Andrew Lunn Cc: 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: [PATCH v2 08/29] ARM: davinci: dm644-evm: use nvmem lookup for mac address Date: Fri, 10 Aug 2018 10:05:05 +0200 Message-Id: <20180810080526.27207-9-brgl@bgdev.pl> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180810080526.27207-1-brgl@bgdev.pl> References: <20180810080526.27207-1-brgl@bgdev.pl> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Bartosz Golaszewski We now support nvmem lookups for machine code. Add a lookup for mac-address. Signed-off-by: Bartosz Golaszewski --- arch/arm/mach-davinci/board-dm644x-evm.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/arch/arm/mach-davinci/board-dm644x-evm.c b/arch/arm/mach-davinci/board-dm644x-evm.c index 48436f74fd71..829fa1c8d0b4 100644 --- a/arch/arm/mach-davinci/board-dm644x-evm.c +++ b/arch/arm/mach-davinci/board-dm644x-evm.c @@ -22,6 +22,7 @@ #include #include #include +#include #include #include #include @@ -476,6 +477,15 @@ static struct pcf857x_platform_data pcf_data_u35 = { * - ... newer boards may have more */ +static struct nvmem_cell_lookup dm6446evm_mac_address_cell = { + .info = { + .name = "mac-address", + .offset = 0x7f00, + .bytes = ETH_ALEN, + }, + .nvmem_name = "1-00500", +}; + static struct at24_platform_data eeprom_info = { .byte_len = (256*1024) / 8, .page_size = 64, @@ -828,6 +838,8 @@ static __init void davinci_evm_init(void) phy_register_fixup_for_uid(LXT971_PHY_ID, LXT971_PHY_MASK, davinci_phy_fixup); } + + nvmem_add_lookup_table(&dm6446evm_mac_address_cell, 1); } MACHINE_START(DAVINCI_EVM, "DaVinci DM644x EVM") -- 2.18.0