Compiling uClinux (7) in vdsp: confusing success

Source: Internet
Author: User

Haha, uClinux-2.6.x finally ran up under vdsp, in addition to happy or happy! After two weeks of night fights, you can finally comfortably sleep and celebrate:

Linux version 2.6.19.3-ADI-2007R1.1-svn (wmz@gtw.com) (vdsp 4.5) #2 Tue Sep 25 11:24:43 CST 2007
Warning: Limiting memory to 53 MB due to hardware anomaly 05000263
Blackfin support (c) 2004-2007 Analog Devices, Inc.
Compiled for ADSP-BF561 rev 0.3
Blackfin Linux support by http://blackfin.uclinux.org/
Processor speed: 594 MHz core clock and 99 MHz system clock
Board Memory: 64 MB
Kernel managed memory: 64 MB
Memory Map:
TEXT = 0x000-0x00138843
Init = 0x00138843-0x001a29a2
Data = 0x001aa138-0x001aecbc
Stack = 0x001ac000-0x001ae000
BSS = 0x001aecbc-0x001aecbc
Available = 0x001aecbc-0x03500000
Rootfs = 0x03500000-0x03f00000
DMA zone = 0x03f00000-0x04000000
Instruction Cache Enabled
Data Cache Enabled
Hardware trace enabled
Built 1 zonelists. Total pages: 13462
Kernel command line: Root =/dev/mtdblock0 RW console = ttybf0, 57600
Refreshing ing Blackfin priority driven interrupts
PID hash table entries: 256 (Order: 8, 1024 bytes)
Dentry cache hash table entries: 8192 (Order: 3, 32768 bytes)
Inode-Cache hash table entries: 4096 (Order: 2, 16384 bytes)
Physical pages: 3500
Memory available: 51968 K/63831 k ram, (424 K init code, 1186 K kernel code, 0 K data, 1024 k dma)
Blackfin scratchpad data SRAM: 4 kb
Blackfin data_a SRAM: 16 KB
Blackfin data_ B SRAM: 16 KB
Blackfin instruction SRAM: 16 KB
Mount-Cache hash table entries: 512
Blackfin DMA Controller
Ezkit_init (): Registering device resources
Serial: Blackfin serial driver
Bfin-uart.1: ttybf0 at mmio 0xffc00400 (IRQ = 35) is an BFIN-UART
Ramdisk driver initialized: 16 RAM disks of 4096 K size 1024 blocksize
Io scheduler anticipatory registered (default)
Io scheduler CFQ registered
Io scheduler Noop registered
UClinux [MTD]: Ram probe address = 0x3500000 size = 0xa00000
Creating 1 MTD partitions on "Ram ":
0x00000000-0x00a00000: "romfs"
UClinux [MTD]: Set romfs: ext2 to be root filesystem
VFS: mounted root (ext2 filesystem ).
Freeing unused kernel memory: 420 K freed (0x139000-0x1a1000)
Dma_alloc_init: dma_page @ 0x0019c000-256 pages at 0x03f00000
Hostname: not found
/Dev/null: cannot create
/Dev/null: cannot create
Ifconfig: not found
Inetd: not found

Welcome:
______
/__| | __
_ | _______////
| _/| //
| _ | |__ | _ | //
| ___/____ | _ |/____ | /_//_/
| _ |

For further information see:
Http://www.uclinux.org/
Http://blackfin.uclinux.org/

 

Busybox v1.4.1 (15:34:28 Cst) built-in Shell (MSH)
Enter 'help' for a list of built-in commands.

Root: ~> PWD
/
Root: ~> Ls
[1; 34 mbin [0 m [1; 34 mhome [0 m [1; 34 mmnt [0 m %0%0msample.wav [0 m [1; 34 mtmp [0 m
[1; 34 mdev [0 m [1; 34 mlib [0 m [1; 34 mproc [0 m [1; 36 msbin [0 m [1; 34 musr [0 m
[1; 34 metc [0 m [1; 34 mlost + found [0 m [1; 34 mroot [0 m [1; 34 msys [0 m [1; 34 mvar [0 m
Root: ~> CD proc
Root:/proc> ls
[1; 34m1 [0 m [1; 34m6 [0 m [0; 0 mdevices [0 m [0; 0 miomem [0 m [0; 0 mmeminfo [0 m [0; 0 mstat [0 m
[1; 34m2 [0 m [1; 34m7 [0 m [0; 0 mdiskstats [0 m [0; 0 mioports [0 m [0; 0 mmodules [0 m [1; 34 msys [0 m
[1; 34m3 [0 m [1; 34m8 [0 m [1; 34 mdriver [0 m [0; 0 mkallsyms [0 m [1; 36 mmounts [0 m [1; 34 mtty [0 m
[1; 34m38 [0 m [0; 0 mbuddyinfo [0 m [0; 0 mexecdomains [0 m [0; 0 mkmsg [0 m [0; 0 mmtd [0 m [0; 0 muptime [0 m
[1; 34m4 [0 m [1; 34 mbus [0 m [0; 0 mfilesystems [0 m [0; 0 mloadavg [0 m [1; 34 Mnet [0 m [0; 0 mversion [0 m
[1; 34m41 [0 m [0; 0 mcmdline [0 m [1; 34mfs [0 m [0; 0 mlocks [0 m [0; 0 mpartitions [0 m [0; 0 mvmstat [0 m
[1; 34m5 [0 m [0; 0 mcpuinfo [0 m [0; 0 minterrupts [0 m [0; 0 mmaps [0 m [1; 36 mself [0 m [0; 0 mzoneinfo [0 m
Root:/proc> CAT dmesg
Linux version 2.6.19.3-ADI-2007R1.1-svn (wmz@gtw.com) (vdsp 4.5) #2 Tue Sep 25 11:24:43 CST 2007
Warning: Limiting memory to 53 MB due to hardware anomaly 05000263
Blackfin support (c) 2004-2007 Analog Devices, Inc.
Compiled for ADSP-BF561 rev 0.3
Blackfin Linux support by http://blackfin.uclinux.org/
Processor speed: 594 MHz core clock and 99 MHz system clock
Board Memory: 64 MB
Kernel managed memory: 64 MB
Memory Map:
TEXT = 0x000-0x00138843
Init = 0x00138843-0x001a29a2
Data = 0x001aa138-0x001aecbc
Stack = 0x001ac000-0x001ae000
BSS = 0x001aecbc-0x001aecbc
Available = 0x001aecbc-0x03500000
Rootfs = 0x03500000-0x03f00000
DMA zone = 0x03f00000-0x04000000
On node 0 totalpages: 13568
DMA zone: 106 pages used for memmap
DMA zone: 0 pages reserved
DMA zones: 13462 pages, LIFO batch: 3
Normal zone: 0 pages used for memmap
Instruction Cache Enabled
Data Cache Enabled
Hardware trace enabled
Built 1 zonelists. Total pages: 13462
Kernel command line: Root =/dev/mtdblock0 RW console = ttybf0, 57600
Refreshing ing Blackfin priority driven interrupts
PID hash table entries: 256 (Order: 8, 1024 bytes)
Dentry cache hash table entries: 8192 (Order: 3, 32768 bytes)
Inode-Cache hash table entries: 4096 (Order: 2, 16384 bytes)
Physical pages: 3500
Memory available: 51968 K/63831 k ram, (424 K init code, 1186 K kernel code, 0 K data, 1024 k dma)
Blackfin scratchpad data SRAM: 4 kb
Blackfin data_a SRAM: 16 KB
Blackfin data_ B SRAM: 16 KB
Blackfin instruction SRAM: 16 KB
Calibrating delay loop... 1179.64 bogomips (lpj = 2359296)
Mount-Cache hash table entries: 512
Blackfin DMA Controller
Ezkit_init (): Registering device resources
Serial: Blackfin serial driver
Bfin-uart.1: ttybf0 at mmio 0xffc00400 (IRQ = 35) is an BFIN-UART
Ramdisk driver initialized: 16 RAM disks of 4096 K size 1024 blocksize
Io scheduler anticipatory registered (default)
Io scheduler CFQ registered
Io scheduler Noop registered
UClinux [MTD]: Ram probe address = 0x3500000 size = 0xa00000
Creating 1 MTD partitions on "Ram ":
0x00000000-0x00a00000: "romfs"
UClinux [MTD]: Set romfs: ext2 to be root filesystem
VFS: mounted root (ext2 filesystem ).
Freeing unused kernel memory: 420 K freed (0x139000-0x1a1000)
Dma_alloc_init: dma_page @ 0x0019c000-256 pages at 0x03f00000
Root:/proc>

The cute uClinux logo, isn't it?

Of course, there are some confusing questions.

1. Code for loading/root (init/do_mounts.c)

# Ifdef config_block
Create_dev ("/dev/root", root_dev );
Mount_block_root ("/dev/root", root_mountflags );
# Endif
When the system runs here, the/Dev and/root directories are not created in VFS, resulting in the file system being unable to load, resulting in the panic mentioned in the previous article. So I added two lines of statements in IT to create these two directories and everything is OK!

# Ifdef config_block
Sys_mkdir ("/dev", 0700 );
Sys_mkdir ("/root", 0700 );
Create_dev ("/dev/root", root_dev );
Mount_block_root ("/dev/root", root_mountflags );
# Endif

2. You cannot open inline when compiling a file under mm. Otherwise, the file cannot run because it is unclear.

Take a nap first! Zzz ......

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.