Page 1 of 1

SMI Documentation ?

Posted: Sat Nov 22, 2014 3:34 pm
by BruceNaylor
Will the SMI (Secondary Memory Interface) documentation be released any time soon? For me it's become a major stumbling block on using the Compute Module for an industrial application.

Imminent? Within weeks? Within Months? Never?

Regards

Bruce.

Re: SMI Documentation ?

Posted: Sat Nov 22, 2014 4:59 pm
by jamesh
What do you need it for? I've not heard of anyone else using it (that's not to say you don't have a good reason). I beleive Gert knows a bit about it so will ping him.

Re: SMI Documentation ?

Posted: Sat Nov 22, 2014 10:20 pm
by Gert van Loo
Yes, I know about it.
But as I no longer work for Broadcom I do not have access to the documentation anymore.
You will need that for the details but to be honest: the last time I used the interface
the documentation of the SMI is not that great. Good for some coarse idea but lacking
details which to me were important.

Re: SMI Documentation ?

Posted: Sun Nov 23, 2014 12:22 pm
by BruceNaylor
The plan was to have a simple way to suck/spit multi-MB chunks of 16bit wide data with the least CPU overhead. Treat the SMI as DMA'able memory mapped I/O interfacing to an existing hardware solution based on an FPGA. See http://www.troika-systems.com for pics of the current system.

Re: SMI Documentation ?

Posted: Tue Nov 25, 2014 11:40 pm
by Neil
The Host Interface might also do what you want. It can be configured to do DMA transfers on a single 16-bit-wide channel, and the hardware supports the scheduling of transfer blocks for you. But I'm in the same boat as Gert and James so I'm just going by my fading grey cells.....

Neil

Re: SMI Documentation ?

Posted: Wed Nov 26, 2014 5:25 pm
by Gert van Loo
Neil wrote:The Host Interface might also do what you want. It can be configured to do DMA transfers on a single 16-bit-wide channel, and the hardware supports the scheduling of transfer blocks for you. But I'm in the same boat as Gert and James so I'm just going by my fading grey cells.....

Neil
There is the tiny little 'issue' that the host port is not brought out on ANY of the versions.
Not even the computer module....

Re: SMI Documentation ?

Posted: Wed Nov 26, 2014 8:22 pm
by BruceNaylor
Thanks for the input.

Is there really no way to get access to this documentation - officially or otherwise? No snipets of source, no other BC product that uses the same IP? SMI could open the way to an absolute ton of CM derived products.

Re: SMI Documentation ?

Posted: Tue Dec 02, 2014 1:57 pm
by TonyD
To repeat what Bruce said, are they really no plans to release any information on the SMI?

I would like to add a fast ADC (>20Msps) for SDR experimentation or even a el-cheapo scope and was hoping the SMI would be the interface to do that.

Re: SMI Documentation ?

Posted: Thu Jan 22, 2015 4:37 am
by cleverca22
would somebody still with broadcom be able to put together a sample app like the other hello_pi stuff, to get the community started?

Re: SMI Documentation ?

Posted: Mon Jul 11, 2016 4:29 pm
by LukeW
Thought I'd reply to this old thread as it is the first result on google, so other people may come here too, looking for info.

There is now an SMI driver -- see these commits:
https://github.com/raspberrypi/linux/co ... e30329c1d0
https://github.com/raspberrypi/linux/co ... c5917c580a

You can enable the SMI driver by putting

Code: Select all

dtoverlay=smi
into /boot/config.txt. Following this with

Code: Select all

dtoverlay=smi-dev
will enable a chardev interface (/dev/smi) which allows you to shove large amounts of data in and out of the SMI. There is also an experimental NAND flash driver:

Code: Select all

dtoverlay=smi-nand
which allows you to connect a NAND flash chip to the SMI pins and mount it.

There is no public documentation of the SMI peripheral, but if you check out the latter part of this header file (https://github.com/raspberrypi/linux/bl ... 2835_smi.h) you should find a decent summary of the registers and their contents.

Hope this helps.

Re: SMI Documentation ?

Posted: Mon Apr 23, 2018 9:09 pm
by greg2684
Sorry to resurrect this old thread, but LukeW (or anyone else), do you have any info on connecting a NAND flash chip to the SMI pins for use with the smi-nand driver (e.g. pinout mapping, etc.)? Scouring the Internet has not turned up anything.

Re: SMI Documentation ?

Posted: Tue Apr 24, 2018 4:39 am
by rpdom
Some details are given the the BCM2835-ARM-Peripherals file (here). I think it was on page 102 or near there that most of the GPIO alternative pin mappings are listed. ALT1 on most pins is for SMI. The https://pinout.xyz site also shows them, but you have to check each pin to find its SMI function.

Re: SMI Documentation ?

Posted: Tue Apr 24, 2018 5:35 am
by Gavinmc42
You need to dig out oldish ap notes, a quick google found some.

http://www.ti.com/lit/an/spra825/spra825.pdf
https://www.microsemi.com/document-port ... e-app-note

This one is cool- eMMC hacking
https://www.blackhat.com/docs/us-17/wed ... der-wp.pdf

Just wish there was a nice non BGA eMMC chip ;)
Plugin eMMC?

UHS on Pi4?
https://news.samsung.com/global/emmc-to ... s-evolving

SMI is very similar to IDE/Comp0act flash.
So could a embedded flash controller be used, it would do ECC?
http://www.siliconmotion.com/A3.2_Appli ... .php?sn=35
https://www.hyperstone.com/en/F9-Hypers ... -1217.html

Re: SMI Documentation ?

Posted: Tue Apr 24, 2018 8:58 am
by jamesh
There is a Pi SMI driver in the linux source tree, that can give a lot of hints to how it all works.

Re: SMI Documentation ?

Posted: Tue Apr 24, 2018 9:20 am
by Heater
Yukimasa Sugizaki has what looks like a useful SMI diagnostic utility here, raspi-smi-util: https://github.com/Terminus-IMRC/raspi-smi-util

No documentation or comments in there but from the usage messages it can:

Get settings from SMI and print to stdout
Set settings to SMI, reading from stdin
Set addr of SMI
Write size bytes to SMI
Read size bytes from SMI

Not a bad start if it works. The code is pretty small so should be easy to follow what is going on there.

But where is the SMI pinout documentation so that I can hook up an FPGA and get something cooking with this?

Re: SMI Documentation ?

Posted: Tue Apr 24, 2018 10:00 am
by Heater
LukeW,

So if I have "dtoverlay=smi" and "dtoverlay=smi-dev" in config.txt I then get a /dev/smi device.

Then what?

What pins is that device using? How are they used?

I'm getting the itch to talk to an FPGA via SMI.

Re: SMI Documentation ?

Posted: Tue Apr 24, 2018 10:05 am
by Heater
Ouch!

"dtoverlay"= smi uses GPIOs 2-25!

OK, with that and the GPIO pinout docs I think we are set to start poking at it!

Re: SMI Documentation ?

Posted: Tue Apr 24, 2018 10:29 am
by Gavinmc42
Something new for me.
http://www.onfi.org/

More datasheets.
http://www.cypress.com/products/1gb-8gb ... ash-memory

Perhaps start with the 8bit wide ones.
Easy to get a few, just pull apart old USB sticks ;)

NAND flash hat?