u-bootのmkimageだけビルドする
u-bootは組み込みを中心に幅広い機器で使われているブートローダで、BeagleBoardでも使用されている。
組み込みマシンは別に母艦マシンを用意して開発することが多いわけだが、そうなるとu-bootのイメージファイルを作成するコマンドmkimageを母艦マシンのほうで動かしたくなることがある。
u-bootのは多種多様なアーキテクチャをサポートしておりその設定は結構面倒なのだが、mkimageだけが欲しい場合それらの設定をする必要は無い。
まずビルド
そしてインストール
念のため確認
組み込みマシンは別に母艦マシンを用意して開発することが多いわけだが、そうなるとu-bootのイメージファイルを作成するコマンドmkimageを母艦マシンのほうで動かしたくなることがある。
u-bootのは多種多様なアーキテクチャをサポートしておりその設定は結構面倒なのだが、mkimageだけが欲しい場合それらの設定をする必要は無い。
まずビルド
$ cd tools
$ gcc $CFLAGS -I../include -o mkimage -lz mkimage.c
$ gcc $CFLAGS -I../include -o mkimage -lz mkimage.c
そしてインストール
$ install -v -m755 mkimage /usr/local/bin
念のため確認
$ mkimage
Usage: mkimage -l image
-l ==> list image header information
mkimage [-x] -A arch -O os -T type -C comp -a addr -e ep -n name -d data_file[:data_file...] image
-A ==> set architecture to 'arch'
-O ==> set operating system to 'os'
-T ==> set image type to 'type'
-C ==> set compression type 'comp'
-a ==> set load address to 'addr' (hex)
-e ==> set entry point to 'ep' (hex)
-n ==> set image name to 'name'
-d ==> use image data from 'datafile'
-x ==> set XIP (execute in place)
BeagleBoard用Linuxカーネル
BeagleBoardはLinuxを走らせることが出来るが、そのための開発はブランチで今なお進行中でバニラカーネルにはまだ一部しか取り込まれていない。
このためBeagleBoard上で走るLinuxカーネルのソースを入手してくるのはやや面倒だ。
ここではその手順を書いておこうと思う。
細かい説明はいいからとにかく動くカーネルのソースが欲しいという人はこちら。
BeagleBoardはじめとするTI OMAPシリーズのプロセッサを搭載したプラットフォームへのLinuxの移植はlinux-omapブランチで行われている。現時点でのmasterはlinux-2.6.30-rc4ベースなのだが、
うちで試したところ何故かカーネルが一言も吐かずにハングしてしまった。
これについてはどうにも原因がわからなかったが、2.6.28及び2.6.29では再現しなかった。
というわけでまず2.6.29ブランチを引っ張ってくる。
このカーネルにはDSSが含まれていない。DSSはOMAPシリーズのプロセッサに備わっているフレームバッファのドライバで、BeagleBoardのHDMI/S端子映像出力を使用するために必要だ。DSSは
ここで開発されているのだが、OpenEmbeddedのlinux-omap-2.6.29用パッチに含まれているのでこれをこれを利用する。
先ほどのカーネルにDSSのパッチを当てる。ついでにその他のバグフィックスパッチも当てる。
実際のところBeagleBoardのIOMMUは端子が出ておらず、カメラを使うのはほぼ不可能なのでispディレクトリ以下のパッチは当てる必要は無いのだが、入れておくと何も接続されていないIOMMUが一応認識されてほんの少し得をした気分になれる。
続いてOMAP3に内蔵されているC64+DSPのためのパッチをここから拾ってきて当てる。これでユーザ空間からDSPを叩くことが出来るようになる。
最後に少しソースを修正する必要がある。まず、BeagleBoard Rev.CのUSB EHCIを使えるようにするためにこの変更を適用する必要がある。そして、この変更で電力管理ドライバに追加されたコードが叩こうとするレギュレータVPLL2はBeagleBoardの映像出力のピクセルクロックに使用されており、DSSが使用するため電源管理ドライバがつつかないようにする必要がある。この2点を修正するパッチを用意したので、これを当てる。
OpenEmbeddedのパッチを当てたカーネルはデフォルトでクロスコンパイルしようとするので、BeagleBoard上でセルフコンパイルする場合は199行目の
を
に書き換える。
あとの手順はPCでのいつものカーネルビルドと大して変わらないが、uImageを作成するためにあらかじめu-bootのmkimageをパスの通ったところに置いておく。
カーネルコンフィグで何をどう設定していいか解らないときはこの設定を使うといいかもしれない。
ここまで済んだら再起動して、シリアルコンソールからu-bootの設定を変更してブートする。
おつかれさまでした。
# ちなみに現在Rev.CのUSB EHCIが突然使えなくなるバグが報告されているが、原因はまだ特定されておらずこのカーネルでも同様の現象が起こることが確認されている。せっかくRev.Cで復活したUSB EHCIだが当面はUSB OTG側にバスパワーハブを接続して使うのが賢明だろう。
このためBeagleBoard上で走るLinuxカーネルのソースを入手してくるのはやや面倒だ。
ここではその手順を書いておこうと思う。
細かい説明はいいからとにかく動くカーネルのソースが欲しいという人はこちら。
BeagleBoardはじめとするTI OMAPシリーズのプロセッサを搭載したプラットフォームへのLinuxの移植はlinux-omapブランチで行われている。現時点でのmasterはlinux-2.6.30-rc4ベースなのだが、
Texas Instruments X-Loader 1.4.2 (Feb 19 2009 - 12:01:24)
Reading boot sector
Loading u-boot.bin from nand
U-Boot 2009.01-dirty (Feb 19 2009 - 12:22:31)
I2C: ready
OMAP3530-GP rev 2, CPU-OPP2 L3-165MHz
OMAP3 Beagle board + LPDDR/NAND
DRAM: 256 MB
NAND: 256 MiB
MUSB: using high speed
In: serial usbtty
Out: serial usbtty
Err: serial usbtty
Board revision C
Serial #44f800030000000004013f790300600e
Hit any key to stop autoboot: 0
reading uImage
2441432 bytes read
## Booting kernel from Legacy Image at 80300000 ...
Image Name: Linux
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 2441368 Bytes = 2.3 MB
Load Address: 80008000
Entry Point: 80008000
Verifying Checksum ... OK
Loading Kernel Image ... OK
OK
(ここでハング)
Reading boot sector
Loading u-boot.bin from nand
U-Boot 2009.01-dirty (Feb 19 2009 - 12:22:31)
I2C: ready
OMAP3530-GP rev 2, CPU-OPP2 L3-165MHz
OMAP3 Beagle board + LPDDR/NAND
DRAM: 256 MB
NAND: 256 MiB
MUSB: using high speed
In: serial usbtty
Out: serial usbtty
Err: serial usbtty
Board revision C
Serial #44f800030000000004013f790300600e
Hit any key to stop autoboot: 0
reading uImage
2441432 bytes read
## Booting kernel from Legacy Image at 80300000 ...
Image Name: Linux
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 2441368 Bytes = 2.3 MB
Load Address: 80008000
Entry Point: 80008000
Verifying Checksum ... OK
Loading Kernel Image ... OK
OK
(ここでハング)
うちで試したところ何故かカーネルが一言も吐かずにハングしてしまった。
これについてはどうにも原因がわからなかったが、2.6.28及び2.6.29では再現しなかった。
というわけでまず2.6.29ブランチを引っ張ってくる。
$ git clone git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6.git
$ git checkout origin/omap-2.6.29
$ git checkout -b local-omap-2.6.29
$ git checkout origin/omap-2.6.29
$ git checkout -b local-omap-2.6.29
このカーネルにはDSSが含まれていない。DSSはOMAPシリーズのプロセッサに備わっているフレームバッファのドライバで、BeagleBoardのHDMI/S端子映像出力を使用するために必要だ。DSSは
ここで開発されているのだが、OpenEmbeddedのlinux-omap-2.6.29用パッチに含まれているのでこれをこれを利用する。
$ git clone git://git.openembedded.net/openembedded
先ほどのカーネルにDSSのパッチを当てる。ついでにその他のバグフィックスパッチも当てる。
$ cd linux-omap-2.6
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/no-empty-flash-warnings.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/no-cortex-deadlock.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/read_die_ids.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/fix-install.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0001-Revert-gro-Fix-legacy-path-napi_complete-crash.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0002-OMAPFB-move-omapfb.h-to-include-linux.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0003-DSS2-OMAP2-3-Display-Subsystem-driver.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0004-DSS2-OMAP-framebuffer-driver.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0005-DSS2-Add-panel-drivers.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0006-DSS2-HACK-Add-DSS2-support-for-N800.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0007-DSS2-Add-DSS2-support-for-SDP-Beagle-Overo-EVM.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0008-DSS2-Add-function-to-display-object-to-get-the-back.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0009-DSS2-Add-acx565akm-panel.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0010-DSS2-Small-VRFB-context-allocation-bug-fixed.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0011-DSS2-Allocated-memory-for-Color-Look-up-table.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0012-DSS2-Fix-DMA-rotation.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0013-DSS2-Verify-that-overlay-paddr-0.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0014-DSS2-Add-function-to-get-DSS-logic-clock-rate.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0015-DSS2-DSI-calculate-VP_CLK_RATIO-properly.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0016-DSS2-DSI-improve-packet-len-calculation.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0017-DSS2-Disable-video-planes-on-sync-lost-error.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0018-DSS2-check-for-ovl-paddr-only-when-enabling.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0019-DSS2-Check-fclk-limits-when-configuring-video-plane.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0020-DSS2-Check-scaling-limits-against-proper-values.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0021-DSS2-Add-venc-register-dump.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0022-DSS2-FB-remove-unused-var-warning.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0023-DSS2-pass-the-default-FB-color-format-through-board.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0024-DSS2-Beagle-Use-gpio_set_value.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0025-DSS2-VRFB-Macro-for-calculating-base-address-of-th.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0026-DSS2-DSI-sidlemode-to-noidle-while-sending-frame.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0027-DSS2-VRFB-rotation-and-mirroring-implemented.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0028-DSS2-OMAPFB-Added-support-for-the-YUV-VRFB-rotatio.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0029-DSS2-OMAPFB-Set-line_length-correctly-for-YUV-with.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0030-DSS2-dispc_get_trans_key-was-returning-wrong-key-ty.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0031-DSS2-do-bootmem-reserve-for-exclusive-access.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0032-DSS2-Fix-DISPC_VID_FIR-value-for-omap34xx.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0033-DSS2-Prefer-3-tap-filter.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0034-DSS2-VRAM-improve-omap_vram_add_region.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0035-DSS2-Added-the-function-pointer-for-getting-default.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0036-DSS2-Added-support-for-setting-and-querying-alpha-b.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0037-DSS2-Added-support-for-querying-color-keying.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0038-DSS2-OMAPFB-Some-color-keying-pointerd-renamed-in-D.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0039-DSS2-Add-sysfs-entry-to-for-the-alpha-blending-supp.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0040-DSS2-Provided-proper-exclusion-for-destination-colo.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0041-DSS2-Disable-vertical-offset-with-fieldmode.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0042-DSS2-Don-t-enable-fieldmode-automatically.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0043-DSS2-Swap-field-0-and-field-1-registers.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0044-DSS2-add-sysfs-entry-for-seting-the-rotate-type.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0045-DSS2-Fixed-line-endings-from-to.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0046-DSS2-DSI-decrease-sync-timeout-from-60s-to-2s.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0047-DSS2-fix-return-value-for-rotate_type-sysfs-functio.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0048-OMAP2-3-DMA-implement-trans-copy-and-const-fill.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0049-DSS2-VRAM-clear-allocated-area-with-DMA.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0050-DSS2-OMAPFB-remove-fb-clearing-code.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0051-DSS2-VRAM-use-debugfs-not-procfs.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0052-DSS2-VRAM-fix-section-mismatch-warning.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0053-DSS2-disable-LCD-DIGIT-before-resetting-DSS.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/0001-board-ldp-add-regulator-info-to-get-the-microSD-slo.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/fix-unaligned-access.diff
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/make-alignment-visible.diff
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/mmctiming.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/ehci.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/fix-audio-capture.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/ads7846-detection.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0001-USB-musb-only-turn-off-vbus-in-OTG-hosts.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0002-USB-composite-avoid-inconsistent-lock-state.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0003-USB-musb-NAK-timeout-scheme-on-bulk-RX-endpoint.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0004-USB-musb-rewrite-host-periodic-endpoint-allocation.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0005-USB-TWL-disable-VUSB-regulators-when-cable-unplugg.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0006-USB-gadget-composite-device-level-suspend-resume-h.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0007-usb-gadget-fix-ethernet-link-reports-to-ethtool.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0008-usb-musb_host-minor-enqueue-locking-fix-v2.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0009-usb-musb_host-fix-ep0-fifo-flushing.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0010-musb-sanitize-clearing-TXCSR-DMA-bits-take-2.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0011-musb-fix-isochronous-TXDMA-take-2.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0012-musb-fix-possible-panic-while-resuming.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0013-musb_host-refactor-musb_save_toggle-take-2.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0014
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0014-musb_gadget-suppress-parasitic-TX-interrupts-with.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0015-musb_gadget-fix-unhandled-endpoint-0-IRQs.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0016-musb_host-factor-out-musb_ep_-get-set-_qh.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0017-musb_host-refactor-URB-giveback.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0018-musb-split-out-CPPI-interrupt-handler.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0019-musb_host-simplify-check-for-active-URB.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0020-musb_host-streamline-musb_cleanup_urb-calls.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0021-twl4030-usb-fix-minor-reporting-goofage.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0022-musb-use-dma-mode-1-for-TX-if-transfer-size-equals.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0023-musb-add-high-bandwidth-ISO-support.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0024-USB-otg-adding-nop-usb-transceiver.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0025-nop-usb-xceiv-behave-when-linked-as-a-module.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0026-musb-proper-hookup-to-transceiver-drivers.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0027-musb-otg-timer-cleanup.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0028-musb-make-initial-HNP-roleswitch-work-v2.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0029-musb-support-disconnect-after-HNP-roleswitch.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/v4l/0001-V4L2-Add-COLORFX-user-control.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/v4l/0002-V4L-Int-if-v4l2_int_device_try_attach_all-requires.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/v4l/0003-V4L-Int-if-Dummy-slave.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/v4l/0004-V4L-int-device-add-support-for-VIDIOC_QUERYMENU.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/v4l/0005-V4L-Int-if-Add-vidioc_int_querycap.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0001-omap-iommu-tlb-and-pagetable-primitives.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0002-omap-iommu-omap2-architecture-specific-functions.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0003-omap-iommu-omap3-iommu-device-registration.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0004-omap-iommu-simple-virtual-address-space-management.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0005-omap-iommu-entries-for-Kconfig-and-Makefile.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0006-omap-iommu-Don-t-try-BUG_ON-in_interrupt.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0007-omap-iommu-We-support-chained-scatterlists-probabl.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0008-omap2-iommu-entries-for-Kconfig-and-Makefile.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0001-omap3isp-Add-ISP-main-driver-and-register-definitio.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0002-omap3isp-Add-ISP-MMU-wrapper.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0003-omap3isp-Add-userspace-header.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0004-omap3isp-Add-ISP-frontend-CCDC.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0005-omap3isp-Add-ISP-backend-PRV-and-RSZ.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0006-omap3isp-Add-statistics-collection-modules-H3A-and.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0007-omap3isp-Add-CSI2-interface-support.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0008-omap3isp-Add-ISP-tables.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/000
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/0124-leds-gpio-broken-with-current-git.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/modedb-hd720.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/beagleboard/beagle-asoc.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/beagleboard/ehci.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/no-empty-flash-warnings.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/no-cortex-deadlock.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/read_die_ids.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/fix-install.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0001-Revert-gro-Fix-legacy-path-napi_complete-crash.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0002-OMAPFB-move-omapfb.h-to-include-linux.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0003-DSS2-OMAP2-3-Display-Subsystem-driver.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0004-DSS2-OMAP-framebuffer-driver.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0005-DSS2-Add-panel-drivers.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0006-DSS2-HACK-Add-DSS2-support-for-N800.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0007-DSS2-Add-DSS2-support-for-SDP-Beagle-Overo-EVM.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0008-DSS2-Add-function-to-display-object-to-get-the-back.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0009-DSS2-Add-acx565akm-panel.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0010-DSS2-Small-VRFB-context-allocation-bug-fixed.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0011-DSS2-Allocated-memory-for-Color-Look-up-table.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0012-DSS2-Fix-DMA-rotation.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0013-DSS2-Verify-that-overlay-paddr-0.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0014-DSS2-Add-function-to-get-DSS-logic-clock-rate.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0015-DSS2-DSI-calculate-VP_CLK_RATIO-properly.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0016-DSS2-DSI-improve-packet-len-calculation.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0017-DSS2-Disable-video-planes-on-sync-lost-error.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0018-DSS2-check-for-ovl-paddr-only-when-enabling.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0019-DSS2-Check-fclk-limits-when-configuring-video-plane.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0020-DSS2-Check-scaling-limits-against-proper-values.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0021-DSS2-Add-venc-register-dump.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0022-DSS2-FB-remove-unused-var-warning.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0023-DSS2-pass-the-default-FB-color-format-through-board.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0024-DSS2-Beagle-Use-gpio_set_value.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0025-DSS2-VRFB-Macro-for-calculating-base-address-of-th.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0026-DSS2-DSI-sidlemode-to-noidle-while-sending-frame.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0027-DSS2-VRFB-rotation-and-mirroring-implemented.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0028-DSS2-OMAPFB-Added-support-for-the-YUV-VRFB-rotatio.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0029-DSS2-OMAPFB-Set-line_length-correctly-for-YUV-with.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0030-DSS2-dispc_get_trans_key-was-returning-wrong-key-ty.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0031-DSS2-do-bootmem-reserve-for-exclusive-access.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0032-DSS2-Fix-DISPC_VID_FIR-value-for-omap34xx.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0033-DSS2-Prefer-3-tap-filter.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0034-DSS2-VRAM-improve-omap_vram_add_region.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0035-DSS2-Added-the-function-pointer-for-getting-default.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0036-DSS2-Added-support-for-setting-and-querying-alpha-b.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0037-DSS2-Added-support-for-querying-color-keying.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0038-DSS2-OMAPFB-Some-color-keying-pointerd-renamed-in-D.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0039-DSS2-Add-sysfs-entry-to-for-the-alpha-blending-supp.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0040-DSS2-Provided-proper-exclusion-for-destination-colo.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0041-DSS2-Disable-vertical-offset-with-fieldmode.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0042-DSS2-Don-t-enable-fieldmode-automatically.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0043-DSS2-Swap-field-0-and-field-1-registers.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0044-DSS2-add-sysfs-entry-for-seting-the-rotate-type.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0045-DSS2-Fixed-line-endings-from-to.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0046-DSS2-DSI-decrease-sync-timeout-from-60s-to-2s.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0047-DSS2-fix-return-value-for-rotate_type-sysfs-functio.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0048-OMAP2-3-DMA-implement-trans-copy-and-const-fill.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0049-DSS2-VRAM-clear-allocated-area-with-DMA.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0050-DSS2-OMAPFB-remove-fb-clearing-code.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0051-DSS2-VRAM-use-debugfs-not-procfs.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0052-DSS2-VRAM-fix-section-mismatch-warning.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/dss2/0053-DSS2-disable-LCD-DIGIT-before-resetting-DSS.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/0001-board-ldp-add-regulator-info-to-get-the-microSD-slo.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/fix-unaligned-access.diff
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/make-alignment-visible.diff
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/mmctiming.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/ehci.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/fix-audio-capture.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/ads7846-detection.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0001-USB-musb-only-turn-off-vbus-in-OTG-hosts.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0002-USB-composite-avoid-inconsistent-lock-state.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0003-USB-musb-NAK-timeout-scheme-on-bulk-RX-endpoint.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0004-USB-musb-rewrite-host-periodic-endpoint-allocation.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0005-USB-TWL-disable-VUSB-regulators-when-cable-unplugg.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0006-USB-gadget-composite-device-level-suspend-resume-h.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0007-usb-gadget-fix-ethernet-link-reports-to-ethtool.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0008-usb-musb_host-minor-enqueue-locking-fix-v2.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0009-usb-musb_host-fix-ep0-fifo-flushing.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0010-musb-sanitize-clearing-TXCSR-DMA-bits-take-2.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0011-musb-fix-isochronous-TXDMA-take-2.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0012-musb-fix-possible-panic-while-resuming.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0013-musb_host-refactor-musb_save_toggle-take-2.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0014
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0014-musb_gadget-suppress-parasitic-TX-interrupts-with.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0015-musb_gadget-fix-unhandled-endpoint-0-IRQs.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0016-musb_host-factor-out-musb_ep_-get-set-_qh.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0017-musb_host-refactor-URB-giveback.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0018-musb-split-out-CPPI-interrupt-handler.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0019-musb_host-simplify-check-for-active-URB.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0020-musb_host-streamline-musb_cleanup_urb-calls.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0021-twl4030-usb-fix-minor-reporting-goofage.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0022-musb-use-dma-mode-1-for-TX-if-transfer-size-equals.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0023-musb-add-high-bandwidth-ISO-support.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0024-USB-otg-adding-nop-usb-transceiver.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0025-nop-usb-xceiv-behave-when-linked-as-a-module.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0026-musb-proper-hookup-to-transceiver-drivers.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0027-musb-otg-timer-cleanup.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0028-musb-make-initial-HNP-roleswitch-work-v2.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/musb/0029-musb-support-disconnect-after-HNP-roleswitch.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/v4l/0001-V4L2-Add-COLORFX-user-control.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/v4l/0002-V4L-Int-if-v4l2_int_device_try_attach_all-requires.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/v4l/0003-V4L-Int-if-Dummy-slave.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/v4l/0004-V4L-int-device-add-support-for-VIDIOC_QUERYMENU.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/v4l/0005-V4L-Int-if-Add-vidioc_int_querycap.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0001-omap-iommu-tlb-and-pagetable-primitives.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0002-omap-iommu-omap2-architecture-specific-functions.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0003-omap-iommu-omap3-iommu-device-registration.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0004-omap-iommu-simple-virtual-address-space-management.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0005-omap-iommu-entries-for-Kconfig-and-Makefile.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0006-omap-iommu-Don-t-try-BUG_ON-in_interrupt.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0007-omap-iommu-We-support-chained-scatterlists-probabl.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/iommu/0008-omap2-iommu-entries-for-Kconfig-and-Makefile.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0001-omap3isp-Add-ISP-main-driver-and-register-definitio.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0002-omap3isp-Add-ISP-MMU-wrapper.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0003-omap3isp-Add-userspace-header.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0004-omap3isp-Add-ISP-frontend-CCDC.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0005-omap3isp-Add-ISP-backend-PRV-and-RSZ.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0006-omap3isp-Add-statistics-collection-modules-H3A-and.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0007-omap3isp-Add-CSI2-interface-support.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/0008-omap3isp-Add-ISP-tables.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/isp/omap3camera/000
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/0124-leds-gpio-broken-with-current-git.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/modedb-hd720.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/beagleboard/beagle-asoc.patch
$ patch -p1 <../openembedded/recipes/linux/linux-omap-2.6.29/beagleboard/ehci.patch
実際のところBeagleBoardのIOMMUは端子が出ておらず、カメラを使うのはほぼ不可能なのでispディレクトリ以下のパッチは当てる必要は無いのだが、入れておくと何も接続されていないIOMMUが一応認識されてほんの少し得をした気分になれる。
続いてOMAP3に内蔵されているC64+DSPのためのパッチをここから拾ってきて当てる。これでユーザ空間からDSPを叩くことが出来るようになる。
$ patch -p1 <./0001-TI-DSP-BRIDGE-Kconfig-Entry.patch
$ patch -p1 <./0002-TI-DSP-BRIDGE-Header-files.patch
$ patch -p1 <./0003-TI-DSP-BRIDGE-Doff-image-dynamic-loader.patch
$ patch -p1 <./0004-TI-DSP-BRIDGE-Generic-Utilities.patch
$ patch -p1 <./0005-TI-DSP-BRIDGE-Hardware-Interfaces.patch
$ patch -p1 <./0006-TI-DSP-BRIDGE-Platform-Manager.patch
$ patch -p1 <./0007-TI-DSP-BRIDGE-Resource-Manager.patch
$ patch -p1 <./0008-TI-DSP-BRIDGE-Services.patch
$ patch -p1 <./0009-TI-DSP-BRIDGE-Mini-driver.patch
$ patch -p1 <./0010-TI-DSP-BRIDGE-README.patch
$ patch -p1 <./0011-TI-DSP-BRIDGE-Ceanup-GT-sparse-warnings.patch
$ patch -p1 <./0012-TI-DSP-BRIDGE-Cleanup-static-declarations-warnings.patch
$ patch -p1 <./0013-TI-DSP-BRIDGE-Remove-unused-clk-structs.patch
$ patch -p1 <./0014-TI-DSP-BRIDGE-Clean-up-unusedvariables.patch
$ patch -p1 <./0015-TI-DSP-BRIDGE-Cosmetic-changes-reported-from-checkp.patch
$ patch -p1 <./0002-TI-DSP-BRIDGE-Header-files.patch
$ patch -p1 <./0003-TI-DSP-BRIDGE-Doff-image-dynamic-loader.patch
$ patch -p1 <./0004-TI-DSP-BRIDGE-Generic-Utilities.patch
$ patch -p1 <./0005-TI-DSP-BRIDGE-Hardware-Interfaces.patch
$ patch -p1 <./0006-TI-DSP-BRIDGE-Platform-Manager.patch
$ patch -p1 <./0007-TI-DSP-BRIDGE-Resource-Manager.patch
$ patch -p1 <./0008-TI-DSP-BRIDGE-Services.patch
$ patch -p1 <./0009-TI-DSP-BRIDGE-Mini-driver.patch
$ patch -p1 <./0010-TI-DSP-BRIDGE-README.patch
$ patch -p1 <./0011-TI-DSP-BRIDGE-Ceanup-GT-sparse-warnings.patch
$ patch -p1 <./0012-TI-DSP-BRIDGE-Cleanup-static-declarations-warnings.patch
$ patch -p1 <./0013-TI-DSP-BRIDGE-Remove-unused-clk-structs.patch
$ patch -p1 <./0014-TI-DSP-BRIDGE-Clean-up-unusedvariables.patch
$ patch -p1 <./0015-TI-DSP-BRIDGE-Cosmetic-changes-reported-from-checkp.patch
最後に少しソースを修正する必要がある。まず、BeagleBoard Rev.CのUSB EHCIを使えるようにするためにこの変更を適用する必要がある。そして、この変更で電力管理ドライバに追加されたコードが叩こうとするレギュレータVPLL2はBeagleBoardの映像出力のピクセルクロックに使用されており、DSSが使用するため電源管理ドライバがつつかないようにする必要がある。この2点を修正するパッチを用意したので、これを当てる。
$ patch -p1 <./linux-omap-2.6.29_fix_revc_ehci_and_vpll2.diff
OpenEmbeddedのパッチを当てたカーネルはデフォルトでクロスコンパイルしようとするので、BeagleBoard上でセルフコンパイルする場合は199行目の
CROSS_COMPILE ?= arm-linux-
を
CROSS_COMPILE ?=
に書き換える。
あとの手順はPCでのいつものカーネルビルドと大して変わらないが、uImageを作成するためにあらかじめu-bootのmkimageをパスの通ったところに置いておく。
$ make menuconfig
$ make uImage modules
$ make modules_install
$ mount -t ブートパーティション /boot
$ cp arch/arm/boot/uImage /boot/uImage-2.6.29-omap1-dirty
$ make uImage modules
$ make modules_install
$ mount -t ブートパーティション /boot
$ cp arch/arm/boot/uImage /boot/uImage-2.6.29-omap1-dirty
カーネルコンフィグで何をどう設定していいか解らないときはこの設定を使うといいかもしれない。
$ mv linux-omap-2.6.29_beagleboard.conf .config
ここまで済んだら再起動して、シリアルコンソールからu-bootの設定を変更してブートする。
# setenv bootcmd 'mmcinit; fatload mmc 0:1 0x80300000 uimage-2.6.29-omap1-dirty; bootm 0x80300000'
# setenv bootargs 'console=ttyS2,115200n8 console=tty0 root=ルートファイルシステム rootdelay=5 rootfstype=ルートファイルシステムの種類 ro vram=16M omapdss.def_disp=dvi omapfb.mode=dvi:1280x720MR-16@60'
# saveenv
# boot
# setenv bootargs 'console=ttyS2,115200n8 console=tty0 root=ルートファイルシステム rootdelay=5 rootfstype=ルートファイルシステムの種類 ro vram=16M omapdss.def_disp=dvi omapfb.mode=dvi:1280x720MR-16@60'
# saveenv
# boot
おつかれさまでした。
# ちなみに現在Rev.CのUSB EHCIが突然使えなくなるバグが報告されているが、原因はまだ特定されておらずこのカーネルでも同様の現象が起こることが確認されている。せっかくRev.Cで復活したUSB EHCIだが当面はUSB OTG側にバスパワーハブを接続して使うのが賢明だろう。
libjpeg修正版
以前公開したlibjpegはjconfig.hの定義のうち最小限しかチェックしていなかったが、HAVE_PROTOTYPESでないlibjpegではコンパイル出来ないソフトウェアが結構あるらしいことがわかったのでINLINEとHAVE_PROTOTYPEのチェックを追加した。
NEED_BSD_STRINGS等使用しているところを見たことが無いオプションはこの修正版でもチェックしていないので、ひょっとするとLinux以外の環境では問題が起こるかもしれない。
ダウンロードはこちら
NEED_BSD_STRINGS等使用しているところを見たことが無いオプションはこの修正版でもチェックしていないので、ひょっとするとLinux以外の環境では問題が起こるかもしれない。
ダウンロードはこちら
libjpegのビルドシステム
libjpegは名前の通りJPEG画像をエンコード/デコードするオープンソースライブラリで、多くのオープンソースソフトウェアで利用されている。
しかし現時点での最新版がリリースされたのは1998年の3月。なんと10年以上前である。
安定しているのはいいことなのだが、この古さが問題になることがある。
libjpegはlibtool-1.2のスクリプトを内包しており、--enable-sharedが指定されると共有ライブラリのビルドにそれを用いているが、libtoolがARMプロセッサをサポートしたのはlibtool-1.4.3からなのでARMベースのアーキテクチャを理解してくれないのだ。
そこでlibjpegのlibtool関連スクリプトを最新のlibtoolのもので置き換えようと考えるわけだが、
現在の最新版はlibtool-2.2.6。
作り直したほうが早そうだったので、やっつけで作り直してみた(問題が見つかったので修正)。
ソース自体は本家のlibjpegとまったく同じだが、
といった違いがある。
BeagleBoard上で無事ビルド、インストール成功。
しかし現時点での最新版がリリースされたのは1998年の3月。なんと10年以上前である。
安定しているのはいいことなのだが、この古さが問題になることがある。
$ ./configure --prefix=/usr --enable-shared --mandir=/usr/share/man
checking for gcc... gcc
checking whether the C compiler (gcc ) works... yes
checking whether the C compiler (gcc ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking how to run the C preprocessor... gcc -E
checking for function prototypes... yes
checking for stddef.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for size_t... yes
checking for type unsigned char... yes
checking for type unsigned short... yes
checking for type void... yes
checking for working const... yes
checking for inline... __inline__
checking for broken incomplete types... ok
checking for short external names... ok
checking to see if char is signed... no
checking to see if right shift is signed... yes
checking to see if fopen accepts b spec... yes
checking for a BSD compatible install... /usr/bin/install -c
checking for ranlib... ranlib
checking host system type... Invalid configuration `armv7l-unknown-linux-gnu': machine `armv7l-unknown' not recognized
checking libjpeg version number... 62
creating ./config.status
creating Makefile
creating jconfig.h
$
checking for gcc... gcc
checking whether the C compiler (gcc ) works... yes
checking whether the C compiler (gcc ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking how to run the C preprocessor... gcc -E
checking for function prototypes... yes
checking for stddef.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for size_t... yes
checking for type unsigned char... yes
checking for type unsigned short... yes
checking for type void... yes
checking for working const... yes
checking for inline... __inline__
checking for broken incomplete types... ok
checking for short external names... ok
checking to see if char is signed... no
checking to see if right shift is signed... yes
checking to see if fopen accepts b spec... yes
checking for a BSD compatible install... /usr/bin/install -c
checking for ranlib... ranlib
checking host system type... Invalid configuration `armv7l-unknown-linux-gnu': machine `armv7l-unknown' not recognized
checking libjpeg version number... 62
creating ./config.status
creating Makefile
creating jconfig.h
$
libjpegはlibtool-1.2のスクリプトを内包しており、--enable-sharedが指定されると共有ライブラリのビルドにそれを用いているが、libtoolがARMプロセッサをサポートしたのはlibtool-1.4.3からなのでARMベースのアーキテクチャを理解してくれないのだ。
そこでlibjpegのlibtool関連スクリプトを最新のlibtoolのもので置き換えようと考えるわけだが、
The latest stable version is http://ftp.gnu.org/gnu/libtool/libtool-2.2.6a.tar.gz.
現在の最新版はlibtool-2.2.6。
作り直したほうが早そうだったので、やっつけで作り直してみた(問題が見つかったので修正)。
ソース自体は本家のlibjpegとまったく同じだが、
automake/autoconfベース
使用するlibtoolのバージョンが2.2.6
pkgconfig対応
使用するlibtoolのバージョンが2.2.6
pkgconfig対応
といった違いがある。
BeagleBoard上で無事ビルド、インストール成功。
塗るベーコン
変なものの専門店ThinkGeekで見つけた塗るタイプのベーコン、Squeez Bacon。
"終戦の数年後、スウェーデンの小さなレストランで働くある若い男がベーコンの新しい製法を開発しました。"
ご当地では結構歴史のある食品らしい。
"終戦の数年後、スウェーデンの小さなレストランで働くある若い男がベーコンの新しい製法を開発しました。"
ご当地では結構歴史のある食品らしい。