Simon Glass | 56385c5 | 2022-02-08 11:49:59 -0700 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0+ |
2 | /* | ||||
3 | * Copyright 2022 Google LLC | ||||
4 | * | ||||
5 | * Program containing two text sections | ||||
6 | */ | ||||
7 | |||||
8 | int __attribute__((section(".sram_data"))) data[29]; | ||||
9 | |||||
10 | int __attribute__((section(".sram_code"))) calculate(int x) | ||||
11 | { | ||||
12 | data[0] = x; | ||||
13 | |||||
14 | return x * x; | ||||
15 | } | ||||
16 | |||||
17 | int main(void) | ||||
18 | { | ||||
19 | return calculate(123); | ||||
20 | } |