RetroBSD
http://retrobsd.org/

Static ram for swap space?
http://retrobsd.org/viewtopic.php?f=3&t=487
Page 5 of 5

Author:  Pito [ Sat Sep 29, 2012 3:48 pm ]
Post subject:  Reply To: Static ram for swap space?

@madscifi: how you can access both swap and fs with a single adjust in swstrategy? How the system accesses the blocks below adj?

Author:  majenko [ Sat Sep 29, 2012 4:09 pm ]
Post subject:  Reply To: Static ram for swap space?

Right... So I have basic partitioning working. It only works with the "LBA" values in the partition table, but Linux "fdisk" creates those fine. What is the next task for this then?

SD card reading/writing isn't quite stable - it does tend to completely shit itself sometimes, and there is no checking for failures as yet, so that needs implementing. Also, I need to make character /dev/rrd* entries for fdisk to work properly. And then there is the swap device. I have nothing here to test with, so I'm going to want some collaboration with this bit I think.

What the first thing I should do, I think, is create a branch in SVN for this, so that you can both try it out and contribute to it. We need to port/write drivers for the various swap devices. The interface is somewhat simpler now than it was, due to the fact that the rdisk device handles the strategy side of things and just makes block read/write requests. I'm going to port my flash disk device to it as well at some point.

Author:  Pito [ Sat Sep 29, 2012 4:44 pm ]
Post subject:  Reply To: Static ram for swap space?

OK let us see the branch..
PS: you mean ramdisk devices ? Let us call the physical external sram/sdram/mram/fram device "ramdisk" as I am lost otherwise :)

So we need to integrate the sram(cpld) ramdisk via a simpler driver..

Author:  Pito [ Sat Sep 29, 2012 4:56 pm ]
Post subject:  Reply To: Static ram for swap space?

So the driver's names shall follow some standards - ie
sramc.c (sram cpld)
sramp.c (sram par io)
sdramp.c (sdram io)
mrams.c (mram spi)
mramp.c (mram io)
srams.c (sram spi)
frams.c (fram spi)
... or something like that..

Author:  majenko [ Sat Sep 29, 2012 4:58 pm ]
Post subject:  Reply To: Static ram for swap space?

I guess they can - there's no requirement for them to. SD is still sd.c at the moment.

I'm just going to start a new thread for this.

Author:  Pito [ Sat Sep 29, 2012 5:06 pm ]
Post subject:  Reply To: Static ram for swap space?

I mean "our" standards - sd.c stays sd.c of course, but we may have 4 ramdisks live next week - sram_cpld (pito), sdram (madscifi), mram (majenko), serial_sram (jaromir?)..
So we need the names for all the HW variants of the Ramdisks.

Author:  majenko [ Sat Sep 29, 2012 5:20 pm ]
Post subject:  Reply To: Static ram for swap space?

sd.c might change to rd_sd.c, and rd_flash.c might appear.

rd (in the context of the driver) isn't ramdisk, it's RetroDisk. ;) A global umbrella for all block storage devices that support partitioning.

Author:  madscifi [ Sun Sep 30, 2012 1:09 am ]
Post subject:  Reply To: Static ram for swap space?

Pito, adj is only set to a non-zero value in the case that the request is for minor device 1. So for requests on minor device 0 adj is 0, for minor device 1 adj is 2050.

Author:  Pito [ Sun Sep 30, 2012 2:06 am ]
Post subject:  Reply To: Static ram for swap space?

I see, it means you have modified the swap.c in order to select between minor 1 and minor 0 (as I do not see it in the original, therefore my Q).

Author:  Pito [ Sun Sep 30, 2012 5:50 am ]
Post subject:  Reply To: Static ram for swap space?

@madscifi - I would better call your driver

sdramp.c (external sdram ramdisk with parallel io interface)

instead of swapsdram (because it is not swap but ramdisk..)

Author:  madscifi [ Sun Sep 30, 2012 6:08 am ]
Post subject:  Reply To: Static ram for swap space?

Pito, change made.

However, it still depends on the SWAPSZ. I'll change this when the new partition code you and majenko are working is ready.

Author:  madscifi [ Thu Oct 11, 2012 10:17 am ]
Post subject:  Reply To: Static ram for swap space?

Current wiring diagram from the sdram:

http://andaquartergetsyoucoffee.com/images/sdram-partition-r639.png

Note that this is for use with the configuration in sys/pic32/ubw32-uart-sdram folder within the partition branch of the library - specifically with r639. Earlier versions used a slightly different layout. This does NOT match the layout required for the version in the sdram branch. I expect this to change at some point in the future if a version supporting 16 bit data transfers is made.

Author:  wiz [ Thu Oct 11, 2012 9:15 pm ]
Post subject:  Reply To: Static ram for swap space?

Hi Madscifi,

Thanks.

I just printed it.

Somehow I forgot about the whole issue of DDR supply voltages.

Is this chip still being manufactured? Are their other 3.3V chips of higher density that we should look at? Are there other approaches we should look at?

I am thinking that Spartan 6 plus DDR3 might be worth a look?

Wiz



Author:  madscifi [ Fri Oct 12, 2012 10:18 am ]
Post subject:  Reply To: Static ram for swap space?

Most 3.3v SDRAM chips should work, i think, although some parameter changes might be necessary depending on the configuration of the specific chip.

You can order a new AS4C8M16S128 for about $1.70 each and it should be a direct drop-in, although I don't have one to try at the moment. There are larger and smaller sizes of the AS4C4M16S family and any of them should be easily supported. The code needs some improvements to make changing sizes easier, but they changes needed are straightforward.

If your interest is to learn about or experiment with FPGAs then by all means it would be a nice project to build a fast interface through the FPGA to the SDRAM, but from a practical standpoint I don't think it is cost effective. My interest in working on the SDRAM interface was to get swap off of the sd card as inexpensively as possible.

Page 5 of 5 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/