public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Eugen.Hristev at microchip.com <Eugen.Hristev@microchip.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] w1: fix build without CONFIG_W1_EEPROM
Date: Wed, 24 Oct 2018 10:08:24 +0000	[thread overview]
Message-ID: <33afe810-ae0d-dd05-2811-7fa1ee4fc845@microchip.com> (raw)
In-Reply-To: <20181024003128.6c25c8e7@jawa>



On 24.10.2018 01:31, Lukasz Majewski wrote:
> Hi Martin, Eugen,
> 
>> On 23/10/18 10:40, Eugen.Hristev at microchip.com wrote:
>>>
>>> I tried as much as possible to decouple the W1 bus from the W1
>>> EEPROM memories. It is possible that we will have a different
>>> framework for EEPROMs that will include both 1wire and i2c eeproms,
>>> and then the interfacing would be pretty easy to change to.
>>>
>>> That's why I am thinking that w1 bus read should not be much
>>> affected if the 1w EEPROMs are unknown to U-boot
>>>   
>> Yes sure that's great.
>>
>> Somewhat diverting this thread....
>>
>> I noticed that currently "w1 read" displays the data in hex with
>> "%x", which means it prints just one character if in range 00-0f.
>> And as there is no seperator the output isn't currently useful.
>>
>> That's a trivial fix of course but it got me thinking about what do
>> we want to "w1 read" to do?
>>
>> A lot of other storage reading commands use "read" to mean "read to
>> memory" and take a destination RAM address parameter.
>> Eg mmc read, sf read, ...
>>
>> There are counter examples though like "mii read" or "pmic read"
>> which just print the output but they don't read aribitary
>> user defined data like an eeprom.
>>
>> So I was wondering if it would be better to modify "w1 read" to mean
>> "read to memory" and add a new "w1 dump" command
>> to do what "w1 read" currently does (as it is much more convenient
>> for quickly checking the eeprom contents than
>> having to use md).
>>
>> The type of use case I'm thinking of for "read to memory" is if
>> someone wants to put a device tree blob on an eeprom.
>>
> 
> If I may add my 2cents.
> 
> I also would like to see the w1 command to load read data to memory (to
> be consistent with e.g. load), so we could use md.b, mw.b, etc.
> 
>> What do you think?

I believe it's a good thing to have them as you said. The w1 support 
which I made was "initial" and "minimal" . I am happy to see it extended.

Eugen

>>
>> Regards,
>>
>> Martin
>>
>>
>>
>>>> Regards,
>>>>
>>>> Martin
>>>>
>>>>   
>>
>> _______________________________________________
>> U-Boot mailing list
>> U-Boot at lists.denx.de
>> https://lists.denx.de/listinfo/u-boot
> 
> 
> 
> 
> Best regards,
> 
> Lukasz Majewski
> 
> --
> 
> DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
> HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
> Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
> 

      reply	other threads:[~2018-10-24 10:08 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-22 16:51 [U-Boot] [PATCH] w1: fix build without CONFIG_W1_EEPROM Martin Fuzzey
2018-10-23  7:07 ` Eugen.Hristev at microchip.com
2018-10-23  8:31   ` Martin Fuzzey
2018-10-23  8:40     ` Eugen.Hristev at microchip.com
2018-10-23 14:09       ` Martin Fuzzey
2018-10-23 22:31         ` Lukasz Majewski
2018-10-24 10:08           ` Eugen.Hristev at microchip.com [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=33afe810-ae0d-dd05-2811-7fa1ee4fc845@microchip.com \
    --to=eugen.hristev@microchip.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox