Rockbox

Tasklist

FS#10838 - Sansa AMS: Assume clk_ide is used as MCLK for internal SD

Attached to Project: Rockbox
Opened by Jack Halpin (FlynDice) - Wednesday, 09 December 2009, 06:48 GMT
Last edited by Jack Halpin (FlynDice) - Friday, 11 December 2009, 04:54 GMT
Task Type Patches
Category Drivers
Status Closed
Assigned To No-one
Operating System Another
Severity Low
Priority Normal
Reported Version Release 3.4
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

This patch makes adjustments to account for MCLK for the internal pl180 controller being changed from assuming PCLK to assuming IDE_CLK. I noticed that by using the test_disk speed test I could vary the disk throughput of the internal SD by changing the value for IDE_CLK. Then while working on write delays to solve the data crc problems I found that I needed to lower the clock on the internal SD further to induce the problem. When I tried the assumption that MCLK was IDE_CLK instead of PCLK the results lead me to believe quite strongly that this is indeed the case.

This patch changes all references/assumptions of PCLK to IDE_CLK for the internal pl180 controller.
I have lowered the AS3525_IDE_FREQ to 50 MHz in order to be able to divide by 2 for 25 MHz on the internal SD card.
I adjusted the code in debug-as3525.c to account for the change and the frequencies reported should be correct.
I added some #if defined(HAVE_MULTIDRIVE) conditionals to cut out the code dealing with uSD for the clip.
I was also able to isolate the new write delay needed for low frequencies to only run for standard speed uSD cards. That will be the only case for an MCICLK at 15.5 MHz.

With this patch we should have the internal cards running at 25 MHz, HS uSD at 31 MHz, and standard speed uSD cards at 15.5 MHz.

And yes kugel, I did some speed tests..
This task depends upon

Closed by  Jack Halpin (FlynDice)
Friday, 11 December 2009, 04:54 GMT
Reason for closing:  Accepted
Additional comments about closing:  r23929
Comment by Jack Halpin (FlynDice) - Wednesday, 09 December 2009, 19:58 GMT
Here's a copy of the tests for both boosted and unboosted
Comment by MichaelGiacomelli (saratoga) - Friday, 11 December 2009, 02:00 GMT
Works fine on my Fuze.
Comment by Rafaël Carré (funman) - Friday, 11 December 2009, 03:36 GMT
Works fine on my Clip.

Loading...