Differences

This shows you the differences between the selected revision and the current version of the page.

howto:kernel_upload 2006/12/09 21:56 howto:kernel_upload 2017/09/06 17:34 current
Line 1: Line 1:
====== Uploading a Kernel via the Serial Port ====== ====== Uploading a Kernel via the Serial Port ======
-**WARNING: uploading a kernel via the serial port takes about 20 minutes, if interrupted will leave your unit inoperable until the procedure is completed correctly.  U-boot if used incorrectly can leave your unit completely inoperable, even beyond recovery by this procedure.  Since this procedure requires hooking up a serial port, your warranty is already void, but doing anything mentioned here will futher void it.  While care has been taken to ensure the following procedure is correct we offer no gurantee that it will not destroy your hardware and burn down your domcile.**+**WARNING: uploading a kernel via the serial port takes about 20 minutes and uploading a ram disk image can take about 70 minutes, if interrupted will leave your unit inoperable until the procedure is completed correctly.  U-boot if used incorrectly can leave your unit completely inoperable, even beyond recovery by this procedure.  Since this procedure requires hooking up a serial port, your warranty is already void, but doing anything mentioned here will futher void it.  While care has been taken to ensure the following procedure is correct we offer no gurantee that it will not destroy your hardware and burn down your domcile.**
Das U-Boot is a GPL'ed cross-platform boot loader, it is a small piece of software that executes soon after powering up a computer.  It will initialize the basic hardware and, if not interrupted, load and execute the Linux Kernel. Das U-Boot is a GPL'ed cross-platform boot loader, it is a small piece of software that executes soon after powering up a computer.  It will initialize the basic hardware and, if not interrupted, load and execute the Linux Kernel.
-By entering a character soon after u-boot starts outputting messages you can interrupt the boot process and communicate directly with u-boot.  The version of u-boot supplied with the DSM G600 is severly restricted in   the commands it supports, pretty mouch th eonly useful command is ''loadb''.  The ''loadb'' provided by D-Link is non-standard in that instead of loading a binary into RAM, it will take a binary and load it as a kernel and/or a ramdisk image.  for loading a kernel, the command is:+By entering a character soon after u-boot starts outputting messages you can interrupt the boot process and communicate directly with u-boot.  The version of u-boot supplied with the DSM G600 is severly restricted in the commands it supports, pretty mouch the only useful command is ''loadb''.  The ''loadb'' provided by D-Link is non-standard in that instead of loading a binary into RAM, it will take a binary and load it as a kernel and/or a ramdisk image.  For loading a kernel, the command is:
  loadb k   loadb k
 +
 +If you want to load ram disk image instead of kernel then the command is:
 +  loadb r
Loadb uses the ''kermit'' protocol to upload the image.  While minicom claims to provide the kermit protocol it does not appear to work with u-boot, so the kermit program is suggested. Loadb uses the ''kermit'' protocol to upload the image.  While minicom claims to provide the kermit protocol it does not appear to work with u-boot, so the kermit program is suggested.
Line 20: Line 23:
  robust   robust
  set file type bin   set file type bin
-  set rec pack 4096 +  set rec pack 1000 
-  set send pack 4096+  set send pack 1000
  set window 5   set window 5
 +
===== U-Boot command prompt ===== ===== U-Boot command prompt =====
Line 49: Line 53:
  send /tftpboot/pImage   send /tftpboot/pImage
-U-boot will now upload the image, when the upload is complete, type ''"connect"'' to reconnect to u-boot to monitor the next step (which will occur automatically).  After uploading the image u-boot will check the image, if it is a u-boot compatible image and not too large it will program it into flash.  To reboot and execute the new kernel, cycle power **(be sure the programming is done)**.+Next you will see transfer statistics: 
 +<code>C-Kermit 8.0.209, 17 Mar 2003, serv.penthouse.lan [192.168.1.20] 
 + 
 +  Current Directory: /root 
 +Communication Device: /dev/ttyS0 
 + Communication Speed: 9600 
 +              Parity: none 
 +        RTT/Timeout: 01 / 04 
 +            SENDING: /tftpboot/pImage => PIMAGE 
 +          File Type: BINARY 
 +          File Size: 3008666 
 +        Percent Done: 
 +                          ...10...20...30...40...50...60...70...80...90..100 
 + Estimated Time Left: 01:05:31 
 +  Transfer Rate, CPS: 760 
 +        Window Slots: 1 of 1 
 +        Packet Type: D 
 +        Packet Count: 28 
 +      Packet Length: 1000 
 +        Error Count: 0 
 +          Last Error: 
 +        Last Message: 
 + 
 +X to cancel file, Z to cancel group, <CR> to resend last packet, 
 +E to send Error packet, ^C to quit immediately, ^L to refresh screen.</code> 
 + 
 +U-boot will now upload the image, when the upload is complete, type ''"connect"'' to reconnect to u-boot to monitor the next step (which will occur automatically).  After uploading the image u-boot will check the image, if it is a u-boot compatible image and not too large it will program it into flash. 
 + 
 + ## Total Size      = 0x002de89a = 3008666 Bytes 
 +  ## Start Addr      = 0x00100000 
 +  Un-Protect Flash Bank # 1 
 +  Erase Ramdisk from 0xffc10000 to 0xffefffff ....... done 
 +  Erased 47 sectors 
 +  Ramdisk Size = 3008666 
 +  Copy to Flash... done 
 +  Protect Flash Bank # 1 
 +  => 
 + 
 +Next you can use ''bootm'' command or cycle power to execute the new kernel, **(be sure the programming is done before removing the power)**.
 +  => bootm FFF10000 FFC20000

Personal Tools