More SATA boot questions

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

More SATA boot questions

938 Views
JeffMichalski
Contributor I

I reviewed the discussion at:

http://imxcommunity.org/group/imx53quickstartboard/forum/topics/how-to-prepare-sata-disk-for?comment...

Then set out to try this but I can not seem to get the QSB the default Ubuntu Image from a SATA hard disk drive.

I am sure I missing some obvious step like how does uBoot get onto the hard drive.  The uImage file I am working with is uImage-744-g27fdf7b taken directly from the /boot directory from the QSB.

I documented the procedure that I have followed in some detail below:
Any help from someone who has this working would be much appreciated.

 Steps taken so far:

0. Verified 2.1 version silicon

1. Copy the uImage-744-g27fdf7b to my PC TFTP server home directory

2. Rename the file to uImage

3. Soldered on a dip switch onto SW1

4. Changed R46 from a pull-up to a pull-down (the board no longer booted uBoot once I changed R46 to pull-down I so I added an external switch to set R46 as either pull-up or pull-down as needed)

5. Reset R46 to pull-up.
Set all SW1 dip switches off
(Should be QSB default configuration)

6. Executed uBoot commands from section 6.2 and repeated in 8.3 i.MX53 Start Linux User's Guide)

setenv serverip 192.168.180.89
setenv bootfile uImage
saveenv
dhcp
sata info
sata write ${loadaddr} 0x800 0x2000
setenv bootargs_sata 'setenv bootargs ${bootargs} console=tty1 root=/dev/sda1 rootwait rw video=mxcdi1fb:BGR24,XGA di1_primary tve'
setenv bootcmd_sata 'run bootargs_base bootargs_sata; sata read ${loadaddr} 0x800 0x2000; bootm'
setenv bootcmd 'run bootcmd_sata'
saveenv
reset

uboot session output
-------------------

U-Boot 2009.08 (Mar 23 2011 - 12:37:03)

CPU: Freescale i.MX53 family 2.1V at 1000 MHz
mx53 pll1: 1000MHz
mx53 pll2: 400MHz
mx53 pll3: 216MHz
mx53 pll4: 455MHz
ipg clock : 66666666Hz
ipg per clock : 33333333Hz
uart clock : 21600000Hz
cspi clock : 54000000Hz
ahb clock : 133333333Hz
axi_a clock : 400000000Hz
axi_b clock : 200000000Hz
emi_slow clock: 133333333Hz
ddr clock : 400000000Hz
esdhc1 clock : 80000000Hz
esdhc2 clock : 80000000Hz
esdhc3 clock : 80000000Hz
esdhc4 clock : 80000000Hz
nfc clock : 26666666Hz
Board: MX53-LOCO 1.0
Boot Reason: [POR]
Boot Device: SD
I2C: ready
DRAM: 1 GB
MMC: FSL_ESDHC: 0, FSL_ESDHC: 1
In: serial
Out: serial
Err: serial
Net: got MAC address from IIM: 00:04:9f:01:e1:9f
FEC0 [PRIME]
Hit any key to stop autoboot: 0
MX53-LOCO U-Boot > setenv serverip 192.168.180.89
MX53-LOCO U-Boot > setenv bootfile uImage
MX53-LOCO U-Boot > saveenv
Saving Environment to MMC...
Writing to MMC(0)... done
MX53-LOCO U-Boot > dhcp
FEC: enable RMII gasket
PHY indentify @ 0x0 = 0x0007c0f1
BOOTP broadcast 1
FEC: Link is down 7809
BOOTP broadcast 2
DHCP client bound to address 192.168.180.125
Using FEC0 device
TFTP from server 192.168.180.89; our IP address is 192.168.180.125
Filename 'uImage'.
Load address: 0x70800000
Loading: #################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
############################################################
done
Bytes transferred = 2967484 (2d47bc hex)
MX53-LOCO U-Boot > sata info
AHCI 0001.0100 32 slots 1 ports 3 Gbps 0x1 impl SATA mode
flags: ncq stag pm led clo only pmp pio slum part
SATA Device Info:
S/N:
Product model number:
Firmware version:
Capacity: 625142448 sectors

SATA device 0: Model: Firm: Ser#:
Type: Hard Disk
Supports 48-bit addressing
Capacity: 305245.3 MB = 298.0 GB (625142448 x 512)
MX53-LOCO U-Boot > sata write ${loadaddr} 0x800 0x2000

SATA write: device 0 block # 2048, count 8192 ... 8192 blocks written: OK
MX53-LOCO U-Boot > setenv bootargs_sata 'setenv bootargs ${bootargs} console=tty1 root=/dev/sda1 rootwait rw video=mxcdi1fb:BGR24,XGA di1_primary tve'
MX53-LOCO U-Boot > setenv bootcmd_sata 'run bootargs_base bootargs_sata; sata read ${loadaddr} 0x800 0x2000; bootm'
MX53-LOCO U-Boot > setenv bootcmd 'run bootcmd_sata'
MX53-LOCO U-Boot > saveenv
Saving Environment to MMC...
Writing to MMC(0)... done
MX53-LOCO U-Boot >

--------------

7. According to HW reference manual (pp 46,60)

Set Boot Switch (SW1) - Switch 6 On (shorts pin 6 to pin 15)
- Switch 8 On (shorts pin 8 to pin 13)
Set R46 to pull-down

8. Reset the QSB

No response on the serial port.

----------------------------------------------------------------

There are several questions I have after reading the docs:

What is in uImage (does it include uBoot? does it include rootfs or just the kernel proper?)

Does the SATA drive need to be partioned or pre-formatted before uImage is loaded?

Does rootfs need to be copied over to the drive first (It was not clear to me if instructions section 7 in the Linux Start User Guide apply or are an alternative load procedure)

Lastly, are there any Linux kernel configuration file sthat need to be modified (ie fstab, grub.conf ....)?

Regards,
Mich

Tags (1)
0 Kudos
1 Reply

485 Views
peterliu1
Contributor I

Hi, Do you solved the question?

I meet the same problem as you. When I sata info, I get as follows:

MX53-ARD-DDR3 U-Boot > sata info

AHCI 0001.0100 32 slots 1 ports 3 Gbps 0x1 impl SATA mode

flags: ncq stag pm led clo only pmp pio slum part

timeout exit!

timeout exit!

SATA Device Info:

S/N:

Product model number:

Firmware version:

Capacity: 0 sectors

 

SATA device 0: Model:  Firm:  Ser#:

            Type: Hard Disk

            Capacity: not available

 

It looks different with your result such as I cannot get the SATA's capacity but you can. Why SATA device cannot be recognized?

0 Kudos