Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp1114905imm; Wed, 8 Aug 2018 11:00:30 -0700 (PDT) X-Google-Smtp-Source: AA+uWPydmoFyNnOhEuAyf0x3HppnOr7BDYhZbyfm/o2+GCl9I6pMGG4KAeradMpBVH2qs5EhwUju X-Received: by 2002:a63:3c4a:: with SMTP id i10-v6mr3466444pgn.415.1533751229978; Wed, 08 Aug 2018 11:00:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533751229; cv=none; d=google.com; s=arc-20160816; b=dogNqXrzAzARGxBwekGLQ1GYno66OsMx99lPZnIWHKi1KLg5l/6ZAMnCWYBQZJBMmH dpeaItdOIlRpidqJf1AoSDTMvd8eM9/PxSEgOwk6JGKD+91nx0xQ+l6qZNZezTL7HMaJ LolQL5KfuO+zWm9ggQ6v8RscGj6w+WAgw3w/xbyn2kLAqOONV6og0/u05epoCeYocFfC gouT9OpKjQZVo0/qjwH9IAVzFzcHXKgnsSJB61O3pyWX3MLWQJ3zRed4KqQS61hY+3y8 kCs0niBHz8r3YVPXECaHEEPOSKSkyERt8wNkZsDuYT/R/OTo1Wfo5ATCzvEuJ48+j/M5 FLQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=F5Jn5ThbdGMN/ntBl9eM8Z1tLeSTGI/KD270MYviaFk=; b=KyynRgL7aMqxaz1FnTABzLGYKKC8SO9hMcvTmHM8MnmSX09WkfCgNF2fbUJzeB7r5/ oiUqymKWZVo2YLU34StnFXO6vA1MFv5sAfwaYfoq6fNJjmQChV1FO9OzpjASGtnoov2g F3voIiL51KahwtCOaHr9dRhe5H5dKnavFBUTM7ymac3ZB6ZZ8qEhzbDdVBBHf4u0A/Of +osVhEcwGfA44poB4mc9pRjn8Dd9xVnNk74C0iS7HdBy5k8S0FtHu2XpSFy77src2bdC 0tW+ItsbhduvcYHCO2Zl3LPBgWEo+3wsacv4Z7CTn0z0R+vNqOqY6LnWDae5WnFDNKFj JEng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=aE9VzCTT; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t1-v6si5431186pfb.208.2018.08.08.11.00.15; Wed, 08 Aug 2018 11:00: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=@gmail.com header.s=20161025 header.b=aE9VzCTT; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729989AbeHHUUO (ORCPT + 99 others); Wed, 8 Aug 2018 16:20:14 -0400 Received: from mail-ua0-f196.google.com ([209.85.217.196]:45874 "EHLO mail-ua0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727748AbeHHUUN (ORCPT ); Wed, 8 Aug 2018 16:20:13 -0400 Received: by mail-ua0-f196.google.com with SMTP id k8-v6so3313342uaq.12; Wed, 08 Aug 2018 10:59:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=F5Jn5ThbdGMN/ntBl9eM8Z1tLeSTGI/KD270MYviaFk=; b=aE9VzCTT9EiZSsDzfT4P0A9eEEYgeV8t7gv/ETwz82iMTz3Ud9uljeXOtZW2Pv7FJw Qw3toECwSIi9e7O963W2RxgyZlG/12fbhKI1msqBzV14msLWYRttGw8588CjzVLyXvqN zSiWtvWLxXh9qDo2+m5mY6xe52tflui1KcblIiFP5w6zQ90k0ay7FTRnKIYzobYUMgS3 wsBM7RRzIr2Dga8vP7cGYz1p/tvyI0em/fbVtbgpbFDHcqjraP9UniO26Vd7uPRKi869 lKaXC4Hk4E1SVxFqskLnfUKaCrx7ANUVC2aJonfq9w40uZN4UoDQWeyGg7oSeM5yObXp O64w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=F5Jn5ThbdGMN/ntBl9eM8Z1tLeSTGI/KD270MYviaFk=; b=lJLjkxAXG2enlKOk5WFgcKyfuf822cu/akjudLip7mKWWlPvNVM/wPbs+2oyFGJgnL q6rmdxzJo3tsF/vJESXxtM6aK4q08PA9LegxjbeLYqe4BKGXNdlj1s54Ei/O+ub21ujY ok502nc091oM/oO8b+Gfvp58wmj1yE4lDKC6sqpqZbi6DttK8knxuUTybWzBXjs2SimG Ittvp98T/ETKav3dQ8xY/frPC3Kh4JPMFreyJQ0rpx++a5eGcv2dJo0KezmlBccWpihh 3INJxRIg9516/3UDAXQwsRFW2X81sNi8EwZaCNmsBeCssKDzo6QmW5wqPm80Q31nwzq6 SjTg== X-Gm-Message-State: AOUpUlELobFDClRFtEpalqbaUedWH2VY/Jenc7jULiaUnj5NGFCB0JCG U4lhZflxmwiqt/QXwlOOjPnFLv9H+ovtA1OQlkg= X-Received: by 2002:ab0:13c7:: with SMTP id n7-v6mr2710329uae.47.1533751165264; Wed, 08 Aug 2018 10:59:25 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a67:2149:0:0:0:0:0 with HTTP; Wed, 8 Aug 2018 10:59:24 -0700 (PDT) In-Reply-To: References: <20180808153150.23444-1-brgl@bgdev.pl> <20180808153150.23444-22-brgl@bgdev.pl> From: Andy Shevchenko Date: Wed, 8 Aug 2018 20:59:24 +0300 Message-ID: Subject: Re: [PATCH 21/28] ARM: davinci: dm644x-evm: use device properties for at24 eeprom 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 , Andrew Lunn , Linux Documentation List , Linux Kernel Mailing List , linux-arm Mailing List , linux-i2c , "open list:MEMORY TECHNOLOGY..." , Linux OMAP Mailing List , netdev , Bartosz Golaszewski Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Aug 8, 2018 at 8:55 PM, Andy Shevchenko wrote: > On Wed, Aug 8, 2018 at 6:31 PM, Bartosz Golaszewski wrote: >> From: Bartosz Golaszewski >> >> We want to work towards phasing out the at24_platform_data structure. >> There are few users and its contents can be represented using generic >> device properties. Using device properties only will allow us to >> significantly simplify the at24 configuration code. >> >> Remove the at24_platform_data structure and replace it with an array >> of property entries. Drop the byte_len/size property, as the model name >> already implies the EEPROM's size. >> > > Reviewed-by: Andy Shevchenko > >> Signed-off-by: Bartosz Golaszewski >> --- >> arch/arm/mach-davinci/board-dm644x-evm.c | 12 ++++-------- >> 1 file changed, 4 insertions(+), 8 deletions(-) >> >> diff --git a/arch/arm/mach-davinci/board-dm644x-evm.c b/arch/arm/mach-davinci/board-dm644x-evm.c >> index 6d35c6e1b0bd..abfcf42da6fb 100644 >> --- a/arch/arm/mach-davinci/board-dm644x-evm.c >> +++ b/arch/arm/mach-davinci/board-dm644x-evm.c >> @@ -16,8 +16,8 @@ >> #include >> #include >> #include >> -#include >> #include >> +#include >> #include >> #include >> #include >> @@ -486,12 +486,8 @@ static struct nvmem_cell_lookup dm6446evm_mac_address_cell = { >> .nvmem_name = "1-00500", >> }; >> >> -static struct at24_platform_data eeprom_info = { >> - .byte_len = (256*1024) / 8, >> - .page_size = 64, >> - .flags = AT24_FLAG_ADDR16, >> - .setup = davinci_get_mac_addr, >> - .context = (void *)0x7f00, >> +static const struct property_entry eeprom_properties[] = { >> + PROPERTY_ENTRY_U32("pagesize", 64), Missed terminator, though >> }; >> >> /* >> @@ -601,7 +597,7 @@ static struct i2c_board_info __initdata i2c_info[] = { >> }, >> { >> I2C_BOARD_INFO("24c256", 0x50), >> - .platform_data = &eeprom_info, >> + .properties = eeprom_properties, >> }, >> { >> I2C_BOARD_INFO("tlv320aic33", 0x1b), >> -- >> 2.18.0 >> >> -- >> To unsubscribe from this list: send the line "unsubscribe linux-omap" in >> the body of a message to majordomo@vger.kernel.org >> More majordomo info at http://vger.kernel.org/majordomo-info.html > > > > -- > With Best Regards, > Andy Shevchenko -- With Best Regards, Andy Shevchenko