Skip to content

Commit 7cc90a8

Browse files
committed
Add README & LICENSE Files.
Also add missing author in main.c
1 parent 8b9363e commit 7cc90a8

File tree

3 files changed

+51
-2
lines changed

3 files changed

+51
-2
lines changed

LICENSE.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2024 - 2025 woa-msmnile authors
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# XCReader
2+
3+
## Introduction
4+
5+
QC starts using a new format of XBL config since 8450 platforms. The new format designed for it is to store some
6+
important configurations like `XBL DTB`, `CPR`, and `DCB`.
7+
This tool is aim to extract those files from the XBL config.
8+
:::tip
9+
This tool only works on SM8450 and subsequent platforms.
10+
:::
11+
12+
## How to use
13+
14+
- Just run it in a terminal will be fine.
15+
- xbl_config.img is also acceptable.
16+
17+
```
18+
Usage: <Path to xbl_config.elf> <Output Directory>
19+
```
20+
21+
## Build
22+
- Need cmake and C toolchain.
23+
```
24+
git clone https://github.com/woa-msmnile/XBLConfigReader --depth=1
25+
cd XBLConfigReader
26+
mkdir build && cd build
27+
cmake -S .. && cmake --build .
28+
```

main.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
// Entry
1010
int main(int argc, char *argv[]) {
1111
printf("XBLConfigParser Version %s\n", PARSER_VERSION);
12-
printf("Copyright (c) 2024-2025 \n\n");
12+
printf("Copyright (c) 2024-2025 woa-msmnile authors\n\n");
1313

1414
// Check args
1515
if (argc != 3) {
@@ -40,7 +40,7 @@ int main(int argc, char *argv[]) {
4040

4141
// Print ELF header info
4242
printf("ELF Header Information:\n");
43-
printf("ELF Magic: 0x%016llx 0x%016llx\n", *(uint64_t *) hdr->e_ident, *(uint64_t *) (hdr->e_ident + 8));
43+
printf("ELF Magic: 0x%016llx 0x%016llx\n", (uint64_t) hdr->e_ident, (uint64_t) (hdr->e_ident + 8));
4444
printf("Program Header Offset: 0x0%llx\n", hdr->e_phoff);
4545
printf("Program Header Numbers: 0x%x\n", hdr->e_phnum);
4646
printf("Program Header Size: 0x%x\n", hdr->e_phentsize);

0 commit comments

Comments
 (0)