トップ «前の日記(2004年02月17日) 最新 次の日記(2004年02月20日)» 編集
2003|01|02|03|04|05|06|07|08|09|10|11|12|
2004|01|02|03|04|05|06|07|08|09|10|11|12|
2005|01|02|03|04|05|06|07|08|09|10|11|12|
2006|01|02|03|04|05|06|07|08|09|10|11|12|
2007|01|02|03|04|05|06|07|08|09|10|11|12|
2008|01|02|03|04|05|06|07|08|10|12|
2009|02|03|06|07|10|11|12|
2010|01|02|03|04|07|09|10|11|12|
2011|01|03|04|05|06|07|08|10|
2012|01|06|08|09|10|12|
2013|01|02|03|04|07|09|11|12|
2014|01|03|04|05|06|09|
2015|04|
2016|01|08|
ここは旧えびめもです。えびめも2に移行します(2016/12/1)

2004年02月19日

CAT709

linux-2.6.2への移植をはじめる。直すところがいっぱい(*_*)
lib/lib.a(extable.o): In function `search_extable':
extable.o(.text+0x60): multiple definition of `search_extable'
arch/sh/mm/built-in.o(.text+0x290): first defined here
sh3-linux-ld: Warning: size of symbol `search_extable' changed from 70 to 74 in lib/lib.a(extable.o)
make: *** [.tmp_vmlinux1] エラー 1
lib/extable.c と arch/sh/mm/extable.c での同一関数定義。lib/extableの方を消す。

CAT709

いろいろやったらとりあえずカーネルはあがった。
Linux version 2.6.2 (ebihara@boss) (gcc version 3.0.3) #17 Thu Feb 19 05:36:40 JST 2004
setup_cat709
cat709_port_map(start(0x300),stop(0x31f),offset(0xba004000),shift(0))
cat709_set_global_base 0
On node 0 totalpages: 512
  DMA zone: 512 pages, LIFO batch:1
  Normal zone: 0 pages, LIFO batch:1
  HighMem zone: 0 pages, LIFO batch:1
Building zonelist for node : 0
Kernel command line:
Setting GDB trap vector to 0x80000100
init_cat709_IRQ
PID hash table entries: 16 (order 4: 128 bytes)
Calculated peripheral clock value 29492424 differs from sh_pclk value 29421200, fixing..
CPU clock: 117.96MHz
Bus clock: 58.98MHz
Module clock: 29.49MHz
Interval = 73731
Linux version 2.6.2 (ebihara@boss) (gcc version 3.0.3) #17 Thu Feb 19 05:36:40 JST 2004
Linux version 2.6.2 (ebihara@boss) (gcc version 3.0.3) #17 Thu Feb 19 05:36:40 JST 2004
setup_cat709
setup_cat709
cat709_port_map(start(0x300),stop(0x31f),offset(0xba004000),shift(0))
cat709_port_map(start(0x300),stop(0x31f),offset(0xba004000),shift(0))
cat709_set_global_base 0
cat709_set_global_base 0
On node 0 totalpages: 512
On node 0 totalpages: 512
  DMA zone: 512 pages, LIFO batch:1
  DMA zone: 512 pages, LIFO batch:1
  Normal zone: 0 pages, LIFO batch:1
  Normal zone: 0 pages, LIFO batch:1
  HighMem zone: 0 pages, LIFO batch:1
  HighMem zone: 0 pages, LIFO batch:1
Building zonelist for node : 0
Building zonelist for node : 0
Kernel command line:
Kernel command line:
Setting GDB trap vector to 0x80000100
Setting GDB trap vector to 0x80000100
init_cat709_IRQ
init_cat709_IRQ
PID hash table entries: 16 (order 4: 128 bytes)
PID hash table entries: 16 (order 4: 128 bytes)
Calculated peripheral clock value 29492424 differs from sh_pclk value 29421200, fixing..
Calculated peripheral clock value 29492424 differs from sh_pclk value 29421200, fixing..
CPU clock: 117.96MHz
CPU clock: 117.96MHz
Bus clock: 58.98MHz
Bus clock: 58.98MHz
Module clock: 29.49MHz
Module clock: 29.49MHz
Interval = 73731
Interval = 73731
Memory: 928k/198656k available (798k kernel code, 70092k reserved, 143k data, 40k init)
Calibrating delay loop... 78.43 BogoMIPS
Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
Mount-cache hash table entries: 512 (order: 0, 4096 bytes)
CPU: SH7729
POSIX conformance testing by UNIFIX
Linux NoNET1.0 for Linux 2.6
SuperH SCI(F) driver initialized
ttySC0 at 0xfffffe80 is a SCI
ttySC1 at 0xa4000150 is a SCIF
ttySC2 at 0xa4000140 is a SCIF
Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2
ide: Assuming 50MHz system bus speed for PIO modes; override with idebus=xx
mice: PS/2 mouse device common for all mice
i8042.c: i8042 controller selftest failed. (0x9 != 0x55)
VFS: Cannot open root device "1f02" or unknown-block(31,2)
Please append a correct "root=" boot option
Kernel panic: VFS: Unable to mount root fs on unknown-block(31,2)
まだMTDのドライバを整備していないのでFLASHはマウントできないのでここまで。

CAT709

いろいろやってたら動いた。mtdのドライバは少し書き直した。せっかくなのでlinux-2.6.3にした。
Linux version 2.6.3 (ebihara@boss) (gcc version 3.0.3) #4 Fri Feb 20 03:16:46 JST 2004
setup_cat709
cat709_port_map(start(0x300),stop(0x31f),offset(0xba004000),shift(0))
cat709_set_global_base 0
On node 0 totalpages: 8192
  DMA zone: 8192 pages, LIFO batch:2
  Normal zone: 0 pages, LIFO batch:1
  HighMem zone: 0 pages, LIFO batch:1
Built 1 zonelists
Kernel command line:
Setting GDB trap vector to 0x80000100
init_cat709_IRQ
PID hash table entries: 16 (order 4: 128 bytes)
Calculated peripheral clock value 29488420 differs from sh_pclk value 29421200, fixing..
CPU clock: 117.95MHz
Bus clock: 58.97MHz
Module clock: 29.48MHz
Interval = 73721
Linux version 2.6.3 (ebihara@boss) (gcc version 3.0.3) #4 Fri Feb 20 03:16:46 JST 2004
Linux version 2.6.3 (ebihara@boss) (gcc version 3.0.3) #4 Fri Feb 20 03:16:46 JST 2004
setup_cat709
setup_cat709
cat709_port_map(start(0x300),stop(0x31f),offset(0xba004000),shift(0))
cat709_port_map(start(0x300),stop(0x31f),offset(0xba004000),shift(0))
cat709_set_global_base 0
cat709_set_global_base 0
On node 0 totalpages: 8192
On node 0 totalpages: 8192
  DMA zone: 8192 pages, LIFO batch:2
  DMA zone: 8192 pages, LIFO batch:2
  Normal zone: 0 pages, LIFO batch:1
  Normal zone: 0 pages, LIFO batch:1
  HighMem zone: 0 pages, LIFO batch:1
  HighMem zone: 0 pages, LIFO batch:1
Built 1 zonelists
Built 1 zonelists
Kernel command line:
Kernel command line:
Setting GDB trap vector to 0x80000100
Setting GDB trap vector to 0x80000100
init_cat709_IRQ
init_cat709_IRQ
PID hash table entries: 16 (order 4: 128 bytes)
PID hash table entries: 16 (order 4: 128 bytes)
Calculated peripheral clock value 29488420 differs from sh_pclk value 29421200, fixing..
Calculated peripheral clock value 29488420 differs from sh_pclk value 29421200, fixing..
CPU clock: 117.95MHz
CPU clock: 117.95MHz
Bus clock: 58.97MHz
Bus clock: 58.97MHz
Module clock: 29.48MHz
Module clock: 29.48MHz
Interval = 73721
Interval = 73721
Memory: 31080k/2129920k available (992k kernel code, 1048012k reserved, 157k data, 40k init)
Calibrating delay loop... 78.43 BogoMIPS
Dentry cache hash table entries: 524288 (order: 9, 2097152 bytes)
Inode-cache hash table entries: 262144 (order: 8, 1048576 bytes)
Mount-cache hash table entries: 512 (order: 0, 4096 bytes)
CPU: SH7729
POSIX conformance testing by UNIFIX
Linux NoNET1.0 for Linux 2.6
JFFS2 version 2.2. (C) 2001-2003 Red Hat, Inc.
pty: 256 Unix98 ptys configured
SuperH SCI(F) driver initialized
ttySC0 at 0xfffffe80 is a SCI
ttySC1 at 0xa4000150 is a SCIF
ttySC2 at 0xa4000140 is a SCIF
Real Time Clock Driver v1.12
Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2
ide: Assuming 50MHz system bus speed for PIO modes; override with idebus=xx
Using anticipatory io scheduler
 Amd/Fujitsu Extended Query Table v1.1 at 0x0040
number of CFI chips: 1
cfi_cmdset_0002: Disabling fast programming due to code brokenness.
Creating 3 MTD partitions on "CAT709 Flash1":
0x00000000-0x00020000 : "ipl"
0x00020000-0x00100000 : "kernel"
0x00100000-0x00800000 : "Flash FS"
mice: PS/2 mouse device common for all mice
VFS: Mounted root (cramfs filesystem) readonly.
Freeing unused kernel memory: 40k freed
hello
hello
hello
hello
hello
hello
hello
/sbin/init を helloプログラムだけにしてとりあえずプロセスが動作するところまで確認した。メモリーサイズがおかしい。

CAT709

メモリーサイズがおかしいのは arch/sh/mm/init.c のバグだろう。下のように直して報告した。
@@ -182,8 +182,8 @@
 
        high_memory = (void *)(memory_end & PAGE_MASK);
 #endif
-
-       max_mapnr = num_physpages = MAP_NR(high_memory);
+       extern unsigned long memory_start;
+       max_mapnr = num_physpages = MAP_NR(high_memory) - MAP_NR
(memory_start);
 
        /* clear the zero-page */
        memset(empty_zero_page, 0, PAGE_SIZE);

サルサ

くそー踊りて〜