message
stringlengths
6
474
diff
stringlengths
8
5.22k
Remove wrong file in ESP32 CMake
@@ -19,7 +19,6 @@ list(APPEND TARGET_ESP32_NANOCLR_SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/nanoHAL.cp # append target HAL source files list(APPEND TARGET_ESP32_NANOCLR_SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/targetHAL_Time.cpp") -list(APPEND TARGET_ESP32_NANOCLR_SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/targetHAL_Network.cpp") # append target PAL source files list(APPEND TARGET_ESP32_NANOCLR_SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/targetPAL_Events.cpp")
in_windows_exporter_metrics: use new CFL timer api
@@ -929,7 +929,7 @@ int we_perflib_update_counters(struct flb_we *ctx, int result; - timestamp = cmt_time_now(); + timestamp = cfl_time_now(); result = we_perflib_query(ctx, query, &measurement);
add k210 to ci queue
@@ -145,6 +145,7 @@ jobs: - {RTT_BSP: "hc32l196", RTT_TOOL_CHAIN: "sourcery-arm"} - {RTT_BSP: "tae32f5300", RTT_TOOL_CHAIN: "sourcery-arm"} - {RTT_BSP: "bluetrum/ab32vg1-ab-prougen", RTT_TOOL_CHAIN: "sourcery-riscv64-unknown-elf"} + - {RTT_BSP: "k210", RTT_TOOL_CHAIN: "sourcery-riscv-none-embed"} steps: - uses: actions/checkout@v2 - name: Set up Python
DSC: Fix *NIX build issues
[BuildOptions] # While there are no PCDs as of now, there at least are some custom macros. DEFINE OCPKG_BUILD_OPTIONS_GEN = -D DISABLE_NEW_DEPRECATED_INTERFACES $(OCPKG_BUILD_OPTIONS) - DEFINE OCPKG_ANAL_OPTIONS_GEN = -DANALYZER_UNREACHABLE=__builtin_unreachable -DANALYZER_NORETURN=__attribute__((noreturn)) + DEFINE OCPKG_ANAL_OPTIONS_GEN = "-DANALYZER_UNREACHABLE=__builtin_unreachable" "-DANALYZER_NORETURN=__attribute__((noreturn))" GCC:DEBUG_*_*_CC_FLAGS = -D OC_TARGET_DEBUG=1 $(OCPKG_BUILD_OPTIONS_GEN) $(OCPKG_ANAL_OPTIONS_GEN) GCC:NOOPT_*_*_CC_FLAGS = -D OC_TARGET_NOOPT=1 $(OCPKG_BUILD_OPTIONS_GEN) $(OCPKG_ANAL_OPTIONS_GEN)
Fix dead code in sslLogCallback relating to should_log variable. Coverity scans found that the should_log logic in sslLogCallback is not working as expected because the variable is not correctly initialised (the conditional code before logging always sets the value to 1, which it already is).
@@ -82,8 +82,8 @@ redisContextFuncs redisContextSSLFuncs; * Callback used for debugging */ static void sslLogCallback(const SSL *ssl, int where, int ret) { - const char *retstr = ""; - int should_log = 1; + const char *retstr; + int should_log = 0; /* Ignore low-level SSL stuff */ if (where & SSL_CB_ALERT) {
Reword description for GUC dtx_phase2_retry_second
@@ -3951,8 +3951,10 @@ struct config_int ConfigureNamesInt_gp[] = { {"dtx_phase2_retry_second", PGC_SUSET, GP_ARRAY_TUNING, - gettext_noop("Maximum number of timeout during two phase commit after which master PANICs."), - NULL, + gettext_noop("Maximum time for which coordinator tries to finish a prepared transaction"), + gettext_noop("The timer starts if finising a prepared transaction fails." + " Coordinator keeps retrying the finish-prepared operation" + " until this timeout (seconds)."), GUC_SUPERUSER_ONLY | GUC_NO_SHOW_ALL | GUC_NOT_IN_SAMPLE | GUC_UNIT_S }, &dtx_phase2_retry_second,
Travis: Please begin using Trusty.
@@ -2,21 +2,12 @@ language: cpp os: - linux sudo: false +dist: trusty notifications: email: on_success: change # [always|never|change] # default: change on_failure: always # [always|never|change] # default: always -addons: - apt: - sources: - # The cmake Travis has doesn't like the add_executable line. - # This is the fix I found. - - george-edison55-precise-backports # cmake 3.2.3 / doxygen 1.8.3 - packages: - - cmake - - cmake-data - script: - mkdir build - pushd build
Update docs/Chipyard-Basics/Configs-Parameters-Mixins.rst [skip ci]
@@ -103,6 +103,31 @@ implementation. The lazy module defines all the logical connections between generators and exchanges configuration information among them, while the module implementation performs the actual Chisel RTL elaboration. +In the MySoC example class, the "outer" ``MySoC`` instantiates the "inner" +``MySoCModuleImp`` as a lazy module. This delays immediate elaboration +of the module. The ``RocketSubsystem`` outer base class, as well as the +``HasPeripheryX`` outer traits contain code to perform high-level logical +connections. For example, the ``HasPeripherySerial`` outer trait contains code +to lazily instantiate the ``SerialAdapter``, and connect the SerialAdapter's +TileLink node to the frontbus. + +The ``ModuleImp`` classes and traits perform elaboration of real RTL. +For example, the ``HasPeripherySerialModuleImp`` trait physically connects +the ``SerialAdapter`` module, and instantiates queues. + +In the test harness, the SoC is elaborated with +``val dut = Module(LazyModule(MySoC))``. +After elaboration, the result will be a MySoC module, which contains a +SerialAdapter module (among others). + +From a high level, classes which extend LazyModule *must* reference +their module implementation through``lazy val module``, and they +*may* optionally reference other lazy modules (which will elaborate + as child modules in the module hierarchy). The "inner" modules + contain the implementation for the module, and may instantiate + other normal modules OR lazy modules (for nested Diplomacy + graphs, for example. This is very advanced). + Mix-in ---------------------------
Add a function call, cause we can
#define N 10 +__device__ int foo(int i) { return i + 1; } + __global__ void addVector(int *vectorA, int *vectorB, int *vectorC) { int i = hipBlockIdx_x; if (i < N) { - vectorC[i] = vectorA[i] + vectorB[i]; + vectorC[i] = vectorA[i] + vectorB[i] + foo(i); } }
admin/prun: register openmpi4 variant
@@ -257,6 +257,8 @@ elif [ $LMOD_FAMILY_MPI == "openmpi" ];then launch_openmpi $EXEC $ARGS elif [ $LMOD_FAMILY_MPI == "openmpi3" ];then launch_openmpi $EXEC $ARGS +elif [ $LMOD_FAMILY_MPI == "openmpi4" ];then + launch_openmpi $EXEC $ARGS else _error "Unsupported or unknown MPI family -> $LMOD_FAMILY_MPI" fi
Update TSCH Readme file
@@ -89,25 +89,9 @@ To use TSCH, first make sure your platform supports it. Currently, `jn516x`, `sky`, `z1`, `cc2538dk`, `zoul`, `openmote-cc2538`, `srf06-cc26xx`, and `cooja` are the supported platforms. To add your own, we refer the reader to the next section. -To add TSCH to your application, first include the TSCH module from your makefile with: +To add TSCH to your application, configure the TSCH module from your makefile with: -`MODULES += os/net/mac/tsch` - -Then, enable TSCH from your project conf with the following: - -``` -/* Netstack layers */ -#undef NETSTACK_CONF_MAC -#define NETSTACK_CONF_MAC tschmac_driver -#undef NETSTACK_CONF_RDC -#define NETSTACK_CONF_RDC nordc_driver -#undef NETSTACK_CONF_FRAMER -#define NETSTACK_CONF_FRAMER framer_802154 - -/* IEEE802.15.4 frame version */ -#undef FRAME802154_CONF_VERSION -#define FRAME802154_CONF_VERSION FRAME802154_IEEE802154E_2012 -``` +`MAKE_MAC = MAKE_MAC_TSCH` If you are running with RPL, it is recommended to enable the `tsch-rpl` module with:
u3: adds u3qdb_wyt declaration
# define u3qdb_tap u3qdi_tap u3_noun u3qdb_uni(u3_noun, u3_noun); u3_noun u3qdb_urn(u3_noun, u3_noun); +# define u3qdb_wyt u3qdi_wyt u3_noun u3qdi_apt(u3_noun); u3_noun u3qdi_bif(u3_noun, u3_noun);
actions: fix install dir
@@ -66,7 +66,9 @@ jobs: brew postinstall dbus brew services restart dbus cmake -E make_directory ${{runner.workspace}}/build - echo "INSTALL_DIR=${{runner.workspace}}/build/install" >> $GITHUB_ENV + export INSTALL_DIR=${{runner.workspace}}/build/install + echo $INSTALL_DIR + echo "INSTALL_DIR=$INSTALL_DIR" >> $GITHUB_ENV echo "$INSTALL_DIR/bin" >> $GITHUB_PATH export JAVA_HOME=$(/usr/libexec/java_home --failfast) echo "$JAVA_HOME/bin" >> $GITHUB_PATH
Using engine's task instead of listen's task.
@@ -1033,6 +1033,10 @@ nxt_router_listen_socket_close(nxt_task_t *task, void *obj, void *data) joint = listen->socket.data; nxt_queue_remove(&listen->link); + + /* 'task' refers to listen->task and we cannot use after nxt_free() */ + task = &task->thread->engine->task; + nxt_free(listen); nxt_router_listen_socket_release(task, joint);
Return an error when trying to add rules that contain undefined permission groups.
++ perm |= {pax/path rit/rite} ^+ +> + =/ mis/(set @ta) + %+ roll + =- ~(tap in -) + ?- -.rit + $r who:(fall red.rit *rule) + $w who:(fall wit.rit *rule) + $rw (~(uni in who:(fall red.rit *rule)) who:(fall wit.rit *rule)) + == + |= {w/whom s/(set @ta)} + ?: |(?=($& -.w) (~(has by cez) p.w)) s + (~(put in s) p.w) + ?^ mis + =- (emit hen %give %mack `[%leaf "No such group(s): {-}"]~) + %+ roll ~(tap in `(set @ta)`mis) + |= {g/@ta t/tape} + ?~ t (trip g) + :(weld t ", " (trip g)) =< (emit hen %give %mack ~) ?- -.rit $r wake(per (put-perm per pax red.rit))
dojo: BMI260 motion sensor tuning Tuning standard ref of BMI260 motion sensor. BRANCH=cherry TEST=ectool motionsense
@@ -88,6 +88,12 @@ static const mat33_fp_t lid_standard_ref = { { 0, 0, FLOAT_TO_FP(-1)} }; +static const mat33_fp_t bmi260_standard_ref = { + { 0, FLOAT_TO_FP(-1), 0}, + { FLOAT_TO_FP(1), 0, 0}, + { 0, 0, FLOAT_TO_FP(1)} +}; + struct motion_sensor_t motion_sensors[] = { /* * Note: bmi160: supports accelerometer and gyro sensor @@ -177,7 +183,7 @@ struct motion_sensor_t bmi260_base_accel = { .drv_data = &g_bmi260_data, .port = I2C_PORT_ACCEL, .i2c_spi_addr_flags = BMI260_ADDR0_FLAGS, - .rot_standard_ref = &base_standard_ref, + .rot_standard_ref = &bmi260_standard_ref, .min_frequency = BMI_ACCEL_MIN_FREQ, .max_frequency = BMI_ACCEL_MAX_FREQ, .default_range = 4, /* g */ @@ -207,7 +213,7 @@ struct motion_sensor_t bmi260_base_gyro = { .port = I2C_PORT_ACCEL, .i2c_spi_addr_flags = BMI260_ADDR0_FLAGS, .default_range = 1000, /* dps */ - .rot_standard_ref = &base_standard_ref, + .rot_standard_ref = &bmi260_standard_ref, .min_frequency = BMI_GYRO_MIN_FREQ, .max_frequency = BMI_GYRO_MAX_FREQ, };
added devices, known as working
@@ -94,12 +94,19 @@ Manufacturers do change chipsets without changing model numbers. Sometimes they This list is for information purposes only and should not be regarded as a binding presentation of the products: | VENDOR MODEL | ID | -| -------------------- | --------------------------------------------------------------------------------- | +| -------------------- | --------------------------------------------------------------------------------------------- | | EDIMAX EW-7711UAN | ID 7392:7710 Edimax Technology Co., Ltd | | ALLNET ALL-WA0150N | ID 148f:7601 Ralink Technology, Corp. MT7601U Wireless Adapter | | SEMPRE WU150-1 | ID 148f:7601 Ralink Technology, Corp. MT7601U Wireless Adapter | -| TP-LINK Archer T2UH | ID 148f:761a Ralink Technology, Corp. MT7610U ("Archer T2U" 2.4G+5G WLAN Adapter) | | TENDA W311U+ | ID 148f:3070 Ralink Technology, Corp. RT2870/RT3070 Wireless Adapter | +| ALFA AWUS036H | ID 0bda:8187 Realtek Semiconductor Corp. RTL8187 Wireless Adapter | +| ALFA AWUS036NH | ID 148f:3070 Ralink Technology, Corp. RT2870/RT3070 Wireless Adapter | +| LogiLink WL0151 | ID 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter | +| TP-LINK TL-WN722N v1 | ID 0cf3:9271 Qualcomm Atheros Communications AR9271 802.11n | +| TP-LINK Archer T2UH* | ID 148f:761a Ralink Technology, Corp. MT7610U ("Archer T2U" 2.4G+5G WLAN Adapter) | +| ASUS USB-AC51* | ID 0b05:17d1 ASUSTek Computer, Inc. AC51 802.11a/b/g/n/ac Wireless Adapter [Mediatek MT7610U] | + +* kernel >= 5.4 recommended! Always verify the actual chipset with 'lsusb' and/or 'lspci'!
fix the position of ] in IPv6 stringify
@@ -144,8 +144,8 @@ void json_write_pair_c(FILE *out, const char *name, size_t name_len, const h2olo // e.g. [2001:0db8:85a3::8a2e:0370:7334]:12345" fputs("\"[", out); fwrite(addr, 1, addr_len, out); + fputs("]\"", out); fputc(':', out); fprintf(out, "%" PRId32, port); - fputs("]\"", out); } }
Validate length before use it, not vice versa. r353060 should have contained this... This fixes
#ifdef __FreeBSD__ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: head/sys/netinet/sctp_asconf.c 353123 2019-10-05 13:28:01Z tuexen $"); +__FBSDID("$FreeBSD: head/sys/netinet/sctp_asconf.c 353303 2019-10-08 11:07:16Z tuexen $"); #endif #include <netinet/sctp_os.h> @@ -343,11 +343,11 @@ sctp_process_asconf_delete_ip(struct sockaddr *src, #endif aparam_length = ntohs(aph->ph.param_length); - ph = (struct sctp_paramhdr *)(aph + 1); - param_type = ntohs(ph->param_type); if (aparam_length < sizeof(struct sctp_asconf_paramhdr) + sizeof(struct sctp_paramhdr)) { return (NULL); } + ph = (struct sctp_paramhdr *)(aph + 1); + param_type = ntohs(ph->param_type); #if defined(INET) || defined(INET6) param_length = ntohs(ph->param_length); if (param_length + sizeof(struct sctp_asconf_paramhdr) != aparam_length) {
Properly return error on EVP_PKEY_CTX_set_dh_nid and EVP_PKEY_CTX_set_dhx_rfc5114 Fixes
@@ -1004,8 +1004,11 @@ static int fix_dh_nid(enum state state, return 0; if (state == PRE_CTRL_TO_PARAMS) { - ctx->p2 = (char *)ossl_ffc_named_group_get_name - (ossl_ffc_uid_to_dh_named_group(ctx->p1)); + if ((ctx->p2 = (char *)ossl_ffc_named_group_get_name + (ossl_ffc_uid_to_dh_named_group(ctx->p1))) == NULL) { + ERR_raise(ERR_LIB_EVP, EVP_R_INVALID_VALUE); + return 0; + } ctx->p1 = 0; } @@ -1028,16 +1031,24 @@ static int fix_dh_nid5114(enum state state, switch (state) { case PRE_CTRL_TO_PARAMS: - ctx->p2 = (char *)ossl_ffc_named_group_get_name - (ossl_ffc_uid_to_dh_named_group(ctx->p1)); + if ((ctx->p2 = (char *)ossl_ffc_named_group_get_name + (ossl_ffc_uid_to_dh_named_group(ctx->p1))) == NULL) { + ERR_raise(ERR_LIB_EVP, EVP_R_INVALID_VALUE); + return 0; + } + ctx->p1 = 0; break; case PRE_CTRL_STR_TO_PARAMS: if (ctx->p2 == NULL) return 0; - ctx->p2 = (char *)ossl_ffc_named_group_get_name - (ossl_ffc_uid_to_dh_named_group(atoi(ctx->p2))); + if ((ctx->p2 = (char *)ossl_ffc_named_group_get_name + (ossl_ffc_uid_to_dh_named_group(atoi(ctx->p2)))) == NULL) { + ERR_raise(ERR_LIB_EVP, EVP_R_INVALID_VALUE); + return 0; + } + ctx->p1 = 0; break;
Nissa: modify Amber LED RGB setting <R, G, B> = <70, 30, 0> BRANCH=none TEST=check Amber LED as expected
color-map-blue = < 0 0 100>; color-map-yellow = < 0 50 50>; color-map-white = <100 100 100>; - color-map-amber = <100 5 0>; + color-map-amber = < 70 30 0>; brightness-range = <100 100 100 0 0 0>;
docs: fix documentation wrongly stating ESP_SLEEP_WAKEUP_GPIO is light sleep only ESP_SLEEP_WAKEUP_GPIO is also a valid deep sleep wakeup cause on targets with SOC_GPIO_SUPPORT_DEEPSLEEP_WAKEUP Closes
@@ -75,7 +75,7 @@ typedef enum { ESP_SLEEP_WAKEUP_TIMER, //!< Wakeup caused by timer ESP_SLEEP_WAKEUP_TOUCHPAD, //!< Wakeup caused by touchpad ESP_SLEEP_WAKEUP_ULP, //!< Wakeup caused by ULP program - ESP_SLEEP_WAKEUP_GPIO, //!< Wakeup caused by GPIO (light sleep only) + ESP_SLEEP_WAKEUP_GPIO, //!< Wakeup caused by GPIO (light sleep only on ESP32, S2 and S3) ESP_SLEEP_WAKEUP_UART, //!< Wakeup caused by UART (light sleep only) ESP_SLEEP_WAKEUP_WIFI, //!< Wakeup caused by WIFI (light sleep only) ESP_SLEEP_WAKEUP_COCPU, //!< Wakeup caused by COCPU int
Add correct flags for CLANG_CL
@@ -2385,15 +2385,7 @@ SSE41_CFLAGS= AVX_CFLAGS= AVX2_CFLAGS= when ($ARCH_X86_64 || $ARCH_I386) { - when ($MSVC) { - SSE2_CFLAGS=/D__SSE2__=1 - SSE3_CFLAGS=/D__SSE3__=1 - SSSE3_CFLAGS=/D__SSSE3__=1 - SSE41_CFLAGS=/D__SSE41__=1 - AVX_CFLAGS=/arch:AVX - AVX2_CFLAGS=/arch:AVX2 - } - elsewhen ($CLANG || $GCC) { + when ($CLANG || $CLANG_CL || $GCC) { SSE2_CFLAGS=-msse2 SSE3_CFLAGS=-msse3 SSSE3_CFLAGS=-mssse3 @@ -2401,6 +2393,14 @@ when ($ARCH_X86_64 || $ARCH_I386) { AVX_CFLAGS=-mavx AVX2_CFLAGS=-mavx2 } + elsewhen ($MSVC) { + SSE2_CFLAGS=/D__SSE2__=1 + SSE3_CFLAGS=/D__SSE3__=1 + SSSE3_CFLAGS=/D__SSSE3__=1 + SSE41_CFLAGS=/D__SSE41__=1 + AVX_CFLAGS=/arch:AVX + AVX2_CFLAGS=/arch:AVX2 + } } ### Generic macro definition for _SRC (just a placeholder, it does nothing)
BugID:17787848:[PreValidate] Add SYSINFO_ARCH/SYSINFO_MCU define for yts certificate
@@ -183,6 +183,8 @@ endif GLOBAL_CFLAGS += -DSYSINFO_PRODUCT_MODEL=\"$(CONFIG_SYSINFO_PRODUCT_MODEL)\" GLOBAL_CFLAGS += -DSYSINFO_DEVICE_NAME=\"$(CONFIG_SYSINFO_DEVICE_NAME)\" +GLOBAL_CFLAGS += -DSYSINFO_ARCH=\"$(HOST_ARCH)\" +GLOBAL_CFLAGS += -DSYSINFO_MCU=\"$(HOST_MCU_FAMILY)\" # Keil project support $(NAME)_KEIL_VENDOR = STMicroelectronics
Use `runpy` to run modules
This script asks user for input and runs the given command. """ -import importlib import os import os.path import sys import traceback import pyto +import runpy if len(sys.argv) == 1: usage = "Usage: <module-name> [<args>]" @@ -31,28 +31,11 @@ def main(): bin = os.path.expanduser("~/Documents/stash_extensions/bin") sys.path.insert(-1, bin) - spec = importlib.util.find_spec(module_name) - try: - sys.path.remove(bin) - except ValueError: - pass - if spec is None: - print("python: No module named "+module_name) - return - module_path = spec.origin - - __main__path = os.path.dirname(module_path)+"/main.py" - if not os.path.isfile(__main__path): - __main__path = os.path.dirname(module_path)+"/__main__.py" - if os.path.isfile(__main__path) and os.path.basename(module_path) == "__init__.py": - module_path = __main__path sys.argv = command try: - spec = importlib.util.spec_from_file_location("__main__", module_path) - script = importlib.util.module_from_spec(spec) - spec.loader.exec_module(script) + runpy._run_module_as_main(module_name) except KeyboardInterrupt: pass except SystemExit:
apps/examples/procfs_test: Fix wrong entry function name Fix wrong entry function name to 'procfs_test_main'
@@ -200,7 +200,7 @@ static int read_pid_entry(FAR const char *dirpath, FAR struct dirent *entryp, FA #ifdef CONFIG_BUILD_KERNEL int main(int argc, FAR char *argv[]) #else -int proc_test_main(int argc, char *argv[]) +int procfs_test_main(int argc, char *argv[]) #endif { int ret;
Specify input types actions
res) (defn reverse - "Reverses the order of the elements in a given array or tuple and returns it + "Reverses the order of the elements in a given array or buffer and returns it mutated." [t] (def len-1 (- (length t) 1)) (defn reversed "Reverses the order of the elements in a given array or tuple and returns - a new array." + a new array. If string or buffer is provided function returns array of chars reversed." [t] (def len (length t)) (var n (- len 1))
only frequencies between 2400 and 7000MHz are valid
@@ -819,7 +819,7 @@ if(eapolmsgerrorcount > 0) fprintf(stdout, "EAPOL messages (malformed packets). c = 0; fprintf(stdout, "\nfrequency statistics (frequency: received packets)\n" "--------------------------------------------------\n"); -for(p = 0; p < 0xffff; p ++) +for(p = 2400; p < 7000; p ++) { if(usedfrequency[p] != 0) {
tls13:server:Add finalize write_server_hello and dummy body
@@ -759,6 +759,21 @@ static int ssl_tls13_prepare_server_hello( mbedtls_ssl_context *ssl ) return( ret ); } +static int ssl_tls13_write_client_hello_body( mbedtls_ssl_context *ssl, + unsigned char *buf, + unsigned char *end, + size_t *out_len ) +{ + return( MBEDTLS_ERR_SSL_FEATURE_UNAVAILABLE ); +} + + +static int ssl_tls13_finalize_server_hello( mbedtls_ssl_context *ssl ) +{ + mbedtls_ssl_handshake_set_state( ssl, MBEDTLS_SSL_ENCRYPTED_EXTENSIONS ); + return( 0 ); +} + static int ssl_tls13_write_server_hello( mbedtls_ssl_context *ssl ) { int ret = 0;
fixing kink~
* For information on usage and redistribution, and for a DISCLAIMER OF ALL * WARRANTIES, see the file, "LICENSE.txt," in this distribution. */ -/* CHECKED negative float in 2nd inlet: "illegal slope value %f", - but no complaints for signal input -- this is impossible in Pd. - The only thing we could do (and a bit stupid one) would be to - clock this exception out from the perf routine. */ - #include "m_pd.h" static t_class *kink_class; @@ -26,7 +21,7 @@ static t_int *kink_perform(t_int *w) { float iph = *in1++; float slope = *in2++; - slope = (slope < 0 ? 100 : slope); + slope = (slope < 0 ? 0 : slope > 100 ? 100 : slope); float oph = iph * slope; if (oph > .5) {
cr50: prepare to release 0.4.20 BRANCH=cr50 TEST=none
"timestamp": 0, "epoch": 0, // FWR diversification contributor, 32 bits. "major": 4, // FW2_HIK_CHAIN counter. - "minor": 19, // Mostly harmless version field. + "minor": 20, // Mostly harmless version field. "applysec": -1, // Mask to and with fuse BROM_APPLYSEC. "config1": 13, // Which BROM_CONFIG1 actions to take before launching. "err_response": 0, // Mask to or with fuse BROM_ERR_RESPONSE.
esp32/machine_pin: Add new PULL_HOLD pin pull mode.
#include "machine_rtc.h" #include "modesp32.h" +// Used to implement gpio_hold_en() functionality; value should be distinct from all IDF pull modes +#define GPIO_PULLHOLD (8) + typedef struct _machine_pin_obj_t { mp_obj_base_t base; gpio_num_t id; @@ -168,7 +171,15 @@ STATIC mp_obj_t machine_pin_obj_init_helper(const machine_pin_obj_t *self, size_ if (args[ARG_pull].u_obj == mp_const_none) { gpio_set_pull_mode(self->id, GPIO_FLOATING); } else { - gpio_set_pull_mode(self->id, mp_obj_get_int(args[ARG_pull].u_obj)); + int mode = mp_obj_get_int(args[ARG_pull].u_obj); + if (mode == GPIO_PULLHOLD) { + gpio_hold_en(self->id); + } else { + if (GPIO_IS_VALID_OUTPUT_GPIO(self->id)) { + gpio_hold_dis(self->id); + } + gpio_set_pull_mode(self->id, mode); + } } } @@ -320,6 +331,7 @@ STATIC const mp_rom_map_elem_t machine_pin_locals_dict_table[] = { { MP_ROM_QSTR(MP_QSTR_OPEN_DRAIN), MP_ROM_INT(GPIO_MODE_INPUT_OUTPUT_OD) }, { MP_ROM_QSTR(MP_QSTR_PULL_UP), MP_ROM_INT(GPIO_PULLUP_ONLY) }, { MP_ROM_QSTR(MP_QSTR_PULL_DOWN), MP_ROM_INT(GPIO_PULLDOWN_ONLY) }, + { MP_ROM_QSTR(MP_QSTR_PULL_HOLD), MP_ROM_INT(GPIO_PULLHOLD) }, { MP_ROM_QSTR(MP_QSTR_IRQ_RISING), MP_ROM_INT(GPIO_PIN_INTR_POSEDGE) }, { MP_ROM_QSTR(MP_QSTR_IRQ_FALLING), MP_ROM_INT(GPIO_PIN_INTR_NEGEDGE) }, { MP_ROM_QSTR(MP_QSTR_WAKE_LOW), MP_ROM_INT(GPIO_PIN_INTR_LOLEVEL) },
Current directory variable $(CURDIR) instead of "/path/to/vplanet/" (in right branch) This will allow anybody to immediately use the copied line without having to edit it.
@@ -22,7 +22,7 @@ default: @echo 'tsch: set path=($$path /path/to/vplanet/)' @echo 'csh : set path=($$path /path/to/vplanet/)' @echo 'or permanently add the VPLanet directory to the $$PATH by editing the appropriate environment file. e.g.:' - @echo 'bash: echo '"'"'export PATH=$$PATH:/path/to/vplanet/'"'"' >> ~/.bashrc' + @echo 'bash: echo '"'"'export PATH=$$PATH:$(CURDIR)'"'"' >> ~/.bashrc' @echo "==========================================================================================================" debug: @@ -41,7 +41,7 @@ opt: @echo 'tsch: set path=($$path /path/to/vplanet/)' @echo 'csh : set path=($$path /path/to/vplanet/)' @echo 'or permanently add the VPLanet directory to the $$PATH by editing the appropriate environment file. e.g.:' - @echo 'bash: echo '"'"'export PATH=$$PATH:/path/to/vplanet/'"'"' >> ~/.bashrc' + @echo 'bash: echo '"'"'export PATH=$$PATH:$(CURDIR)'"'"' >> ~/.bashrc' @echo "==========================================================================================================" profile:
NetKVM: LockFreeQueue: Fix Dequeue methods
@@ -248,6 +248,11 @@ public: TEntryType *Dequeue() { TEntryType * ptr = m_Queue.Dequeue(); + if (ptr == nullptr) + { + FillQueue(); + ptr = m_Queue.Dequeue(); + } DecrementCount(ptr != nullptr); return ptr; } @@ -257,6 +262,11 @@ public: TEntryType *DequeueMC() { TEntryType * ptr = m_Queue.DequeueMC(); + if (ptr == nullptr) + { + FillQueue(); + ptr = m_Queue.DequeueMC(); + } DecrementCount(ptr != nullptr); return ptr; } @@ -292,12 +302,11 @@ private: } } - void DecrementCount(BOOLEAN increment) + void DecrementCount(BOOLEAN decrement) { - if (increment) + if (decrement) { InterlockedDecrement(&m_ElementCount); - FillQueue(); } }
CI: rework compile test
@@ -29,7 +29,7 @@ TOOLS= tools sky TOOLSDIR=../../tools TESTLOGS=$(patsubst %,%.testlog, $(TOOLS)) -all: summary +all: clean summary tools.testlog: @echo -n Building tool: $(basename $@)
Add vendor string Shanghai as the successor to Centaur
@@ -283,6 +283,7 @@ int get_vendor(void){ if (!strcmp(vendor, "CyrixInstead")) return VENDOR_CYRIX; if (!strcmp(vendor, "NexGenDriven")) return VENDOR_NEXGEN; if (!strcmp(vendor, "CentaurHauls")) return VENDOR_CENTAUR; + if (!strcmp(vendor, " Shanghai ")) return VENDOR_CENTAUR; if (!strcmp(vendor, "RiseRiseRise")) return VENDOR_RISE; if (!strcmp(vendor, " SiS SiS SiS")) return VENDOR_SIS; if (!strcmp(vendor, "GenuineTMx86")) return VENDOR_TRANSMETA;
Documentation: add pointer to the documentation generation in GSG Add a pointer to the documentation generation tutorial from the Getting Started Guide (in the "Building ACRN") section.
@@ -514,6 +514,9 @@ The build results are found in the ``build`` directory. artefacts, set the ``O`` (that is capital letter 'O') to the desired value. Example: ``make O=build-uefi PLATFORM=uefi``. +Generating the documentation is decribed in details in the :ref:`acrn_doc` +tutorial. + You can also build these components individually. The following steps assume that you have already cloned the ``acrn-hypervisor`` repository and are using it as the current working directory.
[apps] Remove initial latency from benchmark B
@@ -245,6 +245,11 @@ void systolic_rcp_pe(const uint32_t rep_count, // Set data offset depending on PE position data_offset = 0; + // Start benchmark (remove initial latency from benchmark) + // (we could use any data, data_* chosen arbitrarily) + blocking_queue_push(queue_next_horz, &data_horz); + blocking_queue_push(queue_next_vert, &data_vert); + // Execute step-wise matrix multiplication for (uint32_t y = 0; y < num_rows_C; ++y) { for (uint32_t x = 0; x < num_cols_C; ++x) { @@ -317,6 +322,14 @@ void systolic_cp_pe(const uint32_t col_idx, const uint32_t rep_count, // Set data offset depending on PE position data_offset = col_idx; + // Start benchmark (remove initial latency from benchmark) + // (we could use any data, data_* chosen arbitrarily) + blocking_queue_pop(queue_prev_horz, &data_horz); + if (queue_next_horz) { + blocking_queue_push(queue_next_horz, &data_horz); + } + blocking_queue_push(queue_next_vert, &data_vert); + // Execute step-wise matrix multiplication for (uint32_t y = 0; y < num_rows_C; ++y) { for (uint32_t x = 0; x < num_cols_C; ++x) { @@ -391,6 +404,14 @@ void systolic_rp_pe(const uint32_t row_idx, const uint32_t rep_count, // Set data offset depending on PE position data_offset = row_idx * SYSTOLIC_SIZE; + // Start benchmark (remove initial latency from benchmark) + // (we could use any data, data_* chosen arbitrarily) + blocking_queue_pop(queue_prev_vert, &data_vert); + blocking_queue_push(queue_next_horz, &data_horz); + if (queue_next_vert) { + blocking_queue_push(queue_next_vert, &data_vert); + } + // Execute step-wise matrix multiplication for (uint32_t y = 0; y < num_rows_C; ++y) { for (uint32_t x = 0; x < num_cols_C; ++x) { @@ -467,6 +488,17 @@ void systolic_np_pe(const uint32_t row_idx, const uint32_t col_idx, // Set data offset depending on PE position data_offset = row_idx * SYSTOLIC_SIZE + col_idx; + // Start benchmark (remove initial latency from benchmark) + // (we could use any data, data_* chosen arbitrarily) + blocking_queue_pop(queue_prev_horz, &data_horz); + blocking_queue_pop(queue_prev_vert, &data_vert); + if (queue_next_horz) { + blocking_queue_push(queue_next_horz, &data_horz); + } + if (queue_next_vert) { + blocking_queue_push(queue_next_vert, &data_vert); + } + // Execute step-wise matrix multiplication for (uint32_t y = 0; y < num_rows_C; ++y) { for (uint32_t x = 0; x < num_cols_C; ++x) {
Fix dangling pointer reference in stream_cleanup_files. We can't access the entry after it is removed from dynahash. Author: Peter Smith Discussion:
@@ -2740,14 +2740,14 @@ stream_cleanup_files(Oid subid, TransactionId xid) { char path[MAXPGPATH]; StreamXidHash *ent; + bool found = false; - /* Remove the xid entry from the stream xid hash */ + /* By this time we must have created the transaction entry */ ent = (StreamXidHash *) hash_search(xidhash, (void *) &xid, - HASH_REMOVE, - NULL); - /* By this time we must have created the transaction entry */ - Assert(ent != NULL); + HASH_FIND, + &found); + Assert(found); /* Delete the change file and release the stream fileset memory */ changes_filename(path, subid, xid); @@ -2763,6 +2763,9 @@ stream_cleanup_files(Oid subid, TransactionId xid) pfree(ent->subxact_fileset); ent->subxact_fileset = NULL; } + + /* Remove the xid entry from the stream xid hash */ + hash_search(xidhash, (void *) &xid, HASH_REMOVE, NULL); } /*
some sfx processing minor fixes
#define MIN_PERIOD_VALUE 10 #define MAX_PERIOD_VALUE 4096 #define BASE_NOTE_FREQ 440.0 -#define BASE_NOTE_POS 49 +#define BASE_NOTE_POS 49.0 #define ENVELOPE_FREQ_SCALE 2 #define NOTES_PER_MUNUTE (TIC_FRAMERATE / NOTES_PER_BEET * 60) #define min(a,b) ((a) < (b) ? (a) : (b)) @@ -89,14 +89,14 @@ static void update_amp(blip_buffer_t* blip, tic_sound_register_data* data, s32 n blip_add_delta( blip, data->time, delta ); } -static inline s32 freq2note(double freq) +static inline double freq2note(double freq) { - return (s32)round((double)NOTES * log2(freq / BASE_NOTE_FREQ)) + BASE_NOTE_POS; + return (double)NOTES * log2(freq / BASE_NOTE_FREQ) + BASE_NOTE_POS; } -static inline double note2freq(s32 note) +static inline s32 note2freq(double note) { - return pow(2, (note - BASE_NOTE_POS) / (double)NOTES) * BASE_NOTE_FREQ; + return round(pow(2, (note - BASE_NOTE_POS) / (double)NOTES) * BASE_NOTE_FREQ); } static inline s32 freq2period(double freq) @@ -104,7 +104,7 @@ static inline s32 freq2period(double freq) if(freq == 0.0) return MAX_PERIOD_VALUE; enum {Rate = CLOCKRATE * ENVELOPE_FREQ_SCALE / ENVELOPE_VALUES}; - s32 period = (s32)round(Rate / freq - 1.0); + s32 period = round((double)Rate / freq - 1.0); if(period < MIN_PERIOD_VALUE) return MIN_PERIOD_VALUE; if(period > MAX_PERIOD_VALUE) return MAX_PERIOD_VALUE; @@ -391,7 +391,7 @@ static void channelSfx(tic_mem* memory, s32 index, s32 note, s32 octave, s32 dur // start index of idealized piano enum {PianoStart = -8}; - s32 freq = (s32)note2freq(note + octave * NOTES + PianoStart); + s32 freq = note2freq(note + octave * NOTES + PianoStart); c->duration = duration; c->freq = freq; @@ -1129,7 +1129,7 @@ static void sfx(tic_mem* memory, s32 index, s32 freq, Channel* channel, tic_soun { s8 arp = effect->data[channel->pos.arpeggio].arpeggio * (effect->reverse ? -1 : 1); - if(arp) freq = (s32)note2freq(freq2note(freq)+arp); + if(arp) freq = note2freq(freq2note(freq)+arp); freq += effect->data[channel->pos.pitch].pitch * (effect->pitch16x ? 16 : 1);
docs: update on expression with stack api usage regard the stack setup.
@@ -33,17 +33,12 @@ The usage may looks like the code below: //Allocate a stack buffer, from heap or as a static form: portSTACK_TYPE *shared_stack = malloc(8192 * sizeof(portSTACK_TYPE)); - //points to the top of stack, that is it the last word of allocated buffer: - portSTACK_TYPE *ext_stack_top = (portSTACK_TYPE *)&shared_stack[0] + - ((sizeof(8192 * sizeof(portSTACK_TYPE))) / - sizeof(portSTACK_TYPE)); - //Allocate a mutex to protect its usage: SemaphoreHandle_t printf_lock = xSemaphoreCreateMutex(); //Call the desired function using the macro helper: ESP_EXECUTE_EXPRESSION_WITH_STACK(printf_lock, - ext_stack_top, + shared_stack, printf("Executing this from external stack! \n")); free(shared_stack); }
Don't test SRP when it's disabled
@@ -363,11 +363,15 @@ SKIP: { "NPN handshake test"); } +SKIP: { + skip "No SRP support in this OpenSSL build", 1 + if disabled("srp"); + #Test 20: SRP extension -#Note: We are not actually going to perform an SRP handshake (TLSProxy does not -#support it). However it is sufficient for us to check that the SRP extension -#gets added on the client side. There is no SRP extension generated on the -#server side anyway. + #Note: We are not actually going to perform an SRP handshake (TLSProxy + #does not support it). However it is sufficient for us to check that the + #SRP extension gets added on the client side. There is no SRP extension + #generated on the server side anyway. $proxy->clear(); $proxy->clientflags("-no_tls1_3 -srpuser user -srppass pass:pass"); $proxy->start(); @@ -375,6 +379,7 @@ checkhandshake($proxy, checkhandshake::DEFAULT_HANDSHAKE, checkhandshake::DEFAULT_EXTENSIONS | checkhandshake::SRP_CLI_EXTENSION, "SRP extension test"); +} #Test 21: EC handshake SKIP: {
usrsock_server: combine response and events when socket setup case
@@ -234,6 +234,7 @@ static int usrsock_rpmsg_socket_handler(struct rpmsg_endpoint *ept, { struct usrsock_request_socket_s *req = data; struct usrsock_rpmsg_s *priv = priv_; + uint16_t events = 0; int i; int retr; int ret = -ENFILE; @@ -250,6 +251,10 @@ static int usrsock_rpmsg_socket_handler(struct rpmsg_endpoint *ept, { priv->epts[i] = ept; ret = i; /* Return index as the usockid */ + if (req->type != SOCK_STREAM && req->type != SOCK_SEQPACKET) + { + events = USRSOCK_EVENT_SENDTO_READY; + } } break; @@ -258,7 +263,7 @@ static int usrsock_rpmsg_socket_handler(struct rpmsg_endpoint *ept, pthread_mutex_unlock(&priv->mutex); } - retr = usrsock_rpmsg_send_ack(ept, 0, req->head.xid, ret); + retr = usrsock_rpmsg_send_ack(ept, events, req->head.xid, ret); if (retr >= 0 && ret >= 0 && req->type != SOCK_STREAM && req->type != SOCK_SEQPACKET) { @@ -267,7 +272,6 @@ static int usrsock_rpmsg_socket_handler(struct rpmsg_endpoint *ept, priv->pfds[ret].events = POLLIN; usrsock_rpmsg_notify_poll(priv); pthread_mutex_unlock(&priv->mutex); - retr = usrsock_rpmsg_send_event(ept, ret, USRSOCK_EVENT_SENDTO_READY); } return retr;
dssframesync: fixing braces/scope
@@ -298,8 +298,10 @@ int dsssframesync_execute_seekpn(dsssframesync _q, float complex _x) float complex * v = qdetector_cccf_execute(_q->detector, _x); // check if frame has been detected + printf("seeking pn...\n"); if (v == NULL) return LIQUID_OK; + printf("FRAME DETECTED\n"); // get estimates _q->tau_hat = qdetector_cccf_get_tau(_q->detector); @@ -397,7 +399,7 @@ int dsssframesync_execute_rxheader(dsssframesync _q, float complex _x) _q->header_spread[_q->symbol_counter % synth_crcf_get_length(_q->header_synth)] = mf_out; ++_q->symbol_counter; - if (_q->symbol_counter % synth_crcf_get_length(_q->header_synth) != 0) { + if (_q->symbol_counter % synth_crcf_get_length(_q->header_synth)) return LIQUID_OK; int header_complete = dsssframesync_decode_header(_q); @@ -405,7 +407,7 @@ int dsssframesync_execute_rxheader(dsssframesync _q, float complex _x) if (!header_complete) return LIQUID_OK; - if (_q->header_valid) + if (_q->header_valid) { _q->symbol_counter = 0; _q->state = DSSSFRAMESYNC_STATE_RXPAYLOAD; return LIQUID_OK;
Fixed typos in Kconfig mesage -> message memmory -> memory
@@ -89,7 +89,7 @@ config RT_USING_I2C if RT_USING_I2C config RT_I2C_DEBUG - bool "Use I2C debug mesage" + bool "Use I2C debug message" default n config RT_USING_I2C_BITOPS @@ -99,7 +99,7 @@ endif if RT_USING_I2C_BITOPS config RT_I2C_BITOPS_DEBUG - bool "Use simulate I2C debug mesage" + bool "Use simulate I2C debug message" default n endif @@ -257,11 +257,11 @@ config RT_USING_AUDIO if RT_USING_AUDIO config RT_AUDIO_REPLAY_MP_BLOCK_SIZE - int "Replay memmory pool block size" + int "Replay memory pool block size" default 4096 config RT_AUDIO_REPLAY_MP_BLOCK_COUNT - int "Replay memmory pool block count" + int "Replay memory pool block count" default 2 config RT_AUDIO_RECORD_PIPE_SIZE
mount-info: fix ini linecontinuation
@@ -28,8 +28,8 @@ else FOLDER="$1" fi -$KDB mount $FOLDER/METADATA.ini "$MOUNTPOINT/metadata/#0" ini -$KDB mount $FOLDER/CONTRACT.ini "$MOUNTPOINT/contract/#0" ini +$KDB mount $FOLDER/METADATA.ini "$MOUNTPOINT/metadata/#0" ini -c linecont=" " +$KDB mount $FOLDER/CONTRACT.ini "$MOUNTPOINT/contract/#0" ini -c linecont=" " $KDB mount --resolver noresolver none "$MOUNTPOINT/uname" uname $KDB mount --resolver noresolver none "$MOUNTPOINT/desktop" desktop
rune/libenclave/skeleton: run an enclave ecall exapmle in pal v3
@@ -20,6 +20,7 @@ int pal_get_version(void) int pal_init(pal_attr_v3_t *attr) { int ret; + char *result; parse_args(attr->attr_v1.args); @@ -32,18 +33,31 @@ int pal_init(pal_attr_v3_t *attr) if (attr->fd != -1 && attr->addr != 0) { enclave_fd = attr->fd; secs.base = attr->addr; - initialized = true; - return 0; + goto out; } ret = encl_init(); if (ret != 0) return ret; +out: + result = malloc(sizeof(INIT_HELLO)); + if (!result) { + fprintf(stderr, "fail to malloc INIT_HELLO\n"); + return -ENOMEM; + } + ret = SGX_ENTER_1_ARG(ECALL_INIT, (void *) secs.base, result); + if (ret) { + fprintf(stderr, "failed to initialize enclave\n"); + free(result); + return ret; + } + puts(result); + free(result); + initialized = true; return 0; - } int pal_create_process(pal_create_process_args *args)
Separate function calls out into two stages
@@ -14,7 +14,8 @@ static Value typeNative(DictuVM *vm, int argCount, Value *args) { } int length = 0; - return OBJ_VAL(takeString(vm, valueTypeToString(vm, args[0], &length), length)); + char *type = valueTypeToString(vm, args[0], &length); + return OBJ_VAL(takeString(vm, type, length)); } static Value setNative(DictuVM *vm, int argCount, Value *args) {
chat-cli: proper prefix for tab completion
:: ++ tab-list |= sole-id=@ta - tab-list:sh:tc + %+ turn tab-list:sh:tc + |= [term=cord detail=tank] + [(cat 3 ';' term) detail] :: ++ on-command |= [sole-id=@ta =command]
Add model number for Tiger Lake H (mobile variant)
@@ -663,7 +663,7 @@ static gotoblas_t *get_coretype(void){ return NULL; case 9: case 8: - if (model == 12) { // Tiger Lake + if (model == 12 || model == 13) { // Tiger Lake if (support_avx512()) return &gotoblas_SKYLAKEX; if(support_avx2()){
Added split build directories
@@ -62,26 +62,27 @@ west build -b planck_rev6 ``` ### Pristine Building -When building for a new board and/or shield after having built one previously, you may need to enable the pristine build option. This option removes all existing files in the build directory and regenerates them, and can be enabled by adding either --pristine or -p to the command: +When building for a new board and/or shield after having built one previously, you may need to enable the pristine build option. This option removes all existing files in the build directory before regenerating them, and can be enabled by adding either --pristine or -p to the command: ```sh west build -p -b proton_c -- -DSHIELD=kyria_left ``` -### Split Keyboards +### Building For Split Keyboards :::note For split keyboards, you will have to build and flash each side separately the first time you install ZMK. ::: -By default, the `build` command outputs a single .uf2 file named `zmk.uf2` so building left and then right immediately after will overwrite your left firmware. In addition, you will need to pristine build each side to ensure the correct files are used. To avoid having to pristine build each time and separate the left and right build files, we recommend setting up separate build directories for each half. You can do this by first building left into `build\left`: +By default, the `build` command outputs a single .uf2 file named `zmk.uf2` so building left and then right immediately after will overwrite your left firmware. In addition, you will need to pristine build each side to ensure the correct files are used. To avoid having to pristine build every time and separate the left and right build files, we recommend setting up separate build directories for each half. You can do this by using the `-d` parameter and first building left into `build/left`: ``` west build -d build/left -b nice_nano -- -DSHIELD=kyria_left ``` -and then building right into `build\right`: +and then building right into `build/right`: ``` west build -d build/right -b nice_nano -- -DSHIELD=kyria_right ``` +This produces `left` and `right` subfolders under the `build` directory and two separate .uf2 files. For future work on a specific half, use the `-d` parameter again to ensure you are building into the correct location. ## Flashing @@ -92,5 +93,5 @@ board with it in bootloader mode: west flash ``` -For boards that have drag and drop .uf2 flashing capability, the .uf2 file to flash can be found in `build\zephyr` and is by default named `zmk.uf2`. +For boards that have drag and drop .uf2 flashing capability, the .uf2 file to flash can be found in `build\zephyr` (or `build\left|right\zephyr` if you followed the instructions for splits) and is by default named `zmk.uf2`.
ulp risc_v: fix bug about bit for wakeup trigger
typedef struct { esp_sleep_pd_option_t pd_options[ESP_PD_DOMAIN_MAX]; uint64_t sleep_duration; - uint32_t wakeup_triggers : 11; + uint32_t wakeup_triggers : 15; uint32_t ext1_trigger_mode : 1; uint32_t ext1_rtc_gpio_mask : 18; uint32_t ext0_trigger_level : 1;
vppinfra: fix typo in tw_timer_template.c Fix minor memory leak Type: fix Ticket: Fixes:
@@ -476,7 +476,7 @@ void TW (tw_timer_wheel_free) (TWT (tw_timer_wheel) * tw) } } -#if TW_OVERFLOW_VECVOR > 0 +#if TW_OVERFLOW_VECTOR > 0 ts = &tw->overflow; head = pool_elt_at_index (tw->timers, ts->head_index); next_index = head->next;
docs: remove older ntp instructions for leap/WW
@@ -25,10 +25,6 @@ example configuration. [sms](*\#*) exportfs -a [sms](*\#*) systemctl restart nfs-server [sms](*\#*) systemctl enable nfs-server - -# Enable NTP time service on computes and identify master host as local NTP server -[sms](*\#*) echo "server ${sms_ip}" >> $CHROOT/etc/chrony.conf -[sms](*\#*) cp /etc/ntp.keys $CHROOT/etc/ntp.keys \end{lstlisting} % end_ohpc_run
Update joy.c Changed joyAxisY[port] in static u16 readMouse(u16 port) as Y axis was wrong (input was correctly captured but direction reversed).
@@ -768,7 +768,7 @@ static u16 readMouse(u16 port) if (md[0] & 0x02) my |= my ? 0xFF00 : 0xFFFF; /* y sign extend */ joyAxisX[port] += (s16)mx; - joyAxisY[port] += (s16)my; + joyAxisY[port] -= (s16)my; if (md[1] & 8) val |= BUTTON_START; if (md[1] & 4) val |= BUTTON_MMB;
Support job-uri's of the form 'ipp://host/ipp/print/nnn'.
@@ -6057,6 +6057,8 @@ serverProcessIPP( if ((resptr = strchr(resource + 11, '/')) != NULL) *resptr = '\0'; + else + resource[11] = '\0'; if ((client->printer = serverFindPrinter(resource)) == NULL) {
remove delete -pcd LSA from OS builds ndctl provides zero-label with proper checks
#include "Common.h" #include "ShowFirmwareCommand.h" #include "ShowPcdCommand.h" -#include "DeletePcdCommand.h" #include "StartFormatCommand.h" #include "ShowPreferencesCommand.h" #include "SetPreferencesCommand.h" #include "DumpSupportCommand.h" extern void nvm_current_cmd(struct Command Command); #else +#include "DeletePcdCommand.h" EFI_GUID gNvmDimmConfigProtocolGuid = EFI_DCPMM_CONFIG_PROTOCOL_GUID; #endif EFI_GUID gNvmDimmDriverHealthGuid = EFI_DRIVER_HEALTH_PROTOCOL_GUID; @@ -453,6 +453,12 @@ RegisterCommands( if (EFI_ERROR(Rc)) { goto done; } + + Rc = RegisterDeletePcdCommand(); + if (EFI_ERROR(Rc)) { + goto done; + } + #endif Rc = RegisterShowErrorCommand(); if (EFI_ERROR(Rc)) { @@ -514,11 +520,6 @@ RegisterCommands( goto done; } - Rc = RegisterDeletePcdCommand(); - if (EFI_ERROR(Rc)) { - goto done; - } - Rc = RegisterShowPreferencesCommand(); if (EFI_ERROR(Rc)) { goto done;
Make sure OSSL_STORE_load() isn't caught in an endless loop The post process callback might potentially say "no" to everything (by constantly returning NULL) and thereby cause an endless loop. Ensure that we stop all processing when "eof" is reached.
@@ -90,6 +90,9 @@ OSSL_STORE_INFO *OSSL_STORE_load(OSSL_STORE_CTX *ctx) OSSL_STORE_INFO *v = NULL; again: + if (OSSL_STORE_eof(ctx)) + return NULL; + v = ctx->loader->load(ctx->loader_ctx, ctx->ui_method, ctx->ui_data); if (ctx->post_process != NULL && v != NULL) {
hw/mcu/stm/stm32_common: SPI_4 and SPI_5 definitions. Missing SPI definitions on STM32 common drivers. HAL is ready to use SPI_4 and SPI_5 but they are not expanded from application.
@@ -283,17 +283,17 @@ syscfg.defs: value: '' SPI_3_MASTER: - description: 'SPI 2 master' + description: 'SPI 3 master' value: 0 restrictions: - "!SPI_3_SLAVE" SPI_3_SLAVE: - description: 'SPI 2 slave' + description: 'SPI 3 slave' value: 0 restrictions: - "!SPI_3_MASTER" SPI_3: - description: 'SPI 2 enabled' + description: 'SPI 3 enabled' value: 'MYNEWT_VAL_SPI_3_MASTER || MYNEWT_VAL_SPI_3_SLAVE' SPI_3_CUSTOM_CFG: description: 'Allow SPI_3 configuration override' @@ -311,6 +311,64 @@ syscfg.defs: description: 'SS pin for SPI_3' value: '' + SPI_4_MASTER: + description: 'SPI 4 master' + value: 0 + restrictions: + - "!SPI_4_SLAVE" + SPI_4_SLAVE: + description: 'SPI 4 slave' + value: 0 + restrictions: + - "!SPI_4_MASTER" + SPI_4: + description: 'SPI 4 enabled' + value: 'MYNEWT_VAL_SPI_4_MASTER || MYNEWT_VAL_SPI_4_SLAVE' + SPI_4_CUSTOM_CFG: + description: 'Allow SPI_4 configuration override' + value: 0 + SPI_4_PIN_SCK: + description: 'SCK pin for SPI_4' + value: '' + SPI_4_PIN_MOSI: + description: 'MOSI pin for SPI_4' + value: '' + SPI_4_PIN_MISO: + description: 'MISO pin for SPI_4' + value: '' + SPI_4_PIN_SS: + description: 'SS pin for SPI_4' + value: '' + + SPI_5_MASTER: + description: 'SPI 5 master' + value: 0 + restrictions: + - "!SPI_5_SLAVE" + SPI_5_SLAVE: + description: 'SPI 5 slave' + value: 0 + restrictions: + - "!SPI_5_MASTER" + SPI_5: + description: 'SPI 5 enabled' + value: 'MYNEWT_VAL_SPI_5_MASTER || MYNEWT_VAL_SPI_5_SLAVE' + SPI_5_CUSTOM_CFG: + description: 'Allow SPI_5 configuration override' + value: 0 + SPI_5_PIN_SCK: + description: 'SCK pin for SPI_5' + value: '' + SPI_5_PIN_MOSI: + description: 'MOSI pin for SPI_5' + value: '' + SPI_5_PIN_MISO: + description: 'MISO pin for SPI_5' + value: '' + SPI_5_PIN_SS: + description: 'SS pin for SPI_5' + value: '' + I2C_0: description: 'I2C (TWI) interface 0' value: 0
py/obj.h: Use uint64_t instead of mp_int_t in repr-D MP_OBJ_IS_x macros. This follows how it's already done in MP_OBJ_IS_OBJ: the objects are considered 64-bit unsigned ints for the purpose of bitwise manipulation.
@@ -171,12 +171,12 @@ static inline bool MP_OBJ_IS_OBJ(mp_const_obj_t o) #elif MICROPY_OBJ_REPR == MICROPY_OBJ_REPR_D static inline bool MP_OBJ_IS_SMALL_INT(mp_const_obj_t o) - { return ((((mp_int_t)(o)) & 0xffff000000000000) == 0x0001000000000000); } + { return ((((uint64_t)(o)) & 0xffff000000000000) == 0x0001000000000000); } #define MP_OBJ_SMALL_INT_VALUE(o) (((mp_int_t)((o) << 16)) >> 17) #define MP_OBJ_NEW_SMALL_INT(small_int) (((((uint64_t)(small_int)) & 0x7fffffffffff) << 1) | 0x0001000000000001) static inline bool MP_OBJ_IS_QSTR(mp_const_obj_t o) - { return ((((mp_int_t)(o)) & 0xffff000000000000) == 0x0002000000000000); } + { return ((((uint64_t)(o)) & 0xffff000000000000) == 0x0002000000000000); } #define MP_OBJ_QSTR_VALUE(o) ((((uint32_t)(o)) >> 1) & 0xffffffff) #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 1) | 0x0002000000000001))
added VTK libraries to the link list
@@ -172,7 +172,8 @@ VISIT_INSTALL_TARGETS(simV2runtime_ser) IF(VISIT_PARALLEL) ADD_PARALLEL_LIBRARY(simV2runtime_par ${LIBSIM_RUNTIME_SOURCES} ${LIBSIM_STATIC_SOURCES}) - TARGET_LINK_LIBRARIES(simV2runtime_par engine_par ${LIBSIM_RUNTIME_VIEWER_LIBS_PAR}) +# TARGET_LINK_LIBRARIES(simV2runtime_par engine_par vtksys vtkpng vtkmetaio vtkDICOMParser vtkImagingSources vtkglew vtkCommonSystem vtkCommonColor vtkCommonComputationalGeometry vtkFiltersStatistics vtkalglib vtklz4 vtkImagingFourier ${LIBSIM_RUNTIME_VIEWER_LIBS_PAR}) + TARGET_LINK_LIBRARIES(simV2runtime_par engine_par ${VTK_LIBRARIES} ${LIBSIM_RUNTIME_VIEWER_LIBS_PAR}) IF(NOT APPLE) SET_TARGET_PROPERTIES(simV2runtime_par PROPERTIES INSTALL_RPATH "$ORIGIN") ENDIF(NOT APPLE)
Fix linux-build.sh for .NETCore 2.1
@@ -9,7 +9,7 @@ echo "Building into $BUILDIR" # publish mkdir -p $BUILDIR -dotnet publish -c Release --framework netcoreapp2.0 -o $BUILDIR +dotnet publish -c Release --framework netcoreapp2.1 -o $BUILDIR # build libcryptonote (cd ../Native/libcryptonote && make)
simpler usage
# xmake getter # usage: (in powershell) -# Invoke-Webrequest <my location> -OutFile get.ps1 -# . .\get.ps1 +# Invoke-Expression (Invoke-Webrequest <my location> -UseBasicParsing).Content $ver='v2.1.3' Invoke-Webrequest "https://github.com/tboox/xmake/releases/download/$ver/xmake-$ver.exe" -OutFile "$pid-xmake-installer.exe"
Update readme.md Add new benchmark figures
@@ -264,11 +264,13 @@ with 128GB ECC memory, running Ubuntu 18.04.1 with LibC 2.27 and GCC 7.3.0. The first benchmark set consists of programs that allocate a lot: -![bench-r5a-4xlarge-t1](doc/bench-r5a-4xlarge-t1.png) +![bench-r5a-1](doc/bench-r5a-1.svg) +![bench-r5a-2](doc/bench-r5a-2.svg) Memory usage: -![bench-r5a-4xlarge-m1](doc/bench-r5a-4xlarge-m1.png) +![bench-r5a-rss-1](doc/bench-r5a-rss-1.svg) +![bench-r5a-rss-1](doc/bench-r5a-rss-2.svg) The benchmarks above are (with N=16 in our case): @@ -309,9 +311,6 @@ diffrerences here when running with 16 cores in parallel. The second benchmark tests specific aspects of the allocators and shows more extreme differences between allocators: -![bench-r5a-4xlarge-t2](doc/bench-r5a-4xlarge-t2.png) - -![bench-r5a-4xlarge-m2](doc/bench-r5a-4xlarge-m2.png) The benchmarks in the second set are (again with N=16): @@ -354,6 +353,14 @@ Hoard allocator is specifically designed to avoid this false sharing and we are not sure why it is not doing well here (although it still runs almost 5&times; faster than tcmalloc and jxmalloc). +## Benchmarks on a 4-core Intel workstation + +![bench-z4-1](doc/bench-z4-1.svg) +![bench-z4-2](doc/bench-z4-2.svg) + +![bench-z4-rss-1](doc/bench-z4-rss-1.svg) +![bench-z4-rss-2](doc/bench-z4-rss-2.svg) + # References
libbarrelfish: pmap serialisation: global mapping cnodes: allocate mapping cnodes in deserialise() when GLOBAL_MCN is set
@@ -165,7 +165,7 @@ static errval_t deserialise_tree(struct pmap *pmap, struct serial_entry **in, pmapx->used_cap_slots ++; */ -#if 0 +#if GLOBAL_MCN /* allocate mapping cnodes */ for (int i = 0; i < MCN_COUNT; i++) { err = cnode_create_l2(&n->u.vnode.mcn[i], &n->u.vnode.mcnode[i]);
Fixed spelling mistakes of function LPC17xx_SD_WirteDataBlock -> LPC17xx_SD_WriteDataBlock
@@ -32,7 +32,7 @@ static uint8_t LPC17xx_SD_SendCmd(uint8_t cmd, uint32_t arg); static bool LPC17xx_SD_ReadSector(uint32_t sector, uint8_t *buff, uint32_t count); static bool LPC17xx_SD_ReadDataBlock(uint8_t *buff, uint32_t cnt); static bool LPC17xx_SD_WriteSector(uint32_t sector, const uint8_t *buff, uint32_t count); -static bool LPC17xx_SD_WirteDataBlock(const uint8_t *buff, uint8_t token); +static bool LPC17xx_SD_WriteDataBlock(const uint8_t *buff, uint8_t token); static bool LPC17xx_SD_ReadCfg(SDCFG *cfg); static bool LPC17xx_SD_WaitForReady(void); @@ -279,7 +279,7 @@ static bool LPC17xx_SD_WriteSector(uint32_t sector, const uint8_t *buff, uint32_ if (count == 1) /* Single block write */ { if ((LPC17xx_SD_SendCmd(WRITE_BLOCK, sector) == 0) - && LPC17xx_SD_WirteDataBlock(buff, TOKEN_SINGLE_BLOCK)) + && LPC17xx_SD_WriteDataBlock(buff, TOKEN_SINGLE_BLOCK)) count = 0; } else /* Multiple block write */ @@ -289,12 +289,12 @@ static bool LPC17xx_SD_WriteSector(uint32_t sector, const uint8_t *buff, uint32_ { do { - if (!LPC17xx_SD_WirteDataBlock(buff, TOKEN_MULTI_BLOCK)) break; + if (!LPC17xx_SD_WriteDataBlock(buff, TOKEN_MULTI_BLOCK)) break; buff += 512; } while (--count); #if 1 - if (!LPC17xx_SD_WirteDataBlock(0, TOKEN_STOP_TRAN)) /* STOP_TRAN token */ + if (!LPC17xx_SD_WriteDataBlock(0, TOKEN_STOP_TRAN)) /* STOP_TRAN token */ count = 1; #else LPC17xx_SPI_SendByte(TOKEN_STOP_TRAN); @@ -312,7 +312,7 @@ static bool LPC17xx_SD_WriteSector(uint32_t sector, const uint8_t *buff, uint32_ 0xFC -> multi block 0xFD -> Stop *****************************************************************************/ -static bool LPC17xx_SD_WirteDataBlock(const uint8_t *buff, uint8_t token) +static bool LPC17xx_SD_WriteDataBlock(const uint8_t *buff, uint8_t token) { uint8_t resp, i;
util/mkdef.pl: handle line terminators correctly When parsing the header files, mkdef.pl didn't clear the line terminator properly. In most cases, this didn't matter, but there were moments when this caused parsing errors (such as CRLFs in certain cases). Fixes
@@ -412,10 +412,10 @@ sub do_defs print STDERR "DEBUG: parsing ----------\n" if $debug; while(<IN>) { + s|\R$||; # Better chomp if($parens > 0) { #Inside a DEPRECATEDIN $stored_multiline .= $_; - $stored_multiline =~ s|\R$||; # Better chomp print STDERR "DEBUG: Continuing multiline DEPRECATEDIN: $stored_multiline\n" if $debug; $parens = count_parens($stored_multiline); if ($parens == 0) { @@ -847,7 +847,6 @@ sub do_defs \@current_algorithms); } else { $stored_multiline = $_; - $stored_multiline =~ s|\R$||; print STDERR "DEBUG: Found multiline DEPRECATEDIN starting with: $stored_multiline\n" if $debug; next; }
docs/contributors: add credit for docs
@@ -104,6 +104,7 @@ Notable contributors ---------------------------------------------- - Add new DCD port for Silabs EFM32GG12 with SLTB009A board +- Rewrite documentation in rst and setup for readthedocs `Raspberry Pi Team <https://github.com/raspberrypi>`__
Seg fault bug fix when isValidJoin fails.
@@ -618,8 +618,6 @@ port_INLINE void activity_synchronize_endOfFrame(PORT_TIMER_WIDTH capturedTime) // before authenticating the beacon, because nonce is created from the ASN if (!ieee154e_vars.isSync && ieee802514_header.frameType == IEEE154_TYPE_BEACON) { if (!isValidJoin(ieee154e_vars.dataReceived, &ieee802514_header)) { - // invalidate variables - memset(&ieee154e_vars, 0, sizeof(ieee154e_vars_t)); break; } }
Fix compatibility with old CMake versions
-cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.3) set(VERSION_MAJOR 1) set(VERSION_MINOR 0) @@ -226,8 +226,14 @@ target_include_directories(wren PRIVATE ${THIRDPARTY_DIR}/wren/src/vm) # MRUBY ################################ -find_program(RAKE_EXE rake REQUIRED) -find_program(YACC_EXE yacc REQUIRED) +find_program(RAKE rake) +find_program(YACC yacc) +if(NOT RAKE) + message(FATAL_ERROR "Program `rake' not found! Ruby and `rake' are required to build mruby support.") +endif() +if(NOT YACC) + message(FATAL_ERROR "Program `yacc' not found! Either `yacc' or GNU Bison is required to build mruby support.") +endif() set(MRUBY_DIR ${THIRDPARTY_DIR}/mruby) if(EMSCRIPTEN) @@ -243,7 +249,7 @@ ExternalProject_Add(mruby_vendor SOURCE_DIR ${MRUBY_DIR} CONFIGURE_COMMAND "" BUILD_IN_SOURCE TRUE - BUILD_COMMAND ${RAKE_EXE} MRUBY_CONFIG=${MRUBY_CONFIG} + BUILD_COMMAND ${RAKE} MRUBY_CONFIG=${MRUBY_CONFIG} INSTALL_COMMAND "" BUILD_BYPRODUCTS ${MRUBY_LIBRARIES} )
OcBootManagementLib: Add missing LF
@@ -1682,7 +1682,7 @@ AddFileSystemEntryForCustom ( if (EFI_ERROR (Status)) { DEBUG (( DEBUG_WARN, - "OCB: Failed to add custom entry %a - %r", + "OCB: Failed to add custom entry %a - %r\n", BootContext->PickerContext->CustomEntries[Index].Name, Status ));
Early out candidate search on first failure
@@ -1277,6 +1277,11 @@ unsigned int compute_ideal_endpoint_formats( { errors_of_best_combination[best_error_index] = 1e30f; } + // Early-out if no more candidates are valid + else + { + break; + } } for (unsigned int i = 0; i < tune_candidate_limit; i++)
Read scene from banked data and use that to find image to load
@@ -38,7 +38,7 @@ void SceneRender(); void SceneInit_b() { - UBYTE imageIndex; + UWORD sceneIndex, imageIndex; BANK_PTR bank_ptr; UWORD ptr; UBYTE tilesetIndex, width, height; @@ -50,7 +50,11 @@ void SceneInit_b() WX_REG = MAXWNDPOSX; WY_REG = MAXWNDPOSY; - imageIndex = 10; + sceneIndex = 16; + ReadBankedBankPtr(16, &bank_ptr, &scene_bank_ptrs[sceneIndex]); + ptr = ((UWORD)&bank_20_data) + bank_ptr.offset; + + imageIndex = ReadBankedUWORD(bank_ptr.bank, ptr); // Load Image Tiles - V3 pointer to bank_ptr (31000) (42145) ReadBankedBankPtr(16, &bank_ptr, &image_bank_ptrs[imageIndex]);
in_netif: don't discard return value of init_entry_linux
@@ -144,9 +144,7 @@ static int configure(struct flb_in_netif_config *ctx, ctx->first_snapshot = FLB_TRUE; /* assign first_snapshot with FLB_TRUE */ - init_entry_linux(ctx); - - return 0; + return init_entry_linux(ctx); } static inline int is_specific_interface(struct flb_in_netif_config *ctx,
forward libc interface used by wasi-libc; originally by in PR but rebased to the dev branch
@@ -262,7 +262,15 @@ int reallocarr(void* p, size_t count, size_t size) { return mi_reallocarr(p void* memalign(size_t alignment, size_t size) { return mi_memalign(alignment, size); } void* _aligned_malloc(size_t alignment, size_t size) { return mi_aligned_alloc(alignment, size); } -#if defined(__GLIBC__) && defined(__linux__) +#if defined(__wasi__) + // forward __libc interface (see PR #667) + void* __libc_malloc(size_t size) MI_FORWARD1(mi_malloc, size) + void* __libc_calloc(size_t count, size_t size) MI_FORWARD2(mi_calloc, count, size) + void* __libc_realloc(void* p, size_t size) MI_FORWARD2(mi_realloc, p, size) + void __libc_free(void* p) MI_FORWARD0(mi_free, p) + void* __libc_memalign(size_t alignment, size_t size) { return mi_memalign(alignment, size); } + +#elif defined(__GLIBC__) && defined(__linux__) // forward __libc interface (needed for glibc-based Linux distributions) void* __libc_malloc(size_t size) MI_FORWARD1(mi_malloc,size) void* __libc_calloc(size_t count, size_t size) MI_FORWARD2(mi_calloc,count,size)
CLEANUP: change assert condition to support all item types. Previously, it was a function to support only collection types, but we changed the assert condition to support all item types.
@@ -300,7 +300,7 @@ bool prefix_issame(prefix_t *pt, const char *prefix, const int nprefix) void prefix_bytes_incr(prefix_t *pt, ENGINE_ITEM_TYPE item_type, const uint32_t bytes) { /* It's called when a collection element is inserted */ - assert(item_type > ITEM_TYPE_KV && item_type < ITEM_TYPE_MAX); + assert(item_type < ITEM_TYPE_MAX); pt->items_bytes[item_type] += bytes; pt->total_bytes_exclusive += bytes; @@ -318,7 +318,7 @@ void prefix_bytes_incr(prefix_t *pt, ENGINE_ITEM_TYPE item_type, const uint32_t void prefix_bytes_decr(prefix_t *pt, ENGINE_ITEM_TYPE item_type, const uint32_t bytes) { /* It's called when a collection element is removed */ - assert(item_type > ITEM_TYPE_KV && item_type < ITEM_TYPE_MAX); + assert(item_type < ITEM_TYPE_MAX); pt->items_bytes[item_type] -= bytes; pt->total_bytes_exclusive -= bytes;
Fix undefined behavior and warning with clang This fixes a warning from clang about undefined behavior: error: embedding a directive within macro arguments has undefined behavior [-Werror,-Wembedded-directive]
@@ -4076,15 +4076,14 @@ static void usage(void) { printf(" - ssl_session_cache: enable server-side SSL session cache, to support session\n" " resumption\n" " - ssl_kernel_tls: enable kernel TLS offload\n" - " - ssl_min_version: minimum protocol version to accept (default: %s)\n" + " - ssl_min_version: minimum protocol version to accept (default: %s)\n", + ssl_proto_text(settings.ssl_min_version)); #if defined(TLS1_3_VERSION) - " valid values are 0(%s), 1(%s), 2(%s), or 3(%s).\n", - ssl_proto_text(settings.ssl_min_version), + printf(" valid values are 0(%s), 1(%s), 2(%s), or 3(%s).\n", ssl_proto_text(TLS1_VERSION), ssl_proto_text(TLS1_1_VERSION), ssl_proto_text(TLS1_2_VERSION), ssl_proto_text(TLS1_3_VERSION)); #else - " valid values are 0(%s), 1(%s), or 2(%s).\n", - ssl_proto_text(settings.ssl_min_version), + printf(" valid values are 0(%s), 1(%s), or 2(%s).\n", ssl_proto_text(TLS1_VERSION), ssl_proto_text(TLS1_1_VERSION), ssl_proto_text(TLS1_2_VERSION)); #endif
media: Check if process_handler is already set if register_stream_in_device_process_handler is not NULL, process_handler is already registered. So just return AUDIO_MANAGER_SUCCESS
@@ -1619,6 +1619,12 @@ audio_manager_result_t register_stream_in_device_process_handler(int card_id, in card = &g_audio_in_cards[card_id]; config = &card->config[device_id]; + if (config->process_handler != NULL) + { + medvdbg("Handler is already registered\n"); + return AUDIO_MANAGER_SUCCESS; + } + process_type = get_process_type_audio_param_value(type); if (((config->device_process_type) & process_type) == 0) {
BugID: update udevapp README
@@ -40,6 +40,7 @@ udevapp ### Running > need to update `aos-cube` to 0.3.0 or later +> if using `AliOS Studio`, need to update `AliOS Studio` to 0.10.9 or later. Before running `aos ota udevapp@xxxx`, you need to set the `productKey` and `deviceName`, typing blow commands in board's console: @@ -65,6 +66,10 @@ Once done, reboot board, running `aos ota udevapp@xxxx -d <devicename> -p <produ ![](https://img.alicdn.com/tfs/TB1GINADwTqK1RjSZPhXXXfOFXa-919-571.gif) +Or using `AliOS Studio` to update device binary quickly: + +![](https://img.alicdn.com/tfs/TB14ROOHbrpK1RjSZTEXXcWAVXa-1140-820.gif) + and device log display like this: ![](https://img.alicdn.com/tfs/TB1ZohLDAzoK1RjSZFlXXai4VXa-926-571.gif)
Add a test demonstrating a memory leak in cbor_builder_byte_string_callback
@@ -138,6 +138,39 @@ static void test_builder_byte_string_callback_append_item_alloc_failure( _cbor_stack_pop(&stack); } +static void test_builder_byte_string_callback_append_parent_alloc_failure( + void** _CBOR_UNUSED(_state)) { + struct _cbor_stack stack = _cbor_stack_init(); + _cbor_stack_push(&stack, cbor_new_indefinite_bytestring(), 0); + struct _cbor_decoder_context context = { + .creation_failed = false, + .syntax_error = false, + .root = NULL, + .stack = &stack, + }; + + // Allocate new item, but fail to push it into the parent on the stack + WITH_MOCK_MALLOC( + { cbor_builder_byte_string_callback(&context, bytestring_data, 3); }, 3, + MALLOC, MALLOC, REALLOC_FAIL); + + assert_true(context.creation_failed); + assert_false(context.syntax_error); + assert_int_equal(context.stack->size, 1); + + // The stack remains unchanged + cbor_item_t* bytestring = stack.top->item; + assert_int_equal(cbor_refcount(bytestring), 1); + assert_true(cbor_typeof(bytestring) == CBOR_TYPE_BYTESTRING); + assert_true(cbor_isa_bytestring(bytestring)); + assert_int_equal(cbor_bytestring_length(bytestring), 0); + assert_true(cbor_bytestring_is_indefinite(bytestring)); + assert_int_equal(cbor_bytestring_chunk_count(bytestring), 0); + + cbor_decref(&bytestring); + _cbor_stack_pop(&stack); +} + int main(void) { const struct CMUnitTest tests[] = { cmocka_unit_test(test_default_callbacks), @@ -145,6 +178,8 @@ int main(void) { cmocka_unit_test(test_builder_byte_string_callback_append_alloc_failure), cmocka_unit_test( test_builder_byte_string_callback_append_item_alloc_failure), + cmocka_unit_test( + test_builder_byte_string_callback_append_parent_alloc_failure), }; cmocka_run_group_tests(tests, NULL, NULL);
Fixed typo on README.md.
-City GoAccess [![Build Status](https://travis-ci.org/allinurl/goaccess.svg?branch=master)](http://travis-ci.org/allinurl/goaccess) [![GoAccess](https://goaccess.io/badge?v1.0)](http://goaccess.io) -6======= +GoAccess [![Build Status](https://travis-ci.org/allinurl/goaccess.svg?branch=master)](http://travis-ci.org/allinurl/goaccess) [![GoAccess](https://goaccess.io/badge?v1.0)](http://goaccess.io) +======== ## What is it? ## GoAccess is an open source **real-time web log analyzer** and interactive
[awm2] Prevent windows from being resized too small
@@ -834,10 +834,14 @@ impl Desktop { { //println!("\tResizing hover window"); let old_frame = resized_window.frame(); - let new_frame = self.bind_rect_to_screen_size( + let mut new_frame = self.bind_rect_to_screen_size( old_frame.replace_size(old_frame.size + Size::new(rel_shift.x, rel_shift.y)), ); + // Don't let the window get too small + new_frame.size.width = max(new_frame.size.width, 200); + new_frame.size.height = max(new_frame.size.height, 200); resized_window.set_frame(new_frame); + //println!("Set window to {new_frame}"); #[cfg(target_os = "axle")] {
Eliminated unnecessary swapping of the persistent memory indexes.
@@ -522,9 +522,9 @@ GetDimmsCurrentConfig( **/ if (ISsNum > 1) { for (Index = 0; Index < DimmConfigsNum; Index++) { - for (Index2 = 0; Index2 < DimmConfigsNum; Index2++) { - if ((pDimmConfigs[Index].Persistent[0].PersistentIndex == pDimmConfigs[Index2].Persistent[1].PersistentIndex) || - (pDimmConfigs[Index].Persistent[1].PersistentIndex == pDimmConfigs[Index2].Persistent[0].PersistentIndex)) { + for (Index2 = Index + 1; Index2 < DimmConfigsNum; Index2++) { + if (((pDimmConfigs[Index].Persistent[0].PersistentIndex == pDimmConfigs[Index2].Persistent[1].PersistentIndex) && (pDimmConfigs[Index].Persistent[0].PersistentIndex != 0)) || + ((pDimmConfigs[Index].Persistent[1].PersistentIndex == pDimmConfigs[Index2].Persistent[0].PersistentIndex) && (pDimmConfigs[Index].Persistent[1].PersistentIndex != 0))) { PersistentTmp = pDimmConfigs[Index2].Persistent[1]; pDimmConfigs[Index2].Persistent[1] = pDimmConfigs[Index2].Persistent[0]; pDimmConfigs[Index2].Persistent[0] = PersistentTmp;
first take at filetype functionality
@@ -33,6 +33,7 @@ before used to always bang on callback, now only bangs now due to new x->x_fileb #define COLLTHREAD 1 //default is threaded #define COLLEMBED 0 //default for save in patch #define COLL_ALLBANG 1 //bang all when read instead of specific object +#define COLL_FILENAME 100 //filename max size enum { COLL_HEADRESET, COLL_HEADNEXT, COLL_HEADPREV, /* distinction not used, currently */ @@ -100,6 +101,7 @@ typedef struct _coll pthread_cond_t unsafe_cond; t_symbol *x_s; + t_symbol *x_fileext; t_int unsafe; t_int init; //used to make sure that the secondary thread is ready to go @@ -1903,7 +1905,14 @@ static void coll_write(t_coll *x, t_symbol *s) if (!x->unsafe) { t_collcommon *cc = x->x_common; if (s && s != &s_) { - x->x_s = s; + char buf[MAXPDSTRING]; + if(x->x_fileext != &s_) + { + strncpy(buf, s->s_name, MAXPDSTRING - 5); // period + 3 char ext + null + strcat(buf, x->x_fileext->s_name); + x->x_s = gensym(buf); + } + else x->x_s = s; if (x->x_threaded == 1) { x->unsafe = 10; @@ -1973,6 +1982,16 @@ static void coll_writeagain(t_coll *x) static void coll_filetype(t_coll *x, t_symbol *s) { /* dummy */ + if(s != &s_) + { + if(strcmp(s -> s_name, "text") == 0) x->x_fileext = gensym(".txt"); + else if(strcmp(s -> s_name, "csv") == 0) x->x_fileext = gensym(".csv"); + else x->x_fileext = &s_; + } + else + { + x->x_fileext = &s_; + }; } static void coll_dump(t_coll *x)
HV: Initialize one variable to fix the compiling warning If the optimization option is enabled, it is possible that one variable is not initialized before using in the get_vioapic_info. (In fact the warning is bogus) This is only to reduce the compiling warning.
@@ -636,6 +636,7 @@ int get_vioapic_info(char *str, int str_max, int vmid) size -= len; str += len; + rte = 0; for (pin = 0 ; pin < vioapic_pincount(vm); pin++) { vioapic_get_rte(vm, pin, (void *)&rte); low = rte;
[deb] - Add dependencies for debian packages.
@@ -10,9 +10,8 @@ Homepage: http://github.com/ROCm-Developer-Tools/aomp Package: aomp Architecture: amd64 #Depends: ${shlibs:Depends},${misc:Depends} -Depends: ${misc:Depends} +Depends: gcc, g++, libelf-dev, libdrm-amdgpu1, libnuma-dev Description: AOMP is an experimental OpenMP compiler LLVM 15.0 for offloading to either Radeon GPUs or Nvidia GPUs. Nvidia GPUs are not supported on aarch64. - AOMP requires either rocm, cuda, or both. - Dependencies are not specified here for flexibility. + AOMP requires the dkms module from ROCm, amdgpu-dkms.
add vnet/util/radix.h to nobase_include_HEADERS list header is included by ip6.h and should therefore be made public
@@ -62,7 +62,8 @@ nobase_include_HEADERS += \ vnet/rewrite.h \ vnet/vnet.h \ vnet/vnet_all_api_h.h \ - vnet/vnet_msg_enum.h + vnet/vnet_msg_enum.h \ + vnet/util/radix.h API_FILES += vnet/interface.api
Vertcoin caveats
@@ -40,6 +40,10 @@ Refer to [this file](https://github.com/coinfoundry/miningcore/blob/master/src/M - Claymore Miner must be configured to communicate using this protocol by supplying the `-esm 3` command line option - Genoil's `ethminer` must be configured to communicate using this protocol by supplying the `-SP 2` command line option +#### Vertcoin + +- Be sure to copy the file `verthash.dat` from your vertcoin blockchain folder to your Miningcore server +- In your Miningcore config file add this property to your vertcoin pool configuration: `"vertHashDataFile": "/path/to/verthash.dat",` ### Donations
arch/stm32l4: Fix usages of undefined function. Fix unsages of undefined function, sem_wait/post and ferr/info.
#include <tinyara/arch.h> #include <tinyara/progmem.h> +#include <debug.h> #include <semaphore.h> #include <assert.h> #include <errno.h> @@ -126,7 +127,7 @@ static inline void sem_lock(void) { /* Take the semaphore (perhaps waiting) */ - ret = nxsem_wait(&g_sem); + ret = sem_wait(&g_sem); /* The only case that an error should occur here is if the wait was * awakened by a signal. @@ -139,7 +140,7 @@ static inline void sem_lock(void) static inline void sem_unlock(void) { - nxsem_post(&g_sem); + sem_post(&g_sem); } static void flash_unlock(void) @@ -187,7 +188,7 @@ static inline void flash_optbytes_lock(void) static inline void flash_erase(size_t page) { - finfo("erase page %u\n", page); + fvdbg("erase page %u\n", page); modifyreg32(STM32L4_FLASH_CR, 0, FLASH_CR_PAGE_ERASE); modifyreg32(STM32L4_FLASH_CR, FLASH_CR_PNB_MASK, FLASH_CR_PNB(page)); @@ -255,12 +256,12 @@ uint32_t stm32l4_flash_user_optbytes(uint32_t clrbits, uint32_t setbits) regval = getreg32(STM32L4_FLASH_OPTR); - finfo("Flash option bytes before: 0x%x\n", regval); + fvdbg("Flash option bytes before: 0x%x\n", regval); regval = (regval & ~clrbits) | setbits; putreg32(regval, STM32L4_FLASH_OPTR); - finfo("Flash option bytes after: 0x%x\n", regval); + fvdbg("Flash option bytes after: 0x%x\n", regval); /* Start Option Bytes programming and wait for completion. */ @@ -510,7 +511,7 @@ out: if (ret != OK) { - ferr("flash write error: %d, status: 0x%x\n", ret, getreg32(STM32L4_FLASH_SR)); + fdbg("flash write error: %d, status: 0x%x\n", ret, getreg32(STM32L4_FLASH_SR)); modifyreg32(STM32L4_FLASH_SR, 0, FLASH_SR_ALLERRS); }
%new story diffs over /burden now get treated as burdens.
(so-hear:sor & [our.bol nom.dif] dif.dif) :: $new - ::TODO? shouldn't this act the same as $burden in ++ta-take? =< so-done - %- ~(so-hear so nom.dif ~ (fall (~(get by stories) nom.dif) *story)) - [& [our.bol nom.dif] %bear ~ [cof.dif.dif ~] [~ ~]] + %- ~(so-bear so nom.dif ~ (fall (~(get by stories) nom.dif) *story)) + [~ [cof.dif.dif ~] [~ ~]] == :: $circle
ec key validation checks updated
@@ -1855,7 +1855,59 @@ err: OPENSSL_free(buf); return r; } -#endif + +static int check_ec_key_field_public_range_test(int id) +{ + int ret = 0, type = 0; + const EC_POINT *pub = NULL; + const EC_GROUP *group = NULL; + const EC_METHOD *meth = NULL; + const BIGNUM *field = NULL; + BIGNUM *x = NULL, *y = NULL; + EC_KEY *key = NULL; + + if (!(TEST_ptr(x = BN_new()) + && TEST_ptr(y = BN_new()) + && TEST_ptr(key = EC_KEY_new_by_curve_name(curves[id].nid)) + && TEST_ptr(group = EC_KEY_get0_group(key)) + && TEST_ptr(meth = EC_GROUP_method_of(group)) + && TEST_ptr(field = EC_GROUP_get0_field(group)) + && TEST_int_gt(EC_KEY_generate_key(key), 0) + && TEST_int_gt(EC_KEY_check_key(key), 0) + && TEST_ptr(pub = EC_KEY_get0_public_key(key)) + && TEST_int_gt(EC_POINT_get_affine_coordinates(group, pub, x, y, + NULL), 0))) + goto err; + + /* + * Make the public point out of range by adding the field (which will still + * be the same point on the curve). The add is different for char2 fields. + */ + type = EC_METHOD_get_field_type(meth); + if (type == NID_X9_62_characteristic_two_field) { + /* test for binary curves */ + if (!TEST_true(BN_GF2m_add(x, x, field))) + goto err; + } else if (type == NID_X9_62_prime_field) { + /* test for prime curves */ + if (!TEST_true(BN_add(x, x, field))) + goto err; + } else { + /* this should never happen */ + TEST_error("Unsupported EC_METHOD field_type"); + goto err; + } + if (!TEST_int_le(EC_KEY_set_public_key_affine_coordinates(key, x, y), 0)) + goto err; + + ret = 1; +err: + BN_free(x); + BN_free(y); + EC_KEY_free(key); + return ret; +} +#endif /* OPENSSL_NO_EC */ int setup_tests(void) { @@ -1880,7 +1932,8 @@ int setup_tests(void) ADD_TEST(group_field_test); ADD_ALL_TESTS(check_named_curve_test, crv_len); ADD_ALL_TESTS(check_named_curve_lookup_test, crv_len); -#endif + ADD_ALL_TESTS(check_ec_key_field_public_range_test, crv_len); +#endif /* OPENSSL_NO_EC */ return 1; }
Fixed measurements buffer cast Trying a cast to uint8_t*
@@ -855,7 +855,7 @@ SURVIVE_EXPORT void survive_optimizer_setup_buffers(survive_optimizer *ctx, void size_t measurementAllocSize = ctx->poseLength * sizeof(survive_optimizer_measurement) * 2 * sensor_cnt * NUM_GEN2_LIGHTHOUSES; memset(ctx->measurements, 0, measurementAllocSize); - ctx->obj_up_vectors = (survive_optimizer_measurement *)measurements_buffer + measurementAllocSize; + ctx->obj_up_vectors = (uint8_t*)measurements_buffer + measurementAllocSize; ctx->cam_up_vectors = ctx->obj_up_vectors + ctx->poseLength; memset(ctx->parameters_info, 0, sizeof(mp_par) * par_count); for (int i = 0; i < survive_optimizer_get_parameters_count(ctx); i++) {
http3: check the pointer before dereferencing
@@ -321,6 +321,8 @@ static void control_stream_handle_input(h2o_http3_conn_t *conn, struct st_h2o_ht static void discard_handle_input(h2o_http3_conn_t *conn, struct st_h2o_http3_ingress_unistream_t *stream, const uint8_t **src, const uint8_t *src_end, int is_eos) { + if (src == NULL) + return; *src = src_end; }
update to cibuildwheels 2.4
@@ -56,7 +56,7 @@ jobs: - name: Build wheels for linux if: runner.os == 'Linux' - uses: pypa/[email protected] + uses: pypa/[email protected] env: CIBW_BUILD: ${{ matrix.cibw_build }} CIBW_SKIP: "*musllinux*" @@ -65,7 +65,7 @@ jobs: - name: Build wheels for macos if: runner.os != 'Linux' - uses: pypa/[email protected] + uses: pypa/[email protected] env: CIBW_BUILD: ${{ matrix.cibw_build }} CIBW_BEFORE_BUILD: pip install cython
Match variable style syntax per Cary
@@ -90,10 +90,10 @@ If you are building dynamic libraries, once you have configured, built, and installed the libraries, you should see the following pattern of symlinks and files in the install lib folder: - libHalf.so -> libHalf-LIB_SUFFIX.so - libHalf-LIB_SUFFIX.so -> libHalf-LIB_SUFFIX.so.SO_MAJOR_VERSION - libHalf-LIB_SUFFIX.so.SO_MAJOR_VERSION -> libHalf-LIB_SUFFIX.so.SO_FULL_VERSION - libHalf-LIB_SUFFIX.so.SO_FULL_VERSION (actual file) + libHalf.so -> libHalf-$LIB_SUFFIX.so + libHalf-$LIB_SUFFIX.so -> libHalf-$LIB_SUFFIX.so.$SO_MAJOR_VERSION + libHalf-$LIB_SUFFIX.so.$SO_MAJOR_VERSION -> libHalf-$LIB_SUFFIX.so.$SO_FULL_VERSION + libHalf-$LIB_SUFFIX.so.$SO_FULL_VERSION (actual file) You can configure the LIB_SUFFIX, although it defaults to the library major and minor version, so in the case of a 2.3 library, it would default
feat(ci): update known_failure_cases_repo before running tests
# clone test env configs - retry_failed git clone $TEST_ENV_CONFIG_REPO - python $CHECKOUT_REF_SCRIPT ci-test-runner-configs ci-test-runner-configs - - cd tools/ci/python_packages/tiny_test_fw/bin + # git clone the known failure cases repo, run test + - retry_failed git clone $KNOWN_FAILURE_CASES_REPO known_failure_cases # run test - - python Runner.py $TEST_CASE_PATH -c $CONFIG_FILE -e $ENV_FILE + - cd tools/ci/python_packages/tiny_test_fw/bin + - run_cmd python Runner.py $TEST_CASE_PATH -c $CONFIG_FILE -e $ENV_FILE --known_failure_cases_file $CI_PROJECT_DIR/known_failure_cases/known_failure_cases.txt .example_test_template: extends: # clone test env configs - retry_failed git clone $TEST_ENV_CONFIG_REPO - python $CHECKOUT_REF_SCRIPT ci-test-runner-configs ci-test-runner-configs - - cd tools/ci/python_packages/tiny_test_fw/bin + # git clone the known failure cases repo, run test + - retry_failed git clone $KNOWN_FAILURE_CASES_REPO known_failure_cases # run test - - python Runner.py $COMPONENT_UT_DIRS -c $CONFIG_FILE -e $ENV_FILE + - cd tools/ci/python_packages/tiny_test_fw/bin + - run_cmd python Runner.py $COMPONENT_UT_DIRS -c $CONFIG_FILE -e $ENV_FILE --known_failure_cases_file $CI_PROJECT_DIR/known_failure_cases/known_failure_cases.txt .component_ut_32_template: extends:
That error message was such a liar;
@@ -35,7 +35,7 @@ bool luax_checkvertexformat(lua_State* L, int index, VertexFormat* format) { } int length = lua_objlen(L, index); - lovrAssert(length <= 8, "Only 8 vertex attributes are supported"); + lovrAssert(length <= 8, "Up to 8 vertex attributes are supported"); for (int i = 0; i < length; i++) { lua_rawgeti(L, index, i + 1);
CLEANUP: current LSN is returned in do_log_buff_write().
@@ -341,19 +341,16 @@ static uint32_t do_log_buff_flush(bool flush_all) return nflush; } -static void do_log_buff_write(LogRec *logrec, log_waiter_t *waiter, bool dual_write) +static LogSN do_log_buff_write(LogRec *logrec, bool dual_write) { log_BUFFER *logbuff = &log_gl.log_buffer; + LogSN current_lsn; uint32_t total_length = sizeof(LogHdr) + logrec->header.body_length; uint32_t spare_length; assert(total_length < logbuff->size); pthread_mutex_lock(&log_gl.log_write_lock); - if (waiter != NULL) { - waiter->lsn = log_gl.nxt_write_lsn; - } - /* find the positon to write in log buffer */ while (1) { if (logbuff->head <= logbuff->tail) { @@ -394,9 +391,10 @@ static void do_log_buff_write(LogRec *logrec, log_waiter_t *waiter, bool dual_wr logbuff->tail += total_length; /* update nxt_write_lsn */ + current_lsn = log_gl.nxt_write_lsn; log_gl.nxt_write_lsn.roffset += total_length; - /* update log flush reqeust */ + /* update log flush request */ if (logbuff->fque[logbuff->fend].nflush > 0 && logbuff->fque[logbuff->fend].dual_write != dual_write) { if ((++logbuff->fend) == logbuff->fqsz) logbuff->fend = 0; @@ -422,6 +420,7 @@ static void do_log_buff_write(LogRec *logrec, log_waiter_t *waiter, bool dual_wr do_log_flusher_wakeup(&log_gl.log_flusher); } } + return current_lsn; } static void do_log_buff_complete_dual_write(bool success) @@ -501,7 +500,10 @@ static void *log_flush_thread_main(void *arg) void cmdlog_buff_write(LogRec *logrec, log_waiter_t *waiter, bool dual_write) { /* write the log record on the log buffer */ - do_log_buff_write(logrec, waiter, dual_write); + LogSN current_lsn = do_log_buff_write(logrec, dual_write); + if (waiter) { + waiter->lsn = current_lsn; + } } void cmdlog_buff_flush(LogSN *upto_lsn)
log name of min ack delay tp
@@ -438,6 +438,9 @@ char const* picoquic_log_tp_name(uint64_t tp_number) case picoquic_tp_enable_one_way_delay: tp_name = "enable_one_way_delay"; break; + case picoquic_tp_min_ack_delay: + tp_name = "min_ack_delay"; + break; default: break; }
esp32/mpconfigport.h: Enable MICROPY_PY_DELATTR_SETATTR. To align with unix and stm32 ports.
// control over Python builtins #define MICROPY_PY_FUNCTION_ATTRS (1) #define MICROPY_PY_DESCRIPTORS (1) +#define MICROPY_PY_DELATTR_SETATTR (1) #define MICROPY_PY_STR_BYTES_CMP_WARN (1) #define MICROPY_PY_BUILTINS_STR_UNICODE (1) #define MICROPY_PY_BUILTINS_STR_CENTER (1)