message
stringlengths 6
474
| diff
stringlengths 8
5.22k
|
---|---|
BugID:18258260: Remove the built-in component dependencies in build system | @@ -327,16 +327,6 @@ ifndef CC
$(error No matching toolchain found for architecture $(HOST_ARCH))
endif
-
-
-# Process all the components + AOS
-
-COMPONENTS += $(HOST_MCU_FAMILY) osal init
-
-ifneq ($(ONLY_BUILD_LIBRARY), yes)
-COMPONENTS += auto_component
-endif
-
# MBINS build support
ifeq ($(MBINS),app)
COMPONENTS += mbins.umbins
|
Allow scope_attach_PID.yml to exist
Don't fail, just reuse the existing scope_attach_PID.yml file in shared
memory if it exists. | @@ -864,9 +864,7 @@ main(int argc, char **argv, char **env)
snprintf(path, sizeof(path), "/scope_attach_%d.yml", pid);
- // Permissions on the file need to allow the library in the attached
- // process to remove the shared memory object.
- int shmFd = shm_open(path, O_RDWR|O_CREAT|O_EXCL, S_IRUSR|S_IRGRP|S_IROTH);
+ int shmFd = shm_open(path, O_RDWR|O_CREAT, S_IRUSR|S_IRGRP|S_IROTH);
if (shmFd == -1) {
perror("error: shm_open() failed");
return EXIT_FAILURE;
|
ARMv8: adding stack pointer and L0 page table to ARM coredata | */
/*
- * Copyright (c) 2012, ETH Zurich.
+ * Copyright (c) 2012, 2017 ETH Zurich.
* Copyright (c) 2015, 2016 Hewlett Packard Enterprise Development LP.
* All rights reserved.
*
@@ -29,6 +29,8 @@ struct armv8_coredata_elf {
*
*/
struct armv8_core_data {
+ lpaddr_t stack;
+ lpaddr_t l0_pagetable;
lpaddr_t multiboot2; ///< The physical multiboot2 location
uint64_t multiboot2_size;
lpaddr_t efi_mmap;
|
test-suite: update munge check to look for OS RPM | @@ -8,8 +8,8 @@ if [ -s ./common/TEST_ENV ];then
source ./common/TEST_ENV
fi
-@test "[munge] check for RPM" {
- run rpm -q munge${DELIM}
+@test "[munge] check for OS provdied RPM" {
+ run rpm -q munge
assert_success
}
|
Simplify padding check and get rid of psa_sig_md in rsa_decrypt_wrap() | @@ -227,24 +227,14 @@ static int rsa_decrypt_wrap( void *ctx,
int key_len;
unsigned char buf[MBEDTLS_PK_RSA_PRV_DER_MAX_BYTES];
mbedtls_pk_info_t pk_info = mbedtls_rsa_info;
- psa_algorithm_t psa_sig_md;
((void) f_rng);
((void) p_rng);
#if !defined(MBEDTLS_RSA_ALT)
- switch( rsa->padding )
- {
- case MBEDTLS_RSA_PKCS_V15:
- psa_sig_md = PSA_ALG_RSA_PKCS1V15_CRYPT;
- break;
-
- default:
+ if( rsa->padding != MBEDTLS_RSA_PKCS_V15 )
return( MBEDTLS_ERR_RSA_INVALID_PADDING );
- }
-#else
- psa_sig_md = PSA_ALG_RSA_PKCS1V15_CRYPT;
-#endif
+#endif /* !MBEDTLS_RSA_ALT */
if( ilen != mbedtls_rsa_get_len( rsa ) )
return( MBEDTLS_ERR_RSA_BAD_INPUT_DATA );
@@ -259,7 +249,7 @@ static int rsa_decrypt_wrap( void *ctx,
psa_set_key_type( &attributes, PSA_KEY_TYPE_RSA_KEY_PAIR );
psa_set_key_usage_flags( &attributes, PSA_KEY_USAGE_DECRYPT );
- psa_set_key_algorithm( &attributes, psa_sig_md );
+ psa_set_key_algorithm( &attributes, PSA_ALG_RSA_PKCS1V15_CRYPT );
status = psa_import_key( &attributes,
buf + sizeof( buf ) - key_len, key_len,
@@ -270,8 +260,10 @@ static int rsa_decrypt_wrap( void *ctx,
goto cleanup;
}
- status = psa_asymmetric_decrypt( key_id, psa_sig_md, input, ilen,
- NULL, 0, output, osize, olen );
+ status = psa_asymmetric_decrypt( key_id, PSA_ALG_RSA_PKCS1V15_CRYPT,
+ input, ilen,
+ NULL, 0,
+ output, osize, olen );
if( status != PSA_SUCCESS )
{
ret = mbedtls_pk_error_from_psa_rsa( status );
|
tasn_dec: use do/while around statement macros
Use the do {} while (0) construct around macros whose bodies are complete
statements (including one that has internal control flow!). This is
safer and avoids any risk of misinterpretation if the macro is used in
an unexpected context. | @@ -90,9 +90,9 @@ unsigned long ASN1_tag2bit(int tag)
/* Macro to initialize and invalidate the cache */
-#define asn1_tlc_clear(c) if ((c) != NULL) (c)->valid = 0
+#define asn1_tlc_clear(c) do { if ((c) != NULL) (c)->valid = 0; } while (0)
/* Version to avoid compiler warning about 'c' always non-NULL */
-#define asn1_tlc_clear_nc(c) (c)->valid = 0
+#define asn1_tlc_clear_nc(c) do {(c)->valid = 0; } while (0)
/*
* Decode an ASN1 item, this currently behaves just like a standard 'd2i'
|
fix: Return a list for changed files in git hooks
Why:
In python, filter() will return an iterable object instead of a list,
making it difficult to test if it's empty. Also using list comprehension
is more readable. | @@ -23,8 +23,7 @@ def commit_is_ready(file_names=""):
if not file_names:
file_names = get_modified_files()
- existing_files = filter(file_exists, file_names)
- source_file_names = filter(file_is_checkable, existing_files)
+ files_to_check = [f for f in file_names if file_exists(f) and file_is_checkable(f)]
checks = [
check_secrets,
@@ -33,7 +32,7 @@ def commit_is_ready(file_names=""):
check_whitespace,
]
for check in checks:
- failed_files = check(source_file_names)
+ failed_files = check(files_to_check)
if failed_files:
return failed_files
return []
|
Added Array test cases to function tests | @@ -423,6 +423,25 @@ TEST_F(BasicFuncTests, sendDifferentPriorityEvents)
EventProperties event("first_event");
event.SetPriority(EventPriority_Normal);
event.SetProperty("property", "value");
+ std::vector<int64_t> intvector(8);
+ std::fill(intvector.begin(), intvector.begin() + 4, 5);
+ std::fill(intvector.begin() + 3, intvector.end() - 2, 8);
+ event.SetProperty("property1", intvector);
+
+ std::vector<double> dvector(8);
+ std::fill(dvector.begin(), dvector.begin() + 4, 4.9999);
+ std::fill(dvector.begin() + 3, dvector.end() - 2, 7.9999);
+ event.SetProperty("property2", dvector);
+
+ std::vector<std::string> svector(8);
+ std::fill(svector.begin(), svector.begin() + 4, "string");
+ std::fill(svector.begin() + 3, svector.end() - 2, "string2");
+ event.SetProperty("property3", svector);
+
+ std::vector<GUID_t> gvector(8);
+ std::fill(gvector.begin(), gvector.begin() + 4, GUID_t("00010203-0405-0607-0809-0A0B0C0D0E0F"));
+ std::fill(gvector.begin() + 3, gvector.end() - 2, GUID_t("00000000-0000-0000-0000-000000000000"));
+ event.SetProperty("property4", gvector);
logger->LogEvent(event);
@@ -450,6 +469,25 @@ TEST_F(BasicFuncTests, sendMultipleTenantsTogether)
{
EventProperties event1("first_event");
event1.SetProperty("property", "value");
+ std::vector<int64_t> intvector(8);
+ std::fill(intvector.begin(), intvector.begin() + 4, 5);
+ std::fill(intvector.begin() + 3, intvector.end() - 2, 8);
+ event.SetProperty("property1", intvector);
+
+ std::vector<double> dvector(8);
+ std::fill(dvector.begin(), dvector.begin() + 4, 4.9999);
+ std::fill(dvector.begin() + 3, dvector.end() - 2, 7.9999);
+ event.SetProperty("property2", dvector);
+
+ std::vector<std::string> svector(8);
+ std::fill(svector.begin(), svector.begin() + 4, "string");
+ std::fill(svector.begin() + 3, svector.end() - 2, "string2");
+ event.SetProperty("property3", svector);
+
+ std::vector<GUID_t> gvector(8);
+ std::fill(gvector.begin(), gvector.begin() + 4, GUID_t("00010203-0405-0607-0809-0A0B0C0D0E0F"));
+ std::fill(gvector.begin() + 3, gvector.end() - 2, GUID_t("00000000-0000-0000-0000-000000000000"));
+ event.SetProperty("property4", gvector);
logger->LogEvent(event1);
|
common/gpio.c: Format with clang-format
BRANCH=none
TEST=none | @@ -74,8 +74,8 @@ static int gpio_config_pins(enum module_id id, uint32_t port, uint32_t pin_mask,
gpio_set_flags_by_mask(
af->port, (af->mask & pin_mask),
enable ? af->flags : GPIO_INPUT);
- gpio_set_alternate_function(af->port,
- (af->mask & pin_mask),
+ gpio_set_alternate_function(
+ af->port, (af->mask & pin_mask),
enable ? af->func : GPIO_ALT_FUNC_NONE);
rv = EC_SUCCESS;
/* We're done here if we were just setting one port. */
@@ -222,8 +222,8 @@ int gpio_or_ioex_get_level(int signal, int *value)
int signal_is_gpio(int signal)
{
- return ((signal >= GPIO_SIGNAL_START)
- && (signal < GPIO_SIGNAL_START + GPIO_COUNT));
+ return ((signal >= GPIO_SIGNAL_START) &&
+ (signal < GPIO_SIGNAL_START + GPIO_COUNT));
}
__attribute__((weak)) void gpio_set_wakepin(enum gpio_signal signal,
|
Use fixed value of DILL_RDTSC_DIFF | #if defined(__x86_64__) || defined(__i386__)
#include <x86intrin.h>
+
+#define DILL_RDTSC_DIFF 1000000ULL
#endif
#include "cr.h"
#include "pollset.h"
#include "utils.h"
-static __attribute__((noinline)) uint64_t dill_now_measure(void) {
- uint64_t start_rdtsc = __rdtsc();
- usleep(100);
- uint64_t stop_rdtsc = __rdtsc();
- int64_t diff_rdtsc = stop_rdtsc - start_rdtsc;
- if(diff_rdtsc < 0) diff_rdtsc = -diff_rdtsc;
- return diff_rdtsc * 5;
-}
-
static int64_t mnow(void) {
#if defined __APPLE__
static mach_timebase_info_data_t dill_mtid = {0};
@@ -84,12 +77,10 @@ int64_t now(void) {
#if defined(__x86_64__) || defined(__i386__)
static int64_t last_tick = 0;
static uint64_t last_rdtsc = 0;
- static uint64_t rdtsc_diff = 0ULL;
uint64_t rdtsc = __rdtsc();
int64_t diff = rdtsc - last_rdtsc;
- if(dill_slow(!rdtsc_diff)) rdtsc_diff = dill_now_measure();
if(diff < 0) diff = -diff;
- if(dill_fast(diff < rdtsc_diff))
+ if(dill_fast(diff < DILL_RDTSC_DIFF))
return last_tick;
else
last_rdtsc = rdtsc;
|
Disable by default some vulkan layers that cause issues | @@ -25,4 +25,4 @@ fi
LD_PRELOAD="${LD_PRELOAD}:${MANGOHUD_LIB_NAME}"
LD_LIBRARY_PATH="${LD_LIBRARY_PATH}:@ld_libdir_mangohud@"
-exec env MANGOHUD=1 LD_LIBRARY_PATH="${LD_LIBRARY_PATH}" LD_PRELOAD="${LD_PRELOAD}" "$@"
+exec env DISABLE_LAYER_AMD_SWITCHABLE_GRAPHICS_1=1 NODEVICE_SELECT=1 MANGOHUD=1 LD_LIBRARY_PATH="${LD_LIBRARY_PATH}" LD_PRELOAD="${LD_PRELOAD}" "$@"
|
Link Checker: Check CppCMS links again | @@ -13,9 +13,3 @@ https://webdemo.libelektra.org
https://debian-stretch-repo.libelektra.org
https://crates.io/crates/elektra
https://crates.io/crates/elektra-sys
-
-# cppcms website has been down for quite a while for unknown reasons
-http://cppcms.com
-http://cppcms.com/wikipp/en/page/apt
-http://cppcms.com/wikipp/en/page/cppcms_1x_config
-http://cppcms.com/wikipp/en/page/cppcms_1x_build
|
Add a FAQ for common issues | @@ -242,6 +242,11 @@ A colleague challenged me to find a name as unpronounceable as [gnirehtet].
[`strcpy`]: http://man7.org/linux/man-pages/man3/strcpy.3.html
+## Common issues
+
+See the [FAQ](FAQ.md).
+
+
## Developers
Read the [developers page].
|
tests: functional: Remove non-existing field from CoreConfig | @@ -42,7 +42,6 @@ class CoreConfig(Structure):
("_volume_type", c_uint8),
("_core_id", c_uint16),
("_name", c_char_p),
- ("_cache_id", c_uint16),
("_try_add", c_bool),
("_seq_cutoff_threshold", c_uint32),
("_user_metadata", UserMetadata),
|
alef: cap cwnd | ^- pump-metrics
::
=. num-live (add num-live num-sent)
- ?> (lte num-live cwnd)
metrics
:: +on-ack: adjust metrics based on a packet getting acknowledged
::
:: if below congestion threshold, add 1; else, add avg. 1 / cwnd
::
=. cwnd
+ %+ min 200
?: in-slow-start
+(cwnd)
(add cwnd !=(0 (mod (mug now) cwnd)))
|
BUFR decoding: Crash in case of invalid delayed replication | @@ -265,6 +265,7 @@ static size_t __expand(grib_accessor* a, bufr_descriptors_array* unexpanded, buf
}
grib_context_free(c,v);
inner_expanded=do_expand(a,inner_unexpanded,ccp,err);
+ if (*err) return 0;
grib_bufr_descriptors_array_delete(inner_unexpanded);
#if MYDEBUG
for (i=0;i<inner_expanded->n;i++) {
@@ -297,6 +298,8 @@ static size_t __expand(grib_accessor* a, bufr_descriptors_array* unexpanded, buf
grib_context_log(c, GRIB_LOG_ERROR,
"Delayed replication: %06ld: expected %d but only found %lu elements",
u->code, us->X, unexpanded->n - 1);
+ *err = GRIB_DECODING_ERROR;
+ return 0;
}
for (j=0;j<us->X+1;j++) {
DESCRIPTORS_POP_FRONT_OR_RETURN(unexpanded, u0);
@@ -307,6 +310,7 @@ static size_t __expand(grib_accessor* a, bufr_descriptors_array* unexpanded, buf
#endif
}
inner_expanded=do_expand(a,inner_unexpanded,ccp,err);
+ if (*err) return 0;
grib_bufr_descriptors_array_delete(inner_unexpanded);
size=BUFR_DESCRIPTORS_ARRAY_USED_SIZE(inner_expanded);
#if MYDEBUG
@@ -349,6 +353,7 @@ static size_t __expand(grib_accessor* a, bufr_descriptors_array* unexpanded, buf
for (i=0;i<us->X;i++) grib_bufr_descriptor_delete(ur[i]);
grib_context_free(c,ur);
inner_expanded=do_expand(a,inner_unexpanded,ccp,err);
+ if (*err) return 0;
grib_bufr_descriptors_array_delete(inner_unexpanded);
#if MYDEBUG
for (i=0;i<inner_expanded->n;i++) {
@@ -507,6 +512,7 @@ static bufr_descriptors_array* do_expand(grib_accessor* a,bufr_descriptors_array
#endif
while (unexpanded->n) {
__expand(a,unexpanded,expanded,ccp,err);
+ if (*err) return NULL;
}
#if MYDEBUG
{
@@ -630,6 +636,7 @@ static int expand(grib_accessor* a)
ccp.associatedFieldWidth=0;
ccp.newStringWidth=0;
self->expanded=do_expand(a,unexpanded,&ccp,&err);
+ if (err) return err;
grib_context_expanded_descriptors_list_push(c,key,self->expanded,unexpanded_copy);
grib_bufr_descriptors_array_delete(unexpanded);
|
docs: Add the missing dependency libseccomp-devel | @@ -98,6 +98,7 @@ export AESM_PATH=$PWD
Download the package from [here](https://github.com/alibaba/inclavare-containers/releases/).
- On CentOS 7.5:
```shell
+yum install -y libseccomp
rpm -ivh rune-0.3.0-1.el7.x86_64.rpm
rpm -ivh occlum-pal-0.14.0-1.el7.x86_64.rpm
```
@@ -138,7 +139,6 @@ You need to specify a set of parameters to `docker run` in order to use `rune`,
```shell
export OCCLUM_INSTANCE_DIR=occlum-app
-yum install -y libseccomp
docker run -it --rm --runtime=rune \
-e ENCLAVE_TYPE=intelSgx \
-e ENCLAVE_RUNTIME_PATH=/opt/occlum/build/lib/libocclum-pal.so \
|
Yardoc: Replace Doxygen format in rmstruct.c | @@ -187,13 +187,9 @@ Export_ChromaticityInfo(ChromaticityInfo *ci, VALUE chrom)
/**
- * Create a string representation of a Magick::Chromaticity.
+ * Return a string representation of a {Magick::Chromaticity} object.
*
- * Ruby usage:
- * - @verbatim Magick::Chromaticity#to_s @endverbatim
- *
- * @param self this object
- * @return the string
+ * @return [String] the string
*/
VALUE
ChromaticityInfo_to_s(VALUE self)
@@ -352,13 +348,9 @@ destroy_ColorInfo(ColorInfo *ci)
/**
- * Return a string representation of a Magick::Color object.
- *
- * Ruby usage:
- * - @verbatim Color#to_s @endverbatim
+ * Return a string representation of a {Magick::Color} object.
*
- * @param self this object
- * @return the string
+ * @return [String] the string
*/
VALUE
Color_to_s(VALUE self)
@@ -512,12 +504,9 @@ destroy_TypeInfo(TypeInfo *ti)
/**
- * Implement the Font#to_s method.
- *
- * No Ruby usage (internal function)
+ * Return a string representation of a {Magick::Font} object.
*
- * @param self this object
- * @return the string
+ * @return [String] the string
*/
VALUE
Font_to_s(VALUE self)
@@ -654,13 +643,9 @@ Export_PrimaryInfo(PrimaryInfo *pi, VALUE sp)
/**
- * Create a string representation of a Magick::PrimaryInfo.
+ * Return a string representation of a {Magick::PrimaryInfo} object.
*
- * Ruby usage:
- * - @verbatim Magick::PrimaryInfo#to_s @endverbatim
- *
- * @param self this object
- * @return the string
+ * @return [String] the string
*/
VALUE
PrimaryInfo_to_s(VALUE self)
@@ -738,13 +723,9 @@ Export_RectangleInfo(RectangleInfo *rect, VALUE sr)
/**
- * Create a string representation of a Magick::Rectangle.
- *
- * Ruby usage:
- * - @verbatim Magick::Rectangle#to_s @endverbatim
+ * Return a string representation of a {Magick::Rectangle} object.
*
- * @param self this object
- * @return the string
+ * @return [String] the string
*/
VALUE
RectangleInfo_to_s(VALUE self)
@@ -821,13 +802,9 @@ Export_SegmentInfo(SegmentInfo *segment, VALUE s)
/**
- * Create a string representation of a Magick::Segment.
+ * Return a string representation of a {Magick::Segment} object.
*
- * Ruby usage:
- * - @verbatim Magick::SegmentInfo#to_s @endverbatim
- *
- * @param self this object
- * @return the string
+ * @return [String] the string
*/
VALUE
SegmentInfo_to_s(VALUE self)
@@ -935,13 +912,9 @@ Export_TypeMetric(TypeMetric *tm, VALUE st)
/**
- * Create a string representation of a Magick::TypeMetric.
- *
- * Ruby usage:
- * - @verbatim Magick::TypeMetric#to_s @endverbatim
+ * Return a string representation of a {Magick::TypeMetric} object.
*
- * @param self this object
- * @return the string
+ * @return [String] the string
*/
VALUE
TypeMetric_to_s(VALUE self)
|
redrix: Disable power LED during S0ix
BRANCH=none
TEST=On Redrix. Verify LED will not blink on S0ix. | @@ -218,16 +218,8 @@ static void led_set_battery(void)
static void led_set_power(void)
{
- static unsigned int power_tick;
-
- power_tick++;
-
if (chipset_in_state(CHIPSET_STATE_ON))
led_set_color_power(LED_WHITE);
- else if (chipset_in_state(CHIPSET_STATE_ANY_SUSPEND))
- led_set_color_power((power_tick %
- LED_TICKS_PER_CYCLE < LED_ON_TICKS) ?
- LED_WHITE : LED_OFF);
else
led_set_color_power(LED_OFF);
}
|
Check Bashisms: Ignore `run_dev_env` | @@ -13,8 +13,8 @@ find -version > /dev/null 2>&1 > /dev/null && FIND=find || FIND='find -E'
# this way we also check subdirectories
# The script `check-env-dep` uses process substitution which is **not** a standard `sh` feature!
# See also: https://unix.stackexchange.com/questions/151925
-scripts=$($FIND scripts/ -type f -not -regex \
- '.+(/docker/.+|check-env-dep|Jenkinsfile(.daily)?|gitignore|kdb_zsh_completion|sed|Vagrantfile|\.(cmake|fish|in|md|txt))$' | \
+scripts=$($FIND scripts/ -type f -not -regex '.+/docker/.+' -not -regex \
+ '.+(check-env-dep|Jenkinsfile(.daily)?|gitignore|kdb_zsh_completion|run_dev_env|sed|Vagrantfile|\.(cmake|fish|in|md|txt))$' | \
xargs)
checkbashisms $scripts
ret=$?
|
xpath NEW when evaluation checking | @@ -5277,6 +5277,32 @@ moveto_root(struct lyxp_set *set, int options)
}
}
+/**
+ * @brief Check whether a node has some unresolved "when".
+ *
+ * @param[in] node Node to check.
+ * @return LY_ERR value (LY_EINCOMPLETE if there are some unresolved "when")
+ */
+static LY_ERR
+moveto_when_check(const struct lyd_node *node)
+{
+ const struct lysc_node *schema;
+
+ if (!node) {
+ return LY_SUCCESS;
+ }
+
+ schema = node->schema;
+ do {
+ if (schema->when && !(node->flags & LYD_WHEN_TRUE)) {
+ return LY_EINCOMPLETE;
+ }
+ schema = schema->parent;
+ } while (schema && (schema->nodetype & (LYS_CASE | LYS_CHOICE)));
+
+ return LY_SUCCESS;
+}
+
/**
* @brief Check @p node as a part of NameTest processing.
*
@@ -5306,10 +5332,10 @@ moveto_node_check(const struct lyd_node *node, enum lyxp_node_type root_type, co
return LY_ENOT;
}
- /* TODO when check */
- /*if (!LYD_WHEN_DONE(node->when_status)) {
+ /* when check */
+ if (moveto_when_check(node)) {
return LY_EINCOMPLETE;
- }*/
+ }
/* match */
return LY_SUCCESS;
@@ -5991,10 +6017,10 @@ moveto_self_add_children_r(const struct lyd_node *parent, uint32_t parent_pos, e
continue;
}
- /* TODO when check */
- /*if (!LYD_WHEN_DONE(sub->when_status)) {
+ /* when check */
+ if (moveto_when_check(sub)) {
return LY_EINCOMPLETE;
- }*/
+ }
if (!set_dup_node_check(dup_check_set, sub, LYXP_NODE_ELEM, -1)) {
set_insert_node(to_set, sub, 0, LYXP_NODE_ELEM, to_set->used);
@@ -6207,10 +6233,10 @@ moveto_parent(struct lyxp_set *set, int all_desc, int options)
continue;
}
- /* TODO when check */
- /*if (new_node && !LYD_WHEN_DONE(new_node->when_status)) {
+ /* when check */
+ if (moveto_when_check(new_node)) {
return LY_EINCOMPLETE;
- }*/
+ }
/* node already there can also be the root */
if (!new_node) {
|
avx: use vectors of fixed-length elements for some comparisons
Hopefully this fixes the clang issue. | @@ -1370,7 +1370,7 @@ simde_mm_cmp_pd (simde__m128d a, simde__m128d b, const int imm8)
r.i64 = (int64_t __attribute__((__vector_size__(16)))) (a.f64 <= b.f64);
break;
case SIMDE_CMP_FALSE_OQ:
- r.i32f = (a.i32f ^ a.i32f);
+ r.i32 = (a.i32 ^ a.i32);
break;
case SIMDE_CMP_NEQ_OQ:
r.i64 = (int64_t __attribute__((__vector_size__(16)))) (a.f64 != b.f64);
@@ -1382,7 +1382,7 @@ simde_mm_cmp_pd (simde__m128d a, simde__m128d b, const int imm8)
r.i64 = (int64_t __attribute__((__vector_size__(16)))) (a.f64 > b.f64);
break;
case SIMDE_CMP_TRUE_UQ:
- r.i32f = ~(a.i32f ^ a.i32f);
+ r.i32 = ~(a.i32 ^ a.i32);
break;
case SIMDE_CMP_EQ_OS:
r.i64 = (int64_t __attribute__((__vector_size__(16)))) (a.f64 == b.f64);
|
web ui jenkins: change `true` back to `isMaster()`, re-enable full build | @@ -138,7 +138,12 @@ stage("Main builds") {
parallel generateMainBuildStages()
}
-maybeStage("Build artifacts", true) {
+stage("Full builds") {
+ milestone label: "Full builds"
+ parallel generateFullBuildStages()
+}
+
+maybeStage("Build artifacts", isMaster()) {
milestone label: "artifacts"
parallel generateArtifactStages()
}
@@ -147,7 +152,7 @@ maybeStage("Deploy Homepage", isMaster()) {
deployHomepage()
}
-maybeStage("Deploy Web UI", true) {
+maybeStage("Deploy Web UI", isMaster()) {
deployWebUI()
}
@@ -261,7 +266,7 @@ def dockerInit() {
"web-base", this.&idHomepage,
".",
"./scripts/docker/webui/base/Dockerfile",
- true
+ isMaster()
)
/* Image building elektrad */
|
add target for slow tests | @@ -323,7 +323,7 @@ endif
ifeq ($(MAKESTAGE),1)
.PHONY: doc/commands.txt $(TARGETS)
-default all clean allclean distclean doc/commands.txt doxygen test utest utest_gpu gputest pythontest shared-lib $(TARGETS):
+default all clean allclean distclean doc/commands.txt doxygen test utest utest_gpu gputest testslow pythontest shared-lib $(TARGETS):
$(MAKE) MAKESTAGE=2 $(MAKECMDGOALS)
tests/test-%: force
@@ -781,6 +781,8 @@ endif
test: ${TESTS}
+testslow: ${TESTS_SLOW}
+
gputest: ${TESTS_GPU}
pythontest: ${TESTS_PYTHON}
|
Fix objCache on Windows systems | @@ -59,7 +59,10 @@ const generateIncludesLookup = async (buildIncludeRoot) => {
const includesLookup = {};
for (const filePath of allIncludeFiles) {
const fileContents = await readFile(filePath, "utf8");
- includesLookup[Path.relative(buildIncludeRoot, filePath)] = {
+ const key = Path.relative(buildIncludeRoot, filePath)
+ .split(Path.sep)
+ .join(Path.posix.sep);
+ includesLookup[key] = {
contents: fileContents,
referencedFiles: referencedFiles(fileContents),
checksum: checksumString(fileContents),
|
Package json settings | {
"name": "gb-studio",
"productName": "GB Studio",
- "version": "1.0.0",
- "description": "My Electron application description",
+ "version": "0.1.0",
+ "description": "Visual retro game maker",
"main": "dist/index.js",
"scripts": {
"start": "run-p parcel:watch start:electron",
},
"keywords": [],
"author": "cmaltby",
- "license": "MIT",
+ "license": "UNLICENSED",
"config": {
"forge": {
"make_targets": {
|
Add the correct enum value for DSA public key serialization | @@ -173,7 +173,7 @@ static int dsa_pub_print(void *ctx, void *dsa, OSSL_CORE_BIO *cout,
if (out == NULL)
return 0;
- ret = ossl_prov_print_dsa(out, dsa, 0);
+ ret = ossl_prov_print_dsa(out, dsa, dsa_print_pub);
BIO_free(out);
return ret;
|
occ: sensors-groups: Add DT properties to mark HWMON sensor groups
Fix the sensor type to match HWMON sensor types. Add compatible flag
to indicate the environmental sensor groups so that operations on
these groups can be handled by HWMON linux interface. | @@ -1590,13 +1590,13 @@ void occ_add_sensor_groups(struct dt_node *sg, u32 *phandles, u32 *ptype,
{ OCC_SENSOR_TYPE_GENERIC, "generic",
OPAL_SENSOR_GROUP_ENABLE
},
- { OCC_SENSOR_TYPE_CURRENT, "current",
+ { OCC_SENSOR_TYPE_CURRENT, "curr",
OPAL_SENSOR_GROUP_ENABLE
},
- { OCC_SENSOR_TYPE_VOLTAGE, "voltage",
+ { OCC_SENSOR_TYPE_VOLTAGE, "in",
OPAL_SENSOR_GROUP_ENABLE
},
- { OCC_SENSOR_TYPE_TEMPERATURE, "temperature",
+ { OCC_SENSOR_TYPE_TEMPERATURE, "temp",
OPAL_SENSOR_GROUP_ENABLE
},
{ OCC_SENSOR_TYPE_UTILIZATION, "utilization",
@@ -1643,6 +1643,17 @@ void occ_add_sensor_groups(struct dt_node *sg, u32 *phandles, u32 *ptype,
dt_add_property_cells(node, "sensor-group-id", handle);
dt_add_property_string(node, "type", groups[j].str);
+
+ if (groups[j].type == OCC_SENSOR_TYPE_CURRENT ||
+ groups[j].type == OCC_SENSOR_TYPE_VOLTAGE ||
+ groups[j].type == OCC_SENSOR_TYPE_TEMPERATURE ||
+ groups[j].type == OCC_SENSOR_TYPE_POWER) {
+ dt_add_property_string(node, "sensor-type",
+ groups[j].str);
+ dt_add_property_string(node, "compatible",
+ "ibm,opal-sensor");
+ }
+
dt_add_property_cells(node, "ibm,chip-id", chipid);
dt_add_property_cells(node, "reg", handle);
if (groups[j].ops == OPAL_SENSOR_GROUP_ENABLE) {
|
[hardware] Shuffle AXI channels for maximum DMA bandwidth | @@ -377,6 +377,13 @@ module mempool_group
axi_tile_req_t [NumAXIMastersPerGroup-1:0] axi_mst_req;
axi_tile_resp_t [NumAXIMastersPerGroup-1:0] axi_mst_resp;
+ axi_tile_req_t [NumTilesPerGroup+NumDmasPerGroup-1:0] axi_slv_req;
+ axi_tile_resp_t [NumTilesPerGroup+NumDmasPerGroup-1:0] axi_slv_resp;
+
+ for (genvar i = 0; i < NumDmasPerGroup; i++) begin : gen_axi_slv_vec
+ assign axi_slv_req[i*(NumTilesPerDma+1)+:NumTilesPerDma+1] = {axi_dma_req[i],axi_tile_req[i*NumTilesPerDma+:NumTilesPerDma]};
+ assign {axi_dma_resp[i],axi_tile_resp[i*NumTilesPerDma+:NumTilesPerDma]} = axi_slv_resp[i*(NumTilesPerDma+1)+:NumTilesPerDma+1];
+ end : gen_axi_slv_vec
axi_hier_interco #(
.NumSlvPorts (NumTilesPerGroup+NumDmasPerGroup),
@@ -400,8 +407,8 @@ module mempool_group
.rst_ni (rst_ni ),
.test_i (1'b0 ),
.ro_cache_ctrl_i (ro_cache_ctrl_q),
- .slv_req_i ({axi_dma_req,axi_tile_req} ),
- .slv_resp_o ({axi_dma_resp,axi_tile_resp}),
+ .slv_req_i (axi_slv_req ),
+ .slv_resp_o (axi_slv_resp ),
.mst_req_o (axi_mst_req ),
.mst_resp_i (axi_mst_resp )
);
|
out_loki: enable processing multiple tasks in loki output plugin.
The Loki output plugin previously disabled processing mulitple tasks per
flush because Loki historically did not support out-of-order writes.
However this behavior had a deleterious effect on throughput. | @@ -1658,5 +1658,5 @@ struct flb_output_plugin out_loki_plugin = {
/* for testing */
.test_formatter.callback = cb_loki_format_test,
- .flags = FLB_OUTPUT_NET | FLB_IO_OPT_TLS | FLB_OUTPUT_NO_MULTIPLEX,
+ .flags = FLB_OUTPUT_NET | FLB_IO_OPT_TLS,
};
|
Run attestation sample only if DCAP libraries exist | @@ -62,12 +62,12 @@ else ()
# they can run even if they weren't built against SGX, because in
# that cause they directly interface with the AESM service.
if (BUILD_ENCLAVES)
- list(APPEND SAMPLES_LIST data-sealing attestation)
+ list(APPEND SAMPLES_LIST data-sealing)
# These tests can only run with SGX-FLC, meaning they were built
# against SGX.
if (HAS_QUOTE_PROVIDER)
- list(APPEND SAMPLES_LIST attested_tls)
+ list(APPEND SAMPLES_LIST attested_tls attestation)
endif ()
endif ()
endif ()
|
docs/license: Add myself to copyright holders. | @@ -3,7 +3,7 @@ MicroPython license information
The MIT License (MIT)
-Copyright (c) 2013-2017 Damien P. George, and others
+Copyright (c) 2013-2019 Damien P. George, Paul Sokolovsky, and others
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
|
Ocean data: remove entries from grib2 tables v24 | 11 11 Cumulonimbus (CB) base (m)
12 12 Cumulonimbus (CB) top (m)
13 13 Lowest level where vertically integrated cloud cover exceeds the specified percentage (cloud base for a given percentage cloud cover) (%)
-14 14 Level of free convection (LFC) (-)
-15 15 Convective condensation level (CCL) (-)
-16 16 Level of neutral buoyancy or equilibrium level (LNB) (-)
+14 14 Level of free convection (LFC)
+15 15 Convective condensation level (CCL)
+16 16 Level of neutral buoyancy or equilibrium level (LNB)
# 17-19 Reserved
20 20 Isothermal level (K)
21 21 Lowest level where mass density exceeds the specified value (base for a given threshold of mass density) (kg m-3)
23 23 Lowest level where air concentration exceeds the specified value (base for a given threshold of air concentration) (Bq m-3)
24 24 Highest level where air concentration exceeds the specified value (top for a given threshold of air concentration) (Bq m-3)
25 25 Highest level where radar reflectivity exceeds the specified value (echo top for a given threshold of reflectivity) (dBZ)
-# 26-29 Reserved
-30 30 Specified radius from the center of the Sun (m)
-31 31 Solar photosphere
-32 32 Ionospheric D-region level
-33 33 Ionospheric E-region level
-34 34 Ionospheric F1-region level
-35 35 Ionospheric F2-region level
-# 36-99 Reserved
+# 26-99 Reserved
100 pl Isobaric surface (Pa)
101 sfc Mean sea level
102 102 Specific altitude above mean sea level (m)
# 120-149 Reserved
150 150 Generalized vertical height coordinate
151 sol Soil level (Numeric)
-152 sol Sea ice level (Numeric)
-# 153-159 Reserved
+# 152-159 Reserved
160 o2d Depth below sea level (m)
161 161 Depth below water surface (m)
162 sfc Lake or river bottom (-)
|
GraphContent: reduce margin on headings | @@ -239,7 +239,7 @@ const header = ({ children, depth, ...rest }) => {
<H4 display='block'>{children}</H4>
);
return (
- <Box {...rest} mt="2" mb="4">
+ <Box {...rest}>
{inner}
</Box>
);
|
License: Fix GitHub license detection again | # BSD 3-Clause License
-Copyright (c) 2017, [Elektra Initiative](/doc/AUTHORS.md)
- Some rights reserved.
-
+Copyright (c) 2017 [Elektra Initiative](/doc/AUTHORS.md), All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
|
[DeviceDriver] Change the special device commands form 0x1X to 0x2X. It will avoid same of general device commands. | @@ -966,13 +966,13 @@ enum rt_device_class_type
/**
* special device commands
*/
-#define RT_DEVICE_CTRL_CHAR_STREAM 0x10 /**< stream mode on char device */
-#define RT_DEVICE_CTRL_BLK_GETGEOME 0x10 /**< get geometry information */
-#define RT_DEVICE_CTRL_BLK_SYNC 0x11 /**< flush data to block device */
-#define RT_DEVICE_CTRL_BLK_ERASE 0x12 /**< erase block on block device */
-#define RT_DEVICE_CTRL_BLK_AUTOREFRESH 0x13 /**< block device : enter/exit auto refresh mode */
-#define RT_DEVICE_CTRL_NETIF_GETMAC 0x10 /**< get mac address */
-#define RT_DEVICE_CTRL_MTD_FORMAT 0x10 /**< format a MTD device */
+#define RT_DEVICE_CTRL_CHAR_STREAM 0x20 /**< stream mode on char device */
+#define RT_DEVICE_CTRL_BLK_GETGEOME 0x20 /**< get geometry information */
+#define RT_DEVICE_CTRL_BLK_SYNC 0x21 /**< flush data to block device */
+#define RT_DEVICE_CTRL_BLK_ERASE 0x22 /**< erase block on block device */
+#define RT_DEVICE_CTRL_BLK_AUTOREFRESH 0x23 /**< block device : enter/exit auto refresh mode */
+#define RT_DEVICE_CTRL_NETIF_GETMAC 0x20 /**< get mac address */
+#define RT_DEVICE_CTRL_MTD_FORMAT 0x20 /**< format a MTD device */
typedef struct rt_device *rt_device_t;
|
Fix read multiple attributes from Window Covering Cluster | @@ -120,7 +120,6 @@ void DeRestPluginPrivate::handleWindowCoveringClusterIndication(const deCONZ::Ap
{
while(!stream.atEnd())
{
-
stream >> attrid;
if (isReadAttr)
{
@@ -137,15 +136,18 @@ void DeRestPluginPrivate::handleWindowCoveringClusterIndication(const deCONZ::Ap
{
stream >> attrValue;
}
+ // only read 16-bit values, i.e. attrTypeId 0x21,0x31,0x09,0x19,0x29
+ else if ( ((attrTypeId >> 4) <= 0x03 && (attrTypeId & 0x0F) == 0x01) || // 0x21,0x31
+ ((attrTypeId >> 4) <= 0x02 && (attrTypeId & 0x0F) == 0x09)) // 0x09,0x19,0x29
+ {
+ quint16 attrVal16;
+ stream >> attrVal16;
+ }
else
{
return;
}
-
- break;
- }
-
NodeValue::UpdateType updateType = NodeValue::UpdateByZclReport;
if (attrid == 0x0008) // current CurrentPositionLiftPercentage 0-100
@@ -206,7 +208,7 @@ void DeRestPluginPrivate::handleWindowCoveringClusterIndication(const deCONZ::Ap
Sensor *sensor = getSensorNodeForAddressAndEndpoint(ind.srcAddress(), 0x02);
if (sensor)
{
- ResourceItem *item = 0;
+ ResourceItem *item = nullptr;
item = sensor->item(RConfigWindowCoveringType);
if (item)
@@ -217,6 +219,7 @@ void DeRestPluginPrivate::handleWindowCoveringClusterIndication(const deCONZ::Ap
}
}
}
+ }
if (updated)
{
|
test: remove png file output | #include <stdlib.h>
#include <LCUI_Build.h>
#include <LCUI/LCUI.h>
-#include <LCUI/image.h>
#include <LCUI/gui/widget.h>
#include <LCUI/gui/widget/textview.h>
#include <LCUI/gui/css_parser.h>
@@ -18,18 +17,6 @@ static struct {
LCUI_Widget text;
} self;
-#ifdef LCUI_BUILD_IN_WIN32
-static void LoggerHandler(const char *str)
-{
- OutputDebugStringA(str);
-}
-
-static void LoggerHandlerW(const wchar_t *str)
-{
- OutputDebugStringW(str);
-}
-#endif
-
static void build(void)
{
LCUI_Widget pack, root;
@@ -124,7 +111,6 @@ static int check_widget_opactiy(void)
CHECK_WITH_TEXT("check child 2 footer background color",
check_color(expected_color, color));
- LCUI_WritePNGFile("test_widget_opacity.png", &canvas);
Graph_Free(&canvas);
return ret;
}
@@ -175,10 +161,6 @@ int main(void)
{
LCUI_Widget btn_plus, btn_minus;
-#ifdef LCUI_BUILD_IN_WIN32
- Logger_SetHandler(LoggerHandler);
- Logger_SetHandlerW(LoggerHandlerW);
-#endif
LCUI_Init();
build();
|
build: prepare vioscsi for ARM64 build | <Configuration>Win10 Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
+ <ProjectConfiguration Include="Win10 Release|ARM64">
+ <Configuration>Win10 Release</Configuration>
+ <Platform>ARM64</Platform>
+ </ProjectConfiguration>
<ProjectConfiguration Include="Win8.1 Release|x64">
<Configuration>Win8.1 Release</Configuration>
<Platform>x64</Platform>
<TargetVersion>Windows10</TargetVersion>
<PlatformToolset>WindowsKernelModeDriver10.0</PlatformToolset>
</PropertyGroup>
+ <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Win10 Release|ARM64'">
+ <TargetVersion>Windows10</TargetVersion>
+ <PlatformToolset>WindowsKernelModeDriver10.0</PlatformToolset>
+ </PropertyGroup>
<PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Win8.1 Release|x64'">
<TargetVersion>WindowsV6.3</TargetVersion>
<PlatformToolset>WindowsKernelModeDriver10.0</PlatformToolset>
<OutDir>objfre_win10_amd64\amd64\</OutDir>
<IntDir>objfre_win10_amd64\amd64\</IntDir>
</PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Win10 Release|ARM64'">
+ <OutDir>objfre_win10_arm64\arm64\</OutDir>
+ <IntDir>objfre_win10_arm64\arm64\</IntDir>
+ </PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Win8.1 Release|x64'">
<OutDir>objfre_win8_amd64\amd64\</OutDir>
<IntDir>objfre_win8_amd64\amd64\</IntDir>
<WppGenerateUsingTemplateFile Condition="'$(Configuration)|$(Platform)'=='Win10 Release|x64'">{km-StorDefault.tpl}*.tmh</WppGenerateUsingTemplateFile>
<WppScanConfigurationData Condition="'$(Configuration)|$(Platform)'=='Win10 Release|x64'">trace.h</WppScanConfigurationData>
</ClCompile>
+ <ClCompile>
+ <WppEnabled Condition="'$(Configuration)|$(Platform)'=='Win10 Release|ARM64'">true</WppEnabled>
+ <WppGenerateUsingTemplateFile Condition="'$(Configuration)|$(Platform)'=='Win10 Release|ARM64'">{km-StorDefault.tpl}*.tmh</WppGenerateUsingTemplateFile>
+ <WppScanConfigurationData Condition="'$(Configuration)|$(Platform)'=='Win10 Release|ARM64'">trace.h</WppScanConfigurationData>
+ </ClCompile>
<ClCompile>
<WppEnabled Condition="'$(Configuration)|$(Platform)'=='Win7 Release|x64'">true</WppEnabled>
<WppGenerateUsingTemplateFile Condition="'$(Configuration)|$(Platform)'=='Win7 Release|x64'">{km-StorDefault.tpl}*.tmh</WppGenerateUsingTemplateFile>
|
Docs: Use badges instead of emojis in the support table of the README
Closes | @@ -6,15 +6,18 @@ ESP-IDF is the development framework for Espressif SoCs supported on Windows, Li
# ESP-IDF Release and SoC Compatibility
-The following table shows ESP-IDF support of Espressif SoCs where :yellow_circle: and :green_circle: denote preview status and support, respectively. In preview status the build is not yet enabled and some crucial parts could be missing (like documentation, datasheet). Please use an ESP-IDF release where the desired SoC is already supported.
+The following table shows ESP-IDF support of Espressif SoCs where ![alt text][preview] and ![alt text][supported] denote preview status and support, respectively. In preview status the build is not yet enabled and some crucial parts could be missing (like documentation, datasheet). Please use an ESP-IDF release where the desired SoC is already supported.
|Chip | v3.3 | v4.0 | v4.1 | v4.2 | v4.3 | v4.4 | |
-|:----------- |:-------------: | :-------------:| :-------------:| :-------------:| :-------------:| :-------------:|:---------------------------------------------------------- |
-|ESP32 | :green_circle: | :green_circle: | :green_circle: | :green_circle: | :green_circle: | :green_circle: | |
-|ESP32-S2 | | | | :green_circle: | :green_circle: | :green_circle: | |
-|ESP32-C3 | | | | | :green_circle: | :green_circle: | |
-|ESP32-S3 | | | | | :yellow_circle:| :green_circle: | [Announcement](https://www.espressif.com/en/news/ESP32_S3) |
-|ESP32-H2 | | | | | | :yellow_circle:| [Announcement](https://www.espressif.com/en/news/ESP32_H2) |
+|:----------- |:---------------------: | :---------------------:| :---------------------:| :---------------------:| :---------------------:| :---------------------:|:---------------------------------------------------------- |
+|ESP32 | ![alt text][supported] | ![alt text][supported] | ![alt text][supported] | ![alt text][supported] | ![alt text][supported] | ![alt text][supported] | |
+|ESP32-S2 | | | | ![alt text][supported] | ![alt text][supported] | ![alt text][supported] | |
+|ESP32-C3 | | | | | ![alt text][supported] | ![alt text][supported] | |
+|ESP32-S3 | | | | | ![alt text][preview] | ![alt text][supported] | [Announcement](https://www.espressif.com/en/news/ESP32_S3) |
+|ESP32-H2 | | | | | | ![alt text][preview] | [Announcement](https://www.espressif.com/en/news/ESP32_H2) |
+
+[supported]: https://img.shields.io/badge/-supported-green "supported"
+[preview]: https://img.shields.io/badge/-preview-orange "preview"
Espressif SoCs released before 2016 (ESP8266 and ESP8285) are supported by [RTOS SDK](https://github.com/espressif/ESP8266_RTOS_SDK) instead.
|
multifile: pass config to child backends | @@ -62,6 +62,7 @@ typedef struct
GetPhases getPhase;
KeySet * modules;
KeySet * childBackends;
+ KeySet * childConfig;
char * resolver;
char * storage;
unsigned short stayAlive;
@@ -204,6 +205,7 @@ int elektraMultifileClose (Plugin * handle ELEKTRA_UNUSED, Key * errorKey ELEKTR
elektraModulesClose (mc->modules, NULL);
ksDel (mc->modules);
ksDel (mc->childBackends);
+ ksDel (mc->childConfig);
elektraFree (mc);
elektraPluginSetData (handle, NULL);
return 1; // success
@@ -253,7 +255,12 @@ static MultiConfig * initialize (Plugin * handle, Key * parentKey)
}
if (stayAliveKey) mc->stayAlive = 1;
if (recursiveKey) mc->recursive = 1;
-
+ Key * cutKey = keyNew ("/child", KEY_END);
+ KeySet * childConfig = ksCut (config, cutKey);
+ keyDel (cutKey);
+ mc->childConfig = elektraRenameKeys (childConfig, "system");
+ ksAppend (config, childConfig);
+ ksDel (childConfig);
mc->childBackends = ksNew (0, KS_END);
mc->modules = ksNew (0, KS_END);
elektraModulesInit (mc->modules, NULL);
@@ -274,8 +281,9 @@ static Codes initBackend (MultiConfig * mc, SingleConfig * s, Key * parentKey)
s->parentString = childParentString;
// fprintf (stderr, "Added file %s:(%s)\n\tChildParentKey: %s\n", s->fullPath, s->filename, s->parentString);
Plugin * resolver = NULL;
- resolver = elektraPluginOpen (mc->resolver, mc->modules, ksNew (1, keyNew ("system/path", KEY_VALUE, s->fullPath, KEY_END), KS_END),
- parentKey);
+ KeySet * childConfig = ksDup (mc->childConfig);
+ ksAppendKey (childConfig, keyNew ("/path", KEY_VALUE, s->fullPath, KEY_END));
+ resolver = elektraPluginOpen (mc->resolver, mc->modules, childConfig, parentKey);
// fprintf (stderr, "%s:(%s)\n", keyName (parentKey), keyString (parentKey));
if (!resolver)
{
|
pbio/drivebase: implement Stop.HOLD
This is equivalent to driving 0 mm. | @@ -111,7 +111,7 @@ static pbio_error_t pbio_drivebase_actuate(pbio_drivebase_t *db, pbio_actuation_
// Hold is not yet implemented
if (sum_actuation == PBIO_ACTUATION_HOLD || dif_actuation == PBIO_ACTUATION_HOLD) {
- return PBIO_ERROR_NOT_IMPLEMENTED;
+ return pbio_drivebase_straight(db, 0, db->control_distance.settings.max_rate, db->control_distance.settings.max_rate);
}
// Brake is the same as duty, so just actuate
|
removed "!" from snap_helloworld help | @@ -80,7 +80,7 @@ static void usage(const char *prog)
"echo clean possible temporary old files \n"
"rm /tmp/t2; rm /tmp/t3\n"
"echo Prepare the text to process\n"
- "echo \"Hello world. This is my first CAPI SNAP experience. It's real fun!\""
+ "echo \"Hello world. This is my first CAPI SNAP experience. It's real fun\""
" > /tmp/t1\n"
"\n"
"echo Run the application + hardware action on FPGA\n"
@@ -102,7 +102,7 @@ static void usage(const char *prog)
"echo clean possible temporary old files \n"
"rm /tmp/t2; rm /tmp/t3\n"
"echo Prepare the text to process\n"
- "echo \"Hello world. This is my first CAPI SNAP experience. It's real fun!\""
+ "echo \"Hello world. This is my first CAPI SNAP experience. It's real fun\""
" > /tmp/t1\n"
"\n"
"echo Run the application + hardware action on the FPGA emulated on CPU\n"
|
[numerics] fix bug in NM_extract_diag_block5 | @@ -1756,13 +1756,14 @@ void NM_extract_diag_block5(NumericsMatrix* M, int block_row_nb, double ** Block
}
case NM_SPARSE_BLOCK:
{
+ assert(0); /* this has to be checked carefully */
int diagPos = SBM_diagonal_block_index(M->matrix1, block_row_nb);
(*Block) = M->matrix1->block[diagPos];
break;
}
case NM_SPARSE:
{
- size_t start_row = (size_t)block_row_nb + block_row_nb + block_row_nb;
+ size_t start_row = (size_t)5*block_row_nb;
NSM_extract_block(M, *Block, start_row, start_row, 5, 5);
break;
}
|
Fix 'show interface span' field length
Allow to display longer interface names, e.g. VirtualEthernet0/0/0.102
The field length (32) is now the same as for 'show interface'. | @@ -206,7 +206,7 @@ show_interfaces_span_command_fn (vlib_main_t * vm,
clib_bitmap_t *b = clib_bitmap_dup_or (d, l);
if (header)
{
- vlib_cli_output (vm, "%-20s %-20s %6s %6s", "Source", "Destination",
+ vlib_cli_output (vm, "%-32s %-32s %6s %6s", "Source", "Destination",
"Device", "L2");
header = 0;
}
@@ -219,7 +219,7 @@ show_interfaces_span_command_fn (vlib_main_t * vm,
int l2 = (clib_bitmap_get (lrxm->mirror_ports, i) +
clib_bitmap_get (ltxm->mirror_ports, i) * 2);
- vlib_cli_output (vm, "%-20v %-20U (%6s) (%6s)", s,
+ vlib_cli_output (vm, "%-32v %-32U (%6s) (%6s)", s,
format_vnet_sw_if_index_name, vnm, i,
states[device], states[l2]);
vec_reset_length (s);
|
SOVERSION bump to version 2.20.18 | @@ -66,7 +66,7 @@ set(LIBYANG_VERSION ${LIBYANG_MAJOR_VERSION}.${LIBYANG_MINOR_VERSION}.${LIBYANG_
# set version of the library
set(LIBYANG_MAJOR_SOVERSION 2)
set(LIBYANG_MINOR_SOVERSION 20)
-set(LIBYANG_MICRO_SOVERSION 17)
+set(LIBYANG_MICRO_SOVERSION 18)
set(LIBYANG_SOVERSION_FULL ${LIBYANG_MAJOR_SOVERSION}.${LIBYANG_MINOR_SOVERSION}.${LIBYANG_MICRO_SOVERSION})
set(LIBYANG_SOVERSION ${LIBYANG_MAJOR_SOVERSION})
|
remove only use of /_ with an aura | :::: /hoon/comments/tree/ren
::
/? 310
-/: /%/comments /_ @da
+/: /%/comments
+ /; |= a/(map knot {ship marl})
+ =- (sort - dor)
+ %+ turn (~(tap by a))
+ |=({b/knot c/{ship marl}} [(slav %da b) c])
+ /_
/; |= a/manx ^- {ship marl}
~| a
?> ?=(_[/div ;/(~) ~[[%h2 **] ~[[%code **] ;/(who=**)]] kid=**] a)
- => .(a ^+([/div ;/(~) ~[[%h2 **] ~[[%code **] ;/(who=*tape)]] kid=*marl] a))
+ %. a
+ |: a=[/div ;/(~) ~[[%h2 **] ~[[%code **] ;/(who=*tape)]] kid=*marl]
[(slav %p (crip who.a)) kid.a]
/&elem&/md/
::
|
[CUDA] Fix CL_MEM_ALLOC_HOST_PTR | @@ -270,10 +270,11 @@ pocl_cuda_alloc_mem_obj(cl_device_id device, cl_mem mem_obj, void *host_ptr)
}
else if (flags & CL_MEM_ALLOC_HOST_PTR)
{
- void *ptr;
- result = cuMemHostAlloc(&ptr, mem_obj->size, CU_MEMHOSTREGISTER_DEVICEMAP);
+ result = cuMemHostAlloc(&mem_obj->mem_host_ptr, mem_obj->size,
+ CU_MEMHOSTREGISTER_DEVICEMAP);
CUDA_CHECK(result, "cuMemHostAlloc");
- result = cuMemHostGetDevicePointer((CUdeviceptr*)&b, ptr, 0);
+ result = cuMemHostGetDevicePointer((CUdeviceptr*)&b,
+ mem_obj->mem_host_ptr, 0);
CUDA_CHECK(result, "cuMemHostGetDevicePointer");
}
else
|
update the logger for ADD_ADDRESS frames | @@ -934,6 +934,61 @@ size_t picoquic_log_crypto_hs_frame(FILE* F, uint8_t* bytes, size_t bytes_max)
return byte_index;
}
+size_t picoquic_log_add_address_frame(FILE* F, uint8_t* bytes, size_t bytes_max)
+{
+ size_t byte_index = 1;
+
+ uint8_t has_port = 0;
+ uint8_t ip_vers;
+ uint8_t addr_id;
+
+ uint8_t flags_and_ip_ver = bytes[byte_index++];
+ has_port = (flags_and_ip_ver & 0x10);
+ ip_vers = (flags_and_ip_ver & 0x0f);
+ addr_id = bytes[byte_index++];
+
+ char hostname[256];
+ const char* x;
+
+ struct sockaddr_in sa;
+ struct sockaddr_in6 sa6;
+
+ if (ip_vers == 4) {
+ memcpy(&sa.sin_addr.s_addr, &bytes[byte_index], 4);
+ byte_index += 4;
+ if (has_port) {
+ memcpy(&sa.sin_port, &bytes[byte_index], 2);
+ byte_index += 2;
+ }
+ x = inet_ntop(AF_INET, &sa.sin_addr, hostname, sizeof(hostname));
+
+ } else if (ip_vers == 6) {
+ memcpy(&sa6.sin6_addr, &bytes[byte_index], 16);
+ byte_index += 16;
+ if (has_port) {
+ memcpy(&sa6.sin6_port, &bytes[byte_index], 2);
+ byte_index += 2;
+ }
+ x = inet_ntop(AF_INET6, &sa6.sin6_addr, hostname, sizeof(hostname));
+
+ } else {
+ fprintf(F, " Malformed ADD ADDRESS, unknown IP version %d\n", (int)ip_vers);
+ return bytes_max;
+ }
+
+ fprintf(F, " ADD ADDRESS with ID 0x");
+ fprintf(F, "%02x", addr_id);
+ fprintf(F, " Address: ");
+ fprintf(F, "%s", x);
+ if (has_port) {
+ fprintf(F, " Port: ");
+ fprintf(F, "%d", (ip_vers == 4) ? sa.sin_port : sa6.sin6_port);
+ }
+ fprintf(F, "\n");
+
+ return byte_index;
+}
+
size_t picoquic_log_mp_new_connection_id_frame(FILE* F, uint8_t* bytes, size_t bytes_max)
{
size_t byte_index = 1;
@@ -1090,6 +1145,10 @@ void picoquic_log_frames(FILE* F, uint64_t cnx_id64, uint8_t* bytes, size_t leng
byte_index += picoquic_log_new_token_frame(F, bytes + byte_index,
length - byte_index);
break;
+ case 0x22: /* ADD_ADDRESS */
+ byte_index += picoquic_log_add_address_frame(F, bytes + byte_index,
+ length - byte_index);
+ break;
case 0x26: /* MP_NEW_CONNECTION_ID */
byte_index += picoquic_log_mp_new_connection_id_frame(F, bytes + byte_index,
length - byte_index);
|
board/anahera/board.c: Format with clang-format
BRANCH=none
TEST=none | @@ -73,7 +73,6 @@ __override void board_set_charge_limit(int port, int supplier, int charge_ma,
* to account for the charger chip margin.
*/
charge_ma = charge_ma * 95 / 100;
- charge_set_input_current_limit(MAX(charge_ma,
- CONFIG_CHARGER_INPUT_CURRENT),
- charge_mv);
+ charge_set_input_current_limit(
+ MAX(charge_ma, CONFIG_CHARGER_INPUT_CURRENT), charge_mv);
}
|
Additional catching-up | @@ -66,9 +66,11 @@ Furthermore some information of SIXEL-ready SDL applications are reported.
### X11 on SIXEL terminals
-[XSIXEL](https://github.com/saitoha/xserver-sixel) is a kdrive server implementation for SIXEL terminals.
+[Xsixel](https://github.com/saitoha/xserver-sixel) is a kdrive server implementation for SIXEL terminals.
- 
+ 
+
+ 
### W3M integration
|
Clean more (git-ignored) generated files | @@ -89,9 +89,9 @@ explicit_index.cram: ex1.cram
cp ex1.cram $@
clean:
- rm -fr *.bam *.bai *.fai *.pileup* *.cram \
+ rm -fr *.bam *.bai *.csi *.fai *.gzi *.pileup* *.cram *.crai \
*~ calDepth *.dSYM pysam_*.sam \
- ex2.sam ex2.sam.gz ex1.sam \
+ ex2.sam ex2.sam.gz ex1.sam ex1.fa.gz \
with_md.sam.gz \
*.fq.gz
|
Add EIP1559 to changelog | @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).
+## [1.8.9](https://github.com/ledgerhq/app-ethereum/compare/1.8.8...1.8.0) - 2021-8-03
+
+### Added
+
+- Added support for EIP-1559 and EIP-2930 style transactions.
+
## [1.8.8](https://github.com/ledgerhq/app-ethereum/compare/1.8.7...1.8.8) - 2021-7-21
### Added
|
Corrected Sengled PAR38 Bulbs consumption unit | @@ -7112,8 +7112,8 @@ void DeRestPluginPrivate::updateSensorNode(const deCONZ::NodeEvent &event)
if (i->modelId() == QLatin1String("SmartPlug") || // Heiman
i->modelId().startsWith(QLatin1String("PSMP5_")) || // Climax
- i->modelId().startsWith(QLatin1String("SKHMP30"))) // GS smart plug
- // Sengled PAR38 Bulbs
+ i->modelId().startsWith(QLatin1String("SKHMP30")) || // GS smart plug
+ i->modelId().startsWith(QLatin1String("E13-"))) // Sengled PAR38 Bulbs
{
consumption += 5; consumption /= 10; // 0.1 Wh -> Wh
}
@@ -7126,10 +7126,6 @@ void DeRestPluginPrivate::updateSensorNode(const deCONZ::NodeEvent &event)
{
consumption /= 1000;
}
- else if (i->modelId().startsWith(QLatin1String("E13-"))) // Sengled PAR38 Bulbs
- {
- consumption /= 10000;
- }
if (item)
{
|
common/mock/usb_pe_sm_mock.c: Format with clang-format
BRANCH=none
TEST=none | struct mock_pe_port_t mock_pe_port[CONFIG_USB_PD_PORT_MAX_COUNT];
-
/**
* Resets all mock PE ports to initial values
*/
@@ -108,7 +107,8 @@ void pd_set_src_caps(int port, int cnt, uint32_t *src_caps)
}
void pd_request_power_swap(int port)
-{}
+{
+}
int pd_get_rev(int port, enum tcpci_msg_type type)
{
|
Travis: Install Cheetah template engine | @@ -16,7 +16,8 @@ matrix:
osx_image: xcode6.4
before_install:
- - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
+ - |
+ if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
rvm list;
rvm install 2.3.1;
rvm use 2.3.1;
@@ -35,6 +36,7 @@ before_install:
brew install openssl botan libgcrypt;
brew install libgit2;
brew install xerces-c;
+ pip install cheetah; # Required by kdb-gen
export Qt5_DIR=/usr/local/opt/qt5;
brew config;
fi
|
options/posix: Make extract_entry set pw_gecos. | @@ -15,7 +15,7 @@ namespace {
__ensure(!entry->pw_dir);
__ensure(!entry->pw_shell);
- frg::string_view segments[7];
+ frg::string_view segments[8];
// Parse the line into exactly 6 segments.
size_t s = 0;
@@ -48,12 +48,15 @@ namespace {
__ensure(dir);
auto shell = strndup(segments[6].data(), segments[6].size());
__ensure(shell);
+ auto real_name = strndup(segments[7].data(), segments[7].size());
+ __ensure(real_name);
entry->pw_name = name;
entry->pw_uid = *uid;
entry->pw_gid = *gid;
entry->pw_dir = dir;
entry->pw_shell = shell;
+ entry->pw_gecos = real_name;
return true;
}
|
fix build of last merge commit | @@ -1845,7 +1845,7 @@ bool DeRestPluginPrivate::checkSensorBindingsForAttributeReporting(Sensor *senso
// Aurora
sensor->modelId().startsWith(QLatin1String("DoubleSocket50AU")) ||
// Bosch
- sensor->modelId().startsWith(QLatin1String("ISW-ZPR1-WP13")))
+ sensor->modelId().startsWith(QLatin1String("ISW-ZPR1-WP13")) ||
// Aqara Opple
sensor->modelId().contains(QLatin1String("86opcn01")))
{
|
INI: fix ordering with multifile resolver | @@ -678,6 +678,15 @@ static void setParents (KeySet * ks, Key * parentKey)
}
static void stripInternalData (Key * parentKey, KeySet *);
+static void incOrder (Key * key)
+{
+ Key * orderKey = keyNew ("/", KEY_CASCADING_NAME, KEY_END);
+ keyAddName (orderKey, keyString (keyGetMeta (key, "internal/ini/order")));
+ elektraArrayIncName (orderKey);
+ keySetMeta (key, "internal/ini/order", keyBaseName (orderKey));
+ keyDel (orderKey);
+}
+
int elektraIniGet (Plugin * handle, KeySet * returned, Key * parentKey)
{
@@ -763,6 +772,7 @@ int elektraIniGet (Plugin * handle, KeySet * returned, Key * parentKey)
}
ksDel (cbHandle.result);
if (pluginConfig->lastOrder) elektraFree (pluginConfig->lastOrder);
+ incOrder (parentKey);
pluginConfig->lastOrder = strdup (keyString (keyGetMeta (parentKey, "internal/ini/order")));
elektraPluginSetData (handle, pluginConfig);
return ret; /* success */
@@ -1501,9 +1511,18 @@ int elektraIniSet (Plugin * handle, KeySet * returned, Key * parentKey)
Key * head = keyDup (ksHead (returned));
IniPluginConfig * pluginConfig = elektraPluginGetData (handle);
if (pluginConfig->lastOrder && !keyGetMeta (parentKey, "internal/ini/order"))
+ {
keySetMeta (parentKey, "internal/ini/order", pluginConfig->lastOrder);
+ incOrder (parentKey);
+ }
else if (!keyGetMeta (parentKey, "internal/ini/order"))
+ {
keySetMeta (parentKey, "internal/ini/order", "#1");
+ }
+ else
+ {
+ incOrder (parentKey);
+ }
Key * cur;
KeySet * newKS = ksNew (0, KS_END);
ksRewind (returned);
|
KDB Info: Remove empty if-statement | @@ -27,17 +27,15 @@ InfoCommand::InfoCommand ()
int InfoCommand::execute (Cmdline const & cl)
{
std::string subkey;
- if (cl.arguments.size () == 1)
+ if (cl.arguments.size () < 1 || cl.arguments.size () > 2)
{
+ throw invalid_argument ("Need 1 or 2 argument(s)");
}
- else if (cl.arguments.size () == 2)
+
+ if (cl.arguments.size () == 2)
{
subkey = cl.arguments[1];
}
- else
- {
- throw invalid_argument ("Need at 1 or 2 argument(s)");
- }
std::string name = cl.arguments[0];
KeySet conf;
|
Fix dragging treelist column divider Fix regression from commit | @@ -5519,8 +5519,8 @@ VOID PhTnpDrawCell(
if (Column == Context->FirstColumn)
{
- BOOLEAN needsClip;
- HRGN oldClipRegion;
+ BOOLEAN needsClip = FALSE;
+ HRGN oldClipRegion = NULL;
textRect.left += Node->Level * SmallIconWidth;
@@ -5631,9 +5631,11 @@ VOID PhTnpDrawCell(
textRect.left += SmallIconWidth + TNP_ICON_RIGHT_PADDING;
}
- if (needsClip && oldClipRegion)
+ if (needsClip)
{
SelectClipRgn(hdc, oldClipRegion);
+
+ if (oldClipRegion)
DeleteRgn(oldClipRegion);
}
|
Allow yaml to realloc buffer for rest get operations to avoid truncated output... | @@ -132,8 +132,7 @@ rest_dt_get(
return merr(ev(ENOENT));
pathsz = strlen(path) + 2;
- bufsz = 1048576 + pathsz;
- bufsz = ALIGN(bufsz, 1048576 * 2);
+ bufsz = ALIGN(pathsz, 4ul << 20);
buf = malloc(bufsz);
if (!buf)
@@ -142,15 +141,15 @@ rest_dt_get(
sprintf(buf, "/%s", path);
yc.yaml_indent = 0;
- yc.yaml_offset = 0;
- yc.yaml_emit = NULL;
- yc.yaml_buf_sz = bufsz - ALIGN(pathsz, 8);
- yc.yaml_buf = buf + ALIGN(pathsz, 8);
+ yc.yaml_offset = pathsz;
+ yc.yaml_emit = yaml_realloc_buf;
+ yc.yaml_buf_sz = bufsz;
+ yc.yaml_buf = buf;
if (dt_iterate_cmd(tree, DT_OP_EMIT, buf, &dip, 0, fld, val) > 0)
- rest_write_safe(info->resp_fd, yc.yaml_buf, yc.yaml_offset);
+ rest_write_safe(info->resp_fd, yc.yaml_buf + pathsz, yc.yaml_offset - pathsz);
- free(buf);
+ free(yc.yaml_buf);
return 0;
}
|
Fix MSVC Debug build with internal zlib
zlib sets CMAKE_DEBUG_POSTFIX to "d" with msvc in debug | @@ -220,12 +220,19 @@ if(OPENEXR_FORCE_INTERNAL_ZLIB OR NOT TARGET ZLIB::ZLIB)
set(zlibstaticlibname "z")
endif()
+ if(MSVC)
+ set(zlibpostfix "d")
+ endif()
+
if(NOT (APPLE OR WIN32) AND BUILD_SHARED_LIBS AND NOT OPENEXR_FORCE_INTERNAL_ZLIB)
add_library(zlib_shared SHARED IMPORTED GLOBAL)
add_dependencies(zlib_shared zlib_external)
set_property(TARGET zlib_shared PROPERTY
IMPORTED_LOCATION "${zlib_INTERNAL_DIR}/lib/${CMAKE_SHARED_LIBRARY_PREFIX}${zliblibname}${CMAKE_SHARED_LIBRARY_SUFFIX}"
)
+ set_property(TARGET zlib_static PROPERTY
+ IMPORTED_LOCATION_DEBUG "${zlib_INTERNAL_DIR}/lib/${CMAKE_SHARED_LIBRARY_PREFIX}${zliblibname}${zlibpostfix}${CMAKE_SHARED_LIBRARY_SUFFIX}"
+ )
target_include_directories(zlib_shared INTERFACE "${zlib_INTERNAL_DIR}/include")
endif()
@@ -234,6 +241,9 @@ if(OPENEXR_FORCE_INTERNAL_ZLIB OR NOT TARGET ZLIB::ZLIB)
set_property(TARGET zlib_static PROPERTY
IMPORTED_LOCATION "${zlib_INTERNAL_DIR}/lib/${CMAKE_STATIC_LIBRARY_PREFIX}${zlibstaticlibname}${CMAKE_STATIC_LIBRARY_SUFFIX}"
)
+ set_property(TARGET zlib_static PROPERTY
+ IMPORTED_LOCATION_DEBUG "${zlib_INTERNAL_DIR}/lib/${CMAKE_STATIC_LIBRARY_PREFIX}${zlibstaticlibname}${zlibpostfix}${CMAKE_STATIC_LIBRARY_SUFFIX}"
+ )
target_include_directories(zlib_static INTERFACE "${zlib_INTERNAL_DIR}/include")
if(NOT (APPLE OR WIN32) AND BUILD_SHARED_LIBS AND NOT OPENEXR_FORCE_INTERNAL_ZLIB)
|
consistent permissions | @@ -85,7 +85,7 @@ cd %{dname}
%{__mkdir} -p $RPM_BUILD_ROOT/%{_docdir}
-install -m 644 %{SOURCE3} $RPM_BUILD_ROOT/%{_libexecdir}/warewulf/*
+install -m 755 %{SOURCE3} $RPM_BUILD_ROOT/%{_libexecdir}/warewulf/*
%clean
rm -rf $RPM_BUILD_ROOT
|
metadata: further fixes | @@ -1151,38 +1151,38 @@ description = "Who should see this configuration setting?
#
[uid]
-status= currently obsolete
+status= deprecated
type= time
usedby/api= keyNew kdbextension.h
description= The owner of the key.
[gid]
-status= currently obsolete
+status= deprecated
type= time
usedby/api= keyNew kdbextension.h
description= The group of the key.
[mode]
-status= currently obsolete
+status= deprecated
type= int
usedby/api= keyNew kdbextension.h
description= The access mode of the key.
[atime]
type= time
-status= currently obsolete
+status= deprecated
usedby/api= keyNew kdbextension.h
description= The time when the key was last accessed.
[mtime]
type= time
-status= currently obsolete
+status= deprecated
usedby/api= keyNew kdbextension.h
description= The time when the value of a key were last modified.
[ctime]
type= time
-status= currently obsolete
+status= deprecated
usedby/api= keyNew kdbextension.h
description= The time when the metadata of a key were last modified.
@@ -1249,7 +1249,7 @@ description= used to mark a key that contained a binary value before encryption.
status= implemented
usedby/plugins= xerces
type= string
-description= "used to store the name of the xml file's original root element when mounting to a mount point which name doesn't correspond to the xml root element.
+description= "Used to store the name of the xml file's original root element when mounting to a mount point which name doesn't correspond to the xml root element.
This metadata will be stored in the mount point key. When writing or exporting again, the stored name will be used for the root element of the corresponding xml document."
[unit/base]
@@ -1263,7 +1263,7 @@ description = "used to specify the base of an integer value. Currently only the
status = implemented
type = string
usedby/plugins = type boolean
-description = "used by plugins that normalize and restore key values for storing the original key value. Plugins should ALWAYS use this metakey. This key will be cleared on keySetString,
+description = "Used by plugins that normalize and restore key values for storing the original key value. Plugins should ALWAYS use this metakey. This key will be cleared on keySetString,
so if it is present, the key is unchanged and should be restored. Plugins should NEVER overwrite or remove this metakey, if it is present, because this may break other plugins. If a
plugins needs to normalize a value, but 'origvalue' is already set, an error should be produced, because to plugins cannot be responsible for normalizing the same keys."
@@ -1271,21 +1271,21 @@ description = "used by plugins that normalize and restore key values for storing
status = implemented
type = string
usedby/plugins = type
-description = "overrides the allowed true value for this key. Only the given value or 1 will be allowed as true. All true keys will be restored to this value in `kdbSet`.
+description = "Overrides the allowed true value for this key. Only the given value or 1 will be allowed as true. All true keys will be restored to this value in `kdbSet`.
Must be used together with check/boolean/false."
[check/boolean/false]
status = implemented
type = string
usedby/plugins = type
-description = "overrides the allowed false value for this key. Only the given value or 0 will be allowed as false. All false keys will be restored to this value in `kdbSet`.
+description = "Overrides the allowed false value for this key. Only the given value or 0 will be allowed as false. All false keys will be restored to this value in `kdbSet`.
Must be used together with check/boolean/true."
[cache/clear]
status = implemented
usedby/plugins = cache
type = boolean
-description = tells the cache plugin to remove all cache files during the next `kdbGet` in a safe way.
+description = Tells the cache plugin to remove all cache files during the next `kdbGet` in a safe way.
[tomltype]
status = implemented
|
dm/VBS-U: implement read/write callbacks of device-specific cfg
This patch implements the read/write callbacks for the registers in the
device-specific region. This region is implemented in the modern MMIO
bar.
Acked-by: Eddie Dong | @@ -1267,15 +1267,62 @@ virtio_isr_cfg_read(struct pci_vdev *dev, uint64_t offset, int size)
static uint32_t
virtio_device_cfg_read(struct pci_vdev *dev, uint64_t offset, int size)
{
- /* TODO: to be implemented */
- return 0;
+ struct virtio_base *base = dev->arg;
+ struct virtio_ops *vops;
+ const char *name;
+ uint32_t value;
+ uint64_t max;
+ int error;
+
+ vops = base->vops;
+ name = vops->name;
+ value = size == 1 ? 0xff : size == 2 ? 0xffff : 0xffffffff;
+ max = vops->cfgsize ? vops->cfgsize : 0x100000000;
+
+ if (offset + size > max) {
+ fprintf(stderr,
+ "%s: reading from 0x%lx size %d exceeds limit\r\n",
+ name, offset, size);
+ return value;
+ }
+
+ error = (*vops->cfgread)(DEV_STRUCT(base), offset, size, &value);
+ if (error) {
+ fprintf(stderr,
+ "%s: reading from 0x%lx size %d failed %d\r\n",
+ name, offset, size, error);
+ value = size == 1 ? 0xff : size == 2 ? 0xffff : 0xffffffff;
+ }
+
+ return value;
}
static void
virtio_device_cfg_write(struct pci_vdev *dev, uint64_t offset, int size,
uint64_t value)
{
- /* TODO: to be implemented */
+ struct virtio_base *base = dev->arg;
+ struct virtio_ops *vops;
+ const char *name;
+ uint64_t max;
+ int error;
+
+ vops = base->vops;
+ name = vops->name;
+ max = vops->cfgsize ? vops->cfgsize : 0x100000000;
+
+ if (offset + size > max) {
+ fprintf(stderr,
+ "%s: writing to 0x%lx size %d exceeds limit\r\n",
+ name, offset, size);
+ return;
+ }
+
+ error = (*vops->cfgwrite)(DEV_STRUCT(base), offset, size, value);
+ if (error)
+ fprintf(stderr,
+ "%s: writing ot 0x%lx size %d failed %d\r\n",
+ name, offset, size, error);
}
/*
|
[AT] Adjust where the AT socket callback function | @@ -404,6 +404,9 @@ static struct at_socket *alloc_socket(void)
return alloc_socket_by_device(device);
}
+static void at_recv_notice_cb(struct at_socket *sock, at_socket_evt_t event, const char *buff, size_t bfsz);
+static void at_closed_notice_cb(struct at_socket *sock, at_socket_evt_t event, const char *buff, size_t bfsz);
+
int at_socket(int domain, int type, int protocol)
{
struct at_socket *sock = RT_NULL;
@@ -438,6 +441,10 @@ int at_socket(int domain, int type, int protocol)
sock->type = socket_type;
sock->state = AT_SOCKET_OPEN;
+ /* set AT socket receive data callback function */
+ sock->ops->at_set_event_cb(AT_SOCKET_EVT_RECV, at_recv_notice_cb);
+ sock->ops->at_set_event_cb(AT_SOCKET_EVT_CLOSED, at_closed_notice_cb);
+
return sock->socket;
}
@@ -703,10 +710,6 @@ int at_connect(int socket, const struct sockaddr *name, socklen_t namelen)
sock->state = AT_SOCKET_CONNECT;
- /* set AT socket receive data callback function */
- sock->ops->at_set_event_cb(AT_SOCKET_EVT_RECV, at_recv_notice_cb);
- sock->ops->at_set_event_cb(AT_SOCKET_EVT_CLOSED, at_closed_notice_cb);
-
__exit:
if (result < 0)
@@ -760,9 +763,6 @@ int at_recvfrom(int socket, void *mem, size_t len, int flags, struct sockaddr *f
goto __exit;
}
sock->state = AT_SOCKET_CONNECT;
- /* set AT socket receive data callback function */
- sock->ops->at_set_event_cb(AT_SOCKET_EVT_RECV, at_recv_notice_cb);
- sock->ops->at_set_event_cb(AT_SOCKET_EVT_CLOSED, at_closed_notice_cb);
}
/* receive packet list last transmission of remaining data */
@@ -924,9 +924,6 @@ int at_sendto(int socket, const void *data, size_t size, int flags, const struct
goto __exit;
}
sock->state = AT_SOCKET_CONNECT;
- /* set AT socket receive data callback function */
- sock->ops->at_set_event_cb(AT_SOCKET_EVT_RECV, at_recv_notice_cb);
- sock->ops->at_set_event_cb(AT_SOCKET_EVT_CLOSED, at_closed_notice_cb);
}
if ((len = sock->ops->at_send(sock, (char *) data, size, sock->type)) < 0)
|
Make 'tools/wakeuptime' use an offcpu filter
This modifies 'tools/wakeuptime' to include a filter
in offcpu() for capturing data only for a given pid
or for user threads only. | @@ -101,8 +101,13 @@ BPF_STACK_TRACE(stack_traces, STACK_STORAGE_SIZE)
int offcpu(struct pt_regs *ctx) {
u32 pid = bpf_get_current_pid_tgid();
- u64 ts = bpf_ktime_get_ns();
- // XXX: should filter here too, but need task_struct
+ struct task_struct *p = (struct task_struct *) bpf_get_current_task();
+ u64 ts;
+
+ if (FILTER)
+ return 0;
+
+ ts = bpf_ktime_get_ns();
start.update(&pid, &ts);
return 0;
}
|
zephyr/shim/src/usb_muxes.c: Format with clang-format
BRANCH=none
TEST=none | * },
* [1] = { ... },
*/
-MAYBE_CONST struct usb_mux usb_muxes[] = {
- USB_MUX_FOREACH_USBC_PORT(USB_MUX_FIRST, USB_MUX_ARRAY)
-};
+MAYBE_CONST struct usb_mux usb_muxes[] = { USB_MUX_FOREACH_USBC_PORT(
+ USB_MUX_FIRST, USB_MUX_ARRAY) };
/**
* Define all USB muxes except roots e.g.
@@ -66,8 +65,7 @@ USB_MUX_FOREACH_USBC_PORT(USB_MUX_NO_FIRST, USB_MUX_DEFINE)
* change in runtime
*/
#define BB_CONTROLS_CONST \
- COND_CODE_1( \
- CONFIG_PLATFORM_EC_USBC_RETIMER_INTEL_BB_RUNTIME_CONFIG,\
+ COND_CODE_1(CONFIG_PLATFORM_EC_USBC_RETIMER_INTEL_BB_RUNTIME_CONFIG, \
(), (const))
/**
|
define the version earlier and used it for other defs | @@ -20,13 +20,13 @@ function bv_tbb_depends_on
function bv_tbb_info
{
+ export TBB_VERSION=${TBB_VERSION:-"tbb2018_20171205oss"}
if [[ "$OPSYS" == "Darwin" ]] ; then
- export TBB_FILE=${TBB_FILE:-"tbb2018_20171205oss_mac.tgz"}
+ export TBB_FILE=${TBB_FILE:-"${TBB_VERSION}_mac.tgz"}
else
- export TBB_FILE=${TBB_FILE:-"tbb2018_20171205oss_lin.tgz"}
+ export TBB_FILE=${TBB_FILE:-"${TBB_VERSION}_lin.tgz"}
fi
- export TBB_VERSION=${TBB_VERSION:-"tbb2018_20171205oss"}
- export TBB_COMPATIBILITY_VERSION=${TBB_COMPATIBILITY_VERSION:-"tbb2018_20171205oss"}
+ export TBB_COMPATIBILITY_VERSION=${TBB_COMPATIBILITY_VERSION:-"${TBB_VERSION}"}
export TBB_BUILD_DIR=${TBB_BUILD_DIR:-"${TBB_VERSION}"}
export TBB_MD5_CHECKSUM=""
export TBB_SHA256_CHECKSUM=""
|
stats: fix crash due to pointer taken before validate
Type: fix | @@ -12,12 +12,14 @@ static void
vector_rate_collector_fn (vlib_stats_collector_data_t *d)
{
vlib_main_t *this_vlib_main;
- counter_t **counters = d->entry->data;
- counter_t *cb = counters[0];
+ counter_t **counters;
+ counter_t *cb;
f64 vector_rate = 0.0;
u32 i, n_threads = vlib_get_n_threads ();
vlib_stats_validate (d->entry_index, 0, n_threads - 1);
+ counters = d->entry->data;
+ cb = counters[0];
for (i = 0; i < n_threads; i++)
{
|
Added rounding to reorder related arguements to avoid interger related errors | @@ -102,18 +102,18 @@ static void construct_mask(
long reorder_dims[DIMS], complex float* reorder,
long mask_dims[DIMS], complex float* mask)
{
- int n = reorder_dims[0];
- int sy = mask_dims[1];
- int sz = mask_dims[2];
+ long n = reorder_dims[0];
+ long sy = mask_dims[1];
+ long sz = mask_dims[2];
- int y = -1;
- int z = -1;
- int t = -1;
+ long y = 0;
+ long z = 0;
+ long t = 0;
for (int i = 0; i < n; i++) {
- y = reorder[i];
- z = reorder[i + n];
- t = reorder[i + 2 * n];
+ y = lround(creal(reorder[i]));
+ z = lround(creal(reorder[i + n]));
+ t = lround(creal(reorder[i + 2 * n]));
mask[(y + z * sy) + t * sy * sz] = 1;
}
}
@@ -190,9 +190,9 @@ static void kern_apply(const linop_data_t* _data, complex float* dst, const comp
for (int i = 0; i < n; i ++) {
- y = data->reorder[i];
- z = data->reorder[i + n];
- t = data->reorder[i + 2 * n];
+ y = lround(creal(data->reorder[i]));
+ z = lround(creal(data->reorder[i + n]));
+ t = lround(creal(data->reorder[i + 2 * n]));
md_clear(4, vec_dims, vec, CFL_SIZE);
md_zfmac2(4, fmac_dims, vec_str, vec, phi_in_str, (perm + ((wx * nc * tk) * (y + z * sy))), phi_mat_str, data->phi);
@@ -250,8 +250,8 @@ static void kern_adjoint(const linop_data_t* _data, complex float* dst, const co
md_clear(4, vec_dims, vec, CFL_SIZE);
for (int i = 0; i < n; i ++) {
- if ((y == data->reorder[i]) && (z == data->reorder[i + n])) {
- t = data->reorder[i + 2 * n];
+ if ((y == lround(creal(data->reorder[i]))) && (z == lround(creal(data->reorder[i + n])))) {
+ t = lround(creal(data->reorder[i + 2 * n]));
md_copy(4, line_dims, (vec + t * wx * nc), (src + i * wx * nc), CFL_SIZE);
}
}
@@ -536,8 +536,8 @@ static void fftmod_apply(long sy, long sz,
long n = reorder_dims[0];
for (long k = 0; k < n; k++) {
- y = reorder[k];
- z = reorder[k + n];
+ y = lround(creal(reorder[k]));
+ z = lround(creal(reorder[k + n]));
py = cexp(2.i * M_PI * dy * y);
pz = cexp(2.i * M_PI * dz * z);
|
workflow: limit 'release' event to 'created' action | @@ -39,7 +39,7 @@ jobs:
run: |
./build-source.sh
./build.sh build package release
- - if: github.event_name == 'release'
+ - if: github.event_name == 'release' && github.event.action == 'created'
name: Upload release
run: |
assets=()
|
pycopy/tests/types_str_subclassequality: Format with "black". | @@ -4,8 +4,11 @@ description: Instance of a subclass of str cannot be compared for equality with
cause: Unknown
workaround: Unknown
"""
+
+
class S(str):
pass
-s = S('hello')
-print(s == 'hello')
+
+s = S("hello")
+print(s == "hello")
|
Fix parallelism preventing matrix initialization. Remove incorrect call to mark_parallel_sccs | @@ -987,6 +987,9 @@ Graph* build_fusion_conflict_graph(PlutoProg *prog, int *colour, int num_nodes,
if (options->fuse == TYPED_FUSE) {
par_preventing_adj_mat = pluto_matrix_alloc (num_nodes, num_nodes);
+ for(i=0; i<num_nodes; i++) {
+ bzero(par_preventing_adj_mat->val[i], num_nodes*sizeof(int64));
+ }
}
boundcst = get_coeff_bounding_constraints(prog);
@@ -1031,7 +1034,7 @@ Graph* build_fusion_conflict_graph(PlutoProg *prog, int *colour, int num_nodes,
/* Add inter statement fusion and permute preventing edges. */
- if (options->fuse == TYPED_FUSE) {
+ if (options->fuse == TYPED_FUSE && !options->scc_cluster) {
/* The lp solutions are found and the parallel sccs are marked.
* However marking is only used in parallel case of typed fuse only */
mark_parallel_sccs(colour, prog);
|
BugID:22249433:fix "yts@asr5501 test=certificate,rhino,basic,vfs,kv,cjson,aos PV compile error" | #define RHINO_CONFIG_QUEUE 1
#endif
#ifndef RHINO_CONFIG_TASK_SEM
-#define RHINO_CONFIG_TASK_SEM 0
+#define RHINO_CONFIG_TASK_SEM 1
#endif
#ifndef RHINO_CONFIG_EVENT_FLAG
-#define RHINO_CONFIG_EVENT_FLAG 0
+#define RHINO_CONFIG_EVENT_FLAG 1
#endif
#ifndef RHINO_CONFIG_TIMER
#define RHINO_CONFIG_TIMER 1
|
Add --rebuild flag | @@ -44,6 +44,7 @@ musl_targets = [
VERBOSE = False
RETEST = False
+REBUILD = False
def run(cmd):
subprocess.run(cmd, shell=True, check=True, capture_output=not VERBOSE)
@@ -71,7 +72,7 @@ def build_wasi(target):
wasm3_binary = f"build-cross/wasm3-{target['name']}.wasm"
- if not Path(wasm3_binary).exists():
+ if REBUILD or not Path(wasm3_binary).exists():
build_dir = f"build-cross/{target['name']}/"
print(f"Building {target['name']} target")
run(f"""
@@ -104,7 +105,7 @@ def build_musl(target):
wasm3_binary = f"build-cross/wasm3-{target['name']}"
- if not Path(wasm3_binary).exists():
+ if REBUILD or not Path(wasm3_binary).exists():
build_dir = f"build-cross/{target['name']}/"
print(f"Building {target['name']} target")
run(f"""
@@ -161,6 +162,7 @@ if __name__ == '__main__':
parser.add_argument('-j','--jobs', type=int, metavar='N', default=multiprocessing.cpu_count(), help='parallel builds')
parser.add_argument('-v','--verbose', action='store_true', help='verbose output')
parser.add_argument('--retest', action='store_true', help='force tests')
+ parser.add_argument('--rebuild', action='store_true', help='force builds')
parser.add_argument('--target', metavar='NAME')
args = parser.parse_args()
@@ -169,6 +171,7 @@ if __name__ == '__main__':
VERBOSE = args.verbose
RETEST = args.retest
+ REBUILD = args.rebuild
if args.jobs <= 1:
for t in musl_targets:
|
COPYING: Fixed typos | @@ -242,7 +242,7 @@ Copyright: 1996-2001, 2003-2011 Free Software Foundation, Inc.
License: GPL-2+
Files: utils/cups-browsed*
- org.cups.cupsd.Notifier.xml
+ utils/org.cups.cupsd.Notifier.xml
Copyright: 2012-2019 Till Kamppeter
2013-2015 Tim Waugh
2018-2019 Deepak Patankar
@@ -368,7 +368,7 @@ License: LGPL-2
under the terms of the GNU Library General Public License as published by the
Free Software Foundation; version 2 of the License.
.
- On Debian systems, the complete text of version 2 of the GNU Library
+ On Debian systems, the complete text of version 2 of the GNU Library General
Public License can be found in `/usr/share/common-licenses/LGPL-2'.
License: LGPL-2.1+
@@ -377,7 +377,7 @@ License: LGPL-2.1+
Free Software Foundation; version 2.1 of the License, or (at
your option) any later version.
.
- On Debian systems, the complete text of version 2.1 of the GNU Lesser
+ On Debian systems, the complete text of version 2.1 of the GNU Lesser General
Public License can be found in `/usr/share/common-licenses/LGPL-2.1'.
License: BSD-4-clause
|
slot allocation logging | @@ -334,8 +334,8 @@ void dump_type_stack (IM3Compilation o)
i32 regAllocated [2] = { (i32) IsRegisterAllocated (o, 0), (i32) IsRegisterAllocated (o, 1) };
// display whether r0 or fp0 is allocated. these should then also be reflected somewhere in the stack too.
+ d_m3Log(stack, "\n");
d_m3Log(stack, " ");
- printf (" ");
printf ("%s %s ", regAllocated [0] ? "(r0)" : " ", regAllocated [1] ? "(fp0)" : " ");
// printf ("%d", o->stackIndex -)
@@ -373,6 +373,33 @@ void dump_type_stack (IM3Compilation o)
for (u32 r = 0; r < 2; ++r)
d_m3Assert (regAllocated [r] == 0); // reg allocation & stack out of sync
+
+ u16 maxSlot = GetMaxUsedSlotPlusOne (o);
+
+ if (maxSlot > o->slotFirstDynamicIndex)
+ {
+ d_m3Log (stack, " -");
+
+ for (u16 i = o->slotFirstDynamicIndex; i < maxSlot; ++i)
+ printf ("----");
+
+ printf ("\n");
+
+ d_m3Log (stack, " slot |");
+ for (u16 i = o->slotFirstDynamicIndex; i < maxSlot; ++i)
+ printf ("%3d|", i);
+
+ printf ("\n");
+ d_m3Log (stack, " alloc |");
+
+ for (u16 i = o->slotFirstDynamicIndex; i < maxSlot; ++i)
+ {
+ printf ("%3d|", o->m3Slots [i]);
+ }
+
+ printf ("\n");
+ }
+ d_m3Log(stack, "\n");
}
|
OcMachoLib: Verify exact LC size when the exact type is known. | @@ -452,7 +452,7 @@ MachoGetNextSegment64 (
);
if ((NextSegment == NULL)
|| !OC_ALIGNED (NextSegment)
- || (NextSegment->CommandSize < sizeof (*NextSegment))) {
+ || (NextSegment->CommandSize != sizeof (*NextSegment))) {
return NULL;
}
@@ -632,7 +632,7 @@ InternalRetrieveSymtabs64 (
);
if ((Symtab == NULL)
|| !OC_ALIGNED (Symtab)
- || (Symtab->CommandSize < sizeof (*Symtab))) {
+ || (Symtab->CommandSize != sizeof (*Symtab))) {
return FALSE;
}
@@ -669,7 +669,7 @@ InternalRetrieveSymtabs64 (
);
if ((DySymtab == NULL)
|| !OC_ALIGNED (DySymtab)
- || (DySymtab->CommandSize < sizeof (*DySymtab))) {
+ || (DySymtab->CommandSize != sizeof (*DySymtab))) {
return FALSE;
}
|
Remove buffer_size maximum from ssl_server2.c | @@ -451,7 +451,7 @@ int main( void )
" server_port=%%d default: 4433\n" \
" debug_level=%%d default: 0 (disabled)\n" \
" buffer_size=%%d default: 200 \n" \
- " (minimum: 1, max: 16385)\n" \
+ " (minimum: 1)\n" \
" response_size=%%d default: about 152 (basic response)\n" \
" (minimum: 0, max: 16384)\n" \
" increases buffer_size if bigger\n"\
@@ -1572,9 +1572,7 @@ int main( int argc, char *argv[] )
else if( strcmp( p, "buffer_size" ) == 0 )
{
opt.buffer_size = atoi( q );
- if( opt.buffer_size < 1 ||
- ( opt.buffer_size > MBEDTLS_SSL_IN_CONTENT_LEN + 1
- && opt.buffer_size > MBEDTLS_SSL_OUT_CONTENT_LEN + 1 ) )
+ if( opt.buffer_size < 1 )
goto usage;
}
else if( strcmp( p, "response_size" ) == 0 )
|
TTASIM clEnqueueCopyBuffer offset correction | @@ -848,8 +848,8 @@ pocl_tce_copy_rect (void *data,
chunk_info_t *src_chunk = (chunk_info_t*)src_mem_id->mem_ptr;
chunk_info_t *dst_chunk = (chunk_info_t*)dst_mem_id->mem_ptr;
- size_t src_offset = src_origin[0] + src_row_pitch * (src_origin[1] + src_slice_pitch * src_origin[2]);
- size_t dst_offset = dst_origin[0] + dst_row_pitch * (dst_origin[1] + dst_slice_pitch * dst_origin[2]);
+ size_t src_offset = src_origin[0] + src_row_pitch * src_origin[1] + src_slice_pitch * src_origin[2];
+ size_t dst_offset = dst_origin[0] + dst_row_pitch * dst_origin[1] + dst_slice_pitch * dst_origin[2];
size_t j, k;
|
king: First stab at removing terminfo dependency. | @@ -3,12 +3,6 @@ version: 0.10.1
license: MIT
license-file: LICENSE
-flags:
- Release:
- description: "Produce statically-linked executables"
- default: false
- manual: true
-
library:
source-dirs: lib
ghc-options:
@@ -94,7 +88,6 @@ dependencies:
- template-haskell
- terminal-progress-bar
- terminal-size
- - terminfo
- text
- these
- time
@@ -166,12 +159,6 @@ executables:
source-dirs: app
dependencies:
- urbit-king
- when:
- - condition: flag(Release)
- then:
- cc-options: -static
- ld-options: -static -pthread
- else: {}
ghc-options:
- -threaded
- -rtsopts
|
pyopenmv.py Add reset to bootloader. | @@ -33,6 +33,7 @@ __USBDBG_DESCRIPTOR_SAVE= 0x09
__USBDBG_ATTR_READ = 0x8A
__USBDBG_ATTR_WRITE = 0x0B
__USBDBG_SYS_RESET = 0x0C
+__USBDBG_SYS_RESET_TO_BL= 0x0E
__USBDBG_FB_ENABLE = 0x0D
__USBDBG_TX_BUF_LEN = 0x8E
__USBDBG_TX_BUF = 0x8F
@@ -138,6 +139,9 @@ def get_attr(attr):
def reset():
__serial.write(struct.pack("<BBI", __USBDBG_CMD, __USBDBG_SYS_RESET, 0))
+def reset_to_bl():
+ __serial.write(struct.pack("<BBI", __USBDBG_CMD, __USBDBG_SYS_RESET_TO_BL, 0))
+
def bootloader_start():
__serial.write(struct.pack("<I", __BOOTLDR_START))
return struct.unpack("I", __serial.read(4))[0] == __BOOTLDR_START
|
PMW3901, PAA5100: Construct correct class for secret sauce. | #include "libraries/breakout_pmw3901/breakout_pmw3901.hpp"
+#include "libraries/breakout_paa5100/breakout_paa5100.hpp"
#define MP_OBJ_TO_PTR2(o, t) ((t *)(uintptr_t)(o))
@@ -82,7 +83,21 @@ mp_obj_t make_new(enum ChipType chip, const mp_obj_type_t *type, size_t n_args,
self = m_new_obj_with_finaliser(breakout_pmw3901_BreakoutPMW3901_obj_t);
self->base.type = &breakout_pmw3901_BreakoutPMW3901_type;
- self->breakout = new BreakoutPMW3901((BG_SPI_SLOT)slot);
+ if(chip == ChipType::PMW3901) {
+ BreakoutPMW3901 *breakout = new BreakoutPMW3901((BG_SPI_SLOT)slot);
+ if (!breakout->init()) {
+ delete breakout;
+ mp_raise_msg(&mp_type_RuntimeError, "BreakoutPMW3901: Init failed");
+ }
+ self->breakout = breakout;
+ } else {
+ BreakoutPAA5100 *breakout = new BreakoutPAA5100((BG_SPI_SLOT)slot);
+ if (!breakout->init()) {
+ delete breakout;
+ mp_raise_msg(&mp_type_RuntimeError, "BreakoutPAA5100: Init failed");
+ }
+ self->breakout = breakout;
+ }
}
else {
mp_raise_ValueError("slot not a valid value. Expected 0 to 1");
@@ -132,11 +147,24 @@ mp_obj_t make_new(enum ChipType chip, const mp_obj_type_t *type, size_t n_args,
self->base.type = &breakout_pmw3901_BreakoutPMW3901_type;
spi_inst_t *spi = (spi_id == 0) ? spi0 : spi1;
- self->breakout = new BreakoutPMW3901(spi, args[ARG_cs].u_int, sck, mosi, miso, args[ARG_interrupt].u_int);
+ if(chip == ChipType::PMW3901) {
+ BreakoutPMW3901 *breakout = new BreakoutPMW3901(spi, args[ARG_cs].u_int, sck, mosi, miso, args[ARG_interrupt].u_int);
+ if (!breakout->init()) {
+ delete breakout;
+ mp_raise_msg(&mp_type_RuntimeError, "BreakoutPMW3901: Init failed");
+ }
+ self->breakout = breakout;
+ } else {
+ BreakoutPAA5100 *breakout = new BreakoutPAA5100(spi, args[ARG_cs].u_int, sck, mosi, miso, args[ARG_interrupt].u_int);
+ if (!breakout->init()) {
+ delete breakout;
+ mp_raise_msg(&mp_type_RuntimeError, "BreakoutPAA5100: Init failed");
+ }
+ self->breakout = breakout;
+ }
}
self->chip = chip;
- self->breakout->init();
return MP_OBJ_FROM_PTR(self);
}
|
Add '{b=} option to print integers.
It outputs in base b <= 36. | @@ -481,11 +481,13 @@ const intparams = {params
]
opts = parseparams(params, [
+ ("b", true),
("x", false),
("w", true),
("p", true)][:])
for o : opts
match o
+ | ("b", bas): ip.base = getint(bas, "fmt: base must be integer")
| ("x", ""): ip.base = 16
| ("w", wid): ip.padto = getint(wid, "fmt: width must be integer")
| ("p", pad): ip.padfill = decode(pad)
|
Fix user name in simplified db config | @@ -31,7 +31,7 @@ public class DbRepoConfig {
private final static String dbNameAttribute = "Database name";
private final static String accessMethodAttribute = "JDBC column access method";
private final static String connectionStrAttribute = "Raw driver string";
- private final static String userAttribute = "User Name";
+ private final static String userAttribute = "User name";
private final static String passwordAttribute = "Password";
private final static String nameElement = "name";
private final static String repoConnectionsCommand = "repositoryconnections";
|
Add BSON_ITER_HOLDS_NUMBER() & BSON_ITER_HOLDS_INT() | @@ -87,6 +87,12 @@ BSON_BEGIN_DECLS
#define BSON_ITER_HOLDS_MINKEY(iter) \
(bson_iter_type ((iter)) == BSON_TYPE_MINKEY)
+#define BSON_ITER_HOLDS_INT(iter) \
+ (BSON_ITER_HOLDS_INT32 (iter) || BSON_ITER_HOLDS_INT64 (iter))
+
+#define BSON_ITER_HOLDS_NUMBER(iter) \
+ (BSON_ITER_HOLDS_INT (iter) || BSON_ITER_HOLDS_DOUBLE (iter))
+
#define BSON_ITER_IS_KEY(iter, key) \
(0 == strcmp ((key), bson_iter_key ((iter))))
@@ -196,7 +202,9 @@ BSON_EXPORT (bool)
bson_iter_init (bson_iter_t *iter, const bson_t *bson);
BSON_EXPORT (bool)
-bson_iter_init_from_data (bson_iter_t *iter, const uint8_t *data, size_t length);
+bson_iter_init_from_data (bson_iter_t *iter,
+ const uint8_t *data,
+ size_t length);
BSON_EXPORT (bool)
|
demmt: Fix compilation errors from removed nouveau params
NOUVEAU_GETPARAM_(FB|AGP|PCI)_PHYSICAL doesn't exist anymore in newer
versions of libdrm, so let's drop the references to this in order to fix
compilation. | @@ -240,11 +240,8 @@ static char *nouveau_param_names[] = {
_(NOUVEAU_GETPARAM_PCI_VENDOR),
_(NOUVEAU_GETPARAM_PCI_DEVICE),
_(NOUVEAU_GETPARAM_BUS_TYPE),
- _(NOUVEAU_GETPARAM_FB_PHYSICAL),
- _(NOUVEAU_GETPARAM_AGP_PHYSICAL),
_(NOUVEAU_GETPARAM_FB_SIZE),
_(NOUVEAU_GETPARAM_AGP_SIZE),
- _(NOUVEAU_GETPARAM_PCI_PHYSICAL),
_(NOUVEAU_GETPARAM_CHIPSET_ID),
_(NOUVEAU_GETPARAM_VM_VRAM_BASE),
_(NOUVEAU_GETPARAM_GRAPH_UNITS),
@@ -571,10 +568,7 @@ int demmt_drm_ioctl_post(uint32_t fd, uint32_t id, uint8_t dir, uint8_t nr, uint
switch (data->param)
{
case NOUVEAU_GETPARAM_FB_SIZE:
- case NOUVEAU_GETPARAM_FB_PHYSICAL:
case NOUVEAU_GETPARAM_AGP_SIZE:
- case NOUVEAU_GETPARAM_AGP_PHYSICAL:
- case NOUVEAU_GETPARAM_PCI_PHYSICAL:
mmt_log_cont(" (%f MB)", ((double)data->value) / (1 << 20));
if (data->value >> 30 > 0)
mmt_log_cont(" (%f GB)", ((double)data->value) / (1 << 30));
|
Add PhExpandEnvironmentStringsZ | @@ -689,6 +689,19 @@ PhExpandEnvironmentStrings(
_In_ PPH_STRINGREF String
);
+FORCEINLINE
+PPH_STRING
+PhExpandEnvironmentStringsZ(
+ _In_ PWSTR String
+ )
+{
+ PH_STRINGREF string;
+
+ PhInitializeStringRef(&string, String);
+
+ return PhExpandEnvironmentStrings(&string);
+}
+
PHLIBAPI
PPH_STRING
NTAPI
|
Fix fuzz test for s2n_asn1der_to_public_key_and_type name change | @@ -142,7 +142,9 @@ int LLVMFuzzerInitialize(const uint8_t *buf, size_t len)
server_config = s2n_config_new();
GUARD(s2n_config_add_cert_chain_and_key(server_config, certificate_chain, private_key));
- GUARD(s2n_asn1der_to_public_key(&public_key, &server_config->cert_and_key_pairs->cert_chain.head->raw));
+ s2n_cert_type cert_type;
+ GUARD(s2n_asn1der_to_public_key_and_type(&public_key, &cert_type, &server_config->cert_and_key_pairs->cert_chain.head->raw));
+
return 0;
}
|
Avoid division by 0
If the frame_size width or height is 0, just return the current size to
avoid calculations involving divison by 0. | @@ -88,6 +88,11 @@ static SDL_bool get_preferred_display_bounds(struct size *bounds) {
// - it keeps the aspect ratio
// - it scales down to make it fit in the display_size
static struct size get_optimal_size(struct size current_size, struct size frame_size) {
+ if (frame_size.width == 0 || frame_size.height == 0) {
+ // avoid division by 0
+ return current_size;
+ }
+
struct size display_size;
// 32 bits because we need to multiply two 16 bits values
Uint32 w;
|
[CLI] fix wrong error message. | @@ -112,7 +112,7 @@ func execNameUpdate(cmd *cobra.Command, args []string) error {
}
_, err = types.DecodeAddress(to)
if err != nil {
- return fmt.Errorf("Wrong address in --from flag: %v", err.Error())
+ return fmt.Errorf("Wrong address in --to flag: %v", err.Error())
}
amount, err := util.ParseUnit(spending)
if err != nil {
|
bricks/configport: Enable rmul.
This is used by the Color and Matrix types. | #define MICROPY_PY_COLLECTIONS (0)
#define MICROPY_PY_MATH (PYBRICKS_STM32_OPT_FLOAT)
#define MICROPY_PY_CMATH (0)
+#define MICROPY_PY_ALL_SPECIAL_METHODS (PYBRICKS_STM32_OPT_EXTRA_MOD)
+#define MICROPY_PY_REVERSE_SPECIAL_METHODS (PYBRICKS_STM32_OPT_EXTRA_MOD)
#define MICROPY_PY_IO (PYBRICKS_STM32_OPT_EXTRA_MOD)
#define MICROPY_PY_STRUCT (0)
#define MICROPY_PY_SYS (PYBRICKS_STM32_OPT_EXTRA_MOD)
|
Updated Servo2040 description | @@ -60,12 +60,9 @@ There is also a `Calibration` class for performing advanced tweaking of each ser
## Servo 2040
-Servo 2040 is a controller board for 3-pin hobby servos, with additional bells and whistles that make it ideal for many robotics projects! Key features include:
-* Drive up to 18 servos - enough for a hexapod walker!
-* 6 analog sensor headers - have your robot sense its environment
-* Current and voltage monitoring - be sure how your servos are performing
-* 6x RGB LEDs - show sensor states or current or voltage levels
-* Reverse polarity projection - protect all your servos
+Servo 2040 is a **standalone servo controller** for making things with lots of moving parts. It has pre-soldered pin headers for plugging in up to 18 servos, with additional bells and whistles like sensor headers, current monitoring, RGB LEDs, and a user button that make it ideal for many robotics projects!
+
+For more information on this board, check out the store page: [pimoroni.com/servo2040](https://pimoroni.com/servo2040).
### Reading the User Button
|
Support llvm-dsymutil -> dsymutil rename in LLVM 7. | @@ -1679,7 +1679,8 @@ class LD(Linker):
dwarf_tool = self.tc.dwarf_tool
if dwarf_tool is None and self.tc.is_clang and (self.target.is_macos or self.target.is_ios):
- dwarf_tool = '${YMAKE_PYTHON} ${input:"build/scripts/run_llvm_dsymutil.py"} %s/bin/llvm-dsymutil' % self.tc.name_marker
+ dsymutil = '{}/bin/{}dsymutil'.format(self.tc.name_marker, '' if self.tc.version_at_least(7) else 'llvm-')
+ dwarf_tool = '${YMAKE_PYTHON} ${input:"build/scripts/run_llvm_dsymutil.py"} ' + dsymutil
if self.tc.version_at_least(5, 0):
dwarf_tool += ' -flat'
|
qword: Added unlink | @@ -428,8 +428,18 @@ int sys_readlink(const char *path, void *buffer, size_t max_size, ssize_t *lengt
int sys_ftruncate(int fd, size_t size) STUB_ONLY
int sys_fallocate(int fd, off_t offset, size_t size) STUB_ONLY
int sys_unlink(const char *path) {
- mlibc::infoLogger() << "mlibc: " << __func__ << " is a stub!" << frg::endlog;
- return ENOSYS;
+ int ret;
+ int sys_errno;
+
+ asm volatile ("syscall"
+ : "=a"(ret), "=d"(sys_errno)
+ : "a"(34), "D"(path)
+ : "rcx", "r11");
+
+ if (ret == -1)
+ return sys_errno;
+
+ return 0;
}
int sys_symlink(const char *target_path, const char *link_path) STUB_ONLY
int sys_fcntl(int fd, int request, va_list args, int *result) {
|
Exclude network testcases that are not supported
removed tests : dup() api, ITC dup() api, ITC fcntl() | @@ -37,10 +37,7 @@ config TC_NET_ALL
select TC_NET_INET
select TC_NET_ETHER
select TC_NET_NETDB
- select TC_NET_DUP
select ITC_NET_CLOSE
- select ITC_NET_DUP
- select ITC_NET_FCNTL
select ITC_NET_LISTEN
select ITC_NET_SETSOCKOPT
select ITC_NET_SEND
@@ -132,22 +129,10 @@ config TC_NET_NETDB
bool "netdb() api"
default n
-config TC_NET_DUP
- bool "dup() api"
- default n
-
config ITC_NET_CLOSE
bool "ITC close() api"
default n
-config ITC_NET_DUP
- bool "ITC dup() api"
- default n
-
-config ITC_NET_FCNTL
- bool "ITC fcntl() api"
- default n
-
config ITC_NET_LISTEN
bool "ITC listen() api"
default n
|
Avoid breaking existing code due to changes in field names introduced in
The old names can still be used, but they are marked as deprecated and will raise a warning. | @@ -527,14 +527,41 @@ struct YR_RULES
// Array of pointers with an entry for each rule. The rule_idx field in the
// YR_STRING structure is an index within this array.
+ union
+ {
YR_RULE* rules_table;
+ // The previous name for rules_table was rules_list_head, because this
+ // was previously a linked list. The old name is maintained but marked as
+ // deprecated, which will raise a warning if used.
+ // TODO(vmalvarez): Remove this field when a reasonable a few versions
+ // after 4.1 has been released.
+ YR_RULE* rules_list_head YR_DEPRECATED_API;
+ };
// Array of pointers with an entry for each of the defined strings. The idx
// field in the YR_STRING structure is an index within this array.
+ union
+ {
YR_STRING* strings_table;
+ // The previous name for strings_table was strings_list_head, because this
+ // was previously a linked list. The old name is maintained but marked as
+ // deprecated, which will raise a warning if used.
+ // TODO(vmalvarez): Remove this field when a reasonable a few versions
+ // after 4.1 has been released.
+ YR_STRING* strings_list_head YR_DEPRECATED_API;
+ };
// Array of pointers with an entry for each external variable.
+ union
+ {
YR_EXTERNAL_VARIABLE* ext_vars_table;
+ // The previous name for ext_vars_table was externals_list_head, because
+ // this was previously a linked list. The old name is maintained but marked
+ // as deprecated, which will raise a warning if used.
+ // TODO(vmalvarez): Remove this field when a reasonable a few versions
+ // after 4.1 has been released.
+ YR_EXTERNAL_VARIABLE* externals_list_head YR_DEPRECATED_API;
+ };
// Pointer to the Aho-Corasick transition table.
YR_AC_TRANSITION* ac_transition_table;
|
Do not use return code for thread run function
The decoder sometimes returned a non-zero value on error, but not on
every path.
Since we never use the value, always return 0 at the end (like in the
controller). | @@ -40,37 +40,33 @@ static void notify_stopped(void) {
static int run_decoder(void *data) {
struct decoder *decoder = data;
- int ret = 0;
AVCodec *codec = avcodec_find_decoder(AV_CODEC_ID_H264);
if (!codec) {
LOGE("H.264 decoder not found");
- return -1;
+ goto run_end;
}
AVCodecContext *codec_ctx = avcodec_alloc_context3(codec);
if (!codec_ctx) {
LOGC("Could not allocate decoder context");
- return -1;
+ goto run_end;
}
if (avcodec_open2(codec_ctx, codec, NULL) < 0) {
LOGE("Could not open H.264 codec");
- ret = -1;
goto run_finally_free_codec_ctx;
}
AVFormatContext *format_ctx = avformat_alloc_context();
if (!format_ctx) {
LOGC("Could not allocate format context");
- ret = -1;
goto run_finally_close_codec;
}
unsigned char *buffer = av_malloc(BUFSIZE);
if (!buffer) {
LOGC("Could not allocate buffer");
- ret = -1;
goto run_finally_free_format_ctx;
}
@@ -80,7 +76,6 @@ static int run_decoder(void *data) {
// avformat_open_input takes ownership of 'buffer'
// so only free the buffer before avformat_open_input()
av_free(buffer);
- ret = -1;
goto run_finally_free_format_ctx;
}
@@ -88,7 +83,6 @@ static int run_decoder(void *data) {
if (avformat_open_input(&format_ctx, NULL, NULL, NULL) < 0) {
LOGE("Could not open video stream");
- ret = -1;
goto run_finally_free_avio_ctx;
}
@@ -142,7 +136,8 @@ run_finally_close_codec:
run_finally_free_codec_ctx:
avcodec_free_context(&codec_ctx);
notify_stopped();
- return ret;
+run_end:
+ return 0;
}
void decoder_init(struct decoder *decoder, struct frames *frames, socket_t video_socket) {
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.