0

古い「ボード ファイル」形式を使用する arm i.mx6 ボード用の 3.0.35 Linux カーネルと、適切なイメージと rootfs を生成するために使用された古い (2013.02) buildroot リポジトリが提供されました。

私の目標は、最新の buildroot パブリック リポジトリ コミットを使用して、将来的にパッケージを最新の状態に保つことが容易になるようにすることです。現在、パッケージ ファイル (OpenSSL、lighttpd など) を手動で編集して、buildroot 経由で最新バージョンを利用できるようにする必要があります。

最新のビルドルート (2016.05 以降) 内でボード構成を複製しようとしました。新しいsystemd(Linaro 2013.01 -> CodeBench ARM 2014.05)をサポートするためにツールチェーンを変更する必要があったことを除いて、すべてが多かれ少なかれ同じままでした。結果:

  • Buildroot: ビルド成功
  • U-Boot: イメージは動作します
  • カーネル: イメージが原因でカーネル パニックが発生する

私の質問は本当に次のとおりです。

  1. 古いカーネルを新しい buildroot/toolchain で使用できますか? それとも非互換性ですか? 特定のツールチェーンは古いカーネルをサポートしていませんか?
  2. 互換性がない場合、古いビルドルートのパッケージを最新の状態に保つ簡単な方法はありますか?
  3. 上記の両方がオプションでない場合、ボード ファイルからデバイス ツリーへの移行を支援するツールはありますか? dts への変換は簡単ですか、それとも長いプロジェクトですか?

編集: Linaro 2014.09 ツールチェーンに変更。以前は、init システムとして systemd 202 を使用していました。新しい buildroot には、systemd のカーネル ヘッダー >= 3.10 に対してビルドされたツールチェーンが必要なため、init システムを systemv に切り替える必要がありました。これが私が受け取っているクラッシュです:

Starting kernel ...

Linux version 3.0.35 (eschumacher@ubuntu) (gcc version 4.9.2 20140904 (prerelease) (crosstool-NG linaro-1.13.1-4.9-2014.09 - Linaro GCC 4.9-2014.09) ) #1 SMP PREEMPT Tue Jun 21 11:01:40 PDT 2016
CPU: ARMv7 Processor [412fc09a] revision 10 (ARMv7), cr=10c53c7d
CPU: VIPT nonaliasing data cache, VIPT aliasing instruction cache
Machine: i.MX 6Quad/DualLite/Solo SMARC CPU Board
Memory policy: ECC disabled, Data cache writealloc
CPU identified as i.MX6DL/SOLO, silicon rev 1.1
PERCPU: Embedded 7 pages/cpu @8bc06000 s5440 r8192 d15040 u32768
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 84992
Kernel command line: console=ttymxc3,115200 root=/dev/mmcblk0p2 rootwait rw
PID hash table entries: 2048 (order: 1, 8192 bytes)
Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
Memory: 336MB = 336MB total
Memory: 327580k/327580k available, 196708k reserved, 0K highmem
Virtual kernel memory layout:
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)
    DMA     : 0xf4600000 - 0xffe00000   ( 184 MB)
    vmalloc : 0xa0800000 - 0xf2000000   (1304 MB)
    lowmem  : 0x80000000 - 0xa0000000   ( 512 MB)
    pkmap   : 0x7fe00000 - 0x80000000   (   2 MB)
    modules : 0x7f000000 - 0x7fe00000   (  14 MB)
      .init : 0x80008000 - 0x80039000   ( 196 kB)
      .text : 0x80039000 - 0x80af9538   (11010 kB)
      .data : 0x80afa000 - 0x80b53be0   ( 359 kB)
       .bss : 0x80b53c04 - 0x80ba775c   ( 335 kB)
SLUB: Genslabs=13, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
Preemptible hierarchical RCU implementation.
NR_IRQS:624
MXC GPIO hardware
sched_clock: 32 bits at 3000kHz, resolution 333ns, wraps every 1431655ms
Set periph_clk's parent to pll2_pfd_400M!
arm_max_freq=800MHz
MXC_Early serial console at MMIO 0x21f0000 (options '115200')
bootconsole [ttymxc3] enabled
Console: colour dummy device 80x30
Calibrating delay loop... 1581.05 BogoMIPS (lpj=7905280)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
hw perfevents: enabled with ARMv7 Cortex-A9 PMU driver, 7 counters available
Brought up 1 CPUs
SMP: Total of 1 processors activated (1581.05 BogoMIPS).
devtmpfs: initialized
print_constraints: dummy:
NET: Registered protocol family 16
print_constraints: vddpu: 725 <--> 1300 mV at 700 mV fast normal
print_constraints: vddcore: 725 <--> 1300 mV at 1150 mV fast normal
print_constraints: vddsoc: 725 <--> 1300 mV at 1200 mV fast normal
print_constraints: vdd2p5: 2000 <--> 2775 mV at 2400 mV fast normal
print_constraints: vdd1p1: 800 <--> 1400 mV at 1100 mV fast normal
print_constraints: vdd3p0: 2625 <--> 3400 mV at 3000 mV fast normal
hw-breakpoint: found 6 breakpoint and 1 watchpoint registers.
hw-breakpoint: 1 breakpoint(s) reserved for watchpoint single-step.
hw-breakpoint: maximum watchpoint size is 4 bytes.
L310 cache controller enabled
l2x0: 16 ways, CACHE_ID 0x410000c8, AUX_CTRL 0x02050000, Cache size: 524288 B
bio: create slab <bio-0> at 0
mxs-dma mxs-dma-apbh: initialized
print_constraints: vmmc: 3300 mV
vgaarb: loaded
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
Freescale USB OTG Driver loaded, $Revision: 1.55 $
imx-ipuv3 imx-ipuv3.0: IPU DMFC NORMAL mode: 1(0~1), 5B(4,5), 5F(6,7)
MIPI CSI2 driver module loaded
Advanced Linux Sound Architecture Driver Version 1.0.24.
Bluetooth: Core ver 2.16
NET: Registered protocol family 31
Bluetooth: HCI device and connection manager initialized
Bluetooth: HCI socket layer initialized
Bluetooth: L2CAP socket layer initialized
Bluetooth: SCO socket layer initialized
i2c-core: driver [max17135] using legacy suspend method
i2c-core: driver [max17135] using legacy resume method
Switching to clocksource mxc_timer1
cfg80211: Calling CRDA to update world regulatory domain
Unable to handle kernel NULL pointer dereference at virtual address 00000040
pgd = 80004000
[00000040] *pgd=00000000
Internal error: Oops: 5 [#1] PREEMPT SMP
Modules linked in:
CPU: 0    Not tainted  (3.0.35 #1)
PC is at kmem_cache_alloc+0xa4/0x108
LR is at con_insert_unipair+0xb8/0x104
pc : [<800f40c0>]    lr : [<80299574>]    psr: 60000093
sp : 9202fef0  ip : 9202e000  fp : 00000001
r10: 00000000  r9 : 0bbcf000  r8 : 20000013
r7 : 000000d0  r6 : 92002300  r5 : 00000040  r4 : 80b0fcc8
r3 : 8003a5a0  r2 : 80b0fcc8  r1 : 000024ac  r0 : 00000001
Flags: nZCv  IRQs off  FIQs on  Mode SVC_32  ISA ARM  Segment kernel
Control: 10c53c7d  Table: 1000404a  DAC: 00000015
Process swapper (pid: 1, stack limit = 0x9202e2f0)
Stack: (0x9202fef0 to 0x92030000)
fee0:                                     00002665 921bcee4 920f4900 00000003
ff00: 80b2fee8 80b2fee6 00000003 80299574 00000000 00000001 920f4900 00000003
ff20: 80b2fee8 8029a1a4 00000000 80b30143 92003000 80b729d8 00000136 00000001
ff40: 00000014 80b72bfc 00000001 00000002 00000004 00000000 8001fce4 8001f214
ff60: 00000000 80b72ad8 00000001 8001f714 80a695d4 00000000 80b725d4 00000000
ff80: 8003fb04 00000013 00000000 00000000 00000000 8001eb68 80a37670 00000000
ffa0: 80b53c20 80b53c20 9202e030 800395c0 000001df 00000013 00000000 00000000
ffc0: 00000039 00000000 00000270 8002fb14 8002ffa0 8003fb04 00000013 00000000
ffe0: 00000000 00000000 00000000 8000898c 00000000 8003fb04 c38ac389 c38dc38b
[<800f40c0>] (kmem_cache_alloc+0xa4/0x108) from [<80299574>] (con_insert_unipair+0xb8/0x104)
[<80299574>] (con_insert_unipair+0xb8/0x104) from [<8029a1a4>] (con_set_default_unimap+0xe8/0x178)
[<8029a1a4>] (con_set_default_unimap+0xe8/0x178) from [<8001f214>] (console_map_init+0x44/0x50)
[<8001f214>] (console_map_init+0x44/0x50) from [<8001f714>] (vty_init+0x18c/0x19c)
[<8001f714>] (vty_init+0x18c/0x19c) from [<8001eb68>] (tty_init+0x12c/0x144)
[<8001eb68>] (tty_init+0x12c/0x144) from [<800395c0>] (do_one_initcall+0x114/0x16c)
[<800395c0>] (do_one_initcall+0x114/0x16c) from [<8000898c>] (kernel_init+0xc0/0x144)
[<8000898c>] (kernel_init+0xc0/0x144) from [<8003fb04>] (kernel_thread_exit+0x0/0x8)
Code: 1afffff3 e596a014 e2811004 e3a00001 (e795a00a)
---[ end trace 1b75b31a2719ed1c ]---
Kernel panic - not syncing: Attempted to kill init!
[<8004631c>] (unwind_backtrace+0x0/0xec) from [<80569100>] (panic+0x80/0x19c)
[<80569100>] (panic+0x80/0x19c) from [<80075934>] (complete_and_exit+0x0/0x1c)
[<80075934>] (complete_and_exit+0x0/0x1c) from [<00000001>] (0x1)

編集2:

buildroot 構成を変更して、カーネル ヘッダーを使用して独自のツールチェーンを構築しました。同様のカーネル パニックが引き続き発生します。出力:

Starting kernel ...

Linux version 3.0.35 (eschumacher@ubuntu) (gcc version 4.9.3 (Buildroot 2016.08-           git-00508-geba9c44-dirty) ) #1 SMP PREEMPT Tue Jun 21 16:41:35 PDT 2016
CPU: ARMv7 Processor [412fc09a] revision 10 (ARMv7), cr=10c53c7d
CPU: VIPT nonaliasing data cache, VIPT aliasing instruction cache
Machine: i.MX 6Quad/DualLite/Solo SMARC CPU Board
Memory policy: ECC disabled, Data cache writealloc
CPU identified as i.MX6DL/SOLO, silicon rev 1.1
PERCPU: Embedded 7 pages/cpu @8bc06000 s5440 r8192 d15040 u32768
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 84992
Kernel command line: console=ttymxc3,115200 root=/dev/mmcblk0p2 rootwait rw
PID hash table entries: 2048 (order: 1, 8192 bytes)
Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
Memory: 336MB = 336MB total
Memory: 327564k/327564k available, 196724k reserved, 0K highmem
Virtual kernel memory layout:
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)
    DMA     : 0xf4600000 - 0xffe00000   ( 184 MB)
    vmalloc : 0xa0800000 - 0xf2000000   (1304 MB)
    lowmem  : 0x80000000 - 0xa0000000   ( 512 MB)
    pkmap   : 0x7fe00000 - 0x80000000   (   2 MB)
    modules : 0x7f000000 - 0x7fe00000   (  14 MB)
      .init : 0x80008000 - 0x80039000   ( 196 kB)
      .text : 0x80039000 - 0x80afd458   (11026 kB)
      .data : 0x80afe000 - 0x80b57bc0   ( 359 kB)
       .bss : 0x80b57be4 - 0x80bab73c   ( 335 kB)
SLUB: Genslabs=13, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
Preemptible hierarchical RCU implementation.
NR_IRQS:624
MXC GPIO hardware
sched_clock: 32 bits at 3000kHz, resolution 333ns, wraps every 1431655ms
Set periph_clk's parent to pll2_pfd_400M!
arm_max_freq=800MHz
MXC_Early serial console at MMIO 0x21f0000 (options '115200')
bootconsole [ttymxc3] enabled
Console: colour dummy device 80x30
Calibrating delay loop... 1581.05 BogoMIPS (lpj=7905280)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
hw perfevents: enabled with ARMv7 Cortex-A9 PMU driver, 7 counters available
Brought up 1 CPUs
SMP: Total of 1 processors activated (1581.05 BogoMIPS).
devtmpfs: initialized
print_constraints: dummy:
NET: Registered protocol family 16
print_constraints: vddpu: 725 <--> 1300 mV at 700 mV fast normal
print_constraints: vddcore: 725 <--> 1300 mV at 1150 mV fast normal
print_constraints: vddsoc: 725 <--> 1300 mV at 1200 mV fast normal
print_constraints: vdd2p5: 2000 <--> 2775 mV at 2400 mV fast normal
print_constraints: vdd1p1: 800 <--> 1400 mV at 1100 mV fast normal
print_constraints: vdd3p0: 2625 <--> 3400 mV at 3000 mV fast normal
hw-breakpoint: found 6 breakpoint and 1 watchpoint registers.
hw-breakpoint: 1 breakpoint(s) reserved for watchpoint single-step.
hw-breakpoint: maximum watchpoint size is 4 bytes.
L310 cache controller enabled
l2x0: 16 ways, CACHE_ID 0x410000c8, AUX_CTRL 0x02050000, Cache size: 524288 B
bio: create slab <bio-0> at 0
mxs-dma mxs-dma-apbh: initialized
print_constraints: vmmc: 3300 mV
vgaarb: loaded
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
Freescale USB OTG Driver loaded, $Revision: 1.55 $
imx-ipuv3 imx-ipuv3.0: IPU DMFC NORMAL mode: 1(0~1), 5B(4,5), 5F(6,7)
MIPI CSI2 driver module loaded
Advanced Linux Sound Architecture Driver Version 1.0.24.
Bluetooth: Core ver 2.16
NET: Registered protocol family 31
Bluetooth: HCI device and connection manager initialized
Bluetooth: HCI socket layer initialized
Bluetooth: L2CAP socket layer initialized
Bluetooth: SCO socket layer initialized
i2c-core: driver [max17135] using legacy suspend method
i2c-core: driver [max17135] using legacy resume method
Switching to clocksource mxc_timer1
cfg80211: Calling CRDA to update world regulatory domain
Unable to handle kernel NULL pointer dereference at virtual address 00000040
pgd = 80004000
[00000040] *pgd=00000000
Internal error: Oops: 5 [#1] PREEMPT SMP
Modules linked in:
CPU: 0    Not tainted  (3.0.35 #1)
PC is at kmem_cache_alloc+0xa4/0x108
LR is at con_insert_unipair+0xb8/0x104
pc : [<800f3bbc>]    lr : [<80298a88>]    psr: 60000093
sp : 9202fef8  ip : 9202e000  fp : 00000001
r10: 00000000  r9 : 0bbcf000  r8 : 20000013
r7 : 000000d0  r6 : 92002300  r5 : 00000040  r4 : 80b13cc8
r3 : 8003a5a0  r2 : 80b13cc8  r1 : 000024ac  r0 : 00000001
Flags: nZCv  IRQs off  FIQs on  Mode SVC_32  ISA ARM  Segment kernel
Control: 10c53c7d  Table: 1000404a  DAC: 00000015
Process swapper (pid: 1, stack limit = 0x9202e2f0)
Stack: (0x9202fef8 to 0x92030000)
fee0:                                                       00002665 921bcee4
ff00: 920f4900 00000003 80b33ec8 80b33ec6 00000003 80298a88 80b34123 00000000
ff20: 00000001 920f4900 00000003 802996b8 00000001 80b34123 92003000 80b769b8
ff40: 8001fc40 00000001 00000014 80b76bdc 00000002 00000004 00000000 00000000
ff60: 8001fc40 8001f168 00000000 80b76ab8 00000001 8001f668 80a684a4 8014768c
ff80: 80b765b4 00000000 8003fac4 00000013 00000000 8001eac4 80a36540 00000000
ffa0: 80b57c00 80b57c00 9202e030 800395b8 000001df 00000013 00000000 00000000
ffc0: 00000039 00000000 00000270 8002fa74 8002ff00 8003fac4 00000013 00000000
ffe0: 00000000 00000000 00000000 8000898c 00000000 8003fac4 e345c1eb e0c32c90
[<800f3bbc>] (kmem_cache_alloc+0xa4/0x108) from [<80298a88>] (con_insert_unipair           +0xb8/0x104)
[<80298a88>] (con_insert_unipair+0xb8/0x104) from [<802996b8>] (con_set_default_           unimap+0xe8/0x178)
[<802996b8>] (con_set_default_unimap+0xe8/0x178) from [<8001f168>] (console_map_           init+0x44/0x50)
[<8001f168>] (console_map_init+0x44/0x50) from [<8001f668>] (vty_init+0x18c/0x19           c)
[<8001f668>] (vty_init+0x18c/0x19c) from [<8001eac4>] (tty_init+0x12c/0x144)
[<8001eac4>] (tty_init+0x12c/0x144) from [<800395b8>] (do_one_initcall+0x114/0x1           6c)
[<800395b8>] (do_one_initcall+0x114/0x16c) from [<8000898c>] (kernel_init+0xc0/0           x144)
[<8000898c>] (kernel_init+0xc0/0x144) from [<8003fac4>] (kernel_thread_exit+0x0/           0x8)
Code: 1afffff3 e596a014 e2811004 e3a00001 (e795a00a)
---[ end trace 1b75b31a2719ed1c ]---
Kernel panic - not syncing: Attempted to kill init!
[<800462c8>] (unwind_backtrace+0x0/0xec) from [<80567fcc>] (panic+0x80/0x19c)
[<80567fcc>] (panic+0x80/0x19c) from [<800757e0>] (complete_and_exit+0x0/0x1c)
[<800757e0>] (complete_and_exit+0x0/0x1c) from [<00000001>] (0x1)
4

1 に答える 1

1

コメントで述べたように、クラッシュはFreescale 3.0.35 カーネル クラッシュのものと非常によく似ています。その場合、クラッシュは で発生しmemset.Sます。SHA1 がおよびで始まるアップストリーム カーネルの memset.Sの上位 2 つのコミットは、それぞれこの問題を解決するはずです。c2459d31bd4678

于 2016-06-25T08:21:47.973 に答える