Author Topic: Dingoo, Linux, & RAM  (Read 2277 times)

Stephanie

  • Guest
Dingoo, Linux, & RAM
« on: May 20, 2010, 02:12:49 pm »
Playing around with making my own Dingux kernels, and there's one question that I can't figure out the answer to.

Why does Dingux need to have the ram either hard-coded into the kernel or stated on the kernel command line?

I've been working with Linux since 98 and I don't remember ever needing to do this before; it just figures out how much RAM it has automatically.

Is there some strangeness or quirk in the Dingoo hardware that prevents Linux from figuring out how much RAM is installed?

Thanks!

Nevinryal

  • Guest
Re: Dingoo, Linux, & RAM
« Reply #1 on: May 21, 2010, 05:13:56 am »
I don't know all that much about Linux although I love slax for a simple os. But that is a damn good question. And a weird fact at that.
Just why the hell would the OS need to be told how much ram there was?
Sounds a bit how IRQ's worked. You had the equipment connected to the system but you had to
inform the system of what it could and couldn't do and when. I've also wondered that the physical limitations of the OS's that run on the Dingoo are specifically tied in to the fact that although the Dingoo is a computer, and functions like one, the world it must function in,( in relation to a regular pc anyways ) must be similar to a sandbox of sorts. There are only so many things it can and will ever do, maybe in some way because of this it's simple design just didn't allow for common things like Auto Detection of Hardware maybe even on a very basic scale? But in a way since the engineers would have known EXACTLY what abilities the system would have they knew beforehand that they could just tell it a pre-designated value and simply KNOW it would work because hell they designed the thing in the first place. Anyways, this is just conjecture but I really would like to know why the hell it would need to know that. Oh and hey nice going with your old ZipIt, I got one around here somewhere that managed to have the wrong PSU plugged into it and I believe suffers from a burnt power input. I forgot what the part was called but it's the first little black thing where the power plug goes in and it seems like it can be bypassed I just haven't found a suitable way to replace the power for it. I loved that they used a 56K Modem with WIFI for the Zip It and would hope that the Dingoo could someday allow for it but eh..

darfgarf

  • Guest
Re: Dingoo, Linux, & RAM
« Reply #2 on: May 21, 2010, 08:09:30 am »
It's nothing like slax :p. I think It's due to the way the chip handles the RAM or something, I read something about it in the u-boot reader (just search for u-boot source and grab from sourceforge)

flatmush

  • Posts: 288
Re: Dingoo, Linux, & RAM
« Reply #3 on: May 21, 2010, 11:05:04 am »
PC ram is more complex, it contains a  small area of the ram chip to tell the computer about itself called the SPD. The SPD is read by the bios during startup (through i2c) and this tells your OS about what ram you have.

The Dingoo is an embedded device that uses very basic mobile ram, since all units are meant to be the same it's easier just to hardcode the ram size. It may be possible to detect between 32 and 64 MiB but I don't think anyone has looked into it fully.

Stephanie

  • Guest
Re: Dingoo, Linux, & RAM
« Reply #4 on: May 21, 2010, 12:52:10 pm »
Thanks for the replies! I completely forgot about the SPD... it's been so long since the last embedded linux device I worked on, I can't remember how the memory on that was set up, but you're right, when they're all identical you can make certain assumptions about the hardware.


flatmush

  • Posts: 288
Re: Dingoo, Linux, & RAM
« Reply #5 on: May 21, 2010, 01:26:26 pm »
It may be possible to auto-detect between 32 and 64 MiB though.

Write to address 0 (<base>)in the DRAM (at whatever offset the first address is).
Read from the address at 32MiB offset from the start of the ram (<base> + (32 << 20)).

If the address at 32MiB contains data repeated from address 0 then it means that there is only 32MiB of ram.

I'm not sure if this will work though, since the new Dingoo contains two chips the chip selects could be part of the decode meaning that a read from <base> + 32MiB could just read random noise.