lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <9c1cd548-29a1-8f4a-d05c-ec4884f60b72@ti.com>
Date:   Wed, 25 Apr 2018 14:50:11 +0530
From:   Sekhar Nori <nsekhar@...com>
To:     Bartosz Golaszewski <brgl@...ev.pl>
CC:     Kevin Hilman <khilman@...nel.org>,
        Russell King <linux@...linux.org.uk>,
        Santosh Shilimkar <ssantosh@...nel.org>,
        Linux ARM <linux-arm-kernel@...ts.infradead.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Bartosz Golaszewski <bgolaszewski@...libre.com>
Subject: Re: [RESEND PATCH v2 3/4] ARM: davinci: add aemif & nand support to
 da850-lcdk in legacy mode

On Wednesday 25 April 2018 02:44 PM, Bartosz Golaszewski wrote:
> 2018-04-17 16:09 GMT+02:00 Sekhar Nori <nsekhar@...com>:
>> On Tuesday 17 April 2018 03:59 PM, Bartosz Golaszewski wrote:
>>> From: Bartosz Golaszewski <bgolaszewski@...libre.com>
>>>
>>> We now have support for aemif & nand from board files. As an example
>>> add support for nand to da850-lcdk in legacy mode.
>>
>> Hawkboard is a separate board of its own, although closely related to
>> LCDK. Lets refer to it as hawkboard itself, instead of "LCDK in legacy
>> mode". So:
>>
>> ARM: davinci: omapl138-hawk: ...
>>
>>>
>>> Signed-off-by: Bartosz Golaszewski <bgolaszewski@...libre.com>
>>> ---
>>>  arch/arm/mach-davinci/board-omapl138-hawk.c | 132 ++++++++++++++++++++
>>>  1 file changed, 132 insertions(+)
>>>
>>> diff --git a/arch/arm/mach-davinci/board-omapl138-hawk.c b/arch/arm/mach-davinci/board-omapl138-hawk.c
>>> index 6c997c59a3cd..9c3de56b54e4 100644
>>> --- a/arch/arm/mach-davinci/board-omapl138-hawk.c
>>> +++ b/arch/arm/mach-davinci/board-omapl138-hawk.c
>>> @@ -16,6 +16,11 @@
>>>  #include <linux/gpio.h>
>>>  #include <linux/gpio/machine.h>
>>>  #include <linux/platform_data/gpio-davinci.h>
>>> +#include <linux/platform_data/ti-aemif.h>
>>> +#include <linux/mtd/rawnand.h>
>>> +#include <linux/mtd/partitions.h>
>>> +#include <linux/platform_data/mtd-davinci.h>
>>> +#include <linux/platform_data/mtd-davinci-aemif.h>
>>>  #include <linux/regulator/machine.h>
>>>
>>>  #include <asm/mach-types.h>
>>> @@ -162,6 +167,129 @@ static __init void omapl138_hawk_mmc_init(void)
>>>       gpiod_remove_lookup_table(&mmc_gpios_table);
>>>  }
>>>
>>> +static struct mtd_partition omapl138_hawk_nandflash_partition[] = {
>>> +     {
>>> +             .name           = "u-boot env",
>>> +             .offset         = 0,
>>> +             .size           = SZ_128K,
>>> +             .mask_flags     = MTD_WRITEABLE,
>>> +      },
>>> +     {
>>> +             .name           = "u-boot",
>>> +             .offset         = MTDPART_OFS_APPEND,
>>> +             .size           = SZ_128K,
>>
>> Can you make it 512K as it is in da850-lcdk.dts ?
>>
>>> +             .mask_flags     = MTD_WRITEABLE,
>>> +     },
>>> +     {
>>> +             .name           = "free space",
>>> +             .offset         = MTDPART_OFS_APPEND,
>>> +             .size           = MTDPART_SIZ_FULL,
>>> +             .mask_flags     = 0,
>>> +     },
>>> +};
>>
>>> +static struct aemif_abus_data omapl138_hawk_aemif_abus_data[] = {
>>> +     {
>>> +             .cs     = 3,
>>> +     }
>>> +};
>>> +
>>> +static struct platform_device omapl138_hawk_aemif_devices[] = {
>>> +     {
>>> +             .name           = "davinci_nand",
>>> +             .id             = 1,
>>
>> Is there a reason for .id to be set to 1 here? Ideally it should be -1,
>> I think since there is a single NAND on the board.
>>
> 
> The davinci nand driver uses pdev->id as the chipselect number. I
> guess this should be in the platform data. I'll send a patch for that.

I remember that now. No need to change that, I think. Just a comment
here would suffice.

Thanks,
Sekhar

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ