mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-23 02:05:57 +01:00
qemu-baremetal-cli-args
QEMU part done https://github.com/cirosantilli/linux-kernel-module-cheat/issues/67
This commit is contained in:
@@ -56,23 +56,13 @@ Build the baremetal examples with crosstool-NG.
|
||||
'-mfpu=crypto-neon-fp-armv8', LF,
|
||||
])
|
||||
if self.env['emulator'] == 'gem5':
|
||||
if self.env['machine'] == 'VExpress_GEM5_V1':
|
||||
entry_address = 0x80000000
|
||||
uart_address = 0x1c090000
|
||||
elif self.env['machine'] == 'RealViewPBX':
|
||||
entry_address = 0x10000
|
||||
uart_address = 0x10009000
|
||||
else:
|
||||
raise Exception('unknown machine: ' + self.env['machine'])
|
||||
cc_flags.extend([
|
||||
'-DLKMC_GEM5=1', LF,
|
||||
'-DLKMC_M5OPS_ENABLE=1', LF,
|
||||
])
|
||||
else:
|
||||
entry_address = 0x40000000
|
||||
uart_address = 0x09000000
|
||||
cc_flags.extend(['-D', 'LKMC_QEMU=1', LF])
|
||||
cc_flags.extend(['-D', 'LKMC_UART0_ADDR={:#x}'.format(uart_address), LF])
|
||||
cc_flags.extend(['-D', 'LKMC_UART0_ADDR={:#x}'.format(self.env['uart_address']), LF])
|
||||
cc_flags.extend(self.sh.shlex_split(self.env['ccflags']))
|
||||
bootloader_src = os.path.join(
|
||||
self.env['baremetal_source_lib_dir'],
|
||||
@@ -101,8 +91,8 @@ Build the baremetal examples with crosstool-NG.
|
||||
link=False,
|
||||
)
|
||||
cc_flags.extend([
|
||||
'-Wl,--section-start=.text={:#x}'.format(entry_address), LF,
|
||||
'-Wl,--section-start=.lkmc_memory={:#x}'.format(entry_address + 0x1000000), LF,
|
||||
'-Wl,--section-start=.text={:#x}'.format(self.env['entry_address']), LF,
|
||||
'-Wl,--section-start=.lkmc_memory={:#x}'.format(self.env['entry_address'] + 0x1000000), LF,
|
||||
'-T', self.env['baremetal_link_script'], LF,
|
||||
])
|
||||
with thread_pool.ThreadPool(
|
||||
|
||||
Reference in New Issue
Block a user