• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

system/corennnnn


Commit MetaInfo

Revision028d05f8b216720a877601d41055ff9503fd4ac0 (tree)
Time2016-09-04 08:47:11
AuthorM1cha <sigmaepsilon92@gmai...>
CommiterSteve Kondik

Log Message

mkbootimg: add support for --dt

Change-Id: I19f149fac693420cf1f630b51293bbd3650a1b59

Change Summary

Incremental Difference

--- a/mkbootimg/mkbootimg
+++ b/mkbootimg/mkbootimg
@@ -57,7 +57,7 @@ def write_header(args):
5757 args.base + args.second_offset, # physical load addr
5858 args.base + args.tags_offset, # physical addr for kernel tags
5959 args.pagesize, # flash page size we assume
60- 0, # future expansion: MUST be 0
60+ filesize(args.dt), # size in bytes
6161 (args.os_version << 11) | args.os_patch_level)) # os version and patch level
6262 args.output.write(pack('16s', args.board.encode())) # asciiz product name
6363 args.output.write(pack('512s', args.cmdline[:512].encode()))
@@ -66,6 +66,7 @@ def write_header(args):
6666 update_sha(sha, args.kernel)
6767 update_sha(sha, args.ramdisk)
6868 update_sha(sha, args.second)
69+ update_sha(sha, args.dt)
6970 img_id = pack('32s', sha.digest())
7071
7172 args.output.write(img_id)
@@ -150,6 +151,7 @@ def parse_cmdline():
150151 choices=[2**i for i in range(11,15)], default=2048)
151152 parser.add_argument('--id', help='print the image ID on standard output',
152153 action='store_true')
154+ parser.add_argument('--dt', help='path to the device tree image', type=FileType('rb'))
153155 parser.add_argument('-o', '--output', help='output file name', type=FileType('wb'),
154156 required=True)
155157 return parser.parse_args()
@@ -159,6 +161,7 @@ def write_data(args):
159161 write_padded_file(args.output, args.kernel, args.pagesize)
160162 write_padded_file(args.output, args.ramdisk, args.pagesize)
161163 write_padded_file(args.output, args.second, args.pagesize)
164+ write_padded_file(args.output, args.dt, args.pagesize)
162165
163166
164167 def main():