message
stringlengths 6
474
| diff
stringlengths 8
5.22k
|
---|---|
Added vendor ThinkTech:172 | <xs:enumeration value="Synwit:144" />
<xs:enumeration value="TI:16" />
<xs:enumeration value="Texas Instruments:16" />
+ <xs:enumeration value="ThinkTech:172" />
<xs:enumeration value="Toshiba:92" />
<xs:enumeration value="Triad Semiconductor:104" />
<xs:enumeration value="Unisoc:152" />
|
config: handle empty conf file
Allow the command to complete using default internal configurations.
Print an error message that indicates the file is invalid.
For linux, specify the location of the default configuration. | @@ -33,6 +33,11 @@ function
*/
static dictionary *p_g_dictionary = NULL;
+/**
+@brief global to detect if any preferences were modified
+*/
+static BOOLEAN g_modified_config = FALSE;
+
/**
@brief The default ini file content defined by the ipmctl_default.conf file
*/
@@ -204,6 +209,8 @@ dictionary *nvm_ini_load_dictionary(const char *p_ini_file_name)
return p_g_dictionary;
}
+ g_modified_config = FALSE;
+
// Try to open the file
snprintf(g_ini_path_filename, sizeof (g_ini_path_filename), "%s", p_ini_file_name);
h_file = fopen(g_ini_path_filename, "r");
@@ -284,6 +291,23 @@ dictionary *nvm_ini_load_dictionary(const char *p_ini_file_name)
p_g_dictionary->numb_of_entries += 1;
}
+ // handle special case with empty file
+ if (p_g_dictionary == NULL) {
+ wprintf(L"Error: Could not parse configuration file: %hs\n", g_ini_path_filename);
+#if defined(__LINUX__)
+ wprintf(L"The default configuration can be found here: /usr/share/doc/ipmctl/ipmctl_default.conf\n");
+#else
+ wprintf(L"The default configuration can be found here: ipmctl_default.conf\n");
+#endif
+ // create an empty dictionary so the command will run with default configuration
+ p_g_dictionary = (dictionary *)calloc(1, sizeof(dictionary));
+ if (NULL == p_g_dictionary) {
+ // Close the file
+ fclose(h_file);
+ return NULL;
+ }
+ }
+
// Close the file
fclose(h_file);
@@ -360,8 +384,13 @@ int nvm_ini_set_value(dictionary *p_dictionary, const char *p_key, const char *p
p_key_value = nvm_dictionary_get_set_value(p_dictionary, p_key, p_value);
if (NULL == p_key_value) {
+ wprintf(L"Error: Could not find preference in configuration file: %hs\n", g_ini_path_filename);
return -1;
}
+
+ // set global that the config has been modified
+ g_modified_config = TRUE;
+
return 0;
}
@@ -380,6 +409,12 @@ int nvm_ini_dump_to_file(dictionary *p_dictionary, const char *p_ini_file_name)
return -1;
}
+ // nothing to do if no entries or no modified values
+ if ((p_dictionary->numb_of_entries == 0) ||
+ (!g_modified_config)) {
+ return 0;
+ }
+
// Open and truncated the file
if (0 == *g_ini_path_filename) {
h_file = fopen(p_ini_file_name, "w");
|
Add AgentMcguffin to data.yml | @@ -3811,6 +3811,10 @@ classes:
vtbls:
- ea: 0x1418CB4F8
base: Client::UI::Agent::AgentInterface
+ Client::UI::Agent::AgentMcguffin:
+ vtbls:
+ - ea: 0x141843578
+ base: Client::UI::Agent::AgentInterface
Client::Game::Event::EventHandler:
vtbls:
- ea: 0x141796A20
|
Jenkinsfile: Fix test filter issue for windows
The test filter from automation.get-test-selection didn't propagate correctly
to the Test stage. This resultet in that no tests were run for Windows instance. | @@ -168,7 +168,7 @@ def testPipeline(instance_str, json_entry, subst_dir, filter) {
dir("${abs_instance_workdir}") {
ansiColor('xterm') {
// Check if there is a test filter
- def filter_arg = filter ? "--filter \"${json_entry.filter}\"" : ""
+ def filter_arg = filter ? "--filter \"${filter}\"" : ""
bat "inv -r ${abs_ubxlib_dir}/${pyTasks_subdir} automation.test ${test_report_arg} ${filter_arg} ${instance_str}"
}
}
|
Fix issue with merging branch 'master' into interpose_polish | @@ -183,7 +183,7 @@ transportSend(transport_t* t, const char* msg)
switch (t->type) {
case CFG_UDP:
if (t->udp.sock != -1) {
- int rc = t->send(t->udp.sock, msg, strlen(msg), 0);
+ int rc = send(t->udp.sock, msg, strlen(msg), 0);
if (rc < 0) {
switch (errno) {
case EWOULDBLOCK:
|
Update windows build instructions #no_auto_pr | @@ -256,10 +256,13 @@ make dist-python PYPI_USERNAME=swiftnav PYPI_PASSWORD=...
## Building on Windows
In order to build on Windows, first install the necessary compilers per the
-instructions [on this Microsoft developer blog][1] install the 64-bit Python
-3.7 version of [Conda][2]. You'll also need to install [Chocolatey][3].
+instructions [on this Microsoft developer blog][1] (shortcut: install
+[Microsoft Visual C++ Build Tools][vcbt]) then install the 64-bit
+Python 3.7 version of [Conda][2]. You'll also need to install
+[Chocolatey][3].
[1]: https://devblogs.microsoft.com/python/unable-to-find-vcvarsall-bat/
+[vcbt]: https://www.microsoft.com/en-us/download/details.aspx?id=48159
[2]: https://docs.conda.io/en/latest/miniconda.html
[3]: https://chocolatey.org/docs/installation
|
There's nothing that can be done when exec fails. | @@ -87,7 +87,7 @@ const filterfd = {fd, cmd
}
const sporkfd = {cmd, infds, outfds, errfds
- var pid, err
+ var pid
pid = fork()
/* error */
@@ -132,12 +132,9 @@ const sporkfd = {cmd, infds, outfds, errfds
close(outfds[0])
close(errfds[0])
- err = execvp(cmd[0], cmd)
- if err != Enone
- -> `Err err
- ;;
+ execvp(cmd[0], cmd)
/* if fork succeeds, we never return */
- die("unreachable")
+ die("exec failed")
/* parent */
else
-> `Ok pid
|
add code to unfuck rpms | @@ -63,6 +63,17 @@ debian_copy_output() {
mv ../${PACKAGE_DIR}[_-]* $OUTPUT/$DIST
mv ../lib* $OUTPUT/$DIST
}
+
+rpm_unfuck_source_tarball_location() {
+ cat rpm/oidc-agent.spec \
+ | grep -v ^Source \
+ > rpm/oidc-agent.spec.bckp
+ VERSION=`head debian/changelog -n 1|cut -d \( -f 2|cut -d \) -f 1|cut -d \- -f 1`
+ RELEASE=`head debian/changelog -n 1|cut -d \( -f 2|cut -d \) -f 1|cut -d \- -f 2`
+ sed "s/#DO_NOT_REPLACE_THIS_LINE/Source0: oidc-agent-${VERSION}.tar.gz/" -i rpm/oidc-agent.spec.bckp
+ rm -f rpm/oidc-agent.spec
+ mv rpm/oidc-agent.spec.bckp rpm/oidc-agent.spec
+}
rpm_build_package() {
cd /tmp/build/$PACKAGE_DIR
make rpmsource
@@ -97,10 +108,12 @@ case "$DIST" in
debian_copy_output
;;
centos_8|centos_7|fedora*)
+ rpm_unfuck_source_tarball_location
rpm_build_package
rpm_copy_output
;;
opensuse_15*|opensuse_tumbleweed|sle*)
+ rpm_unfuck_source_tarball_location
rpm_build_package
rpm_copy_output
;;
|
build: Dockerfile: add new parsers | @@ -28,8 +28,15 @@ RUN cmake -DFLB_DEBUG=On \
-DFLB_OUT_KAFKA=On ..
RUN make
RUN install bin/fluent-bit /fluent-bit/bin/
+
# Configuration files
-COPY conf/fluent-bit.conf conf/parsers.conf conf/parsers_java.conf /fluent-bit/etc/
+COPY conf/fluent-bit.conf \
+ conf/parsers.conf \
+ conf/parsers_java.conf \
+ conf/parsers_mult.conf \
+ conf/parsers_openstack.conf \
+ conf/parsers_cinder.conf \
+ /fluent-bit/etc/
FROM gcr.io/google-containers/debian-base-amd64:0.3
MAINTAINER Eduardo Silva <[email protected]>
|
Small whitespace changes for consistency | @@ -612,9 +612,7 @@ local function generate_lua_entry_point(tl_node)
local nargs = ctx:new_cvar("int", "nargs")
local check_nargs = util.render([[
${NARGS_DECL} = cast_int(L->top - (${BASE} + 1));
- if (${NARGS} != ${EXPECTED}) {
- titan_runtime_arity_error(L, ${EXPECTED}, ${NARGS});
- }
+ if (${NARGS} != ${EXPECTED}) { titan_runtime_arity_error(L, ${EXPECTED}, ${NARGS}); }
]], {
BASE = base.name,
NARGS = nargs.name,
@@ -636,11 +634,7 @@ local function generate_lua_entry_point(tl_node)
local slot = ctx:new_cvar("TValue*")
table.insert(check_types, util.render([[
${SLOT_DECL} = ${SLOT_ADDRESS};
- if (!${CHECK_TAG}) {
- titan_runtime_argument_type_error(
- L, ${PARAM_NAME}, ${LINE}, ${EXPECTED_TAG}, ${SLOT_NAME}
- );
- }
+ if (!${CHECK_TAG}) { titan_runtime_argument_type_error(L, ${PARAM_NAME}, ${LINE}, ${EXPECTED_TAG}, ${SLOT_NAME}); }
]], {
SLOT_NAME = slot.name,
SLOT_DECL = c_declaration(slot),
@@ -1502,11 +1496,7 @@ generate_exp = function(exp, ctx)
retval = ret.name
table.insert(body, util.render([[
${SLOT_DECL} = s2v(L->top-1);
- if (!${CHECK_TAG}) {
- titan_runtime_function_return_error(
- L, ${LINE}, ${EXPECTED_TAG}, ${SLOT}
- );
- }
+ if (!${CHECK_TAG}) { titan_runtime_function_return_error(L, ${LINE}, ${EXPECTED_TAG}, ${SLOT}); }
${RET_DECL} = ${GET_SLOT};
L->top--;
]], {
|
level0: disable with LLVM 15+, causes too many compilation failures | @@ -1592,6 +1592,10 @@ if (ENABLE_LEVEL0)
endif()
pkg_check_modules(LEVEL0 REQUIRED level-zero>=1.3)
+ if(NOT LLVM_VERSION LESS "15.0")
+ message(FATAL_ERROR "Level Zero requires LLVM/Clang older than 15; llvm-spirv translator breaks often with 15+ ")
+ endif()
+
if (NOT LEVEL0_FOUND)
message(STATUS "Could not find level-zero via pkg-config, trying to find it directly")
find_library(LEVEL0_LIBRARIES NAMES ze_loader REQUIRED)
|
Wrap TTL expiration in TRY/CATCH instead of allowing reaper to exit on error | @@ -253,10 +253,13 @@ ContinuousQueryReaperMain(void)
for (;;)
{
int deleted = 0;
+ bool error = false;
StartTransactionCommand();
SetCurrentStatementStartTimestamp();
+ PG_TRY();
+ {
ttl_rels = get_ttl_rels(&min_sleep);
foreach(lc, ttl_rels)
@@ -282,13 +285,28 @@ ContinuousQueryReaperMain(void)
set_last_expiration(relid, deleted);
}
}
+ }
+ PG_CATCH();
+ {
+ EmitErrorReport();
+ FlushErrorState();
+
+ error = true;
+
+ if (ActiveSnapshotSet())
+ PopActiveSnapshot();
+
+ AbortCurrentTransaction();
+ StartTransactionCommand();
+ }
+ PG_END_TRY();
CommitTransactionCommand();
/*
* If nothing was deleted on this run, we're done for now
*/
- if (!deleted)
+ if (error || !deleted)
break;
}
|
interface: braces around if statements | @@ -55,8 +55,9 @@ class GcpManager {
}
restart() {
- if (this.#running)
+ if (this.#running) {
this.stop();
+ }
this.start();
}
@@ -105,8 +106,9 @@ class GcpManager {
}
private refreshAfter(durationMs) {
- if (!this.#running)
+ if (!this.#running) {
return;
+ }
if (this.#timeoutId !== null) {
console.warn('GcpManager already has a timeout set');
return;
|
tests: fix test_control_event_serialize
commit changed the protocol, fix the related testing case. | @@ -87,13 +87,13 @@ static void test_serialize_mouse_event(void) {
unsigned char buf[SERIALIZED_EVENT_MAX_SIZE];
int size = control_event_serialize(&event, buf);
- assert(size == 14);
+ assert(size == 18);
const unsigned char expected[] = {
0x02, // CONTROL_EVENT_TYPE_MOUSE
0x00, // AKEY_EVENT_ACTION_DOWN
0x00, 0x00, 0x00, 0x01, // AMOTION_EVENT_BUTTON_PRIMARY
- 0x01, 0x04, 0x04, 0x02, // 260 1026
+ 0x00, 0x00, 0x01, 0x04, 0x00, 0x00, 0x04, 0x02, // 260 1026
0x04, 0x38, 0x07, 0x80, // 1080 1920
};
assert(!memcmp(buf, expected, sizeof(expected)));
@@ -120,11 +120,11 @@ static void test_serialize_scroll_event(void) {
unsigned char buf[SERIALIZED_EVENT_MAX_SIZE];
int size = control_event_serialize(&event, buf);
- assert(size == 17);
+ assert(size == 21);
const unsigned char expected[] = {
0x03, // CONTROL_EVENT_TYPE_SCROLL
- 0x01, 0x04, 0x04, 0x02, // 260 1026
+ 0x00, 0x00, 0x01, 0x04, 0x00, 0x00, 0x04, 0x02, // 260 1026
0x04, 0x38, 0x07, 0x80, // 1080 1920
0x00, 0x00, 0x00, 0x01, // 1
0xFF, 0xFF, 0xFF, 0xFF, // -1
|
common/keyboard_mkbp.c: Format with clang-format
BRANCH=none
TEST=none | @@ -47,8 +47,9 @@ struct ec_mkbp_protocol_config {
static struct ec_mkbp_protocol_config config = {
.valid_mask = EC_MKBP_VALID_SCAN_PERIOD | EC_MKBP_VALID_POLL_TIMEOUT |
EC_MKBP_VALID_MIN_POST_SCAN_DELAY |
- EC_MKBP_VALID_OUTPUT_SETTLE | EC_MKBP_VALID_DEBOUNCE_DOWN |
- EC_MKBP_VALID_DEBOUNCE_UP | EC_MKBP_VALID_FIFO_MAX_DEPTH,
+ EC_MKBP_VALID_OUTPUT_SETTLE |
+ EC_MKBP_VALID_DEBOUNCE_DOWN | EC_MKBP_VALID_DEBOUNCE_UP |
+ EC_MKBP_VALID_FIFO_MAX_DEPTH,
.valid_flags = EC_MKBP_FLAGS_ENABLE,
.flags = EC_MKBP_FLAGS_ENABLE,
.fifo_max_depth = FIFO_DEPTH,
@@ -81,7 +82,8 @@ static int keyboard_get_next_event(uint8_t *out)
DECLARE_EVENT_SOURCE(EC_MKBP_EVENT_KEY_MATRIX, keyboard_get_next_event);
void clear_typematic_key(void)
-{ }
+{
+}
static void set_keyscan_config(const struct ec_mkbp_config *src,
struct ec_mkbp_protocol_config *dst,
@@ -158,8 +160,7 @@ static void keyscan_copy_config(const struct ec_mkbp_config *src,
if (valid_mask & EC_MKBP_VALID_FIFO_MAX_DEPTH) {
/* Validity check for fifo depth */
- dst->fifo_max_depth = MIN(src->fifo_max_depth,
- FIFO_DEPTH);
+ dst->fifo_max_depth = MIN(src->fifo_max_depth, FIFO_DEPTH);
}
new_flags = dst->flags & ~valid_flags;
@@ -182,8 +183,7 @@ host_command_mkbp_set_config(struct host_cmd_handler_args *args)
return EC_RES_SUCCESS;
}
-DECLARE_HOST_COMMAND(EC_CMD_MKBP_SET_CONFIG,
- host_command_mkbp_set_config,
+DECLARE_HOST_COMMAND(EC_CMD_MKBP_SET_CONFIG, host_command_mkbp_set_config,
EC_VER_MASK(0));
static enum ec_status
@@ -206,6 +206,5 @@ host_command_mkbp_get_config(struct host_cmd_handler_args *args)
return EC_RES_SUCCESS;
}
-DECLARE_HOST_COMMAND(EC_CMD_MKBP_GET_CONFIG,
- host_command_mkbp_get_config,
+DECLARE_HOST_COMMAND(EC_CMD_MKBP_GET_CONFIG, host_command_mkbp_get_config,
EC_VER_MASK(0));
|
drv2605 shell: remove the non-existent load_rtp command from help | @@ -76,7 +76,6 @@ drv2605_shell_help(void)
console_printf("\tchip_id\n");
console_printf("\tload_cal [brake_factor loop_gain lra_sample_time lra_blanking_time lra_idiss_time auto_cal_time lra_zc_det_time]\n");
console_printf("\tload_rom [up to 8 uint8_t]\n");
- console_printf("\tload_rtp [uint8_t]\n");
console_printf("\top_mode [reset | rom | pwm | analog | rtp | diag | cal]\n");
console_printf("\tpower_mode [deep | standby | active]\n");
console_printf("\ttrigger\n");
|
Update Changelog for 0.3.17 | OpenBLAS ChangeLog
====================================================================
+Version 0.3.17
+ 15-Jul-2021
+
+common:
+ - reverted the optimization of SGEMV_N/DGEMV_N for small input sizes
+ and consecutive arguments as it led to stack overflows on x86_64
+ with some operating systems (notably OSX and Windows)
+
+ x86_64:
+ - reverted the performance patch for SGEMV_T on AVX512 as it caused
+ wrong results in some applications
+
+ SPARC:
+ - fixed compilation with compilers other than gcc
+====================================================================
Version 0.3.16
11-Jul-2021
|
Update readme for .NET 6 | @@ -28,7 +28,7 @@ For general questions visit the [Discussions Area](https://github.com/coinfoundr
### Linux: pre-built binaries
-- Install [.NET 5 Runtime](https://dotnet.microsoft.com/download/dotnet/5.0)
+- Install [.NET 6 Runtime](https://dotnet.microsoft.com/download/dotnet/6.0)
- For Debian/Ubuntu, install these packages
- `postgresql-11` (or higher, the higher the better)
- `libzmq5`
@@ -42,7 +42,7 @@ For general questions visit the [Discussions Area](https://github.com/coinfoundr
### Windows: pre-built binaries
-- Install [.NET 5 Runtime](https://dotnet.microsoft.com/download/dotnet/5.0)
+- Install [.NET 6 Runtime](https://dotnet.microsoft.com/download/dotnet/6.0)
- Install [PostgreSQL Database](https://www.postgresql.org/)
- Download `miningcore-win-x64.zip` from the latest [Release](https://github.com/coinfoundry/miningcore/releases)
- Extract the Archive
@@ -111,25 +111,25 @@ $ sudo dpkg -i packages-microsoft-prod.deb
$ sudo apt-get update
$ sudo apt-get install -y apt-transport-https
$ sudo apt-get update
-$ sudo apt-get -y install dotnet-sdk-5.0 git cmake build-essential libssl-dev pkg-config libboost-all-dev libsodium-dev libzmq5
+$ sudo apt-get -y install dotnet-sdk-6.0 git cmake build-essential libssl-dev pkg-config libboost-all-dev libsodium-dev libzmq5
$ git clone https://github.com/coinfoundry/miningcore
$ cd miningcore/src/Miningcore
-$ dotnet publish -c Release --framework net5.0 -o ../../build
+$ dotnet publish -c Release --framework net6.0 -o ../../build
```
### Building on Windows
-Download and install the [.NET 5 SDK](https://dotnet.microsoft.com/download/dotnet/5.0)
+Download and install the [.NET 6 SDK](https://dotnet.microsoft.com/download/dotnet/6.0)
```dosbatch
> git clone https://github.com/coinfoundry/miningcore
> cd miningcore/src/Miningcore
-> dotnet publish -c Release --framework net5.0 -o ..\..\build
+> dotnet publish -c Release --framework net6.0 -o ..\..\build
```
### Building on Windows - Visual Studio
-- Install [Visual Studio 2019](https://www.visualstudio.com/vs/). Visual Studio Community Edition is fine.
+- Install [Visual Studio 2022](https://www.visualstudio.com/vs/). Visual Studio Community Edition is fine.
- Open `Miningcore.sln` in Visual Studio
|
Remove notifications and format check from CI
The code isn't formatted in _main_ of all places anyway, so it
effectively blocks every commit. | @@ -34,10 +34,4 @@ script:
- make
- cd $TRAVIS_BUILD_DIR
- python ./scripts/check_manfile.py
- - ./checkFormat.sh
compiler: clang
-notifications:
- email:
- - [email protected]
- slack:
- secure: gLiX4zUhlYMJ0l7kJlb5Wf5CmAynj+WQufThSBPP7XlLZddl6Vql72sJuqwl1ZV75xEsqP05QDulBMJc9AaED7BP53vhngHHgWLwjt026ne5sbA/s98U735jT/qwwFvKWBCYPZ5BQdTmJO3KCyuBJH+tQnptiolog9abksG1WZk=
|
Add virtual dtor to the base class | @@ -36,6 +36,8 @@ namespace ebi
public:
virtual std::string sequence(const std::string& contig, const size_t pos, const size_t length) = 0;
virtual size_t count(const std::string& contig) const = 0;
+
+ virtual ~IFasta(){}
};
class FileBasedFasta : public IFasta
|
pyocf: implement test_cleaner_disabled_nop | import pytest
from pyocf.types.volume import RamVolume
-from pyocf.types.cache import Cache, CacheMetadataSegment
+from pyocf.types.cache import Cache, CacheMetadataSegment, CleaningPolicy
from pyocf.types.core import Core
from pyocf.types.shared import OcfError, OcfCompletion
from pyocf.utils import Size as S
@@ -103,7 +103,6 @@ def test_load_cleaner_disabled(pyocf_ctx):
[email protected](reason="not implemented")
def test_cleaner_disabled_nop(pyocf_ctx):
"""
title: NOP enfocement in cleaner_disabled mode..
@@ -126,7 +125,29 @@ def test_cleaner_disabled_nop(pyocf_ctx):
- disable_cleaner::starting_with_nop_policy
- disable_cleaner::nop_enforcement
"""
- pass
+ cache_device = RamVolume(S.from_MiB(50))
+
+ cache = Cache.start_on_device(cache_device, disable_cleaner=True)
+
+ assert cache.get_cleaning_policy() == CleaningPolicy.NOP, (
+ "Cleaning policy should be NOP after starting cache with disabled cleaner"
+ )
+
+ with pytest.raises(OcfError):
+ cache.set_cleaning_policy(CleaningPolicy.ALRU)
+
+ assert cache.get_cleaning_policy() == CleaningPolicy.NOP, (
+ "It shouldn't be possible to switch cleaning policy to ALRU when cleaner is disabled"
+ )
+
+ with pytest.raises(OcfError):
+ cache.set_cleaning_policy(CleaningPolicy.ACP)
+
+ assert cache.get_cleaning_policy() == CleaningPolicy.NOP, (
+ "It shouldn't be possible to switch cleaning policy to ACP when cleaner is disabled"
+ )
+
+ cache.set_cleaning_policy(CleaningPolicy.NOP)
@pytest.mark.skip(reason="not implemented")
|
Fix PhGetProcessPackageFullName string comparison | @@ -379,9 +379,9 @@ PPH_STRING PhGetProcessPackageFullName(
{
PTOKEN_SECURITY_ATTRIBUTE_V1 attribute = &info->Attribute.pAttributeV1[i];
- if (RtlEqualUnicodeString(&attribute->Name, &attributeNameUs, FALSE))
- {
if (attribute->ValueType == TOKEN_SECURITY_ATTRIBUTE_TYPE_STRING)
+ {
+ if (RtlEqualUnicodeString(&attribute->Name, &attributeNameUs, FALSE))
{
packageName = PhCreateStringFromUnicodeString(&attribute->Values.pString[0]);
break;
|
netutil/ifconfig: enable ipv6 autoconfig
enable ipv6 autoconfig option.
it is disabled by default.
so user uses "ifconfig <interface_name> auto" this command,
it will enable the autoconfig option on that interface and
generate the link-local ipv6 address by autoconfig | @@ -273,6 +273,32 @@ int cmd_ifconfig(int argc, char **argv)
ndbg("DHCPC Mode\n");
gip = addr.s_addr = 0;
+ netlib_set_ipv4addr(intf, &addr);
+#ifdef CONFIG_NET_IPv6
+ } else if (!strcmp(hostip, "auto")) {
+ /* IPV6 auto configuration : Link-Local address */
+
+ ndbg("IPV6 link local address auto config\n");
+ netif = netif_find(intf);
+
+ if (netif) {
+ netif_set_ip6_autoconfig_enabled(netif, 1);
+
+ /* To auto-config linklocal address, netif should have mac address already */
+ netif_create_ip6_linklocal_address(netif, 1);
+ ndbg("generated IPV6 linklocal address - %X : %X : %X : %X\n", PP_HTONL(ip_2_ip6(&netif->ip6_addr[0])->addr[0]), PP_HTONL(ip_2_ip6(&netif->ip6_addr[0])->addr[1]), PP_HTONL(ip_2_ip6(&netif->ip6_addr[0])->addr[2]), PP_HTONL(ip_2_ip6(&netif->ip6_addr[0])->addr[3]));
+#ifdef CONFIG_NET_IPv6_MLD
+ ip6_addr_t solicit_addr;
+
+ /* set MLD6 group to receive solicit multicast message */
+ ip6_addr_set_solicitednode(&solicit_addr, ip_2_ip6(&netif->ip6_addr[0])->addr[3]);
+ mld6_joingroup_netif(netif, &solicit_addr);
+ ndbg("MLD6 group added - %X : %X : %X : %X\n", PP_HTONL(solicit_addr.addr[0]), PP_HTONL(solicit_addr.addr[1]), PP_HTONL(solicit_addr.addr[2]), PP_HTONL(solicit_addr.addr[3]));
+#endif /* CONFIG_NET_IPv6_MLD */
+ }
+
+ return OK;
+#endif /* CONFIG_NET_IPv6 */
} else {
/* Set host IP address */
ndbg("Host IP: %s\n", hostip);
|
Give proper Dict type hints in crypto_knowledge.py
This prevents a return type error in a later function that uses the
dictionaries here properly typed. | @@ -20,7 +20,7 @@ This module is entirely based on the PSA API.
import enum
import re
-from typing import FrozenSet, Iterable, List, Optional, Tuple
+from typing import FrozenSet, Iterable, List, Optional, Tuple, Dict
from .asymmetric_key_data import ASYMMETRIC_KEY_DATA
@@ -148,7 +148,7 @@ class KeyType:
'PSA_ECC_FAMILY_BRAINPOOL_P_R1': (160, 192, 224, 256, 320, 384, 512),
'PSA_ECC_FAMILY_MONTGOMERY': (255, 448),
'PSA_ECC_FAMILY_TWISTED_EDWARDS': (255, 448),
- }
+ } # type: Dict[str, Tuple[int, ...]]
KEY_TYPE_SIZES = {
'PSA_KEY_TYPE_AES': (128, 192, 256), # exhaustive
'PSA_KEY_TYPE_ARIA': (128, 192, 256), # exhaustive
@@ -162,7 +162,7 @@ class KeyType:
'PSA_KEY_TYPE_PEPPER': (128, 256), # sample
'PSA_KEY_TYPE_RAW_DATA': (8, 40, 128), # sample
'PSA_KEY_TYPE_RSA_KEY_PAIR': (1024, 1536), # small sample
- }
+ } # type: Dict[str, Tuple[int, ...]]
def sizes_to_test(self) -> Tuple[int, ...]:
"""Return a tuple of key sizes to test.
|
spwaterfall: adding last remaining testable pieces | @@ -52,6 +52,14 @@ void autotest_spwaterfall_invalid_config()
// test invalid configurations, default construction
CONTEND_ISNULL(spwaterfallcf_create_default( 0, time))
CONTEND_ISNULL(spwaterfallcf_create_default(nfft, 0))
+
+ // create proper object but test invalid internal configurations
+ spwaterfallcf q = spwaterfallcf_create_default(540, 320);
+
+ CONTEND_INEQUALITY(LIQUID_OK, spwaterfallcf_set_rate(q, -10e6))
+ CONTEND_INEQUALITY(LIQUID_OK, spwaterfallcf_set_commands(q, NULL))
+
+ spwaterfallcf_destroy(q);
}
int testbench_spwaterfallcf_compare(const void * _v0, const void * _v1)
@@ -119,6 +127,7 @@ void autotest_spwaterfall_operation()
spwaterfallcf_print(q);
CONTEND_EQUALITY(spwaterfallcf_get_num_freq(q), 1200);
CONTEND_EQUALITY(spwaterfallcf_get_num_time(q), 0);
+ CONTEND_EQUALITY(spwaterfallcf_get_window_len(q),800);
CONTEND_EQUALITY(spwaterfallcf_get_delay(q), 10);
CONTEND_EQUALITY(spwaterfallcf_get_wtype(q), LIQUID_WINDOW_HAMMING);
|
linux/: use TEMP_FAILURE_RETRY with some restartable funcs | @@ -1054,7 +1054,7 @@ static void arch_traceExitSaveData(run_t* run, pid_t pid) {
}
}
- int fd = open(run->crashFileName, O_WRONLY | O_EXCL | O_CREAT, 0600);
+ int fd = TEMP_FAILURE_RETRY(open(run->crashFileName, O_WRONLY | O_EXCL | O_CREAT, 0600));
if (fd == -1 && errno == EEXIST) {
LOG_I("It seems that '%s' already exists, skipping", run->crashFileName);
return;
|
Added dedicated Gira/Jung modelIDs to button map | ]
},
"instaRemoteMap": {
- "modelids": [],
+ "modelids": ["HS_4f_GJ_1", "WS_4f_J_1", "WS_3f_G_1"],
"map": [
[1, "0x01", "ONOFF", "OFF_WITH_EFFECT", "0", "S_BUTTON_1", "S_BUTTON_ACTION_SHORT_RELEASED", "Off with effect"],
[1, "0x01", "ONOFF", "ON", "0", "S_BUTTON_2", "S_BUTTON_ACTION_SHORT_RELEASED", "On"],
|
expand mq test stack size to fix overstack problem during utest. | @@ -19,8 +19,8 @@ static rt_uint8_t mq_buf[(MSG_SIZE + 4) * MAX_MSGS];
static struct rt_thread mq_send_thread;
static struct rt_thread mq_recv_thread;
-static rt_uint8_t mq_send_stack[512];
-static rt_uint8_t mq_recv_stack[512];
+static rt_uint8_t mq_send_stack[1024];
+static rt_uint8_t mq_recv_stack[1024];
static struct rt_event finish_e;
#define MQSEND_FINISH 0x01
|
Add workaround for issue with selection->search->termination of invisible entries | @@ -3433,6 +3433,10 @@ VOID PhGetSelectedProcessItems(
{
PPH_PROCESS_NODE node = ProcessNodeList->Items[i];
+ // HACK workaround issue with multiple select->search->termination and Searchbox->PhApplyTreeNewFilters (dmex)
+ if (!node->Node.Visible)
+ continue;
+
if (node->Node.Selected)
PhAddItemArray(&array, &node->ProcessItem);
}
|
patch/no-sgx-flc: update the URL of the v33 in-tree Linux SGX driver | There are still non-trivial number of systems without FLC support.
# Prerequisite
-- Apply the patch `0001-sgx-Support-SGX1-machine-even-without-FLC-support.patch` to [v33 SGX in-tree driver](https://github.com/jsakkine-intel/linux-sgx/tree/v33).
+- Apply the patch `0001-sgx-Support-SGX1-machine-even-without-FLC-support.patch` to [v33 SGX in-tree driver](https://github.com/haitaohuang/linux-sgx-2/tree/v33).
- Apply the patch `0001-psw-Support-SGX1-machine-with-SGX-in-tree-driver.patch` to [Intel SGX SDK 2.10](https://github.com/intel/linux-sgx/tree/sgx_2.10) or higher.
# Validation
|
core/minute-ia/include/fpu.h: Format with clang-format
BRANCH=none
TEST=none | @@ -20,11 +20,7 @@ static inline float sqrtf(float v)
float root;
/* root = fsqart (v); */
- asm volatile(
- "fsqrt"
- : "=t" (root)
- : "0" (v)
- );
+ asm volatile("fsqrt" : "=t"(root) : "0"(v));
return root;
}
@@ -34,11 +30,7 @@ static inline float fabsf(float v)
float root;
/* root = fabs (v); */
- asm volatile(
- "fabs"
- : "=t" (root)
- : "0" (v)
- );
+ asm volatile("fabs" : "=t"(root) : "0"(v));
return root;
}
@@ -51,8 +43,7 @@ static inline float logf(float v)
{
float res;
- asm volatile(
- "fldln2\n"
+ asm volatile("fldln2\n"
"fxch\n"
"fyl2x\n"
: "=t"(res)
@@ -70,8 +61,7 @@ static inline float expf(float v)
{
float res;
- asm volatile(
- "fldl2e\n"
+ asm volatile("fldl2e\n"
"fmulp\n"
"fld %%st(0)\n"
"frndint\n"
@@ -97,8 +87,7 @@ static inline float powf(float x, float y)
{
float res;
- asm volatile(
- "fyl2x\n"
+ asm volatile("fyl2x\n"
"fld %%st(0)\n"
"frndint\n"
"fsub %%st,%%st(1)\n"
@@ -128,8 +117,7 @@ static inline float ceilf(float v)
asm volatile("fnstcw %0" : "=m"(control_word));
/* Set Rounding Mode to 10B, round up toward +infinity */
control_word_tmp = (control_word | 0x0800) & 0xfbff;
- asm volatile(
- "fld %3\n"
+ asm volatile("fld %3\n"
"fldcw %1\n"
"frndint\n"
"fldcw %2"
@@ -154,8 +142,7 @@ static inline float atanf(float v)
{
float res;
- asm volatile(
- "fld1\n"
+ asm volatile("fld1\n"
"fpatan\n"
: "=t"(res)
: "0"(v));
|
wsman-libxml2-binding: xml_parser_ns_find() fix possible node NULL dereferencing | @@ -430,7 +430,7 @@ xml_parser_ns_find(WsXmlNodeH node,
xmlNode = xmlNode->parent;
}
- if (xmlNs == NULL && bAddAtRootIfNotFound) {
+ if (node != NULL && xmlNs == NULL && bAddAtRootIfNotFound) {
xmlNodePtr xmlRoot =
xmlDocGetRootElement(((xmlDocPtr) node)->doc);
char buf[12];
|
Fix bug in cdc_peek | @@ -209,7 +209,7 @@ static inline void tud_cdc_read_flush (void)
static inline bool tud_cdc_peek (uint8_t* u8)
{
- return tud_cdc_n_peek(u8);
+ return tud_cdc_n_peek(0, u8);
}
static inline uint32_t tud_cdc_write_char (char ch)
|
Coder: fix handling of float literals in 'for' | @@ -368,21 +368,23 @@ local function codefor(ctx, node)
local ilit = node2literal(node.inc)
if ilit then
if ilit > 0 then
- subs.ILIT = c_integer_literal(ilit)
local tmpl
if types.equals(node.decl._type, types.Integer) then
+ subs.ILIT = c_integer_literal(ilit)
tmpl = "$CVAR = l_castU2S(l_castS2U($CVAR) + $ILIT)"
else
+ subs.ILIT = c_float_literal(ilit)
tmpl = "$CVAR += $ILIT"
end
cstep = output(tmpl, subs)
ccmp = output("$CVAR <= _forlimit", subs)
else
- subs.NEGILIT = c_integer_literal(-ilit)
if types.equals(node.decl._type, types.Integer) then
+ subs.NEGILIT = c_integer_literal(-ilit)
cstep = output("$CVAR = l_castU2S(l_castS2U($CVAR) - $NEGILIT)", subs)
else
- cstep = output("$CVAR -= $ILIT", subs)
+ subs.NEGILIT = c_float_literal(-ilit)
+ cstep = output("$CVAR -= $NEGILIT", subs)
end
ccmp = output("_forlimit <= $CVAR", subs)
end
|
Fix wrong case in TARGET setting for Alpine | @@ -117,7 +117,7 @@ matrix:
- <<: *test-alpine
env:
- TARGET_BOX=LINUX64_MUSL
- - BTYPE="BINARY=64 NO_AFFINITY=1 USE_OPENMP=0 NO_LAPACK=0 TARGET=core2"
+ - BTYPE="BINARY=64 NO_AFFINITY=1 USE_OPENMP=0 NO_LAPACK=0 TARGET=CORE2"
- &test-cmake
os: linux
|
groups: World Privacy icon fix
Although the bug was poetic, this makes the icon in GroupLink aware of the group's hidden status and surfaces a lock icon in those cases instead of the "public" globe icon. | @@ -78,7 +78,11 @@ export function GroupLink(
{preview ?
<>
<Box pr='2' display='flex' alignItems='center'>
- <Icon icon='Public' color='gray' mr='1' />
+ <Icon
+ icon={preview.metadata.hidden ? 'Locked' : 'Public'}
+ color='gray'
+ mr='1'
+ />
<Text fontSize='0' color='gray'>
{preview.metadata.hidden ? 'Private' : 'Public'}
</Text>
|
Set only remembered transport params for early data | @@ -7591,7 +7591,20 @@ int ngtcp2_conn_set_remote_transport_params(
void ngtcp2_conn_set_early_remote_transport_params(
ngtcp2_conn *conn, const ngtcp2_transport_params *params) {
- settings_copy_from_transport_params(&conn->remote.settings, params);
+ ngtcp2_transport_params p;
+
+ memset(&p, 0, sizeof(p));
+
+ p.initial_max_streams_bidi = params->initial_max_streams_bidi;
+ p.initial_max_streams_uni = params->initial_max_streams_uni;
+ p.initial_max_stream_data_bidi_local =
+ params->initial_max_stream_data_bidi_local;
+ p.initial_max_stream_data_bidi_remote =
+ params->initial_max_stream_data_bidi_remote;
+ p.initial_max_stream_data_uni = params->initial_max_stream_data_uni;
+ p.initial_max_data = params->initial_max_data;
+
+ settings_copy_from_transport_params(&conn->remote.settings, &p);
conn_sync_stream_id_limit(conn);
conn->tx.max_offset = conn->remote.settings.max_data;
|
meowth: Fix PPC configs.
There are 2.
BRANCH=None
TEST=Flash meowth. Verify that EC doesn't panic.
Commit-Ready: Aseda Aboagye
Tested-by: Aseda Aboagye | @@ -182,19 +182,18 @@ const struct i2c_port_t i2c_ports[] = {
const unsigned int i2c_ports_used = ARRAY_SIZE(i2c_ports);
-/* TODO(aaboagye): Add the other ports. 3 for Zoombini, 2 for Meowth */
const struct ppc_config_t ppc_chips[] = {
{
.i2c_port = I2C_PORT_TCPC0,
.i2c_addr = SN5S330_ADDR0,
.drv = &sn5s330_drv
},
-#ifdef BOARD_ZOOMBINI
{
.i2c_port = I2C_PORT_TCPC1,
.i2c_addr = SN5S330_ADDR0,
- .drv = &sn5s330_drv
+ .drv = &sn5s330_drv,
},
+#ifdef BOARD_ZOOMBINI
{
.i2c_port = I2C_PORT_TCPC2,
.i2c_addr = SN5S330_ADDR0,
|
super-rsu: change bmc_pkg version impl
Change bmc_pkg version property implementation to return a list of two
versions converted to strings. This is done to allow comparing against
the version encoded in the manifest. | @@ -460,7 +460,7 @@ class bmc_pkg(flashable):
@property
def version(self):
- return (self._img.version, self._fw.version)
+ return [str(self._img.version), str(self._fw.version)]
def is_supported(self, flash_info):
return self._img.is_supported(flash_info) and self._fw.is_supported(
|
Applying the windows patch after the checkout completes
I believe this will fix the residual issue. | @@ -12,8 +12,8 @@ foreach ($dir in "$Env:OPENSSLDIR","$Env:OPENSSL64DIR") {
pushd ..
git clone --branch master --single-branch --shallow-submodules --recurse-submodules --no-tags https://github.com/h2o/picotls 2>&1 | %{ "$_" }
cd picotls
-git apply ..\picoquic\ci\picotls-win32.patch
git checkout -q "$COMMIT_ID"
+git apply ..\picoquic\ci\picotls-win32.patch
#git submodule init
#git submodule update
|
remove debug vestiges | @@ -507,10 +507,7 @@ protoop_arg_t plugin_run_protoop(picoquic_cnx_t *cnx, const protoop_params_t *pp
protocol_operation_struct_t *post;
HASH_FIND_PID(cnx->ops, &(pp->pid->hash), post);
if (!post) {
- /* TODO CONTINUE FIXME FIXME */
printf("FATAL ERROR: no protocol operation with id %s\n", pp->pid->id);
- int *a = NULL;
- *a = 42;
exit(-1);
}
|
Forbid HID input without OTG on Windows
On Windows, if the adb daemon is running, opening the USB device will
necessarily fail, so HID input is not possible.
Refs <https://github.com/Genymobile/scrcpy/issues/2773>
PR <https://github.com/Genymobile/scrcpy/pull/3011> | @@ -1680,6 +1680,18 @@ parse_args_with_getopt(struct scrcpy_cli_args *args, int argc, char *argv[],
}
#ifdef HAVE_USB
+
+# ifdef _WIN32
+ if (!opts->otg && (opts->keyboard_input_mode == SC_KEYBOARD_INPUT_MODE_HID
+ || opts->mouse_input_mode == SC_MOUSE_INPUT_MODE_HID)) {
+ LOGE("On Windows, it is not possible to open a USB device already open "
+ "by another process (like adb).");
+ LOGE("Therefore, -K/--hid-keyboard and -M/--hid-mouse may only work in "
+ "OTG mode (--otg).");
+ return false;
+ }
+# endif
+
if (opts->otg) {
// OTG mode is compatible with only very few options.
// Only report obvious errors.
|
perf-tools/pdtoolkit: fix patch level | ---- pdtoolkit-3.25/configure~ 2017-11-06 12:55:45.000000000 -0600
-+++ pdtoolkit-3.25/configure 2017-12-05 16:03:59.368119000 -0600
+--- a/configure 2017-11-06 10:55:45.000000000 -0800
++++ b/configure 2017-12-05 14:32:47.000000000 -0800
-prefix=*)
|
Get rid of a warning about unused results | @@ -634,9 +634,10 @@ static bssl::UniquePtr<SSL_CTX> SetupCtx(const TestConfig *config) {
SSL_CTX_set_client_CA_list(ssl_ctx.get(), nullptr);
}
- SSL_CTX_set_session_id_context(ssl_ctx.get(),
+ if (!SSL_CTX_set_session_id_context(ssl_ctx.get(),
(const unsigned char *)sess_id_ctx,
- sizeof(sess_id_ctx) - 1);
+ sizeof(sess_id_ctx) - 1))
+ return nullptr;
return ssl_ctx;
}
|
Fix move_dll for VS2019
TARGET_FILE_DIR will do the right thing regardless of VR version | @@ -549,7 +549,7 @@ if(WIN32)
add_custom_command(TARGET lovr POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy
$<TARGET_FILE:${ARGV0}>
- ${CMAKE_CURRENT_BINARY_DIR}/$<CONFIGURATION>/$<TARGET_FILE_NAME:${ARGV0}>
+ $<TARGET_FILE_DIR:lovr>/$<TARGET_FILE_NAME:${ARGV0}>
)
endif()
endfunction()
|
ToolStatus: Fix searching waiting/unknown network connections | @@ -473,16 +473,49 @@ BOOLEAN ServiceTreeFilterCallback(
return FALSE;
}
+// copied from ProcessHacker\netlist.c..
+static PPH_STRING PhpNetworkTreeGetNetworkItemProcessName(
+ _In_ PPH_NETWORK_ITEM NetworkItem
+ )
+{
+ PH_FORMAT format[4];
+
+ if (!NetworkItem->ProcessId)
+ return PhaCreateString(L"Waiting connections");
+
+ PhInitFormatS(&format[1], L" (");
+ PhInitFormatU(&format[2], HandleToUlong(NetworkItem->ProcessId));
+ PhInitFormatC(&format[3], ')');
+
+ if (NetworkItem->ProcessName)
+ PhInitFormatSR(&format[0], NetworkItem->ProcessName->sr);
+ else
+ PhInitFormatS(&format[0], L"Unknown process");
+
+ return PH_AUTO(PhFormat(format, 4, 96));
+}
+
BOOLEAN NetworkTreeFilterCallback(
_In_ PPH_TREENEW_NODE Node,
_In_opt_ PVOID Context
)
{
PPH_NETWORK_NODE networkNode = (PPH_NETWORK_NODE)Node;
+ PPH_STRING processNameText;
if (PhIsNullOrEmptyString(SearchboxText))
return TRUE;
+ // TODO: We need export the PPH_NETWORK_NODE->ProcessNameText field to search
+ // waiting/unknown network connections... For now just replicate the data here.
+ processNameText = PhpNetworkTreeGetNetworkItemProcessName(networkNode->NetworkItem);
+
+ if (!PhIsNullOrEmptyString(processNameText))
+ {
+ if (WordMatchStringRef(&processNameText->sr))
+ return TRUE;
+ }
+
if (!PhIsNullOrEmptyString(networkNode->NetworkItem->ProcessName))
{
if (WordMatchStringRef(&networkNode->NetworkItem->ProcessName->sr))
|
extras: fix WEBP_SWAP_16BIT_CSP check
this is defined to 0 by dsp.h if it wasn't defined previously, since:
extras: add WebPUnmultiplyARGB() convenience function | @@ -58,7 +58,7 @@ int WebPImportRGB565(const uint8_t* rgb565, WebPPicture* pic) {
for (y = 0; y < pic->height; ++y) {
const int width = pic->width;
for (x = 0; x < width; ++x) {
-#ifdef WEBP_SWAP_16BIT_CSP
+#if defined(WEBP_SWAP_16BIT_CSP) && (WEBP_SWAP_16BIT_CSP == 1)
const uint32_t rg = rgb565[2 * x + 1];
const uint32_t gb = rgb565[2 * x + 0];
#else
@@ -91,7 +91,7 @@ int WebPImportRGB4444(const uint8_t* rgb4444, WebPPicture* pic) {
for (y = 0; y < pic->height; ++y) {
const int width = pic->width;
for (x = 0; x < width; ++x) {
-#ifdef WEBP_SWAP_16BIT_CSP
+#if defined(WEBP_SWAP_16BIT_CSP) && (WEBP_SWAP_16BIT_CSP == 1)
const uint32_t rg = rgb4444[2 * x + 1];
const uint32_t ba = rgb4444[2 * x + 0];
#else
|
bfd:fix NULL session free/put | @@ -473,7 +473,6 @@ bfd_udp_add_session_internal (bfd_udp_main_t * bum, u32 sw_if_index,
bfd_session_t *bs = bfd_get_session (bum->bfd_main, t);
if (!bs)
{
- bfd_put_session (bum->bfd_main, bs);
return VNET_API_ERROR_BFD_EAGAIN;
}
bfd_udp_session_t *bus = &bs->udp;
|
Update pack description | @@ -2624,6 +2624,7 @@ and 8-bit Java bytecodes in Jazelle state.
<file category="source" name="CMSIS/NN/Source/ConvolutionFunctions/arm_nn_mat_mult_kernel_q7_q15_reordered.c"/>
<file category="source" name="CMSIS/NN/Source/ConvolutionFunctions/arm_convolve_1x1_HWC_q7_fast_nonsquare.c"/>
<file category="source" name="CMSIS/NN/Source/ConvolutionFunctions/arm_convolve_HWC_q7_basic.c"/>
+ <file category="source" name="CMSIS/NN/Source/ConvolutionFunctions/arm_convolve_HWC_q7_basic_nonsquare.c"/>
<file category="source" name="CMSIS/NN/Source/ConvolutionFunctions/arm_convolve_HWC_q7_fast.c"/>
<file category="source" name="CMSIS/NN/Source/ConvolutionFunctions/arm_convolve_HWC_q7_fast_nonsquare.c"/>
@@ -2637,6 +2638,8 @@ and 8-bit Java bytecodes in Jazelle state.
<file category="source" name="CMSIS/NN/Source/NNSupportFunctions/arm_q7_to_q15_reordered_no_shift.c"/>
<file category="source" name="CMSIS/NN/Source/NNSupportFunctions/arm_nntables.c"/>
<file category="source" name="CMSIS/NN/Source/NNSupportFunctions/arm_q7_to_q15_no_shift.c"/>
+ <file category="source" name="CMSIS/NN/Source/NNSupportFunctions/arm_nn_mult_q15.c"/>
+ <file category="source" name="CMSIS/NN/Source/NNSupportFunctions/arm_nn_mult_q7.c"/>
<file category="source" name="CMSIS/NN/Source/PoolingFunctions/arm_pool_q7_HWC.c"/>
|
[mod_magnet] lighty.c.cookie_tokens
lighty.c.cookie_tokens parse cookie header into table
Note: the "lighty.c.*" namespace is EXPERIMENTAL / UNSTABLE
In the future, these may be removed, altered, or moved to a different
namespace. | @@ -1048,6 +1048,43 @@ static int magnet_fspath_simplify(lua_State *L) {
return 1;
}
+static const char * magnet_cookie_param_push(lua_State *L, const char *s) {
+ const char *b = s;
+ while ( *s!=';' && *s!=' ' && *s!='\t' && *s!='\r' && *s!='\n' && *s)
+ ++s;
+ lua_pushlstring(L, b, (size_t)(s-b));
+ return s;
+}
+
+static int magnet_cookie_tokens(lua_State *L) {
+ lua_createtable(L, 0, 0);
+ if (lua_isnil(L, -1))
+ return 1;
+ const char *s = luaL_checkstring(L, -1);
+ do {
+ while (*s==';' || *s==' ' || *s=='\t' || *s=='\r' || *s=='\n')
+ ++s;
+ if (*s == '\0') break;
+ s = magnet_cookie_param_push(L, s);
+ while ( *s==' ' || *s=='\t' || *s=='\r' || *s=='\n')
+ ++s;
+ if (*s == '=') {
+ while ( *s==' ' || *s=='\t' || *s=='\r' || *s=='\n')
+ ++s;
+ if (*s==';' || *s=='\0')
+ lua_pushnil(L);
+ else
+ s = magnet_cookie_param_push(L, s);
+ }
+ else {
+ lua_pushnil(L);
+ }
+ lua_settable(L, -3);
+ while (*s!=';' && *s!='\0') ++s; /* ignore/skip stray tokens */
+ } while (*s++);
+ return 1;
+}
+
static int magnet_atpanic(lua_State *L) {
request_st * const r = magnet_get_request(L);
log_error(r->conf.errh, __FILE__, __LINE__, "(lua-atpanic) %s",
@@ -2006,6 +2043,7 @@ static void magnet_init_lighty_table(lua_State * const L) {
,{ "urlenc_query", magnet_urlenc_query } /* url-encode query-string */
,{ "urlenc_normalize", magnet_urlenc_normalize }/* url-enc normalization */
,{ "fspath_simplify", magnet_fspath_simplify } /* simplify fspath */
+ ,{ "cookie_tokens", magnet_cookie_tokens } /* parse cookie tokens */
,{ NULL, NULL }
};
|
[cmake,tests] for non-RPATH builds, tests need LD_LIBRARY_PATH | @@ -515,8 +515,12 @@ function(build_python_tests)
configure_file(${file} ${SICONOS_SWIG_ROOT_DIR}/tests COPYONLY)
set(name "python_${testname}")
set(exename ${SICONOS_SWIG_ROOT_DIR}/tests/${exename})
- # set_ldlibpath()
+ set_ldlibpath()
add_python_test(${name} ${exename})
endforeach()
endif()
endfunction()
+
+if(WITH_TESTING)
+ set_ldlibpath()
+endif()
|
Add some nice comments | @@ -316,9 +316,9 @@ void MsgAlloc_SetMessage(msg_t *msg)
* the reception of the next one in a thread safe code part.
* Then we can copy it without trouble.
*/
- // copy the message to copy location
+ // backup the message to copy location allowing current_msg to be used by reception
cpy_msg = (msg_t *)current_msg;
- // fake the data_ptr progression
+ // fake the data_ptr progression to be able to receive other messages during the copy
data_ptr = ¤t_msg->stream[data_size + 2];
// finish the message and prepare the next reception
MsgAlloc_EndMsg();
|
symstreamr: making delay autotest more robust and reliable | #include "autotest/autotest.h"
#include "liquid.h"
-// autotest helper functions
+// autotest helper function: measure delay assuming impulse
+// - set gain to 1 for a single sample
+// - set gain to 0 for remaining samples
+// -> this generates one symbol for the modulation scheme
+// - take fft of resulting pulse
+// - observe phase slope across pass-band
void testbench_symstreamrcf_delay(float _bw,
unsigned int _m)
{
@@ -35,26 +40,40 @@ void testbench_symstreamrcf_delay(float _bw,
int ms = LIQUID_MODEM_QPSK;
symstreamrcf gen = symstreamrcf_create_linear(ftype,_bw,_m,beta,ms);
float delay = symstreamrcf_get_delay(gen);
- float tol = 2.0f + 1.0f/_bw; // error tolerance (fairly wide due to random signal)
+ float tol = 0.05; // error tolerance
- unsigned int i;
- for (i=0; i<1000 + (unsigned int)(delay); i++) {
- // generate a single sample
- float complex sample;
- symstreamrcf_write_samples(gen, &sample, 1);
+ // compute buffer length based on delay
+ unsigned int nfft = 2*(120 + (unsigned int)(delay/sqrtf(_bw)));
+ float complex buf_time[nfft];
+ float complex buf_freq[nfft];
- // check to see if value exceeds 1
- if (cabsf(sample) > 1.0f)
- break;
- }
- if (liquid_autotest_verbose)
- printf("expected delay: %.3f, approximate delay: %u, tol: %.3f\n", delay, i, tol);
-
- // verify delay is relatively close to expected
- CONTEND_DELTA((float)delay, (float)i, tol);
+ // write samples to buffer
+ symstreamrcf_write_samples(gen, buf_time, 1);
+ symstreamrcf_set_gain(gen, 0.0f);
+ symstreamrcf_write_samples(gen, buf_time+1, nfft-1);
// destroy objects
symstreamrcf_destroy(gen);
+
+ // take forward transform
+ fft_run(nfft, buf_time, buf_freq, LIQUID_FFT_FORWARD, 0);
+
+ // measure phase slope across pass-band
+ unsigned int m = 0.4 * _bw * nfft; // use 0.4 to account for filter roll-off
+ float complex p = 0.0f;
+ int i;
+ for (i=-(int)m; i<(int)m; i++)
+ p += buf_freq[(nfft+i)%nfft] * conjf(buf_freq[(nfft+i+1)%nfft]);
+ float delay_meas = cargf(p) * nfft / (2*M_PI);
+
+ // print results
+ if (liquid_autotest_verbose) {
+ printf("expected delay: %.6f, measured: %.6f, error: %.6f (tol= %.3f)\n",
+ delay, delay_meas, delay-delay_meas,tol);
+ }
+
+ // verify delay is relatively close to expected
+ CONTEND_DELTA(delay, delay_meas, tol);
}
void autotest_symstreamrcf_delay_00() { testbench_symstreamrcf_delay(0.500f, 4); }
@@ -79,4 +98,3 @@ void autotest_symstreamrcf_delay_17() { testbench_symstreamrcf_delay(0.100f,12);
void autotest_symstreamrcf_delay_18() { testbench_symstreamrcf_delay(0.050f,12); }
void autotest_symstreamrcf_delay_19() { testbench_symstreamrcf_delay(0.025f,12); }
-
|
{AH} updated news | @@ -5,6 +5,40 @@ http://pysam.readthedocs.io/en/latest/release.html
Release notes
=============
+Release 0.14.0
+==============
+
+* SAM/BAM/CRAM headers are now managed by a separate AlignmentHeader
+ class.
+* AlignmentFile.header.as_dict() returns an ordered dictionary.
+* Use "stop" instead of "end" to ensure consistency to
+ VariantFile. The end designations have been kept for backwards
+ compatibility.
+
+* [#611] and [#293] CRAM repeated fetch now works, each iterator
+ reloads index if multiple_iterators=True
+* [#608] pysam now wraps htslib 1.7 and samtools 1.7.
+* [#580] reference_name and next_reference_name can now be set to "*"
+ (will be converted to None to indicate an unmapped location)
+* [#302] providing no coordinate to count_coverage will not count from
+ start/end of contig.
+* [#325] @SQ records will be automatically added to header if they are
+ absent from text section of header.
+* [#529] add get_forward_sequence() and get_forward_qualities()
+ methods
+* [#577] add from_string() and to_dict()/from_dict() methods to
+ AlignedSegment. Rename tostring() to to_string() throughout for
+ consistency
+* [#589] return None from build_alignment_sequence if no MD tag is set
+* [#528] add PileupColumn.__len__ method
+
+Backwards incompatible changes (should only affect a small number of users):
+
+* AlignmentFile.header now returns an AlignmentHeader object. Use
+ AlignmentFile.header.to_dict() to get the dictionary as previously.
+* AlignmentFile.text is now AlignmentFile.header.__str__()
+* AlignmentFile, FastaFile now raise IOError.
+
Release 0.13.0
===============
|
Docker: Use Debian packages for PEGTL | @@ -75,6 +75,7 @@ RUN apt-get update \
ruby-dev \
swig3.0 \
systemd \
+ tao-pegtl-dev \
tclcl-dev \
uuid-dev \
valgrind \
@@ -94,13 +95,6 @@ RUN mkdir -p ${GTEST_ROOT} \
&& tar -zxvf gtest.tar.gz --strip-components=1 -C ${GTEST_ROOT} \
&& rm gtest.tar.gz
-# PEGTL
-ARG PEGTL_VERSION=2.7.1
-RUN cd /tmp \
- && git clone --branch ${PEGTL_VERSION} --depth 1 https://github.com/taocpp/PEGTL.git \
- && cp -R PEGTL/include/tao /usr/local/include \
- && rm -rf PEGTL
-
# YAEP
ARG YAEP_VERSION=550de4cc5600d5f6109c7ebcfbacec51bf80d8d3
RUN cd /tmp \
|
Minor lovr.graphics.clear optimization; | @@ -158,8 +158,10 @@ void lovrGraphicsClear(int color, int depth) {
bits |= GL_DEPTH_BUFFER_BIT;
}
+ if (bits != 0) {
glClear(bits);
}
+}
void lovrGraphicsPresent() {
glfwSwapBuffers(state.window);
|
board/dirinboz/board.h: Format with clang-format
BRANCH=none
TEST=none | /* This I2C moved. Temporarily detect and support the V0 HW. */
extern int I2C_PORT_BATTERY;
-enum adc_channel {
- ADC_TEMP_SENSOR_CHARGER,
- ADC_TEMP_SENSOR_SOC,
- ADC_CH_COUNT
-};
+enum adc_channel { ADC_TEMP_SENSOR_CHARGER, ADC_TEMP_SENSOR_SOC, ADC_CH_COUNT };
enum battery_type {
BATTERY_SIMPLO_COS,
@@ -79,20 +75,11 @@ enum battery_type {
BATTERY_TYPE_COUNT,
};
-enum pwm_channel {
- PWM_CH_KBLIGHT = 0,
- PWM_CH_COUNT
-};
+enum pwm_channel { PWM_CH_KBLIGHT = 0, PWM_CH_COUNT };
-enum ioex_port {
- IOEX_C0_NCT3807 = 0,
- IOEX_C1_NCT3807,
- IOEX_PORT_COUNT
-};
+enum ioex_port { IOEX_C0_NCT3807 = 0, IOEX_C1_NCT3807, IOEX_PORT_COUNT };
-#define PORT_TO_HPD(port) ((port == 0) \
- ? GPIO_USB3_C0_DP2_HPD \
- : GPIO_DP1_HPD)
+#define PORT_TO_HPD(port) ((port == 0) ? GPIO_USB3_C0_DP2_HPD : GPIO_DP1_HPD)
enum temp_sensor_id {
TEMP_SENSOR_CHARGER = 0,
@@ -101,17 +88,9 @@ enum temp_sensor_id {
TEMP_SENSOR_COUNT
};
-enum usba_port {
- USBA_PORT_A0 = 0,
- USBA_PORT_A1,
- USBA_PORT_COUNT
-};
+enum usba_port { USBA_PORT_A0 = 0, USBA_PORT_A1, USBA_PORT_COUNT };
-enum usbc_port {
- USBC_PORT_C0 = 0,
- USBC_PORT_C1,
- USBC_PORT_COUNT
-};
+enum usbc_port { USBC_PORT_C0 = 0, USBC_PORT_C1, USBC_PORT_COUNT };
/*****************************************************************************
* CBI EC FW Configuration
|
vlib: add screen-256color CLI terminal type | @@ -1023,6 +1023,7 @@ unix_cli_terminal_type (u8 * term, uword len)
_("xterm-color");
_("xterm-256color"); /* iTerm on Mac */
_("screen");
+ _("screen-256color"); /* Screen and tmux */
_("ansi"); /* Microsoft Telnet */
#undef _
|
version bump in cyclone library | @@ -632,7 +632,7 @@ void print_cyclone(void)
char cyclone_dir[MAXPDSTRING];
strcpy(cyclone_dir, cyclone_class->c_externdir->s_name);
post("------------------------------------------------------------------------");
- post("Cyclone 0.4; Released September 15th 2019");
+ post("Cyclone 0.4.1; Unreleased");
post("Loading the cyclone library did the following:");
post("A) Loaded the non alpha-numeric objects, which are:");
post("[!-], [!-~], [!/], [!/~], [!=~], [%%~], [+=~], [<=~], [<~], [==~], [>=~] and [>~]");
|
Shell Recorder: Disable self test on Linux/ASAN | @@ -46,12 +46,7 @@ if (ENABLE_KDB_TESTING)
"script.esr"
)
- # Only add the tests below if they work with the current configuration
- list (FIND REMOVED_PLUGINS mini PLUGIN_INDEX)
- if (${PLUGIN_INDEX} EQUAL -1)
- list (APPEND SCRIPT_TESTS "selftest.esr")
- endif (${PLUGIN_INDEX} EQUAL -1)
-
+ # Only add the test below if it works using the current configuration
list (FIND REMOVED_PLUGINS ni PLUGIN_INDEX)
if (${PLUGIN_INDEX} EQUAL -1)
list (APPEND SCRIPT_TESTS "mathcheck.esr")
@@ -73,6 +68,12 @@ if (ENABLE_KDB_TESTING)
# http://lists.llvm.org/pipermail/cfe-dev/2013-August/031194.html
set (ASAN_LINUX ENABLE_ASAN AND ${CMAKE_SYSTEM_NAME} MATCHES "Linux")
if (NOT (${ASAN_LINUX} AND CMAKE_CXX_COMPILER_ID MATCHES "Clang" AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5))
+ # Only add the test below if it works using the current configuration
+ list (FIND REMOVED_PLUGINS mini PLUGIN_INDEX)
+ if (${PLUGIN_INDEX} EQUAL -1)
+ list (APPEND SCRIPT_TESTS "selftest.esr")
+ endif (${PLUGIN_INDEX} EQUAL -1)
+
file (GLOB REPLAY_TESTS replay_tests/*.esr)
foreach (file ${REPLAY_TESTS})
get_filename_component (directory ${file} DIRECTORY)
|
driver/accelgyro_icm426xx.h: Format with clang-format
BRANCH=none
TEST=none | #define ICM426XX_GYRO_STOP_TIME 150000
/* Reg value from Accel FS in G */
-#define ICM426XX_ACCEL_FS_TO_REG(_fs) ((_fs) < 2 ? 3 : \
- (_fs) > 16 ? 0 : \
- 3 - __fls((_fs) / 2))
+#define ICM426XX_ACCEL_FS_TO_REG(_fs) \
+ ((_fs) < 2 ? 3 : (_fs) > 16 ? 0 : 3 - __fls((_fs) / 2))
/* Accel FSR in G from Reg value */
#define ICM426XX_ACCEL_REG_TO_FS(_reg) ((1 << (3 - (_reg))) * 2)
/* Reg value from Gyro FS in dps */
-#define ICM426XX_GYRO_FS_TO_REG(_fs) ((_fs) < 125 ? 4 : \
- (_fs) > 2000 ? 0 : \
- 4 - __fls((_fs) / 125))
+#define ICM426XX_GYRO_FS_TO_REG(_fs) \
+ ((_fs) < 125 ? 4 : (_fs) > 2000 ? 0 : 4 - __fls((_fs) / 125))
/* Gyro FSR in dps from Reg value */
#define ICM426XX_GYRO_REG_TO_FS(_reg) ((1 << (4 - (_reg))) * 125)
/* Reg value from ODR in mHz */
-#define ICM426XX_ODR_TO_REG(_odr) ((_odr) <= 200000 ? \
- 13 - __fls((_odr) / 3125) : \
+#define ICM426XX_ODR_TO_REG(_odr) \
+ ((_odr) <= 200000 ? 13 - __fls((_odr) / 3125) : \
(_odr) < 500000 ? 7 : \
(_odr) < 1000000 ? 15 : \
6 - __fls((_odr) / 1000000))
/* ODR in mHz from Reg value */
-#define ICM426XX_REG_TO_ODR(_reg) ((_reg) == 15 ? 500000 : \
- (_reg) >= 7 ? \
- (1 << (13 - (_reg))) * 3125 : \
+#define ICM426XX_REG_TO_ODR(_reg) \
+ ((_reg) == 15 ? 500000 : \
+ (_reg) >= 7 ? (1 << (13 - (_reg))) * 3125 : \
(1 << (6 - (_reg))) * 1000000)
/* Reg value for the next higher ODR */
-#define ICM426XX_ODR_REG_UP(_reg) ((_reg) == 15 ? 6 : \
- (_reg) == 7 ? 15 : \
- (_reg) - 1)
+#define ICM426XX_ODR_REG_UP(_reg) \
+ ((_reg) == 15 ? 6 : (_reg) == 7 ? 15 : (_reg)-1)
/*
* Register addresses are virtual address on 16 bits.
|
Re-implement ANSI C building with a Github workflow | @@ -36,6 +36,18 @@ jobs:
- name: make doc-nits
run: make doc-nits
+ # This checks that we use ANSI C language syntax and semantics.
+ # We are not as strict with libraries, but rather adapt to what's
+ # expected to be available in a certain version of each platform.
+ check-ansi:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v2
+ - name: config
+ run: CPPFLAGS=-ansi ./config no-asm no-makedepend enable-buildtest-c++ --strict-warnings -D_DEFAULT_SOURCE && perl configdata.pm --dump
+ - name: make
+ run: make -s -j4
+
basic_gcc:
runs-on: ubuntu-latest
steps:
|
Preliminary changelist for 4.2.0RC2 | -CARTO Mobile SDK 4.2.0
+CARTO Mobile SDK 4.2.0RC2
+-------------------
+
+### Changes/fixes:
+
+* Added BalloonPopupButton and related classes so that basic interactivity can be added to BalloonPopups
+* Major SGRE optimizations: replaced one-to-one routing engine with many-to-many routing engine, using optimized data structures for routing
+* Fixed/improved label ordering in vector tile renderer: prefer bigger labels over smaller ones
+* Fixed geometry simplifier attached to LocalVectorDataSource causing a crash
+* Fixed multiple issues with billboard sorting and ray casting.
+* More consistent ordering of vector elements
+* Change billboard rendering to ignore depth testing. Better fit with 3D objects.
+* Fixed potential rendering issue with GeometryCollections when switching between planar/spherical rendering mode
+* Fixed ray-intersection code with Polygon3D, use the closest intersection point, not the first found point
+* Fixed subtle flickering in ClusteredVectorLayer animations
+* Minor performance optimization by using platform-optimized zlib
+* Fixed getElementClickPos method of PopupClickInfo to return click coordinates as pixel coordinates, not normalized-to-size coordinates
+* Documentation fixes
+
+
+CARTO Mobile SDK 4.2.0RC1
-------------------
This version is a major update and brings lots of new features and optimizations. Some features present in older releases are removed or deprecated in this version.
|
Split Conan GCC jobs into smaller jobs. | @@ -11,19 +11,67 @@ jobs:
- os: linux
language: python
python: 3.7
- env: BUILD_TOOL=conan CONAN_GCC_VERSIONS=7 CONAN_ARCHS=x86_64 CONAN_DOCKER_IMAGE=conanio/gcc7
+ env:
+ BUILD_TOOL=conan
+ CONAN_GCC_VERSIONS=7
+ CONAN_DOCKER_IMAGE=conanio/gcc7
+ CONAN_ARCHS=x86_64
+ CONAN_BUILD_TYPES=Debug
services:
- docker
- os: linux
language: python
python: 3.7
- env: BUILD_TOOL=conan CONAN_GCC_VERSIONS=8 CONAN_ARCHS=x86_64 CONAN_DOCKER_IMAGE=conanio/gcc8
+ env:
+ BUILD_TOOL=conan
+ CONAN_GCC_VERSIONS=7
+ CONAN_DOCKER_IMAGE=conanio/gcc7
+ CONAN_ARCHS=x86_64
+ CONAN_BUILD_TYPES=Release
services:
- docker
- os: linux
language: python
python: 3.7
- env: BUILD_TOOL=conan CONAN_GCC_VERSIONS=9 CONAN_ARCHS=x86_64 CONAN_DOCKER_IMAGE=conanio/gcc9
+ env:
+ BUILD_TOOL=conan
+ CONAN_GCC_VERSIONS=8
+ CONAN_DOCKER_IMAGE=conanio/gcc8
+ CONAN_ARCHS=x86_64
+ CONAN_BUILD_TYPES=Debug
+ services:
+ - docker
+ - os: linux
+ language: python
+ python: 3.7
+ env:
+ BUILD_TOOL=conan
+ CONAN_GCC_VERSIONS=8
+ CONAN_DOCKER_IMAGE=conanio/gcc8
+ CONAN_ARCHS=x86_64
+ CONAN_BUILD_TYPES=Release
+ services:
+ - docker
+ - os: linux
+ language: python
+ python: 3.7
+ env:
+ BUILD_TOOL=conan
+ CONAN_GCC_VERSIONS=9
+ CONAN_DOCKER_IMAGE=conanio/gcc9
+ CONAN_ARCHS=x86_64
+ CONAN_BUILD_TYPES=Debug
+ services:
+ - docker
+ - os: linux
+ language: python
+ python: 3.7
+ env:
+ BUILD_TOOL=conan
+ CONAN_GCC_VERSIONS=9
+ CONAN_DOCKER_IMAGE=conanio/gcc9
+ CONAN_ARCHS=x86_64
+ CONAN_BUILD_TYPES=Release
services:
- docker
- os: osx
|
re-run tests since they were increasing coverage before | #include "tls/s2n_tls_parameters.h"
#include "utils/s2n_random.h"
#include "utils/s2n_safety.h"
+
#include "s2n_test.h"
static const uint8_t TLS_VERSIONS[] = {S2N_TLS10, S2N_TLS11, S2N_TLS12};
|
Use Swift String for formatting | @@ -125,12 +125,12 @@ import ios_system
self.isREPLRunning = true
}
- guard let startupURL = Bundle.main.url(forResource: "Startup", withExtension: "py"), let src = try? String(contentsOf: startupURL) as NSString else {
+ guard let startupURL = Bundle.main.url(forResource: "Startup", withExtension: "py"), let src = try? String(contentsOf: startupURL) else {
PyOutputHelper.print(Localizable.Python.alreadyRunning)
return
}
- let code = NSString(format: src, url.path) as String
+ let code = String(format: src, url.path)
PyRun_SimpleStringFlags(code.cValue, nil)
}
}
|
integration: Extend test timeout and remove verbose printing. | @@ -16,4 +16,4 @@ RUN mv ./kubectl /usr/local/bin
COPY bin/kubectl-gadget /bin/kubectl-gadget
COPY --from=build_base /build/gadget-integration.test /bin/gadget-integration.test
-CMD ["/bin/sh", "-c", "gadget-integration.test -test.v -integration"]
+CMD ["/bin/sh", "-c", "gadget-integration.test -integration -test.timeout 20m"]
|
Minor variable name changes and drbg updates | @@ -401,7 +401,7 @@ ACVP_RESULT acvp_enable_sym_cipher_cap_parm(
return ACVP_NO_CAP;
}
- if (acvp_validate_sym_cipher_parm_value(parm, value) != ACVP_SUCCESS) {
+ if (acvp_validate_sym_cipher_parm_value(parm, length) != ACVP_SUCCESS) {
ACVP_LOG_ERR("Invalid sym cipher parm value");
return ACVP_INVALID_ARG;
}
@@ -557,7 +557,7 @@ ACVP_RESULT acvp_enable_hash_cap_parm (
return ACVP_NO_CAP;
}
- if (acvp_validate_hash_parm_value(parm, value) != ACVP_SUCCESS) {
+ if (acvp_validate_hash_parm_value(param, value) != ACVP_SUCCESS) {
ACVP_LOG_ERR("Invalid hash parm value");
return ACVP_INVALID_ARG;
}
@@ -754,6 +754,9 @@ ACVP_RESULT acvp_validate_drbg_parm_value(ACVP_DRBG_PARM parm, int value) {
case ACVP_DRBG_ADD_IN_LEN:
case ACVP_DRBG_RET_BITS_LEN:
case ACVP_DRBG_PRE_REQ_VALS:
+ // TODO: add proper validation for these parameters
+ retval = ACVP_SUCCESS;
+ break;
default:
break;
}
@@ -775,8 +778,7 @@ static ACVP_RESULT acvp_add_ctr_drbg_cap_parm (
return ACVP_INVALID_ARG;
}
- if (acvp_validate_drbg_parm_value(parm, value) != ACVP_SUCCESS) {
- ACVP_LOG_ERR("Invalid drbg parm value");
+ if (acvp_validate_drbg_parm_value(param, value) != ACVP_SUCCESS) {
return ACVP_INVALID_ARG;
}
|
Update textlayer style cache processing | @@ -75,23 +75,33 @@ void TextStyle_Init( LCUI_TextStyle data )
data->pixel_size = 13;
}
-int TextStyle_Copy( LCUI_TextStyle dst, LCUI_TextStyle src )
+int TextStyle_CopyFamily( LCUI_TextStyle dst, LCUI_TextStyle src )
{
- int len;
- *dst = *src;
- if( !dst->has_family ) {
+ size_t len;
+ if( !src->has_family ) {
return 0;
}
- for( len = 0; dst->font_ids[len] != -1; ++len );
+ for( len = 0; src->font_ids[len] != -1; ++len );
len += 1;
+ if( dst->font_ids ) {
+ free( dst->font_ids );
+ }
dst->font_ids = malloc( len * sizeof( int ) );
if( !dst->font_ids ) {
return -ENOMEM;
}
+ dst->has_family = TRUE;
memcpy( dst->font_ids, src->font_ids, len * sizeof( int ) );
return 0;
}
+int TextStyle_Copy( LCUI_TextStyle dst, LCUI_TextStyle src )
+{
+ *dst = *src;
+ dst->font_ids = NULL;
+ return TextStyle_CopyFamily( dst, src );
+}
+
void TextStyle_Destroy( LCUI_TextStyle data )
{
if( data->font_ids ) {
@@ -100,6 +110,37 @@ void TextStyle_Destroy( LCUI_TextStyle data )
data->font_ids = NULL;
}
+void TextStyle_Merge( LCUI_TextStyle base, LCUI_TextStyle target )
+{
+ int *font_ids = NULL;
+ if( !base->has_family && target->has_family ) {
+ base->has_family = TRUE;
+ TextStyle_CopyFamily( base, target );
+ }
+ if( target->has_style && !base->has_style &&
+ target->style != FONT_STYLE_NORMAL ) {
+ base->has_style = TRUE;
+ base->style = target->style;
+ if( LCUIFont_UpdateStyle( base->font_ids,
+ base->style,
+ &font_ids ) > 0 ) {
+ free( base->font_ids );
+ base->font_ids = font_ids;
+ }
+ }
+ if( target->has_weight && !base->has_weight &&
+ target->weight != FONT_WEIGHT_NORMAL ) {
+ base->has_weight = TRUE;
+ base->weight = target->weight;
+ if( LCUIFont_UpdateWeight( base->font_ids,
+ base->weight,
+ &font_ids ) > 0 ) {
+ free( base->font_ids );
+ base->font_ids = font_ids;
+ }
+ }
+}
+
int TextStyle_SetWeight( LCUI_TextStyle ts, LCUI_FontWeight weight )
{
int *font_ids;
|
hash: fix counter when overriding value | @@ -202,6 +202,7 @@ int flb_hash_add(struct flb_hash *ht, char *key, int key_len,
old = mk_list_entry(head, struct flb_hash_entry, _head);
if (strcmp(old->key, entry->key) == 0) {
flb_hash_entry_free(old);
+ table->count--;
break;
}
}
|
Added references to the NIST test data used in the self-test function. | @@ -684,6 +684,29 @@ exit:
#if defined(MBEDTLS_SELF_TEST)
+/* The CTR_DRBG NIST test vectors used here are available at
+ * https://csrc.nist.gov/CSRC/media/Projects/Cryptographic-Algorithm-Validation-Program/documents/drbg/drbgtestvectors.zip
+ *
+ * The parameters used to derive the test data are:
+ *
+ * [AES-128 use df]
+ * [PredictionResistance = True/False]
+ * [EntropyInputLen = 128]
+ * [NonceLen = 64]
+ * [PersonalizationStringLen = 128]
+ * [AdditionalInputLen = 0]
+ * [ReturnedBitsLen = 512]
+ *
+ * [AES-256 use df]
+ * [PredictionResistance = True/False]
+ * [EntropyInputLen = 256]
+ * [NonceLen = 128]
+ * [PersonalizationStringLen = 256]
+ * [AdditionalInputLen = 0]
+ * [ReturnedBitsLen = 512]
+ *
+ */
+
#if defined(MBEDTLS_CTR_DRBG_USE_128_BIT_KEY)
static const unsigned char entropy_source_pr[] =
{ 0x04, 0xd9, 0x49, 0xa6, 0xdc, 0xe8, 0x6e, 0xbb,
|
remove empty file, if no hashes are converted | @@ -2240,6 +2240,7 @@ static int index;
static char *pmkideapolhcoutname;
static char *pmkideapoljtroutname;
struct timeval tv;
+static struct stat statinfo;
static const char *short_options = "o:j:hv";
static const struct option long_options[] =
@@ -2353,6 +2354,20 @@ for(index = optind; index < argc; index++)
if(fh_pmkideapolhc != NULL) fclose(fh_pmkideapolhc);
if(fh_pmkideapoljtr != NULL) fclose(fh_pmkideapoljtr);
+if(pmkideapolhcoutname != NULL)
+ {
+ if(stat(pmkideapolhcoutname, &statinfo) == 0)
+ {
+ if(statinfo.st_size == 0) remove(pmkideapolhcoutname);
+ }
+ }
+if(pmkideapoljtroutname != NULL)
+ {
+ if(stat(pmkideapoljtroutname, &statinfo) == 0)
+ {
+ if(statinfo.st_size == 0) remove(pmkideapoljtroutname);
+ }
+ }
return EXIT_SUCCESS;
}
/*===========================================================================*/
|
Compiler warning re abs | @@ -199,7 +199,7 @@ static int unpack_long(grib_accessor* a, long* val, size_t *len)
/* pl[0] is guaranteed to exist. Have already asserted previously */
for(i=1; i<plsize; ++i) {
- const long diff = abs(pl[i] - pl[i-1]);
+ const long diff = labs(pl[i] - pl[i-1]);
/* There are two values at the equator which are equal. */
/* So diff is either 4 or 0 */
if (diff != 4 && diff != 0) {
|
Add tini as minimal init system | @@ -35,7 +35,7 @@ RUN chmod 0644 * \
##############################
RUN apk update \
- && apk add -u supervisor goaccess
+ && apk add -u supervisor goaccess tini
# Cleanup
#########
@@ -61,4 +61,4 @@ EXPOSE 7890
# Set the entry point to init.sh
###########################################
-ENTRYPOINT ["/opt/init.sh"]
+ENTRYPOINT ["/sbin/tini", "--", "/opt/init.sh"]
|
test/recipes/30-test_evp_libctx.t: use fips-and-base.cnf
The FIPS provider module doesn't have any encoders, the base provider
is needed for that. | @@ -31,7 +31,7 @@ plan tests =>
+ 1;
unless ($no_fips) {
- @test_args = ("-config", srctop_file("test","fips.cnf"),
+ @test_args = ("-config", srctop_file("test","fips-and-base.cnf"),
"-provider", "fips");
ok(run(app(['openssl', 'fipsinstall',
|
Fix sshd start logic for centos7
/etc/init.d/sshd doesn't exist
disable newer host key types in sshd_config | @@ -68,6 +68,10 @@ setup_sshd() {
test -e /etc/ssh/ssh_host_rsa_key || ssh-keygen -f /etc/ssh/ssh_host_rsa_key -N '' -t rsa
test -e /etc/ssh/ssh_host_dsa_key || ssh-keygen -f /etc/ssh/ssh_host_dsa_key -N '' -t dsa
+ # For Centos 7, disable looking for host key types that older Centos versions don't support.
+ sed -ri 's@^HostKey /etc/ssh/ssh_host_ecdsa_key$@#&@' /etc/ssh/sshd_config
+ sed -ri 's@^HostKey /etc/ssh/ssh_host_ed25519_key$@#&@' /etc/ssh/sshd_config
+
# See https://gist.github.com/gasi/5691565
sed -ri 's/UsePAM yes/UsePAM no/g' /etc/ssh/sshd_config
# Disable password authentication so builds never hang given bad keys
@@ -75,8 +79,7 @@ setup_sshd() {
setup_ssh_for_user root
- # Test that sshd can start
- /etc/init.d/sshd start
+ /usr/sbin/sshd
ssh_keyscan_for_user root
ssh_keyscan_for_user gpadmin
|
a way to disable SPLIT_DWARF macro | @@ -1881,12 +1881,15 @@ when ($ADD_GDB_INDEX_VALUE && $HOST_OS_LINUX == "yes" && $TARGET_PLATFORM == "LI
PEERDIR+=contrib/libs/platform/tools/misc/binutils
}
+SPLIT_DWARF_VALUE=no
+NO_SPLIT_DWARF=no
+
macro SPLIT_DWARF() {
SET(SPLIT_DWARF_VALUE yes)
}
SPLIT_DWARF_OUTPUT=${output;tobindir;pre=$MODULE_PREFIX;suf=$MODULE_SUFFIX.debug:REALPRJNAME}
-when ($SPLIT_DWARF_VALUE == "yes" && $NO_DEBUGINFO != "yes" && $HOST_OS_LINUX == "yes" && $TARGET_PLATFORM == "LINUX") {
+when ($SPLIT_DWARF_VALUE == "yes" && $NO_SPLIT_DWARF != "yes" && $NO_DEBUGINFO != "yes" && $HOST_OS_LINUX == "yes" && $TARGET_PLATFORM == "LINUX") {
DWARF_COMMAND+= \
$OBJCOPY_TOOL --only-keep-debug $TARGET $SPLIT_DWARF_OUTPUT && \
$STRIP_TOOL --remove-section .gnu_debuglink $TARGET && \
|
Fix annoying double pci_change events | @@ -157,11 +157,13 @@ default_start_function_new(coreid_t where, struct module_info* mi, char* record,
return KALUGA_ERR_DRIVER_NOT_AUTO;
}
+ char *oct_id;
+
// TODO: Determine cls here as well
{
int64_t vendor_id, device_id, bus, dev, fun;
- err = oct_read(record, "_ { bus: %d, device: %d, function: %d, vendor: %d, device_id: %d }",
- &bus, &dev, &fun,
+ err = oct_read(record, "%s { bus: %d, device: %d, function: %d, vendor: %d, device_id: %d }",
+ &oct_id, &bus, &dev, &fun,
&vendor_id, &device_id);
if(err_is_fail(err)){
@@ -194,7 +196,7 @@ default_start_function_new(coreid_t where, struct module_info* mi, char* record,
char module_name[100];
sprintf(module_name, "%s_module", mi->binary);
- struct driver_instance* drv = ddomain_create_driver_instance(module_name, record);
+ struct driver_instance* drv = ddomain_create_driver_instance(module_name, oct_id);
char *args[4] = {NULL, NULL, NULL, NULL};
int args_len = 0;
|
update testshell_markdown_kdb_get | @@ -63,7 +63,7 @@ sudo kdb mount get.ecf spec:/tests/get/examples/kdb-get dump
# Create the keys we use for the examples
kdb set user:/tests/get/examples/kdb-get/key myKey
-kdb meta-set /tests/get/examples/kdb-get/anotherKey default defaultValue
+kdb meta-set spec:/tests/get/examples/kdb-get/anotherKey default defaultValue
# To get the value of a key:
kdb get user:/tests/get/examples/kdb-get/key
|
undefined behavior: signed integer overflow | @@ -2839,7 +2839,7 @@ ppd_hash_option(ppd_option_t *option) /* I - Option */
for (hash = option->keyword[0], k = option->keyword + 1; *k;)
- hash = 33 * hash + *k++;
+ hash = (int)(33U * (unsigned)hash) + *k++;
return (hash & 511);
}
|
Fixed parsing crosshair color function | @@ -119,11 +119,9 @@ parse_no_display(const char *str)
}
static unsigned
-parse_color(const char (*str))
+parse_color(const char *str)
{
- std::string string = str;
- string = "0x" + string;
- return strtol(string.c_str(), NULL, 0);
+ return strtol(str, NULL, 16);
}
static unsigned
|
Fix a missing rand -> ossl_rand rename | @@ -35,7 +35,7 @@ static size_t get_hardware_random_value(unsigned char *buf, size_t len);
* Returns the total entropy count, if it exceeds the requested
* entropy count. Otherwise, returns an entropy count of 0.
*/
-size_t prov_acquire_entropy_from_cpu(RAND_POOL *pool)
+size_t ossl_prov_acquire_entropy_from_cpu(RAND_POOL *pool)
{
size_t bytes_needed;
unsigned char *buffer;
|
acl2: fix bug in ACE matching logic
Tested-by: IoTivity Jenkins | @@ -110,15 +110,19 @@ oc_sec_ace_find_resource(oc_ace_res_t *start, oc_sec_ace_t *ace,
} else {
res = res->next;
}
+
while (res != NULL) {
- bool match = true;
+ bool positive = false, match = true;
if (href && oc_string_len(res->href) > 0) {
if ((strlen(href) + skip) != oc_string_len(res->href) ||
memcmp(oc_string(res->href) + skip, href,
oc_string_len(res->href) - skip) != 0) {
match = false;
+ } else {
+ positive = true;
}
}
+
if (match && rt && oc_string_array_get_allocated_size(res->types) > 0) {
size_t i, j;
bool rt_match = false;
@@ -137,21 +141,28 @@ oc_sec_ace_find_resource(oc_ace_res_t *start, oc_sec_ace_t *ace,
}
if (!rt_match) {
match = false;
+ } else {
+ positive = true;
}
}
+
if (match && interfaces != 0 && res->interfaces != 0) {
if ((interfaces & res->interfaces) == 0) {
match = false;
+ } else {
+ positive = true;
}
}
if (match && wildcard != 0 && res->wildcard != 0) {
if ((wildcard & res->wildcard) == 0) {
match = false;
+ } else {
+ positive = true;
}
}
- if (match) {
+ if (match && positive) {
return res;
}
@@ -535,8 +546,9 @@ oc_sec_ace_get_res(oc_ace_subject_type_t type, oc_ace_subject_t *subject,
got_ace:
res = oc_sec_ace_find_resource(NULL, ace, href, rt, interfaces, wildcard);
- if (!res && create)
+ if (!res && create) {
goto new_res;
+ }
goto done;
@@ -590,9 +602,11 @@ new_ace:
new_res:
res = oc_memb_alloc(&res_l);
-
if (res) {
+ res->wildcard = 0;
+ if (wildcard != OC_ACE_NO_WC) {
res->wildcard = wildcard;
+ }
#ifdef OC_DEBUG
switch (res->wildcard) {
case OC_ACE_WC_ALL_DISCOVERABLE:
|
amp_adapter: improve log
[Detail]
improve log with ulog system
[Verified Cases]
Build Pass: <py_engine_demo>
Test Pass: <py_engine_demo> | @@ -126,9 +126,9 @@ int aos_wifi_init(aos_wifi_manager_t *wifi_manager)
int ret = 0;
netmgr_hdl_t hdl = netmgr_get_dev(WIFI_DEV_PATH);
if (hdl >= 0) {
- LOGE(LOG_TAG, "wifi already init by other task\r\n");
+ LOGI(LOG_TAG, "wifi already init by other task\r\n");
} else {
- LOGE(LOG_TAG, "aos_wifi_init start");
+ LOGD(LOG_TAG, "aos_wifi_init start\r\n");
ret = event_service_init(NULL);
if (ret != 0) {
LOGE(LOG_TAG, "event_service_init failed\r\n");
|
esp32s2/fpga: Fix a clock configure in bootloader | @@ -25,9 +25,15 @@ void bootloader_clock_configure(void)
{
esp_rom_uart_tx_wait_idle(0);
- uint32_t clock = 40000000;
- ets_update_cpu_frequency(clock / 1000000);
- REG_WRITE(RTC_CNTL_STORE5_REG, (clock >> 12) | ((clock >> 12) << 16));
+ uint32_t xtal_freq_mhz = 40;
+#ifdef CONFIG_IDF_TARGET_ESP32S2
+ uint32_t apb_freq_hz = 20000000;
+#else
+ uint32_t apb_freq_hz = 40000000;
+#endif // CONFIG_IDF_TARGET_ESP32S2
+ ets_update_cpu_frequency(apb_freq_hz / 1000000);
+ REG_WRITE(RTC_CNTL_STORE5_REG, (apb_freq_hz >> 12) | ((apb_freq_hz >> 12) << 16));
+ REG_WRITE(RTC_CNTL_STORE4_REG, (xtal_freq_mhz) | ((xtal_freq_mhz) << 16));
}
void bootloader_fill_random(void *buffer, size_t length)
|
remove git and add alsa-lib-dev, alsa-utils, wget to alpine.sh | @@ -74,7 +74,7 @@ echo $alpine_url/community >> $root_dir/etc/apk/repositories
chroot $root_dir /bin/sh <<- EOF_CHROOT
apk update
-apk add openssh iw wpa_supplicant dhcpcd dnsmasq hostapd iptables dcron chrony gpsd git subversion make gcc musl-dev fftw-dev libconfig-dev curl nano
+apk add openssh iw wpa_supplicant dhcpcd dnsmasq hostapd iptables dcron chrony gpsd subversion make gcc musl-dev fftw-dev libconfig-dev alsa-lib-dev alsa-utils curl wget nano
ln -s /etc/init.d/bootmisc etc/runlevels/boot/bootmisc
ln -s /etc/init.d/hostname etc/runlevels/boot/hostname
|
peview: Fix open file dialog error message | @@ -50,8 +50,6 @@ INT WINAPI wWinMain(
};
PPH_STRING commandLine;
- CoInitializeEx(NULL, COINIT_APARTMENTTHREADED | COINIT_DISABLE_OLE1DDE);
-
if (!NT_SUCCESS(PhInitializePhLibEx(L"PE Viewer", ULONG_MAX, hInstance, 0, 0)))
return 1;
@@ -128,6 +126,9 @@ INT WINAPI wWinMain(
};
PVOID fileDialog;
+ if (!SUCCEEDED(CoInitializeEx(NULL, COINIT_APARTMENTTHREADED | COINIT_DISABLE_OLE1DDE)))
+ return 1;
+
fileDialog = PhCreateOpenFileDialog();
PhSetFileDialogOptions(fileDialog, PH_FILEDIALOG_NOPATHVALIDATE);
PhSetFileDialogFilter(fileDialog, filters, RTL_NUMBER_OF(filters));
@@ -148,8 +149,8 @@ INT WINAPI wWinMain(
PhGetString(applicationFileName),
PvFileName->Buffer,
SW_SHOWDEFAULT,
+ PH_SHELL_EXECUTE_NOZONECHECKS,
0,
- ULONG_MAX,
NULL
))
{
|
Test XML_ParseBuffer API in various parse states | @@ -2446,6 +2446,61 @@ START_TEST(test_misc_alloc_ns)
}
END_TEST
+/* Test XML_ParseBuffer interface with namespace and a dicky allocator */
+START_TEST(test_misc_alloc_ns_parse_buffer)
+{
+ XML_Memory_Handling_Suite memsuite = { duff_allocator, realloc, free };
+ XML_Char ns_sep[2] = { ' ', '\0' };
+ const char *text = "<doc>Hello</doc>";
+ void *buffer;
+
+ /* Make sure the basic parser is allocated */
+ allocation_count = 10000;
+ parser = XML_ParserCreate_MM(NULL, &memsuite, ns_sep);
+ if (parser == NULL)
+ fail("Parser not created");
+
+ /* Try a parse before the start of the world */
+ /* (Exercises new code path) */
+ allocation_count = 0;
+ if (XML_ParseBuffer(parser, 0, XML_FALSE) != XML_STATUS_ERROR)
+ fail("Pre-init XML_ParseBuffer not faulted");
+ if (XML_GetErrorCode(parser) != XML_ERROR_NO_MEMORY)
+ fail("Pre-init XML_ParseBuffer faulted for wrong reason");
+
+ /* Now with actual memory allocation */
+ allocation_count = 10000;
+ if (XML_ParseBuffer(parser, 0, XML_FALSE) != XML_STATUS_OK)
+ xml_failure(parser);
+
+ /* Get the parser into suspended state */
+ XML_SetCharacterDataHandler(parser, clearing_aborting_character_handler);
+ resumable = XML_TRUE;
+ buffer = XML_GetBuffer(parser, strlen(text));
+ if (buffer == NULL)
+ fail("Could not acquire parse buffer");
+ memcpy(buffer, text, strlen(text));
+ if (XML_ParseBuffer(parser, strlen(text),
+ XML_TRUE) != XML_STATUS_SUSPENDED)
+ xml_failure(parser);
+ if (XML_GetErrorCode(parser) != XML_ERROR_NONE)
+ xml_failure(parser);
+ if (XML_ParseBuffer(parser, strlen(text), XML_TRUE) != XML_STATUS_ERROR)
+ fail("Suspended XML_ParseBuffer not faulted");
+ if (XML_GetErrorCode(parser) != XML_ERROR_SUSPENDED)
+ xml_failure(parser);
+
+ /* Get it going again and complete the world */
+ XML_SetCharacterDataHandler(parser, NULL);
+ if (XML_ResumeParser(parser) != XML_STATUS_OK)
+ xml_failure(parser);
+ if (XML_ParseBuffer(parser, strlen(text), XML_TRUE) != XML_STATUS_ERROR)
+ fail("Post-finishing XML_ParseBuffer not faulted");
+ if (XML_GetErrorCode(parser) != XML_ERROR_FINISHED)
+ xml_failure(parser);
+}
+END_TEST
+
/* Test that freeing a NULL parser doesn't cause an explosion.
* (Not actually tested anywhere else)
*/
@@ -2987,6 +3042,7 @@ make_suite(void)
tcase_add_test(tc_misc, test_misc_alloc_create_parser_with_encoding);
tcase_add_test(tc_misc, test_misc_alloc_ns);
tcase_add_test(tc_misc, test_misc_null_parser);
+ tcase_add_test(tc_misc, test_misc_alloc_ns_parse_buffer);
suite_add_tcase(s, tc_alloc);
tcase_add_checked_fixture(tc_alloc, alloc_setup, alloc_teardown);
|
hw: mcu: pic32mz2048efg100: Fix spi mode | @@ -159,18 +159,18 @@ hal_spi_config_master(int spi_num, struct hal_spi_settings *psettings)
switch (psettings->data_mode) {
case HAL_SPI_MODE0:
- SPIxCONCLR(spi_num) = _SPI1CON_CKP_MASK | _SPI1CON_CKE_MASK;
- break;
- case HAL_SPI_MODE1:
SPIxCONCLR(spi_num) = _SPI1CON_CKP_MASK;
SPIxCONSET(spi_num) = _SPI1CON_CKE_MASK;
break;
+ case HAL_SPI_MODE1:
+ SPIxCONCLR(spi_num) = _SPI1CON_CKP_MASK | _SPI1CON_CKE_MASK;
+ break;
case HAL_SPI_MODE2:
- SPIxCONCLR(spi_num) = _SPI1CON_CKE_MASK;
- SPIxCONSET(spi_num) = _SPI1CON_CKP_MASK;
+ SPIxCONSET(spi_num) = _SPI1CON_CKP_MASK | _SPI1CON_CKE_MASK;
break;
case HAL_SPI_MODE3:
- SPIxCONSET(spi_num) = _SPI1CON_CKP_MASK | _SPI1CON_CKE_MASK;
+ SPIxCONCLR(spi_num) = _SPI1CON_CKE_MASK;
+ SPIxCONSET(spi_num) = _SPI1CON_CKP_MASK;
break;
default:
return -1;
|
py/objstr: When constructing str from bytes, check for existing qstr.
This patch uses existing qstr data where possible when constructing a str
from a bytes object. | @@ -164,6 +164,13 @@ mp_obj_t mp_obj_str_make_new(const mp_obj_type_t *type, size_t n_args, size_t n_
mp_raise_msg(&mp_type_UnicodeError, NULL);
}
#endif
+
+ // Check if a qstr with this data already exists
+ qstr q = qstr_find_strn((const char*)str_data, str_len);
+ if (q != MP_QSTR_NULL) {
+ return MP_OBJ_NEW_QSTR(q);
+ }
+
mp_obj_str_t *o = MP_OBJ_TO_PTR(mp_obj_new_str_copy(type, NULL, str_len));
o->data = str_data;
o->hash = str_hash;
|
arch: cxd56xx: Remove -Wmissing-braces warning
Remove -Wmissing-braces warning in cxd56_cpu1signal.c. | @@ -73,9 +73,11 @@ static struct cxd56cpu1_info_s g_cpu1_info =
{
INVALID_PROCESS_ID,
0,
+ {
{
0
}
+ }
};
/****************************************************************************
|
ble_att_svr: fix keysize check for SC Only mode
Keysize is kept in bytes and not bits | @@ -288,7 +288,7 @@ ble_att_svr_check_perms(uint16_t conn_handle, int is_read,
* require it on level 4
*/
if (MYNEWT_VAL(BLE_SM_SC_ONLY)) {
- if (sec_state.key_size != 128 ||
+ if (sec_state.key_size != 16 ||
!sec_state.authenticated ||
!sec_state.encrypted) {
return BLE_ATT_ERR_INSUFFICIENT_KEY_SZ;
|
IPsec: increment tunnel intf tx counters
Recent changes removed the function that was incrementing the
tx counters. Increment them in the esp_encrypt functions. | @@ -114,6 +114,8 @@ dpdk_esp_encrypt_inline (vlib_main_t * vm,
{
u32 n_left_from, *from, *to_next, next_index, thread_index;
ipsec_main_t *im = &ipsec_main;
+ vnet_main_t *vnm = im->vnet_main;
+ vnet_interface_main_t *vim = &vnm->interface_main;
u32 thread_idx = vlib_get_thread_index ();
dpdk_crypto_main_t *dcm = &dpdk_crypto_main;
crypto_resource_t *res = 0;
@@ -304,6 +306,13 @@ dpdk_esp_encrypt_inline (vlib_main_t * vm,
(&ipsec_sa_counters, thread_index, sa_index0,
1, b0->current_length);
+ /* Update tunnel interface tx counters */
+ if (is_tun)
+ vlib_increment_combined_counter
+ (vim->combined_sw_if_counters + VNET_INTERFACE_COUNTER_TX,
+ thread_index, vnet_buffer (b0)->sw_if_index[VLIB_TX],
+ 1, b0->current_length);
+
res->ops[res->n_ops] = op;
res->bi[res->n_ops] = bi0;
res->n_ops += 1;
|
lwip - Fix time calculation.
The `sys_now` function is supposed to calculate milliseconds since boot.
However, the operands were not in the correct order, so the units
were off.
In sim, this caused the tcpip_thread() task handler to never yield to
other tasks during timeout calculation. | @@ -106,7 +106,7 @@ sys_now(void)
/*
* XXX not right when g_os_time rolls over
*/
- t = os_time_get() * OS_TICKS_PER_SEC / 1000;
+ t = os_time_get() * 1000 / OS_TICKS_PER_SEC;
return t;
}
|
[update] return value judgment. | @@ -88,8 +88,20 @@ static int uart_dma_sample(int argc, char *argv[])
sizeof(msg_pool),
RT_IPC_FLAG_FIFO);
- rt_device_open(serial, RT_DEVICE_FLAG_RDWR | RT_DEVICE_FLAG_DMA_RX);
- rt_device_set_rx_indicate(serial, uart_input);
+ ret = rt_device_open(serial, RT_DEVICE_FLAG_RDWR | RT_DEVICE_FLAG_DMA_RX);
+ if (ret != RT_EOK)
+ {
+ rt_kprintf("serial device open fail!.\n");
+ return -RT_ERROR;
+ }
+
+ ret = rt_device_set_rx_indicate(serial, uart_input);
+ if (ret != RT_EOK)
+ {
+ rt_kprintf("set rx indicate fail!.\n");
+ return -RT_ERROR;
+ }
+
rt_device_write(serial, 0, str, (sizeof(str) - 1));
rt_thread_t thread = rt_thread_create("serial", serial_thread_entry, RT_NULL, 1024, 25, 10);
|
GraphContent: paragraphs allow for wrapping | @@ -284,7 +284,7 @@ const renderers = {
paragraph: ({ children }) => {
return (
<Box display="block">
- <Text fontSize={1} lineHeight="tall">
+ <Text fontSize={1} lineHeight="tall" style={{ 'overflowWrap': 'break-word' }}>
{children}
</Text>
</Box>
|
clk: initialize wifi lp_clk in esp_perip_clk_init | @@ -180,6 +180,23 @@ void rtc_clk_select_rtc_slow_clk(void)
__attribute__((weak)) void esp_perip_clk_init(void)
{
modem_clock_domain_pmu_state_icg_map_init();
+
+ /* During system initialization, the low-power clock source of the modem
+ * (WiFi, BLE or Coexist) follows the configuration of the slow clock source
+ * of the system. If the WiFi, BLE or Coexist module needs a higher
+ * precision sleep clock (for example, the BLE needs to use the main XTAL
+ * oscillator (40 MHz) to provide the clock during the sleep process in some
+ * scenarios), the module needs to switch to the required clock source by
+ * itself. */ //TODO - WIFI-5233
+ soc_rtc_slow_clk_src_t rtc_slow_clk_src = rtc_clk_slow_src_get();
+ modem_clock_lpclk_src_t modem_lpclk_src = (modem_clock_lpclk_src_t) ( \
+ (rtc_slow_clk_src == SOC_RTC_SLOW_CLK_SRC_RC_SLOW) ? MODEM_CLOCK_LPCLK_SRC_RC_SLOW \
+ : (rtc_slow_clk_src == SOC_RTC_SLOW_CLK_SRC_XTAL32K) ? MODEM_CLOCK_LPCLK_SRC_XTAL32K \
+ : (rtc_slow_clk_src == SOC_RTC_SLOW_CLK_SRC_RC32K) ? MODEM_CLOCK_LPCLK_SRC_RC32K \
+ : (rtc_slow_clk_src == SOC_RTC_SLOW_CLK_SRC_OSC_SLOW) ? MODEM_CLOCK_LPCLK_SRC_EXT32K \
+ : SOC_RTC_SLOW_CLK_SRC_RC_SLOW);
+ modem_clock_select_lp_clock_source(PERIPH_WIFI_MODULE, modem_lpclk_src, 0);
+
ESP_EARLY_LOGW(TAG, "esp_perip_clk_init() has not been implemented yet");
#if 0 // TODO: IDF-5658
uint32_t common_perip_clk, hwcrypto_perip_clk, wifi_bt_sdio_clk = 0;
|
add cma=36M to uEnv-ext4.txt | @@ -9,4 +9,4 @@ devicetree_load_address=0x2000000
bootcmd=fatload mmc 0 ${kernel_load_address} ${kernel_image} && fatload mmc 0 ${devicetree_load_address} ${devicetree_image} && bootm ${kernel_load_address} - ${devicetree_load_address}
-bootargs=console=ttyPS0,115200 root=/dev/mmcblk0p2 ro rootfstype=ext4 earlyprintk rootwait
+bootargs=console=ttyPS0,115200 root=/dev/mmcblk0p2 ro rootfstype=ext4 earlyprintk rootwait cma=36M
|
only match first error/success | @@ -7,11 +7,16 @@ term =
pty.spawn './urbit' <[-B urbit.pill -A .. -cFI zod zod]>
.on \data -> process.stdout.write it
+fin = no
term.pipe (new stream-snitch /dojo> /g).on \match ->
+ return if fin
+ fin := yes
console.log "\n\n---\nnode: got dojo!\n---\n\n"
set-timeout (-> process.exit 0), 1000 # should probably test further
term.pipe (new stream-snitch /ford: /g).on \match ->
+ return if fin
+ fin := yes
console.log "\n\n---\nnode: detected error\n---\n\n"
set-timeout (-> process.exit 1), 1000
|
Link VulkanMemoryAllocator to Vulkan only if static linking is enabled | @@ -15,12 +15,10 @@ set_target_properties(
target_include_directories(VulkanMemoryAllocator PUBLIC ${PROJECT_SOURCE_DIR}/include)
-target_link_libraries(
- VulkanMemoryAllocator
-
- PUBLIC
- Vulkan::Vulkan
-)
+# Only link to Vulkan if static linking is used
+if (NOT ${VMA_DYNAMIC_VULKAN_FUNCTIONS})
+ target_link_libraries(VulkanMemoryAllocator PUBLIC Vulkan::Vulkan)
+endif()
target_compile_definitions(
VulkanMemoryAllocator
|
Subsets and Splits
No saved queries yet
Save your SQL queries to embed, download, and access them later. Queries will appear here once saved.