Skip to content

Commit

Permalink
Minerva working yaay!!
Browse files Browse the repository at this point in the history
  • Loading branch information
Guillem96 committed Dec 29, 2018
1 parent 2dc2bba commit 63ef61b
Show file tree
Hide file tree
Showing 18 changed files with 1,620 additions and 59 deletions.
3 changes: 2 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,14 @@ OBJS = $(addprefix $(BUILD)/$(TARGET)/, \
gui_menu_entry.o \
gui_menu_pool.o \
payloads.o \
sys_sdrammtc.o \
minerva.o \
ianos.o \
)

OBJS += $(addprefix $(BUILD)/$(TARGET)/, \
lz.o blz.o \
diskio.o ff.o ffunicode.o ffsystem.o \
elfload.o elfreloc_arm.o \
)

ARCH := -march=armv4t -mtune=arm7tdmi -mthumb -mthumb-interwork
Expand Down
55 changes: 55 additions & 0 deletions include/ianos/ianos.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
/*
* Copyright (c) 2018 M4xw
* Copyright (c) 2018 CTCaer
*
* This program is free software; you can redistribute it and/or modify it
* under the terms and conditions of the GNU General Public License,
* version 2, as published by the Free Software Foundation.
*
* This program is distributed in the hope it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/

#ifndef IANOS_H
#define IANOS_H

#include <stddef.h>

#include "utils/types.h"
#include "mem/heap.h"
#include "gfx/gfx.h"

typedef enum
{
DRAM_LIB = 0, // DRAM library.
EXEC_ELF = 1, // Executable elf that does not return.
DR64_LIB = 2, // AARCH64 DRAM library.
AR64_ELF = 3, // Executable elf that does not return.
KEEP_IN_RAM = (1 << 31) // Shared library mask.
} elfType_t;

// Module Callback
typedef void (*cbMainModule_t)(const char *s);
typedef void (*memcpy_t)(void *, void *, size_t);
typedef void (*memset_t)(void *, int, size_t);

typedef struct _bdkParams_t
{
gfx_con_t *gfxCon;
gfx_ctxt_t *gfxCtx;
heap_t *sharedHeap;
memcpy_t memcpy;
memset_t memset;
} *bdkParams_t;

// Module Entrypoint
typedef void (*moduleEntrypoint_t)(void *, bdkParams_t);

int ianos_loader(bool sdmount, char *path, elfType_t type, void* config);

#endif
Loading

0 comments on commit 63ef61b

Please sign in to comment.