Skip to content

Commit

Permalink
feat: himax we-1 support (wip) (#2)
Browse files Browse the repository at this point in the history
* chore: cleanup

* feat: himax we-1 support (wip)

* chore: bug fixes

* chore/fix: add missing headers, cleanup

* fix: avoid using C99 style initializer
  • Loading branch information
iChizer0 authored Sep 24, 2023
1 parent b15d4bd commit e07e0f4
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 2 deletions.
5 changes: 4 additions & 1 deletion core/data/el_data_storage.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@
#define _EL_DATA_STORAGE_HPP_

#include <algorithm>
#include <cstdarg>
#include <cstddef>
#include <cstdio>
#include <cstring>
#include <forward_list>
#include <iterator>
Expand All @@ -36,6 +38,7 @@

#include "core/el_config_internal.h"
#include "core/el_debug.h"
#include "core/el_types.h"
#include "core/synchronize/el_guard.hpp"
#include "core/synchronize/el_mutex.hpp"

Expand Down Expand Up @@ -114,7 +117,7 @@ static inline el_storage_kv_t<ValueTypeNoCV> el_make_storage_kv_from_type(VarTyp
static_buffer = it->second;
else {
static_buffer = new char[buffer_size]{}; // we're not going to delete it
std::sprintf(static_buffer, format_str, hash);
std::snprintf(static_buffer, buffer_size, format_str, hash);
hash_list.emplace_front(hash, static_buffer);
}
EL_ASSERT(static_buffer != nullptr);
Expand Down
2 changes: 1 addition & 1 deletion porting/himax/el_flash_himax.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ static int el_flash_db_erase(long offset, size_t size) {

#ifdef CONFIG_EL_LIB_FLASHDB
const struct fal_flash_dev el_flash_db_nor_flash0 = {
{.name = CONFIG_EL_STORAGE_PARTITION_MOUNT_POINT},
.name = CONFIG_EL_STORAGE_PARTITION_MOUNT_POINT,
//0x200000 is the flash size of himax6538, 0x10000 is the data size for flashdb
.addr = (0x200000 - 0x10000),
.len = 0x10000,
Expand Down
1 change: 1 addition & 0 deletions sscma/callback/invoke.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#include <sstream>
#include <string>

#include "internal/algorithm_config_helper.hpp"
#include "sscma/definations.hpp"
#include "sscma/static_resourse.hpp"
#include "sscma/utility.hpp"
Expand Down
5 changes: 5 additions & 0 deletions sscma/repl/server.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
#include <forward_list>
#include <functional>
#include <sstream>
#include <stack>
#include <string>
#include <utility>
#include <vector>
Expand Down Expand Up @@ -77,6 +78,10 @@ struct repl_cmd_t {

namespace sscma::repl {

using namespace edgelab;

using namespace sscma::types;

class Server {
public:
Server() : _cmd_list_lock(), _exec_lock(), _is_ctrl(false), _line_index(-1) {
Expand Down

0 comments on commit e07e0f4

Please sign in to comment.