message
stringlengths
6
474
diff
stringlengths
8
5.22k
no arg error and no outlet for sprintf (changed)
@@ -548,13 +548,8 @@ static void *sprintf_new(t_symbol *s, int ac, t_atom *av) p1 = p2 + 1; sprintf_parsepattern(x, &p1); } - loud_error((t_pd *)x, - "an object created without valid format patterns..."); - return (x); } -#ifdef SPRINTF_DEBUG - loudbug_post("%d slots:", nproxies); -#endif + /* CHECKED: max creates as many inlets, as there are %-signs, no matter if they are valid, or not -- if not, it prints ``can't convert'' errors for any input... */ @@ -586,13 +581,6 @@ static void *sprintf_new(t_symbol *s, int ac, t_atom *av) type = sprintf_parsepattern(x, &p1); if (type >= SPRINTF_MINSLOTTYPE) { -#ifdef SPRINTF_DEBUG - char tmp = *p1; - *p1 = 0; - loudbug_poststring(p2); - loudbug_endpost(); - *p1 = tmp; -#endif if (i < nslots) { char buf[SPRINTF_MAXWIDTH + 1]; /* LATER rethink */ @@ -614,9 +602,6 @@ static void *sprintf_new(t_symbol *s, int ac, t_atom *av) } } } -#ifdef SPRINTF_DEBUG - loudbug_post("printf(\"%s\", ...)", fstring); -#endif outlet_new((t_object *)x, &s_anything); return (x); }
acrn-config: add vbar[1] to SOS and pre-launched VM Add vbar base region 1 for SOS and pre-launched VM ivshmem
@@ -280,6 +280,12 @@ def generate_file(config): bar_0 = MmioWindow(start = int(bar_attr.addr, 16), end = int(bar_attr.addr, 16) + 0x100 - 1) mmiolist_per_vm[vm_id].append(bar_0) mmiolist_per_vm[vm_id].sort() + # vbar[1] for share memory is fix to 4K + free_bar = get_free_mmio([MmioWindow(start=common.SIZE_2G, end=common.SIZE_4G-1)], \ + mmiolist_per_vm[vm_id], 4 * common.SIZE_K) + mmiolist_per_vm[vm_id].append(free_bar) + mmiolist_per_vm[vm_id].sort() + print("{}.vbar_base[1] = {:#x}UL, \\".format(' ' * 54, free_bar.start), file=config) elif i_cnt == len(bar_attr_dic.keys()): print("{}.vbar_base[{}] = {}UL".format(' ' * 54, bar_i, bar_attr.addr), file=config) else: @@ -324,6 +330,12 @@ def generate_file(config): mmiolist_per_vm[vm_id].sort() print("#define SOS_IVSHMEM_DEVICE_%-19s" % (str(idx) + "_VBAR"), " .vbar_base[0] = {:#x}UL, \\".format(free_bar.start), file=config) + # vbar[1] for shared memory is 4K + free_bar = get_free_mmio(matching_mmios, mmiolist_per_vm[vm_id], 4 * common.SIZE_K) + mmiolist_per_vm[vm_id].append(free_bar) + mmiolist_per_vm[vm_id].sort() + print("{}.vbar_base[1] = {:#x}UL, \\".format(' ' * 54, free_bar.start), file=config) + # vbar[2] for shared memory is specified size in MB plus 0x200000 free_bar = get_free_mmio(matching_mmios, mmiolist_per_vm[vm_id], int_size + 0x200000) mmiolist_per_vm[vm_id].append(free_bar) mmiolist_per_vm[vm_id].sort()
[core] skip excess close() when FD_CLOEXEC defined do not run through close() loop after fork() and before execve() when FD_CLOEXEC is defined
@@ -742,7 +742,7 @@ pid_t fdevent_fork_execve(const char *name, char *argv[], char *envp[], int fdin } if (0 != fdevent_set_stdin_stdout_stderr(fdin, fdout, fderr)) _exit(errno); - #ifdef FD_CLOEXEC + #ifndef FD_CLOEXEC /*(might not be sufficient for open fds, but modern OS have FD_CLOEXEC)*/ for (int i = 3; i < 256; ++i) close(i); #endif
Use prtconf to determine CPU type on AIX for
@@ -127,6 +127,33 @@ int detect(void){ #endif #ifdef _AIX + FILE *infile; + char buffer[512], *p; + + p = (char *)NULL; + infile = popen("prtconf|grep 'Processor Type'"); + while (fgets(buffer, sizeof(buffer), infile)){ + if (!strncmp("Pro", buffer, 3)){ + p = strchr(buffer, ':') + 2; +#if 0 + fprintf(stderr, "%s\n", p); +#endif + break; + } + } + + pclose(infile); + + if (!strncasecmp(p, "POWER3", 6)) return CPUTYPE_POWER3; + if (!strncasecmp(p, "POWER4", 6)) return CPUTYPE_POWER4; + if (!strncasecmp(p, "PPC970", 6)) return CPUTYPE_PPC970; + if (!strncasecmp(p, "POWER5", 6)) return CPUTYPE_POWER5; + if (!strncasecmp(p, "POWER6", 6)) return CPUTYPE_POWER6; + if (!strncasecmp(p, "POWER7", 6)) return CPUTYPE_POWER6; + if (!strncasecmp(p, "POWER8", 6)) return CPUTYPE_POWER8; + if (!strncasecmp(p, "Cell", 4)) return CPUTYPE_CELL; + if (!strncasecmp(p, "7447", 4)) return CPUTYPE_PPCG4; + return CPUTYPE_POWER5; #endif
Fix typo in manpage SSL_CONF_cmd(3) Fixes
@@ -64,7 +64,7 @@ Allows servers to accept client-initiated renegotiation. Equivalent to setting B<SSL_OP_ALLOW_CLIENT_RENEGOTIATION>. Only used by servers. -=item B<-legacyrenegotiation> +=item B<-legacy_renegotiation> Permits the use of unsafe legacy renegotiation. Equivalent to setting B<SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION>.
update componen_list util for 1.3.3
@@ -30,7 +30,7 @@ my %ohpcCategoryHeadings = ('admin' => 'Administrative Tools', 'provisioning' => 'Provisioning Tools', 'rms' => 'Resource Management', 'runtimes' => 'Runtimes', - 'serial-libs' => 'Serial Libraries'); + 'serial-libs' => 'Serial / Threaded Libraries'); my @compiler_familes = ("gnu","gnu7","intel"); @@ -41,8 +41,11 @@ my @package_skip = ("ohpc-release","gnu-compilers","R_base","mvapich2-psm","open my %package_equiv = ("gnu7-compilers" => "Gnu Compiler Suite", "intel-compilers-devel" => "Intel Compiler Compatibility Package", "llvm4-compilers" => "LLVM Compiler Suite", + "llvm5-compilers" => "LLVM Compiler Suite", "intel-mpi-devel" => "Intel MPI Compatibility Package", "pbspro-server" => "PBSPro", + "openmpi3" => "openmpi", + "openmpi3-pmix-slurm" => "openmpi", "warewulf-common" => "warewulf", "ptscotch" => "scotch"); my @package_uniq_delim = ("slurm"); @@ -177,6 +180,6 @@ foreach my $category (@ohpcCategories) { } -print STDERR "----------------------------\n"; -print STDERR "# of Components = $component_cnt\n"; +print STDOUT "----------------------------\n"; +print STDOUT "# of Components = $component_cnt\n";
Documenting the options deprecating
@@ -14,13 +14,17 @@ B<openssl list> [B<-1>] [B<-commands>] [B<-digest-commands>] -[B<-digest-algorithms>] -[B<-kdf-algorithms>] +{- output_off() if $disabled{"deprecated-3.0"}; "" +-}[B<-digest-algorithms>] +{- output_on() if $disabled{"deprecated-3.0"}; "" +-}[B<-kdf-algorithms>] [B<-mac-algorithms>] [B<-random-generators>] [B<-cipher-commands>] -[B<-cipher-algorithms>] -[B<-encoders>] +{- output_off() if $disabled{"deprecated-3.0"}; "" +-}[B<-cipher-algorithms>] +{- output_on() if $disabled{"deprecated-3.0"}; "" +-}[B<-encoders>] [B<-decoders>] [B<-key-managers>] [B<-key-exchange-algorithms>] @@ -71,13 +75,17 @@ Display a list of standard commands. =item B<-digest-commands> +This option is deprecated. Use B<digest-algorithms> instead. + Display a list of message digest commands, which are typically used as input to the L<openssl-dgst(1)> or L<openssl-speed(1)> commands. =item B<-cipher-commands> +This option is deprecated. Use B<cipher-algorithms> instead. + Display a list of cipher commands, which are typically used as input -to the L<openssl-dgst(1)> or L<openssl-speed(1)> commands. +to the L<openssl-enc(1)> or L<openssl-speed(1)> commands. =item B<-digest-algorithms>, B<-kdf-algorithms>, B<-mac-algorithms>, B<-cipher-algorithms> @@ -209,7 +217,8 @@ In both cases, C<bar> is the name of the provider. =head1 HISTORY -The B<-engines> option was deprecated in OpenSSL 3.0. +The B<-engines>, B<-digest-commands>, and B<-cipher-commands> options +were deprecated in OpenSSL 3.0. =head1 COPYRIGHT
run_test: Send break before flushing buffers Some extraneous byte is being received when break is sent. This might change might introduce a race condition.
@@ -91,9 +91,9 @@ class SerialTester(object): self.raw_serial.timeout = 1.0 # Reset the target + self.raw_serial.sendBreak() self.raw_serial.reset_output_buffer() self.raw_serial.reset_input_buffer() - self.raw_serial.sendBreak() # Wait until the target is initialized expected_resp = "{init}"
libhfuzz/instrument: end of __sanitizer_cov_8bit_counters_init is not included
@@ -397,6 +397,9 @@ HF_REQUIRE_SSE42_POPCNT void __sanitizer_cov_trace_pc_guard_init(uint32_t* start /* Make sure that the feedback struct is already mmap()'d */ hfuzzInstrumentInit(); + if ((uintptr_t)start == (uintptr_t)stop) { + return; + } /* If this module was already initialized, skip it */ if (*start > 0) { LOG_D("Module %p-%p is already initialized", start, stop); @@ -498,7 +501,7 @@ void __sanitizer_cov_8bit_counters_init(char* start, char* end) { for (size_t i = 0; i < ARRAYSIZE(hf8bitcounters); i++) { if (hf8bitcounters[i].start == NULL) { hf8bitcounters[i].start = (uint8_t*)start; - hf8bitcounters[i].cnt = (uintptr_t)end - (uintptr_t)start + 1; + hf8bitcounters[i].cnt = (uintptr_t)end - (uintptr_t)start; hf8bitcounters[i].guard = instrumentReserveGuard(hf8bitcounters[i].cnt); LOG_D("8-bit module initialization %p-%p (count:%zu) at guard %zu", start, end, hf8bitcounters[i].cnt, hf8bitcounters[i].guard);
BIO_s_mem.pod: fix indirection for out parameter **pp BIO_get_mem_data() and BIO_get_mem_ptr() assign to *pp, not pp
@@ -56,14 +56,14 @@ zero then it will return B<v> when it is empty and it will set the read retry flag (that is BIO_read_retry(b) is true). To avoid ambiguity with a normal positive return value B<v> should be set to a negative value, typically -1. -BIO_get_mem_data() sets B<pp> to a pointer to the start of the memory BIOs data +BIO_get_mem_data() sets *B<pp> to a pointer to the start of the memory BIOs data and returns the total amount of data available. It is implemented as a macro. BIO_set_mem_buf() sets the internal BUF_MEM structure to B<bm> and sets the close flag to B<c>, that is B<c> should be either BIO_CLOSE or BIO_NOCLOSE. It is a macro. -BIO_get_mem_ptr() places the underlying BUF_MEM structure in B<pp>. It is +BIO_get_mem_ptr() places the underlying BUF_MEM structure in *B<pp>. It is a macro. BIO_new_mem_buf() creates a memory BIO using B<len> bytes of data at B<buf>,
ieee802154/coord: Updates logic to reflect changes in nuttx 802154 code
@@ -169,7 +169,6 @@ static int coord_ack(FAR struct ieee_coord_s *coord) static int coord_command_beacon_req(FAR struct ieee_coord_s *coord) { - FAR struct ieee_frame_s *rx = &coord->rxbuf; FAR struct ieee802154_packet_s *tx = &coord->txbuf.packet; int i; @@ -261,14 +260,17 @@ static int coord_command(FAR struct ieee_coord_s *coord) static int coord_manage(FAR struct ieee_coord_s *coord) { /* Decode frame type */ - uint8_t fc1, ftype; + uint16_t frame_ctrl; + uint8_t ftype; int hlen; char buf[IEEE802154_ADDRSTRLEN+1]; FAR struct ieee_frame_s *rx = &coord->rxbuf; int i; - fc1 = rx->packet.data[0]; + frame_ctrl = rx->packet.data[0]; + frame_ctrl |= rx->packet.data[1] << 8; + rx->seq = rx->packet.data[2]; hlen = ieee802154_addrparse(&rx->packet, &rx->dest, &rx->src); @@ -281,7 +283,7 @@ static int coord_manage(FAR struct ieee_coord_s *coord) rx->payload = rx->packet.data + hlen; rx->plen = rx->packet.len - hlen; - ftype = fc1 & IEEE802154_FC1_FTYPE; + ftype = frame_ctrl & IEEE802154_FRAMECTRL_FTYPE; ieee802154_addrtostr(buf,sizeof(buf),&rx->src); printf("[%s -> ", buf); @@ -333,12 +335,11 @@ static void coord_initialize(FAR struct ieee_coord_s *coord, FAR char *dev, coord->chan = strtol(chan , NULL, 0); - coord->addr.ia_len = 2; + coord->addr.ia_mode = IEEE802154_ADDRMODE_SHORT; coord->addr.ia_panid = strtol(panid, NULL, 0); coord->addr.ia_saddr = 0x0001; coord->fd = open(dev, O_RDWR); - } /****************************************************************************
HV: rename acrn_register to acpi_generic_address The name of acrn_register is too generic, rename to acpi_generic_address which is more common. Acked-by: Kevin Tian
@@ -301,7 +301,7 @@ struct acrn_vm_pci_msix_remap { #define SPACE_PLATFORM_COMM 10 #define SPACE_FFixedHW 0x7F -struct acrn_register { +struct acpi_generic_address { uint8_t space_id; uint8_t bit_width; uint8_t bit_offset; @@ -310,7 +310,7 @@ struct acrn_register { } __attribute__((aligned(8))); struct cpu_cx_data { - struct acrn_register cx_reg; + struct acpi_generic_address cx_reg; uint8_t type; uint32_t latency; uint64_t power;
Fix ASN1_TYPE_get/set with type=V_ASN1_BOOLEAN BOOLEAN does not have valid data in the value.ptr member, thus don't use it here. Fixes [extended tests]
int ASN1_TYPE_get(const ASN1_TYPE *a) { - if ((a->value.ptr != NULL) || (a->type == V_ASN1_NULL)) + if (a->type == V_ASN1_BOOLEAN + || a->type == V_ASN1_NULL + || a->value.ptr != NULL) return a->type; else return 0; @@ -23,7 +25,9 @@ int ASN1_TYPE_get(const ASN1_TYPE *a) void ASN1_TYPE_set(ASN1_TYPE *a, int type, void *value) { - if (a->value.ptr != NULL) { + if (a->type != V_ASN1_BOOLEAN + && a->type != V_ASN1_NULL + && a->value.ptr != NULL) { ASN1_TYPE **tmp_a = &a; asn1_primitive_free((ASN1_VALUE **)tmp_a, NULL, 0); }
Update graph labels from commit
@@ -203,7 +203,7 @@ INT_PTR CALLBACK PhpProcessPerformanceDlgProc( else { drawInfo->LabelYFunction = PhSiDoubleLabelYFunction; - drawInfo->LabelYFunctionParameter = 0.0f; + drawInfo->LabelYFunctionParameter = 1.0f; } performanceContext->CpuGraphState.Valid = TRUE; @@ -262,7 +262,7 @@ INT_PTR CALLBACK PhpProcessPerformanceDlgProc( ); } - drawInfo->LabelYFunction = PhSiDoubleLabelYFunction; + drawInfo->LabelYFunction = PhSiSizeLabelYFunction; drawInfo->LabelYFunctionParameter = (FLOAT)processItem->VmCounters.PeakPagefileUsage; performanceContext->PrivateGraphState.Valid = TRUE;
move .repo file creation
@@ -140,6 +140,19 @@ foreach my $distro (@distros) { } } + # add .repo file(s) + + print "Adding [base] repofile contents\n"; + copy("repo.base.in","$tmp_dir/$distro/OpenHPC.local.repo") || die "Unable to copy repo.base.in\n"; + if($micro) { + print "Adding [update] repofile contents\n"; + open (BASE, ">>","$tmp_dir/$distro/OpenHPC.local.repo") || die "Unable to append to repo file\n"; + open (UPDATE,"<","repo.update.in") || die "Unable to access repo.update.in\n"; + print BASE <UPDATE>; + close BASE; + close UPDATE; + } + $tar_args .= " $tmp_dir/$distro"; print "\nCreating dist for $distro:$arch -- \n"; print "tar command -> tar $tar_args\n"; @@ -174,18 +187,7 @@ foreach my $distro (@distros) { $tar_args .= "--exclude $tmp_dir/$distro/iso \\\n"; $tar_args .= " $tmp_dir/$distro"; - # add .repo file(s) - print "Adding [base] repofile contents\n"; - copy("repo.base.in","$tmp_dir/$distro/OpenHPC.local.repo") || die "Unable to copy repo.base.in\n"; - if($micro) { - print "Adding [update] repofile contents\n"; - open (BASE, ">>","$tmp_dir/$distro/OpenHPC.local.repo") || die "Unable to append to repo file\n"; - open (UPDATE,"<","repo.update.in") || die "Unable to access repo.update.in\n"; - print BASE <UPDATE>; - close BASE; - close UPDATE; - } print "dist for $distro:src -- \n"; print "tar command -> tar $tar_args\n";
groups: restrict sigil color input to 6 hex chars
@@ -367,7 +367,9 @@ export class ContactCard extends Component { onChange={this.sigilColorSet} defaultValue={defaultColor} key={"default" + defaultColor} + onKeyPress={ e => !e.key.match(/[0-9a-f]/i) ? e.preventDefault() : null} onBlur={(() => this.setField("color"))} + maxLength={6} style={{ resize: "none", height: 40,
Update check-commit.sh in CI to properly checkout remote branches
@@ -25,6 +25,8 @@ search_submodule() { # Initialize submodule and get the hashes git submodule update --init $dir/$submodule git -C $dir/$submodule fetch --unshallow + git -C $dir/$submodule config remote.origin.fetch "+refs/heads/*:refs/remotes/origin/*" + git -C $dir/$submodule fetch origin status=$(git submodule status) hash=$(echo "$status" | grep "$dir.*$submodule " | awk '{print$1}' | grep -o "[[:alnum:]]*")
Added MinGW to check.
@@ -95,7 +95,7 @@ function (UPNP_addUnitTest testName sourceFile) COMMAND ${testName} ) - if (MSVC OR MSYS) + if (MSVC OR MSYS OR MINGW) UPNP_findTestEnv (${testName} TEST_ENV) message(STATUS "Setting test-env to ${TEST_ENV}") set_tests_properties (${testName} PROPERTIES
Add drawMode to lovrModelDraw Batch;
@@ -61,6 +61,7 @@ static void renderNode(Model* model, uint32_t nodeIndex, int instances) { .instances = instances, .pose = node->skin >= 0 ? pose : NULL }, + .drawMode = primitive->mode, .transform = globalTransform, .material = material });
Remove ineffective codes Results of assert statements are always true, I think we don't need these assert statements anymore JerryScript-DCO-1.0-Signed-off-by: Haesik Jun
@@ -387,7 +387,6 @@ lit_char_to_utf8_bytes (uint8_t *dst_p, /**< destination buffer */ return 2; } - JERRY_ASSERT (!(chr & ~LIT_UTF8_3_BYTE_CODE_POINT_MAX)); /* zzzzyyyy yyxxxxxx -> 1110zzzz 10yyyyyy 10xxxxxx */ *(dst_p++) = (uint8_t) (LIT_UTF8_3_BYTE_MARKER | ((chr >> 12) & LIT_UTF8_LAST_4_BITS_MASK)); *(dst_p++) = (uint8_t) (LIT_UTF8_EXTRA_BYTE_MARKER | ((chr >> 6) & LIT_UTF8_LAST_6_BITS_MASK)); @@ -416,7 +415,6 @@ lit_char_get_utf8_length (ecma_char_t chr) /**< EcmaScript character */ } /* zzzzyyyy yyxxxxxx */ - JERRY_ASSERT (!(chr & ~LIT_UTF8_3_BYTE_CODE_POINT_MAX)); return 3; } /* lit_char_get_utf8_length */
Fix svg link to travis build
@@ -44,7 +44,7 @@ If you like the sound of this, [let's get started][started]. You can even try it [in your browser][browser]! Excited? Well, come on and [get involved][contribute]! -[![Build Status](https://travis-ci.org/wren-lang/wren.svg)](https://travis-ci.org/wren-lang/wren) +[![Build Status](https://travis-ci.org/wren-lang/wren.svg?branch=main)](https://travis-ci.org/wren-lang/wren) [syntax]: http://wren.io/syntax.html [src]: https://github.com/wren-lang/wren/tree/main/src
tools: GCC 11 uses both '.debug_line_str' and '.debug_str' sections
@@ -381,9 +381,7 @@ def load_sections(map_file: TextIO) -> Dict: if srcs: last_src = srcs[-1] if last_src['size'] > 0 and last_src['address'] == int(match_line.group('address'), 16): - if '.comment' != section['name'] and '.debug_str' != section['name'] and\ - 'rodata' not in last_src['sym_name']: - + if section['name'] not in ['.comment', '.debug_str', '.debug_line_str'] and 'rodata' not in last_src['sym_name']: raise RuntimeError('Due to overlap with following lines, size of the line set to 0:\n %s' % dump_src_line(last_src)) last_src['size'] = 0
[numerics] raise an exception if load_npz is not defined in scipy.sparse
@@ -89,24 +89,22 @@ def test_from_csr2(): def test_from_csc162x162(): from siconos.numerics import SBM_from_csparse, SBM_get_value, NM_display - from scipy.sparse import csr_matrix, load_npz, linalg + from scipy.sparse import csr_matrix, linalg + try: + from scipy.sparse import load_npz + except: + return 0 - M = load_npz(os.path.join(working_dir, 'data/csc162x162.npz')) + M = load_npz(os.path.join(working_dir, 'data/csc162x162.npz')) #M = load_npz('data/csc162x162.npz') - #print(linalg.eigs(M+M.transpose(), which='LR')[1]) - #print(M.indices) - #print(M.indptr) - #print(M.data) - blocksize =9 r,SBM = SBM_from_csparse(blocksize,M) assert SBM_get_value(SBM,0,0) == M[0,0] assert SBM_get_value(SBM,161,161) == M[161,161] - #print(SBM_get_value(SBM,0,0)) - #NM_display(SBM) + # # scipy csr 3x3 block
Jenkins: prune all docker images monthly
stage("Trigger monthly libelektra/master build") { build job: "libelektra/master", wait: false } + +stage("Maintain docker nodes") { + parallel generateDockerMaintanenceStages() +} + +/* cleanup temp docker files on all docker nodes */ +def generateDockerMaintanenceStages() { + def nodes = nodesByLabel label:"docker" + def tasks = [:] + + nodes.each { targetNode -> + tasks << cleanupDocker(targetNode) + } + return tasks +} + +def cleanupDocker(targetNode) { + def taskname = "cleanupDocker/${targetNode}" + return [(taskname): { + stage(taskname) { + node(targetNode) { + sh "docker system prune -af" + } + } + }] +}
Shutdown sockets before closing The server socket does not release the port it was listening for if we just close it: we must also shutdown it.
@@ -71,6 +71,7 @@ static socket_t listen_on_port(Uint16 port) { static void close_socket(socket_t *socket) { SDL_assert(*socket != INVALID_SOCKET); + net_shutdown(*socket, SHUT_RDWR); if (!net_close(*socket)) { LOGW("Cannot close socket"); return;
flapjack: disable configs to get flash size TEST=none BRANCH=none
/* USB PD config */ +/* Exclude PD state names from RO image to save space */ +#ifdef SECTION_IS_RO +#undef CONFIG_USB_PD_TCPMV1_DEBUG +#endif #define CONFIG_CHARGE_MANAGER #define CONFIG_USB_POWER_DELIVERY #define CONFIG_USB_PD_TCPMV1 #ifdef SECTION_IS_RO #undef CONFIG_CMD_ADC #undef CONFIG_CMD_APTHROTTLE +#undef CONFIG_CMD_AP_RESET_LOG #undef CONFIG_CMD_CBI #undef CONFIG_CMD_I2C_SCAN #undef CONFIG_CMD_I2C_XFER #undef CONFIG_CMD_SLEEPMASK #undef CONFIG_CMD_SLEEPMASK_SET #undef CONFIG_CMD_SYSLOCK +#undef CONFIG_CONSOLE_CMDHELP #undef CONFIG_HOSTCMD_GET_UPTIME_INFO -#undef CONFIG_CMD_AP_RESET_LOG #endif #define CONFIG_TASK_PROFILING
clay: resurrect ':' for file-change notifications Instead of printing '+' for both additions and modifications.
|(!=(~ sys-changes) !=(~ (need-vane-update changes))) == (sys-update yoki new-data changes) - =. ..park (emil (print deletes ~(key by changes))) + =. ..park + %- emil + =/ changed=(set path) ~(key by changes) + =/ existed=(set path) ~(key by old-lobes) + %^ print deletes + (~(int in changed) existed) + (~(dif in changed) existed) :: clear caches if zuse reloaded :: =/ is-zuse-new=? !=(~ sys-changes) :: Print notification to console :: ++ print - |= [deletes=(set path) changes=(set path)] + |= [deletes=(set path) changes=(set path) additions=(set path)] ^- (list move) - |^ ?~ hun ~ ?: =(0 let.dom) ~ - %+ weld - %+ turn ~(tap in deletes) - |= =path - [u.hun %give %note '-' (path-to-tank path)] - %+ turn ~(tap in changes) + |^ + ;: weld + (paths-to-notes '-' deletes) + (paths-to-notes ':' changes) + (paths-to-notes '+' additions) + == + :: + ++ paths-to-notes + |= [prefix=@tD paths=(set path)] + %+ turn ~(tap in paths) |= =path - [u.hun %give %note '+' (path-to-tank path)] + [u.hun %give %note prefix (path-to-tank path)] :: ++ path-to-tank |= =path
apps/blemesh_shell: Use Incomplete Timer Expired event from Testing API
@@ -61,11 +61,17 @@ static void invalid_bearer_cb(u8_t opcode) console_printf("Invalid bearer: opcode 0x%02x\n", opcode); } +static void incomp_timer_exp_cb(void) +{ + console_printf("Incomplete timer expired\n"); +} + static struct bt_test_cb bt_test_cb = { .mesh_net_recv = net_recv_ev, .mesh_model_bound = model_bound_cb, .mesh_model_unbound = model_unbound_cb, .mesh_prov_invalid_bearer = invalid_bearer_cb, + .mesh_trans_incomp_timer_exp = incomp_timer_exp_cb, }; static void
[Fix] Recep_NodeConcerned return value to MULTIHOST in TOPICS fix
@@ -512,13 +512,8 @@ __attribute__((weak)) luos_localhost_t Recep_NodeConcerned(header_t *header) } break; case TOPIC: - if (Recep_TopicCompare(header->target) == SUCCEED) + if ((Recep_TopicCompare(header->target) == SUCCEED) || (ctx.filter_state == false)) { - return ctx.verbose; - } - else if (ctx.filter_state == false) - { - // if there is a service that deactivated the filtering occupy the message return MULTIHOST; } break;
[CI] sync in +solid updates when making a pill
@@ -33,7 +33,7 @@ mkdir prev |autoload | |mount % . - [ $? = 0 ] && cp -r ../sys prev/zod/home/ + [ $? = 0 ] && cp -r ../sys prev/zod/home/ && cp ../gen/solid.hoon prev/zod/home/gen/ } || { : Pilling: Parent-pill pier not available, trying preceding pill commit HASH2=$(git -C .. log -2 $HASH --format=%H -- sys/ | tail -1)
fix --no-save conflict checks
@@ -186,7 +186,8 @@ static struct argp_option options[] = { "prompting the user", 4}, {"pw-env", OPT_PW_ENV, 0, OPTION_ARG_OPTIONAL, - "Reads the encryption password from environment OIDC_ENCRYPTION_PW, instead of " + "Reads the encryption password from environment OIDC_ENCRYPTION_PW, " + "instead of " "prompting the user", 4}, {"pw-file", OPT_PW_FILE, "FILE", 0, @@ -301,7 +302,6 @@ static error_t parse_opt(int key, char* arg, struct argp_state* state) { case 'g': arguments->debug = 1; break; case 'v': arguments->verbose = 1; break; case 'm': arguments->manual = 1; break; - case OPT_NO_SAVE: arguments->noSave = 1; break; case OPT_REAUTHENTICATE: arguments->reauthenticate = 1; break; case OPT_PUBLICCLIENT: arguments->usePublicClient = 1; break; case 'l': arguments->listAccounts = 1; break; @@ -312,8 +312,17 @@ static error_t parse_opt(int key, char* arg, struct argp_state* state) { case OPT_CONFIRM_NO: arguments->confirm_no = 1; break; case OPT_CONFIRM_YES: arguments->confirm_yes = 1; break; case OPT_CONFIRM_DEFAULT: arguments->confirm_default = 1; break; - case OPT_ONLY_AT: - arguments->only_at = 1; + case OPT_ONLY_AT: arguments->only_at = 1; break; + case OPT_NO_SAVE: + if (arguments->updateConfigFile) { + printError("Update argument cannot be combined with no-save\n"); + exit(EXIT_FAILURE); + } + if (arguments->rename) { + printError("Rename argument cannot be combined with no-save\n"); + exit(EXIT_FAILURE); + } + arguments->noSave = 1; break; // arguments @@ -332,16 +341,12 @@ static error_t parse_opt(int key, char* arg, struct argp_state* state) { case OPT_codeExchange: arguments->codeExchange = arg; break; case OPT_state: arguments->state = arg; break; case 'f': - if (arguments->noSave) { - printError("File argument cannot be combined with no-save\n"); - exit(EXIT_FAILURE); - } arguments->file = arg; arguments->manual = 1; break; case OPT_RENAME: if (arguments->noSave) { - printError("File argument cannot be combined with no-save\n"); + printError("Rename argument cannot be combined with no-save\n"); exit(EXIT_FAILURE); } arguments->rename = arg; @@ -378,7 +383,8 @@ static error_t parse_opt(int key, char* arg, struct argp_state* state) { printError("OIDC_REFRESH_TOKEN not set!\n"); exit(EXIT_FAILURE); } - // Copy env_pass as subsequent getenv calls might modify our just received data + // Copy env_pass as subsequent getenv calls might modify our just received + // data arguments->refresh_token = oidc_strcopy(env_refresh_token); if (arguments->flows == NULL) { arguments->flows = list_new();
compiler-families/arm-compilers-devel: updating to work with Aug 2021 build of arm-linux-compiler which does not hard code version info in the package name
@@ -35,7 +35,8 @@ BuildArch: aarch64 #!BuildIgnore: post-build-checks # We need to ensure the installed version is >=21.0 -Requires: arm-linux-compiler-%{latest_installed_ver}-Generic-AArch64-RHEL-8-aarch64-linux >= 21.0 +#Requires: arm-linux-compiler-%{latest_installed_ver}-Generic-AArch64-RHEL-8-aarch64-linux >= 21.0 +Requires: arm-linux-compiler >= 21.0 Requires: lmod%{PROJ_DELIM} %description
use `h2o_mem_alloc` instead of bare `malloc`
@@ -1498,7 +1498,7 @@ static void do_ssl_async(h2o_socket_t *sock) h2o_socket_t *async_sock = h2o_evloop_socket_create(h2o_socket_get_loop(sock), async_fd, H2O_SOCKET_FLAG_DONT_READ | H2O_SOCKET_FLAG_DONT_NONBLOCK); #endif - struct async_data *adata = malloc(sizeof(struct async_data)); + struct async_data *adata = h2o_mem_alloc(sizeof(struct async_data)); adata->client.sock = sock; adata->async_sock = async_sock;
test(sdmmc_host): add new test to probe over SD (1-bit).
@@ -36,7 +36,7 @@ TEST_CASE("MMC_RSP_BITS", "[sd]") TEST_ASSERT_EQUAL_HEX32(0x11, MMC_RSP_BITS(data, 59, 5)); } -TEST_CASE("can probe SD", "[sd][test_env=UT_T1_SDMODE][ignore]") +TEST_CASE("can probe SD (4-bit)", "[sd][test_env=UT_T1_SDMODE]") { sdmmc_host_t config = SDMMC_HOST_DEFAULT(); sdmmc_slot_config_t slot_config = SDMMC_SLOT_CONFIG_DEFAULT(); @@ -50,8 +50,37 @@ TEST_CASE("can probe SD", "[sd][test_env=UT_T1_SDMODE][ignore]") free(card); } +TEST_CASE("can probe SD (1-bit)", "[sd][test_env=UT_T1_SDMODE]") +{ + //the card DAT3 should be connected to high in SD 1-bit mode + //do it by our own GPIO. + gpio_config_t conf = { + .pin_bit_mask = GPIO_SEL_13, + .mode = GPIO_MODE_OUTPUT, + .pull_up_en = 1, + .pull_down_en = 0, + .intr_type = GPIO_INTR_DISABLE, + }; + gpio_config(&conf); + gpio_set_level(GPIO_NUM_13, 1); + + sdmmc_host_t config = SDMMC_HOST_DEFAULT(); + config.flags = SDMMC_HOST_FLAG_1BIT; + sdmmc_slot_config_t slot_config = SDMMC_SLOT_CONFIG_DEFAULT(); + slot_config.width=1; + TEST_ESP_OK(sdmmc_host_init()); + TEST_ESP_OK(sdmmc_host_init_slot(SDMMC_HOST_SLOT_1, &slot_config)); + sdmmc_card_t* card = malloc(sizeof(sdmmc_card_t)); + TEST_ASSERT_NOT_NULL(card); + TEST_ESP_OK(sdmmc_card_init(&config, card)); + sdmmc_card_print_info(stdout, card); + TEST_ESP_OK(sdmmc_host_deinit()); + free(card); +} + + -TEST_CASE("can probe SD(using SPI)", "[sdspi][test_env=UT_T1_SPIMODE][ignore]") +TEST_CASE("can probe SD(using SPI)", "[sdspi][test_env=UT_T1_SPIMODE]") { sdmmc_host_t config = SDSPI_HOST_DEFAULT(); sdspi_slot_config_t slot_config = SDSPI_SLOT_CONFIG_DEFAULT();
move comments to same line as fields
@@ -2206,23 +2206,16 @@ static const EVP_TEST_METHOD keypair_test_method = { }; typedef struct { - /* Set to 1 if verifying */ - int is_verify; - /* Set to 1 for one shot operation */ - int is_oneshot; - /* Digest to use */ - const EVP_MD *md; - /* Digest context */ - EVP_MD_CTX *ctx; + int is_verify; /* Set to 1 if verifying */ + int is_oneshot; /* Set to 1 for one shot operation */ + const EVP_MD *md; /* Digest to use */ + EVP_MD_CTX *ctx; /* Digest context */ EVP_PKEY_CTX *pctx; - /* Input data: streaming */ - STACK_OF(EVP_TEST_BUFFER) *input; - /* Input data if one shot */ - unsigned char *osin; - size_t osin_len; - /* Expected output */ - unsigned char *output; - size_t output_len; + STACK_OF(EVP_TEST_BUFFER) *input; /* Input data: streaming */ + unsigned char *osin; /* Input data if one shot */ + size_t osin_len; /* Input length data if one shot */ + unsigned char *output; /* Expected output */ + size_t output_len; /* Expected output length */ } DIGESTSIGN_DATA; static int digestsigver_test_init(EVP_TEST *t, const char *alg, int is_verify,
[kernel] correct the multiple OSI test in Simulation
@@ -202,7 +202,7 @@ void Simulation::initialize(SP::Model m, bool withOSI) if (!DSG->properties(*dsi).osi) { _nsds->topology()->setOSI(DSG->bundle(*dsi), *_allOSI->begin()); - if (++_allOSI->begin() != _allOSI->end()) + if (_allOSI->size() > 1) { std::cout <<"Warning. The simulation has multiple OSIs but the DS number " << DSG->bundle(*dsi)->number()
filter: pdftoraster: adapt for const getMediaBox from poppler poppler made getMediaBox const in commit therefore adapt it for cups-filters.
@@ -1686,7 +1686,7 @@ static void outPage(PDFDoc *doc, Catalog *catalog, int pageNo, { SplashBitmap *bitmap; Page *page = catalog->getPage(pageNo); - PDFRectangle *mediaBox = page->getMediaBox(); + PDFRectangle mediaBox = *page->getMediaBox(); int rotate = page->getRotate(); double paperdimensions[2], /* Physical size of the paper */ margins[4]; /* Physical margins of print */ @@ -1696,14 +1696,14 @@ static void outPage(PDFDoc *doc, Catalog *catalog, int pageNo, bool landscape = 0; fprintf(stderr, "DEBUG: mediaBox = [ %f %f %f %f ]; rotate = %d\n", - mediaBox->x1, mediaBox->y1, mediaBox->x2, mediaBox->y2, rotate); - l = mediaBox->x2 - mediaBox->x1; + mediaBox.x1, mediaBox.y1, mediaBox.x2, mediaBox.y2, rotate); + l = mediaBox.x2 - mediaBox.x1; if (l < 0) l = -l; if (rotate == 90 || rotate == 270) header.PageSize[1] = (unsigned)l; else header.PageSize[0] = (unsigned)l; - l = mediaBox->y2 - mediaBox->y1; + l = mediaBox.y2 - mediaBox.y1; if (l < 0) l = -l; if (rotate == 90 || rotate == 270) header.PageSize[0] = (unsigned)l;
BugId:17134677:deleted the DEVELOPERKIT_ENABLE_OTA configuration
@@ -521,7 +521,6 @@ $(CONFIG_FILE): $(AOS_SDK_MAKEFILES) | $(CONFIG_FILE_DIR) $(QUIET)$(call WRITE_FILE_APPEND, $(CONFIG_FILE) ,AOS_RAM_STUB_LIST_FILE := $(AOS_RAM_STUB_LIST_FILE)) $(QUIET)$(call WRITE_FILE_APPEND, $(CONFIG_FILE) ,PING_PONG_OTA := $(PING_PONG_OTA)) $(QUIET)$(call WRITE_FILE_APPEND, $(CONFIG_FILE) ,AOS_CPLUSPLUS_FLAGS:= $(AOS_CPLUSPLUS_FLAGS)) - $(QUIET)$(call WRITE_FILE_APPEND, $(CONFIG_FILE) ,DEVELOPERKIT_ENABLE_OTA := $(DEVELOPERKIT_ENABLE_OTA)) endif CONFIG_PY_FILE := build/scripts/config_mk.py
Immediate connection termination when integrity limit is reached
@@ -6542,13 +6542,10 @@ static int conn_prepare_key_update(ngtcp2_conn *conn, ngtcp2_tstamp ts) { size_t secretlen, ivlen; if ((conn->flags & NGTCP2_CONN_FLAG_HANDSHAKE_CONFIRMED) && - (tx_ckm->use_count >= pktns->crypto.ctx.max_encryption || - conn->crypto.decryption_failure_count >= - pktns->crypto.ctx.max_decryption_failure)) { - if (ngtcp2_conn_initiate_key_update(conn, ts) != 0) { + tx_ckm->use_count >= pktns->crypto.ctx.max_encryption && + ngtcp2_conn_initiate_key_update(conn, ts) != 0) { return NGTCP2_ERR_AEAD_LIMIT_REACHED; } - } if ((conn->flags & NGTCP2_CONN_FLAG_KEY_UPDATE_NOT_CONFIRMED) || (confirmed_ts != UINT64_MAX && confirmed_ts + pto > ts)) { @@ -7105,8 +7102,10 @@ static ngtcp2_ssize conn_recv_pkt(ngtcp2_conn *conn, const ngtcp2_path *path, assert(NGTCP2_ERR_TLS_DECRYPT == nwrite); - if (hd.type == NGTCP2_PKT_SHORT) { - ++conn->crypto.decryption_failure_count; + if (hd.type == NGTCP2_PKT_SHORT && + ++conn->crypto.decryption_failure_count >= + pktns->crypto.ctx.max_decryption_failure) { + return NGTCP2_ERR_AEAD_LIMIT_REACHED; } if (hd.flags & NGTCP2_PKT_FLAG_LONG_FORM) {
test-suite: fix etrae binary name
@@ -64,7 +64,7 @@ setup() { } @test "[$testname] Verify availability of extrae-cmd binary ($LMOD_FAMILY_COMPILER/$LMOD_FAMILY_MPI)" { - run which pprof + run which extrae-cmd assert_success }
Update GCC in MinGW builds. C++17 support in MinGW was getting difficult so I dropped x86 support for the moment.
@@ -160,9 +160,6 @@ jobs: architecture: x86 - os: "windows-2019" architecture: x86_64 - - os: "windows-2019" - architecture: x86 - toolset: mingw - os: "windows-2019" architecture: x86_64 toolset: mingw @@ -185,16 +182,24 @@ jobs: if: runner.os == 'macOS' run: | brew install sdl2 - - name: Set up MinGW + - uses: msys2/setup-msys2@v2 if: ${{ matrix.toolset == 'mingw' }} - uses: egor-tensin/setup-mingw@v2 with: - platform: ${{ matrix.architecture == 'x86_64' && 'x64' || 'x86' }} + msystem: MINGW64 + update: true + install: git scons mingw-w64-x86_64-toolchain mingw-w64-x86_64-SDL2 - name: Build package. + if: ${{ matrix.toolset != 'mingw' }} + working-directory: buildsys/scons + run: | + scons develop_all dist -j 3 -s CPPDEFINES=NDEBUG MODE=DEBUG_RELEASE ARCH=${{ matrix.architecture }} + - name: Build package (MinGW) + if: ${{ matrix.toolset == 'mingw' }} working-directory: buildsys/scons + shell: msys2 {0} run: | - scons develop_all dist -j 3 -s CPPDEFINES=NDEBUG MODE=DEBUG_RELEASE \ - ARCH=${{ matrix.architecture }} ${{ matrix.toolset == 'mingw' && 'TOOLSET=mingw' || '' }} + scons develop_all dist -j 3 -s CPPDEFINES=NDEBUG MODE=DEBUG_RELEASE ARCH=${{ matrix.architecture }} \ + TOOLSET=mingw - name: Archive distribution uses: actions/upload-artifact@v2 with:
firpfb/example: fixing axis labels, adding legend
@@ -35,7 +35,7 @@ int main(int argc, char*argv[]) { // output to file FILE*fid = fopen(OUTPUT_FILENAME,"w"); fprintf(fid,"%% %s: auto-generated file\n\n", OUTPUT_FILENAME); - fprintf(fid,"clear all;\nclose all;\n\n"); + fprintf(fid,"clear all; close all;\n\n"); fprintf(fid,"M = %u; m = %u; num_samples = %u\n", M, m, num_samples); fprintf(fid,"x = zeros(1, num_samples);\n"); fprintf(fid,"y = zeros(1,M*num_samples);\n"); @@ -46,8 +46,9 @@ int main(int argc, char*argv[]) { fprintf(fid,"figure;\n"); fprintf(fid,"plot(ty,y,'-k',tx,x,'ob','MarkerSize',2);\n"); fprintf(fid,"grid on;\n"); - fprintf(fid,"xlabel('normalized frequency');\n"); - fprintf(fid,"ylabel('PSD [dB]');\n"); + fprintf(fid,"xlabel('Input Sample Index');\n"); + fprintf(fid,"ylabel('Signal');\n"); + fprintf(fid,"legend('Output','Input');\n"); fclose(fid); printf("results written to %s\n", OUTPUT_FILENAME); return 0;
apps/s_client.c: harden ldap_ExtendedResponse_parse.
@@ -3091,6 +3091,8 @@ static int ldap_ExtendedResponse_parse(const char *buf, long rem) goto end; } + rem = len; /* ensure that we don't overstep the SEQUENCE */ + /* pull MessageID */ inf = ASN1_get_object(&cur, &len, &tag, &xclass, rem); if (inf != V_ASN1_UNIVERSAL || tag != V_ASN1_INTEGER ||
Changed sceLsdbGetMode to sceLsdbGetStyle
@@ -5962,8 +5962,8 @@ modules: sceLsdbGetCategory: 0x6469796F sceLsdbGetDiscId: 0x1F569CFC sceLsdbGetGameDataId: 0x2FFE0E3F - sceLsdbGetMode: 0xDEC358E4 sceLsdbGetName: 0xD02A8B85 sceLsdbGetOriginalPath: 0x92D14842 sceLsdbGetParentalLevel: 0x226B12F7 sceLsdbGetSelfPath: 0xD6B57313 + sceLsdbGetStyle: 0xDEC358E4
config: add time, vsync explanation
### Limit the application FPS # fps_limit= -### VSYNC [0-3] +### VSYNC [0-3] 0 = adaptive; 1 = off; 2 = mailbox; 3 = on # vsync= ################### VISUAL ################### @@ -24,6 +24,9 @@ gpu_stats ### Display the frametime line graph frame_timing +### Display the current system time +# time + ### Change the hud font size (default is 24) font_size=24 @@ -33,10 +36,8 @@ position=top-left ### Display the current CPU load & frequency for each core # core_load -### Display system memory usage +### Display system ram / vram usage # ram - -### Display system video memory usage # vram ### Disable / hide the hud by deafult
Conditionals: Remove dead code
@@ -156,14 +156,10 @@ static int compareStrings (const char * s1, const char * s2, const Key * suffixL { retval = 0; } - else if (result > 0) + else { retval = 1; } - else if (result < 0) - { - retval = -1; - } } else {
http_server: metrics: prometheus: fix mark
@@ -216,9 +216,9 @@ void cb_metrics_prometheus(mk_request_t *request, void *data) flb_sds_cat(sds, k.via.str.ptr, k.via.str.size); flb_sds_cat(sds, "_", 1); flb_sds_cat(sds, mk.via.str.ptr, mk.via.str.size); - flb_sds_cat(sds, "(name=\"", 7); + flb_sds_cat(sds, "{name=\"", 7); flb_sds_cat(sds, sk.via.str.ptr, sk.via.str.size); - flb_sds_cat(sds, "\") ", 3); + flb_sds_cat(sds, "\"} ", 3); len = snprintf(tmp, sizeof(tmp) - 1, "%lu ", mv.via.u64);
Add Develco magnetic switch to supported device list
@@ -197,6 +197,7 @@ static const SupportedDevice supportedDevices[] = { { VENDOR_NONE, "RES001", tiMacPrefix }, // Hubitat environment sensor, see #1308 { VENDOR_119C, "WL4200S", sinopeMacPrefix}, // Sinope water sensor { VENDOR_DEVELCO, "SMSZB-120", develcoMacPrefix }, // Develco smoke sensor + { VENDOR_DEVELCO, "ZHMS101", develcoMacPrefix }, // Develco magnetic switch { 0, nullptr, 0 } };
(docs) fix FIOBJ type value list
@@ -71,16 +71,17 @@ fiobj_type_enum fiobj_type(FIOBJ o); Returns the object's type. Valid return values are: -`FIOBJ_T_NULL` - Object is the primitive `null` -* `FIOBJ_T_TRUE` - Object is the primitive `true` -* `FIOBJ_T_FALSE` - Object is the primitive `false` -* `FIOBJ_T_NUMBER` - Object is a number. -* `FIOBJ_T_FLOAT` - Object is a floating point number (`double`). -* `FIOBJ_T_STRING` - Object is a binary String. -* `FIOBJ_T_ARRAY` - Object is a FIOBJ array. -* `FIOBJ_T_HASH` - Object is a FIOBJ hash. -* `FIOBJ_T_DATA` - Object is a data stream, either wrapping a temporary file or a memory block. -* `FIOBJ_T_UNKNOWN` - Object type is unknown (a user's type). + +- `FIOBJ_T_NULL` - Object is the primitive `null` +- `FIOBJ_T_TRUE` - Object is the primitive `true` +- `FIOBJ_T_FALSE` - Object is the primitive `false` +- `FIOBJ_T_NUMBER` - Object is a number. +- `FIOBJ_T_FLOAT` - Object is a floating point number (`double`). +- `FIOBJ_T_STRING` - Object is a binary String. +- `FIOBJ_T_ARRAY` - Object is a FIOBJ array. +- `FIOBJ_T_HASH` - Object is a FIOBJ hash. +- `FIOBJ_T_DATA` - Object is a data stream, either wrapping a temporary file or a memory block. +- `FIOBJ_T_UNKNOWN` - Object type is unknown (a user's type). #### `fiobj_type_is` @@ -188,9 +189,11 @@ A type error results in NULL (i.e. object can't be represented automatically as uint64_t fiobj_obj2hash(const FIOBJ o); ``` -Calculates an Objects's SipHash value for possible use as a HashMap key. +Calculates an Object's hash value for possible use as a HashMap key. + +Hash values use the default hashing function defined at compile time. This is usually SipHash 1-3, but could be set to a different hashing function (such as RiskyHash). -The Object MUST answer to the fiobj_obj2cstr, or the result is unusable. In other woords, Hash Objects and Arrays can NOT be used for Hash keys. +The Object MUST answer to the fiobj_obj2cstr, or the result is unusable. In other words, Hash Objects and Arrays can NOT be used for Hash keys. ### Iteration
Fix rare WMI providers tab crash
* Process Hacker - * Process properties: WMI Providor page * - * Copyright (C) 2017 dmex + * Copyright (C) 2017-2019 dmex * * This file is part of Process Hacker. * @@ -255,8 +255,12 @@ HRESULT PhpQueryWmiProviderFileName( VARIANT variant; if (SUCCEEDED(IWbemClassObject_Get(wbemClassObject, L"CLSID", 0, &variant, 0, 0))) + { + if (variant.bstrVal) // returns NULL for some host processes (dmex) { clsidString = PhCreateString(variant.bstrVal); + } + VariantClear(&variant); }
board/kracko/board.h: Format with clang-format BRANCH=none TEST=none
#define CONFIG_CHARGER_OTG #undef CONFIG_CHARGER_SINGLE_CHIP #define CONFIG_OCPC -#define CONFIG_OCPC_DEF_RBATT_MOHMS 21 /* R_DS(on) 10.7mOhm + 10mOhm sns rstr */ +#define CONFIG_OCPC_DEF_RBATT_MOHMS 21 /* R_DS(on) 10.7mOhm + 10mOhm sns rstr \ + */ /* PWM */ #define CONFIG_PWM @@ -109,12 +110,7 @@ enum pwm_channel { }; /* Motion sensors */ -enum sensor_id { - LID_ACCEL, - BASE_ACCEL, - BASE_GYRO, - SENSOR_COUNT -}; +enum sensor_id { LID_ACCEL, BASE_ACCEL, BASE_GYRO, SENSOR_COUNT }; /* ADC channels */ enum adc_channel {
Improve KPH error checking
#include <kphuserp.h> HANDLE PhKphHandle = NULL; -BOOLEAN PhKphVerified; -KPH_KEY PhKphL1Key; +BOOLEAN PhKphVerified = FALSE; +KPH_KEY PhKphL1Key = 0; NTSTATUS KphConnect( _In_opt_ PWSTR DeviceName @@ -196,13 +196,19 @@ NTSTATUS KphConnect2Ex( if (StartService(serviceHandle, 0, NULL)) started = TRUE; + else + status = PhGetLastWin32ErrorAsNtStatus(); + } + else + { + status = PhGetLastWin32ErrorAsNtStatus(); } CloseServiceHandle(scmHandle); } } - if (started) + if (NT_SUCCESS(status) && started) { // Try to open the device again. status = KphConnect(fullDeviceName);
soft_serial: increase timeout
@@ -105,6 +105,8 @@ static void soft_serial_set_output(usart_ports_t port) { } uint8_t soft_serial_init(usart_ports_t port, uint32_t baudrate, uint8_t stop_bits) { + soft_serial_timer_stop(); + DEV.baud = baudrate; DEV.stop_bits = stop_bits; @@ -116,7 +118,6 @@ uint8_t soft_serial_init(usart_ports_t port, uint32_t baudrate, uint8_t stop_bit soft_serial_init_tx(port); soft_serial_init_rx(port); - soft_serial_timer_stop(); timer_init(TIMER_INSTANCE, 1, PWM_CLOCK_FREQ_HZ / (baudrate * BAUD_DIVIDER)); interrupt_enable(TIMER_IRQN, TIMER_PRIORITY); @@ -190,7 +191,7 @@ void soft_serial_rx_update(usart_ports_t port) { } static uint32_t timeout = 0; - if (timeout == 10000) { + if (timeout == 100000) { DEV.rx_state = START_BIT; timeout = 0; soft_serial_timer_stop(); @@ -229,6 +230,7 @@ void soft_serial_rx_update(usart_ports_t port) { if (DEV.rx_state > (STOP_BITS + (BAUD_DIVIDER / 2)) && DEV.rx_state < (STOP_BITS + 1 * BAUD_DIVIDER)) { if (!gpio_pin_read(DEV.rx_pin)) { DEV.rx_state = START_BIT; + timeout = 0; return; } }
rms/slurm: update example slurm config to include file based job completion accounting. This will be stored in /var/log/slurm_jobcomp.log and can be used as a simple proxy for the text based accounting file that existed in earlier versions of slurm (more advanced sites can enable database back-ended accounting instead)
@@ -462,6 +462,7 @@ echo "# OpenHPC default configuration" >> $RPM_BUILD_ROOT/%{_sysconfdir}/slurm.c # 10/2/18 [email protected] - Enabling the task/affinity plugin to add the --cpu-bind option to srun for GEOPM echo "TaskPlugin=task/affinity" >> $RPM_BUILD_ROOT/%{_sysconfdir}/slurm.conf.ohpc echo "PropagateResourceLimitsExcept=MEMLOCK" >> $RPM_BUILD_ROOT/%{_sysconfdir}/slurm.conf.ohpc +echo "JobCompType=jobcomp/filetxt" >> $RPM_BUILD_ROOT/%{_sysconfdir}/slurm.conf.ohpc echo "Epilog=/etc/slurm/slurm.epilog.clean" >> $RPM_BUILD_ROOT/%{_sysconfdir}/slurm.conf.ohpc echo "NodeName=c[1-4] Sockets=2 CoresPerSocket=8 ThreadsPerCore=2 State=UNKNOWN" >> $RPM_BUILD_ROOT/%{_sysconfdir}/slurm.conf.ohpc echo "PartitionName=normal Nodes=c[1-4] Default=YES MaxTime=24:00:00 State=UP Oversubscribe=EXCLUSIVE" >> $RPM_BUILD_ROOT/%{_sysconfdir}/slurm.conf.ohpc @@ -738,10 +739,10 @@ exit 0 %post -# 3/31/17 [email protected] - fix perm for txt accounting file possibility -if [ ! -f /var/log/slurm_jobacct.log ];then - touch /var/log/slurm_jobacct.log - chown slurm: /var/log/slurm_jobacct.log +# 3/23/21 [email protected] - fix perm for txt job accounting possibility +if [ ! -f /var/log/slurm_jobcomp.log ];then + touch /var/log/slurm_jobcomp.log + chown slurm: /var/log/slurm_jobcomp.log fi # 8/8/17 [email protected] - create StateSaveLocation
meson: use one liner dependency on frigg
@@ -41,16 +41,12 @@ if not headers_only libc_deps += cxxshim_dep rtdl_deps += cxxshim_dep - # Ideally we'd use the same one-liner as above, but we can't pass default_options that way - frigg_dep = dependency('frigg', method: 'pkg-config', required: false) - if not frigg_dep.found() - message('frigg not found with pkg-config, falling back to subproject...') - frigg_dep = subproject( + frigg_dep = dependency( 'frigg', - default_options: ['frigg_no_install=true'] - ).get_variable('frigg_dep') - endif - + default_options: ['frigg_no_install=true'], + method: 'pkg-config', + fallback: ['frigg', 'frigg_dep'], + ) libc_deps += frigg_dep rtdl_deps += frigg_dep
minor cleanup in 16 bit stage1
- -;;; apparently this is the preferred technique to zero -;;; a register in x86 -%macro zero 1 - xor %1,%1 -%endmacro - - ;;; we start up at 7c00 in 16 bit mode init: bits 16 @@ -42,29 +34,22 @@ init: jmp ascend smapsig equ 0x534D4150 +regionlen equ 20 ;;; e820 - return the amount of total memory -e820: zero ebx - mov edi, entries - (desc.end - desc) +e820: xor ebx, ebx + mov edi, entries - regionlen .each: mov edx,smapsig mov ax,bseg mov es,ax mov eax,0xe820 - mov ecx, desc.end-desc + mov ecx, regionlen int 0x15 - sub edi, desc.end-desc + sub edi, regionlen test ebx, ebx jne .each ret -;;; this doesn't actually need to live here anymore -desc: - .base dd 0,0 - .length dd 0,0 - .type dd 0 -.end: - - ;;; seta20 - canned function to open up 'extended memory' seta20: in al,0x64 ; Get status
docs: xCAT updates for centos7.6
@@ -15,7 +15,7 @@ creation process using the \texttt{copycds} command assuming that the necessary % begin_ohpc_run % ohpc_comment_header Initialize OS images for use with xCAT \ref{sec:assemble_bos} \begin{lstlisting}[language=bash,literate={-}{-}1,keywords={},upquote=true,keepspaces,literate={BOSVER}{\baseos{}}1] -[sms](*\#*) copycds ${iso_path}/CentOS-7-x86_64-DVD-1804.iso +[sms](*\#*) copycds ${iso_path}/CentOS-7-x86_64-DVD-1810.iso \end{lstlisting} % end_ohpc_run @@ -24,9 +24,9 @@ creation process using the \texttt{copycds} command assuming that the necessary \begin{lstlisting}[language=bash,literate={-}{-}1,keywords={},upquote=true,keepspaces,literate={BOSVER}{\baseos{}}1] # Query available images [sms](*\#*) lsdef -t osimage -centos7.5-x86_64-install-compute (osimage) -centos7.5-x86_64-netboot-compute (osimage) -centos7.5-x86_64-statelite-compute (osimage) +centos7.6-x86_64-install-compute (osimage) +centos7.6-x86_64-netboot-compute (osimage) +centos7.6-x86_64-statelite-compute (osimage) \end{lstlisting} In this example, we leverage
Cortex-M7: Add SCB_InvalidateICache_by_Addr
@@ -2229,6 +2229,7 @@ __STATIC_INLINE uint32_t SCB_GetFPUType(void) #define CCSIDR_SETS(x) (((x) & SCB_CCSIDR_NUMSETS_Msk ) >> SCB_CCSIDR_NUMSETS_Pos ) #define __SCB_DCACHE_LINE_SIZE 32U /*!< Cortex-M7 cache line size is fixed to 32 bytes (8 words). See also register SCB_CCSIDR */ +#define __SCB_ICACHE_LINE_SIZE 32U /*!< Cortex-M7 cache line size is fixed to 32 bytes (8 words). See also register SCB_CCSIDR */ /** \brief Enable I-Cache @@ -2284,6 +2285,36 @@ __STATIC_FORCEINLINE void SCB_InvalidateICache (void) } +/** + \brief I-Cache Invalidate by address + \details Invalidates I-Cache for the given address. + I-Cache is invalidated starting from a 32 byte aligned address in 32 byte granularity. + I-Cache memory blocks which are part of given address + given size are invalidated. + \param[in] addr address + \param[in] isize size of memory block (in number of bytes) +*/ +__STATIC_FORCEINLINE void SCB_InvalidateICache_by_Addr (void *addr, int32_t isize) +{ + #if defined (__ICACHE_PRESENT) && (__ICACHE_PRESENT == 1U) + if ( isize > 0 ) { + int32_t op_size = isize + (((uint32_t)addr) & (__SCB_ICACHE_LINE_SIZE - 1U)); + uint32_t op_addr = (uint32_t)addr /* & ~(__SCB_ICACHE_LINE_SIZE - 1U) */; + + __DSB(); + + do { + SCB->ICIMVAU = op_addr; /* register accepts only 32byte aligned values, only bits 31..5 are valid */ + op_addr += __SCB_ICACHE_LINE_SIZE; + op_size -= __SCB_ICACHE_LINE_SIZE; + } while ( op_size > 0 ); + + __DSB(); + __ISB(); + } + #endif +} + + /** \brief Enable D-Cache \details Turns on D-Cache
oidc-token now uses only the static library
@@ -38,7 +38,7 @@ OBJECTS := $(SOURCES:$(SRCDIR)/%.c=$(OBJDIR)/%.o) AGENT_OBJECTS := $(filter-out $(OBJDIR)/$(ADD).o $(OBJDIR)/$(GEN).o $(OBJDIR)/$(CLIENT).o, $(OBJECTS)) GEN_OBJECTS := $(filter-out $(OBJDIR)/$(AGENT).o $(OBJDIR)/$(ADD).o $(OBJDIR)/$(CLIENT).o, $(OBJECTS)) ADD_OBJECTS := $(filter-out $(OBJDIR)/$(AGENT).o $(OBJDIR)/$(GEN).o $(OBJDIR)/$(CLIENT).o, $(OBJECTS)) -CLIENT_OBJECTS := $(filter-out $(OBJDIR)/$(AGENT).o $(OBJDIR)/$(GEN).o $(OBJDIR)/$(ADD).o, $(OBJECTS)) +CLIENT_OBJECTS := $(OBJDIR)/$(CLIENT).o $(OBJDIR)/utils/cleaner.o rm = rm -f all: dependencies build man oidcdir
Fix Makefile order dependency issue causing non-parallel to fail.
@@ -537,13 +537,7 @@ $(BUILD): $(FW_DIR): $(MKDIR) -p $@ -BOOTLOADER_OBJS: FIRMWARE_OBJS - $(MAKE) -C $(BOOTLDR_DIR) BUILD=$(BUILD)/$(BOOTLDR_DIR) CFLAGS="$(BOOTLDR_CFLAGS) -MMD" - -UVC_OBJS: FIRMWARE_OBJS - $(MAKE) -C $(UVC_DIR) BUILD=$(BUILD)/$(UVC_DIR) CFLAGS="$(UVC_CFLAGS) -MMD" - -FIRMWARE_OBJS: +FIRMWARE_OBJS: | $(BUILD) $(FW_DIR) $(MAKE) -C $(CMSIS_DIR) BUILD=$(BUILD)/$(CMSIS_DIR) CFLAGS="$(CFLAGS) -fno-strict-aliasing -MMD" $(MAKE) -C $(STHAL_DIR) BUILD=$(BUILD)/$(STHAL_DIR) CFLAGS="$(CFLAGS) -MMD" $(MAKE) -C $(MICROPY_DIR)/ports/stm32 BUILD=$(BUILD)/$(MICROPY_DIR) BOARD=$(TARGET) QSTR_DEFS="$(OMV_QSTR_DEFS)" @@ -555,6 +549,12 @@ ifeq ($(CUBEAI), 1) $(MAKE) -C $(CUBEAI_DIR) BUILD=$(BUILD)/$(CUBEAI_DIR) CFLAGS="$(CFLAGS) -fno-strict-aliasing -MMD" endif +UVC_OBJS: FIRMWARE_OBJS + $(MAKE) -C $(UVC_DIR) BUILD=$(BUILD)/$(UVC_DIR) CFLAGS="$(UVC_CFLAGS) -MMD" + +BOOTLOADER_OBJS: FIRMWARE_OBJS + $(MAKE) -C $(BOOTLDR_DIR) BUILD=$(BUILD)/$(BOOTLDR_DIR) CFLAGS="$(BOOTLDR_CFLAGS) -MMD" + # This target generates the main/app firmware image located at 0x08010000 $(FIRMWARE): FIRMWARE_OBJS $(CPP) -P -E -I$(OMV_BOARD_CONFIG_DIR) $(OMV_DIR)/stm32fxxx.ld.S > $(BUILD)/stm32fxxx.lds @@ -580,7 +580,7 @@ $(UVC): FIRMWARE_OBJS UVC_OBJS $(PYTHON) $(MKDFU) -b $(MAIN_APP_ADDR):$(FW_DIR)/$(UVC).bin $(FW_DIR)/$(UVC).dfu # This target generates a combined bootloader+main firmware image. -$(OPENMV): $(BOOTLOADER) $(UVC) $(FIRMWARE) | $(BUILD) $(FW_DIR) +$(OPENMV): $(BOOTLOADER) $(UVC) $(FIRMWARE) $(CAT) $(FW_DIR)/$(BOOTLOADER).bin $(FW_DIR)/$(FIRMWARE).bin > $(FW_DIR)/$(OPENMV).bin $(PYTHON) $(MKDFU) -b 0x08000000:$(FW_DIR)/$(BOOTLOADER).bin -b $(MAIN_APP_ADDR):$(FW_DIR)/$(FIRMWARE).bin $(FW_DIR)/$(OPENMV).dfu $(SIZE) $(FW_DIR)/$(BOOTLOADER).elf
Update theme_overrides.css Changed colors in css file, in order to make documentation website look like official website.
overflow: visible !important; } } + +.wy-side-nav-search { + background-color: #bd2c2a !important; +} + +.wy-nav-top { + background-color: #bd2c2a !important; +} + +.wy-nav-top:hover { + color: #333333 !important; +} + +.wy-nav-top a { + color: #fff !important; +} + +.wy-nav-top a:visited { + color: #fff !important; +} + +.wy-side-nav-search input[type=text] { + border-radius: 0px !important; + border-color: #333333 !important; +} + +.toctree-l1 { + color: #ffffff !important; +} + +.version { + color: #fff !important; +} + +.search { + border-radius: 10px !important; +} + +.icon-home:hover { + color: #333333 !important; +} + +.icon-home:visited { + color: #fff !important; +} + +.icon-home:hover:visited { + color: #333333 !important; + background-color: #bd2c2a !important; +} + +.wy-form { + border-radius: 0px !important; +} + +a:hover { + color: #bd2c2a !important; +} + +a:visited { + color: #429b9e !important; +} + +a:visited:hover { + color: #bd2c2a !important; +} + +.wy-nav-top a:hover { + color: #333333 !important; +}
Fix _Mapping
@@ -29,12 +29,12 @@ _V = TypeVar("_V") class _Mapping(Generic[_K, _V]): def __len__(self) -> int: ... def __contains__(self, key: _K) -> bool: ... - def __iter__(self) -> str: ... - def iterkeys(self) -> Iterator[str]: ... + def __iter__(self) -> Iterator[_K]: ... + def iterkeys(self) -> Iterator[_K]: ... def itervalues(self) -> Iterator[_V]: ... - def iteritems(self) -> Iterator[Tuple[str, _V]]: ... - def keys(self) -> List[str]: ... - def items(self) -> List[Tuple[str, _V]]: ... + def iteritems(self) -> Iterator[Tuple[_K, _V]]: ... + def keys(self) -> List[_K]: ... + def items(self) -> List[Tuple[_K, _V]]: ... def values(self) -> List[_V]: ... def __bool__(self) -> bool: ... def __getitem__(self, key: _K) -> _V: ... @@ -186,7 +186,7 @@ class VariantRecordInfo(_Mapping[str, _InfoValue]): def __delitem__(self, key: str) -> None: ... def clear(self) -> None: ... def update( - self, items: Optional[Mapping[str, _InfoValue]] = ..., **kwargs + self, items: Optional[_Mapping[str, _InfoValue]] = ..., **kwargs ) -> None: ... def pop(self, key: str, default: _D = ...) -> Union[_D, _InfoValue]: ... def __eq__(self, other) -> bool: ...
first pass of +on-publ compiles
|= [=ship =point =peer-state] ^+ event-core :: - !! + (insert-peer-state ship peer-state [life `@`encryption-key]:point) -- :: ++ insert-peer-state
multifile: add global keyset handle to storage plugin
@@ -318,6 +318,7 @@ static Codes initBackend (Plugin * handle, MultiConfig * mc, SingleConfig * s, K else { s->storage = storage; + storage->global = elektraPluginGetGlobalKeySet (handle); } return SUCCESS; }
fixed memory leak in SoloFeature_cellFiltering.cpp
@@ -74,8 +74,7 @@ void SoloFeature::cellFiltering() //calculate filtered statistics - bool *geneDetected = new bool[featuresNumber]; //=true if a gene was detected in at least one cell - memset((void*) geneDetected, 0, featuresNumber); + std::vector<uint32_t> geneDetected(featuresNumber, 0); //=1 if a gene was detected in at least one cell for (uint32 icb=0; icb<nCB; icb++) { if (filteredCells.filtVecBool[icb]) { @@ -94,7 +93,7 @@ void SoloFeature::cellFiltering() for (uint32 ig=0; ig<nGenePerCB[icb]; ig++) { uint32 indG1=countCellGeneUMIindex[icb]+ig*countMatStride; if (countCellGeneUMI[indG1 + pSolo.umiDedup.countInd.main] > 0) { - geneDetected[countCellGeneUMI[indG1]] = true; //gene is present if it's count > 0 for + geneDetected[countCellGeneUMI[indG1]] = 1; //gene is present if it's count > 0 for ng1++; }; }; @@ -110,7 +109,7 @@ void SoloFeature::cellFiltering() filteredCells.nGeneDetected=0; for (uint32 ii=0; ii<featuresNumber; ii++) { - if (geneDetected[ii]) + if (geneDetected[ii]>0) filteredCells.nGeneDetected++; }; @@ -118,8 +117,8 @@ void SoloFeature::cellFiltering() filteredCells.meanReadPerCellUnique = filteredCells.nReadInCellsUnique / filteredCells.nCells; filteredCells.meanGenePerCell = filteredCells.nGeneInCells / filteredCells.nCells; - sort(filteredCells.nReadPerCellUnique.begin(), filteredCells.nReadPerCellUnique.end()); - sort(filteredCells.nGenePerCell.begin(), filteredCells.nGenePerCell.end()); + std::sort(filteredCells.nReadPerCellUnique.begin(), filteredCells.nReadPerCellUnique.end()); + std::sort(filteredCells.nGenePerCell.begin(), filteredCells.nGenePerCell.end()); filteredCells.medianUMIperCell = nUMIperCBsorted[filteredCells.nCells/2]; filteredCells.medianGenePerCell = filteredCells.nGenePerCell[filteredCells.nCells/2];
Using aliasing.
@@ -37,9 +37,9 @@ typedef enum SceCtrlButtons { SCE_CTRL_DOWN = 0x00000040, //!< Down D-Pad button. SCE_CTRL_LEFT = 0x00000080, //!< Left D-Pad button. SCE_CTRL_LTRIGGER = 0x00000100, //!< Left trigger. - SCE_CTRL_L2 = 0x00000100, //!< L2 button. + SCE_CTRL_L2 = SCE_CTRL_LTRIGGER, //!< L2 button. SCE_CTRL_RTRIGGER = 0x00000200, //!< Right trigger. - SCE_CTRL_R2 = 0x00000200, //!< R2 button. + SCE_CTRL_R2 = SCE_CTRL_RTRIGGER, //!< R2 button. SCE_CTRL_L1 = 0x00000400, //!< L1 button. SCE_CTRL_R1 = 0x00000800, //!< R1 button. SCE_CTRL_TRIANGLE = 0x00001000, //!< Triangle button.
ci: revert disable esp32s2 timer test
@@ -69,6 +69,7 @@ TEST_CASE("light sleep followed by deep sleep", "[deepsleep][reset=DEEPSLEEP_RES esp_light_sleep_start(); esp_deep_sleep_start(); } +#endif // !TEMPORARY_DISABLED_FOR_TARGETS(ESP32S2, ESP32C3) TEST_CASE("wake up from light sleep using timer", "[deepsleep]") { @@ -81,7 +82,6 @@ TEST_CASE("wake up from light sleep using timer", "[deepsleep]") (tv_stop.tv_usec - tv_start.tv_usec) * 1e-3f; TEST_ASSERT_INT32_WITHIN(500, 2000, (int) dt); } -#endif // !TEMPORARY_DISABLED_FOR_TARGETS(ESP32S2, ESP32C3) static void test_light_sleep(void* arg) {
odissey: handle basic console SET command
@@ -63,7 +63,8 @@ enum OD_LSHOW, OD_LSTATS, OD_LSERVERS, - OD_LCLIENTS + OD_LCLIENTS, + OD_LSET }; static od_keyword_t od_console_keywords[] = @@ -72,6 +73,7 @@ static od_keyword_t od_console_keywords[] = od_keyword("stats", OD_LSTATS), od_keyword("servers", OD_LSERVERS), od_keyword("clients", OD_LCLIENTS), + od_keyword("set", OD_LSET), { 0, 0, 0 } }; @@ -498,6 +500,22 @@ od_console_query_show(od_client_t *client, od_parser_t *parser) return -1; } +static inline int +od_console_query_set(od_client_t *client, od_parser_t *parser) +{ + shapito_stream_t *stream = &client->stream; + shapito_stream_reset(stream); + (void)parser; + int rc; + rc = shapito_be_write_complete(stream, "SET", 4); + if (rc == -1) + return -1; + rc = shapito_be_write_ready(stream, 'I'); + if (rc == -1) + return -1; + return 0; +} + static inline int od_console_query(od_console_t *console, od_msgconsole_t *msg_console) { @@ -537,6 +555,11 @@ od_console_query(od_console_t *console, od_msgconsole_t *msg_console) if (rc == -1) goto bad_command; break; + case OD_LSET: + rc = od_console_query_set(client, &parser); + if (rc == -1) + goto bad_command; + break; default: goto bad_command; }
options/posix: Define UIO_MAXIOV
#include <bits/ssize_t.h> #include <bits/off_t.h> #include <bits/size_t.h> +#include <limits.h> #ifdef __cplusplus extern "C" { #endif +#define UIO_MAXIOV IOV_MAX + ssize_t readv(int fd, const struct iovec *iov, int iovcnt); ssize_t writev(int fd, const struct iovec *iov, int iovcnt);
[core] ensure socket ready before checking connect ensure socket ready for writing before checking connect() status (sanity check in case request gets rescheduled for another reason before the socket is ready for writing)
@@ -1972,6 +1972,8 @@ static handler_t gw_write_request(gw_handler_ctx * const hctx, request_st * cons __attribute_fallthrough__ case GW_STATE_CONNECT_DELAYED: if (hctx->state == GW_STATE_CONNECT_DELAYED) { /*(not GW_STATE_INIT)*/ + if (!(fdevent_fdnode_interest(hctx->fdn) & FDEVENT_OUT)) + return HANDLER_WAIT_FOR_EVENT; int socket_error = fdevent_connect_status(hctx->fd); if (socket_error != 0) { gw_proc_connect_error(r, hctx->host, hctx->proc, hctx->pid,
properly zero-initialize u3_wcon linked-list pointer
@@ -2082,8 +2082,9 @@ static u3_wcon* _proxy_wcon_new(u3_ward* rev_u) { u3_wcon* won_u = c3_malloc(sizeof(*won_u)); - won_u->rev_u = rev_u; won_u->upt_u.data = won_u; + won_u->rev_u = rev_u; + won_u->nex_u = 0; _proxy_wcon_link(won_u, rev_u);
libhfuzz: param 'new' -> 'n'
@@ -46,7 +46,7 @@ extern "C" { * addr: address of original comparison * n: new value (only if better than the old/current value) */ - void instrumentCmpMap(void *addr, unsigned int new); + void instrumentCmpMap(void *addr, unsigned int n); #if defined(__linux__)
Refomat a few comments on 80 cols
@@ -277,8 +277,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in, if (!BN_uadd(Y, Y, X)) goto err; /* - * as above, BN_mod_add_quick(Y, Y, X, n) would slow things - * down + * as above, BN_mod_add_quick(Y, Y, X, n) would slow things down */ if (!BN_usub(A, A, B)) goto err; @@ -348,8 +347,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in, * (**) sign*Y*a == D*B + M (mod |n|). */ - tmp = A; /* keep the BIGNUM object, the value does not - * matter */ + tmp = A; /* keep the BIGNUM object, the value does not matter */ /* (A, B) := (B, A mod B) ... */ A = B; @@ -377,8 +375,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in, */ /* - * most of the time D is very small, so we can optimize tmp := - * D*X+Y + * most of the time D is very small, so we can optimize tmp := D*X+Y */ if (BN_is_one(D)) { if (!BN_add(tmp, X, Y)) @@ -403,8 +400,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in, goto err; } - M = Y; /* keep the BIGNUM object, the value does not - * matter */ + M = Y; /* keep the BIGNUM object, the value does not matter */ Y = X; X = tmp; sign = -sign;
removes %ames vein/pubs/packet-drop printfs
?| ?=(~ fod) ?=(~ lew.wod.u.fod) == == == == - ~& [%chew-no-will %drop her] (emit %beer our ?:(?=(%earl rac) seg her)) =/ oub bust:puz =/ neg =(~ yed.caq.dur.diz) ?. ?=([%our @ %her @ ~] tea) ~& [%strange-pubs tea] [~ +>] - ~& [%hear-pubs tea sih] =/ our=ship (slav %p i.t.tea) =/ her=ship (slav %p i.t.t.t.tea) =/ gus (need (~(us go ton.fox) our)) ?. ?=([%our @ ~] tea) ~& [%strange-vein tea] [~ +>] - ~& [%hear-vein tea sih] =/ our=ship (slav %p i.t.tea) =. fox (~(vein am [now fox ski]) our life.sih vein.sih) [~ +>.$]
ToolStatus: Improve statusbar update performance
@@ -674,10 +674,16 @@ VOID StatusBarUpdate( ReleaseDC(StatusBarHandle, hdc); + // Note: Suspend redrawing until after updating the statusbar text + // otherwise SB_SETTEXT repaints multiple times during our loop. (dmex) + SendMessage(StatusBarHandle, WM_SETREDRAW, FALSE, 0); SendMessage(StatusBarHandle, SB_SETPARTS, count, (LPARAM)widths); for (i = 0; i < count; i++) { SendMessage(StatusBarHandle, SB_SETTEXT, i, (LPARAM)text[i]); } + + SendMessage(StatusBarHandle, WM_SETREDRAW, TRUE, 0); + InvalidateRect(StatusBarHandle, NULL, TRUE); }
ames: don't scry dudes for every peer
?. dry core %.(core (slog leaf/"ames: #{<corks>} flows can be corked" ~)) :: + =/ dudes ;; (map dude:gall nonce=@) + =< q.q %- need %- need + (rof ~ %gf `beam`[[our %$ da+now] /]) + :: %+ roll ~(tap by peers.ames-state) |= [[=ship =ship-state] corks=@ core=_event-core] ?. ?=(%known -.ship-state) corks^core =/ =peer-state:ames ?>(?=(%known -.ship-state) +.ship-state) - =/ dudes ;; (map dude:gall nonce=@) - =< q.q %- need %- need - (rof ~ %gf `beam`[[our %$ da+now] /]) - :: =/ subs=(jar path [bone sub-nonce=@]) %+ roll ~(tap by snd.peer-state) |= [[=forward=bone *] subs=(jar path [bone sub-nonce=@])]
test ren/ on CI
@@ -29,6 +29,21 @@ Promise.resolve urbit errs := Object.keys errs if errs.length => throw Error "in #errs" urb.reset-listeners! +.then (urb)-> + urb.note "Testing renderers" + errs = {} #REVIEW stream reduce? + cur = "init" + urb.every />> (\[[ -~]+)/ ([_,ren])-> cur := ren + urb.every ERROR, -> + unless errs[cur] + errs[cur] = true + urb.warn "Renderer error detected" + # + <- urb.line ":test [%renders /]" .then + <- urb.expect-echo "%renderers-tested" .then + errs := Object.keys errs + if errs.length => throw Error "in #errs" + urb.reset-listeners! .then (urb)-> urb.note "Running /===/tests" errs = "" #REVIEW stream reduce?
stm32/i2c: Fix bug with I2C4 initialisation.
@@ -222,7 +222,7 @@ void i2c_init0(void) { #endif #if defined(MICROPY_HW_I2C4_SCL) memset(&I2CHandle4, 0, sizeof(I2C_HandleTypeDef)); - I2CHandle3.Instance = I2C4; + I2CHandle4.Instance = I2C4; #endif } @@ -258,7 +258,7 @@ void i2c_init(I2C_HandleTypeDef *i2c) { i2c_unit = 4; scl_pin = &MICROPY_HW_I2C4_SCL; sda_pin = &MICROPY_HW_I2C4_SDA; - __I2C3_CLK_ENABLE(); + __I2C4_CLK_ENABLE(); #endif } else { // I2C does not exist for this board (shouldn't get here, should be checked by caller)
[chainmaker][#436][tests]modify paramters struct name
@@ -24,27 +24,27 @@ static BOAT_RESULT chainmakerWalletPrepare(void) BOAT_RESULT index; //set user private key context - wallet_config.user_prikey_config.prikey_genMode = BOAT_WALLET_PRIKEY_GENMODE_EXTERNAL_INJECTION; - wallet_config.user_prikey_config.prikey_type = BOAT_WALLET_PRIKEY_TYPE_SECP256R1; - wallet_config.user_prikey_config.prikey_format = BOAT_WALLET_PRIKEY_FORMAT_PKCS; - wallet_config.user_prikey_config.prikey_content.field_ptr = (BUINT8 *)chainmaker_user_key; - wallet_config.user_prikey_config.prikey_content.field_len = strlen(chainmaker_user_key) + 1; + wallet_config.user_prikey_cfg.prikey_genMode = BOAT_WALLET_PRIKEY_GENMODE_EXTERNAL_INJECTION; + wallet_config.user_prikey_cfg.prikey_type = BOAT_WALLET_PRIKEY_TYPE_SECP256R1; + wallet_config.user_prikey_cfg.prikey_format = BOAT_WALLET_PRIKEY_FORMAT_PKCS; + wallet_config.user_prikey_cfg.prikey_content.field_ptr = (BUINT8 *)chainmaker_user_key; + wallet_config.user_prikey_cfg.prikey_content.field_len = strlen(chainmaker_user_key) + 1; //set user cert context - wallet_config.user_cert_content.length = strlen(chainmaker_user_cert); - memcpy(wallet_config.user_cert_content.content, chainmaker_user_cert, wallet_config.user_cert_content.length); + wallet_config.user_cert_cfg.length = strlen(chainmaker_user_cert); + memcpy(wallet_config.user_cert_cfg.content, chainmaker_user_cert, wallet_config.user_cert_cfg.length); //set url and name #ifdef TEST_CHAINMAKER__NODE_URL - strncpy(wallet_config.node_url_arry, TEST_CHAINMAKER__NODE_URL, strlen(TEST_CHAINMAKER__NODE_URL)); + strncpy(wallet_config.node_url_cfg, TEST_CHAINMAKER__NODE_URL, strlen(TEST_CHAINMAKER__NODE_URL)); #else - strncpy(wallet_config.node_url_arry, test_chainmaker_node_url, strlen(test_chainmaker_node_url)); + strncpy(wallet_config.node_url_cfg, test_chainmaker_node_url, strlen(test_chainmaker_node_url)); #endif - strncpy(wallet_config.host_name_arry, test_chainmaker_host_name, strlen(test_chainmaker_host_name)); + strncpy(wallet_config.host_name_cfg, test_chainmaker_host_name, strlen(test_chainmaker_host_name)); //tls ca cert - wallet_config.org_tls_ca_cert.length = strlen(chainmaker_tls_ca_cert); - memcpy(wallet_config.org_tls_ca_cert.content, chainmaker_tls_ca_cert, wallet_config.org_tls_ca_cert.length); + wallet_config.tls_ca_cert_cfg.length = strlen(chainmaker_tls_ca_cert); + memcpy(wallet_config.tls_ca_cert_cfg.content, chainmaker_tls_ca_cert, wallet_config.tls_ca_cert_cfg.length); // create wallet #if defined(USE_ONETIME_WALLET)
Don't search through <FlatList /> component if meta/ctrl is being held while typing
@@ -81,6 +81,9 @@ export const FlatList = <T extends FlatListItem>({ if (!hasFocus) { return; } + if (e.metaKey || e.ctrlKey) { + return; + } if (e.key === "ArrowDown") { e.preventDefault(); throttledNext.current(items, selectedId || "");
Add comment on lzw.decoder.suffixes performance
@@ -17,7 +17,13 @@ pub status "?bad code" pri status "?internal error: inconsistent I/O" // TODO: move bulk data buffers like decoder.suffixes or decoder.output into -// the workbuf? +// the workbuf? The first attempt at this was a performance regression for +// decoding all but the smallest GIFs. See these git commits for numbers: +// - 49627b4 Flatten the lzw.decoder.suffixes array +// - f877fb2 Use the workbuf instead of lzw.decoder.suffixes +// - 85be5b9 Delete the obsolete lzw.decoder.suffixes array +// and the roll back has combined numbers: +// - 3056a84 Roll back 3 recent lzw.decoder.suffixes commits pub const decoder_workbuf_len_max_incl base.u64 = 0 pub struct decoder?(
add object dictionary
#include "module_structs.h" #include "robus_struct.h" #include "routingTable.h" +#include "luos_od.h" /** * \fn void luos_init(void)
Replaced other uses of int that take values other than 0
* - Key shares for named groups not in the client's supported_groups extension. **/ -int s2n_client_key_share_extension_size; +uint32_t s2n_client_key_share_extension_size; static int s2n_ecdhe_supported_curves_send(struct s2n_connection *conn, struct s2n_stuffer *out); @@ -54,7 +54,7 @@ int s2n_client_key_share_init() + S2N_SIZE_OF_EXTENSION_DATA_SIZE + S2N_SIZE_OF_CLIENT_SHARES_SIZE; - for (int i = 0; i < S2N_ECC_SUPPORTED_CURVES_COUNT; i++) { + for (uint32_t i = 0; i < S2N_ECC_SUPPORTED_CURVES_COUNT; i++) { s2n_client_key_share_extension_size += S2N_SIZE_OF_KEY_SHARE_SIZE + S2N_SIZE_OF_NAMED_GROUP; s2n_client_key_share_extension_size += s2n_ecc_supported_curves[i]->share_size; } @@ -74,7 +74,7 @@ int s2n_extensions_client_key_share_recv(struct s2n_connection *conn, struct s2n const struct s2n_ecc_named_curve *supported_curve; struct s2n_blob point_blob; uint16_t named_group, share_size; - int supported_curve_index; + uint32_t supported_curve_index; /* bytes_processed is declared as a uint32_t to avoid integer overflow in later calculations */ uint32_t bytes_processed = 0; @@ -87,7 +87,7 @@ int s2n_extensions_client_key_share_recv(struct s2n_connection *conn, struct s2n bytes_processed += share_size + S2N_SIZE_OF_NAMED_GROUP + S2N_SIZE_OF_KEY_SHARE_SIZE; supported_curve = NULL; - for (int i = 0; i < S2N_ECC_SUPPORTED_CURVES_COUNT; i++) { + for (uint32_t i = 0; i < S2N_ECC_SUPPORTED_CURVES_COUNT; i++) { if (named_group == s2n_ecc_supported_curves[i]->iana_id) { supported_curve_index = i; supported_curve = s2n_ecc_supported_curves[i]; @@ -126,7 +126,7 @@ int s2n_extensions_client_key_share_recv(struct s2n_connection *conn, struct s2n return 0; } -int s2n_extensions_client_key_share_size(struct s2n_connection *conn) +uint32_t s2n_extensions_client_key_share_size(struct s2n_connection *conn) { return s2n_client_key_share_extension_size; } @@ -157,7 +157,7 @@ static int s2n_ecdhe_supported_curves_send(struct s2n_connection *conn, struct s const struct s2n_ecc_named_curve *named_curve = NULL; struct s2n_ecc_params *ecc_params = NULL; - for (int i = 0; i < S2N_ECC_SUPPORTED_CURVES_COUNT; i++) { + for (uint32_t i = 0; i < S2N_ECC_SUPPORTED_CURVES_COUNT; i++) { ecc_params = &conn->secure.client_ecc_params[i]; named_curve = s2n_ecc_supported_curves[i];
[software] Correct __PACK2 builtin
@@ -16,7 +16,7 @@ typedef unsigned char v4u __attribute__((vector_size(4))); inline v2s __PACK2(const int32_t x, const int32_t y) { v2s output; - asm volatile("pv.pack.h %[z], %[x], %[y];" + asm volatile("pv.pack %[z], %[x], %[y];" : [z] "=r"(output) : [x] "r"(x), [y] "r"(y)); return output;
Added usb packet statistics
@@ -142,6 +142,7 @@ struct SurviveUSBInterface usb_callback cb; int which_interface_am_i; //for indexing into uiface const char * hname; //human-readable names + size_t packet_count; }; struct SurviveViveData @@ -155,6 +156,7 @@ struct SurviveViveData og_thread_t servicethread[MAX_USB_DEVS]; #else struct libusb_context* usbctx; + size_t read_count; #endif }; @@ -214,6 +216,7 @@ static void handle_transfer(struct libusb_transfer* transfer) iface->actual_len = transfer->actual_length; iface->cb( iface ); + iface->packet_count++; if( libusb_submit_transfer(transfer) ) { @@ -776,6 +779,7 @@ int survive_vive_usb_poll( SurviveContext * ctx, void * v ) return 0; #else SurviveViveData * sv = v; + sv->read_count++; int r = libusb_handle_events( sv->usbctx ); if( r ) {
anx7447: Read ANX7447 firmware version Add ANX7447 firmware version reading for new adding PD firmware. BRANCH=None TEST=make buildall -j Tested-by: Jimmy Wu
@@ -847,6 +847,34 @@ static void anx7447_dump_registers(int port) } #endif /* defined(CONFIG_CMD_TCPC_DUMP) */ + +static int anx7447_get_chip_info(int port, int live, + struct ec_response_pd_chip_info_v1 *chip_info) +{ + int rv = tcpci_get_chip_info(port, live, chip_info); + int val; + + if (rv) + return rv; + + if (chip_info->fw_version_number == -1 || live) { + /* + * Before reading ANX7447 SPI slave address 0x7e for + * new added FW version, need to read ANX7447 I2c + * slave address 0x58 first to wake up ANX7447. + */ + tcpc_read(port, ANX7447_REG_OCM_VERSION, &val); + rv = anx7447_reg_read(port, ANX7447_REG_OCM_VERSION, &val); + + if (rv) + return rv; + if (val != 0) + chip_info->fw_version_number = val; + } + + return rv; +} + /* * ANX7447 is a TCPCI compatible port controller, with some caveats. * It seems to require both CC lines to be set always, instead of just @@ -880,7 +908,7 @@ const struct tcpm_drv anx7447_tcpm_drv = { #ifdef CONFIG_USB_PD_DUAL_ROLE_AUTO_TOGGLE .drp_toggle = anx7447_tcpc_drp_toggle, #endif - .get_chip_info = &tcpci_get_chip_info, + .get_chip_info = &anx7447_get_chip_info, .set_snk_ctrl = &tcpci_tcpm_set_snk_ctrl, .set_src_ctrl = &tcpci_tcpm_set_src_ctrl, #ifdef CONFIG_USB_PD_TCPC_LOW_POWER
hslua-marshalling: do not check type in peek*Raw This is the responsibility of the wrapping peeker.
@@ -282,7 +282,7 @@ peekSet elementPeeker = withContext "Set" -- | Get value at key from a table. peekFieldRaw :: LuaError e => Peeker e a -> Name -> Peeker e a -peekFieldRaw peeker name = typeChecked "table" Lua.istable $ \idx -> +peekFieldRaw peeker name idx = retrieving ("raw field '" <> name <> "'") $! do liftLua $ do absidx <- Lua.absindex idx @@ -293,7 +293,7 @@ peekFieldRaw peeker name = typeChecked "table" Lua.istable $ \idx -> -- | Get value at integer index key from a table. peekIndexRaw :: LuaError e => Lua.Integer -> Peeker e a -> Peeker e a -peekIndexRaw i peeker = typeChecked "table" Lua.istable $ \idx -> do +peekIndexRaw i peeker idx = do let showInt (Lua.Integer x) = fromString $ show x retrieving (fromString $ "raw index '" <> showInt i <> "'") $! do liftLua $ rawgeti idx i
stm32/usb: Remove mp_hal_set_interrupt_char now that it's reset at boot.
@@ -115,7 +115,6 @@ void pyb_usb_init0(void) { #if MICROPY_HW_USB_ENABLE_CDC2 usb_device.usbd_cdc2_itf.attached_to_repl = false; #endif - mp_hal_set_interrupt_char(-1); MP_STATE_PORT(pyb_hid_report_desc) = MP_OBJ_NULL; }
doc: Add news entry for KDBError & keyset!
@@ -205,6 +205,8 @@ you up to date with the multi-language support provided by Elektra. - Add the `elektra-sys` crate which contains raw bindings to libelektra for Rust. _(Philipp Gackstatter)_ - Add the `elektra` crate which contains safe wrapper methods for the raw bindings. The crate contains bindings for the low-level API, which means that the data types `Key` and `KeySet` can now safely be used from Rust. The Rust version of the API has been designed to take advantage of Rust's type system and to be in accordance with the memory safety of Rust. For instance, the Key has been divided into `StringKey` and `BinaryKey`, to prevent type mismatches at compile time. With the binding for `KDB`, one can take advantage of the elektra ecosystem from Rust. See the [Readme](../../src/bindings/rust/README.md) for more. _(Philipp Gackstatter)_ - The [elektra](https://crates.io/crates/elektra) and [elektra-sys](https://crates.io/crates/elektra-sys) crates have been published to crates.io for easier usage. _(Philipp Gackstatter)_ +- Rewrote the `KDBError` to follow the specification fully and in particular allow catching out of memory errors by catching resource errors. +- Added a `keyset!` macro to easily create a keyset with many keys in a single invocation. ### <<Binding3>>
linux-raspberrypi: bump to Linux version 4.19.113
-LINUX_VERSION ?= "4.19.108" +LINUX_VERSION ?= "4.19.113" LINUX_RPI_BRANCH ?= "rpi-4.19.y" -SRCREV = "4137a0c092ab26fd3b40f49b321988e99800d085" +SRCREV = "4f2a4cc501c428c940549f39d5562e60404ac4f7" require linux-raspberrypi_4.19.inc
board/casta/board.c: Format with clang-format BRANCH=none TEST=none
@@ -65,10 +65,10 @@ static void ppc_interrupt(enum gpio_signal signal) /* ADC channels */ const struct adc_t adc_channels[] = { - [ADC_TEMP_SENSOR_AMB] = { - "TEMP_AMB", NPCX_ADC_CH0, ADC_MAX_VOLT, ADC_READ_MAX+1, 0}, - [ADC_TEMP_SENSOR_CHARGER] = { - "TEMP_CHARGER", NPCX_ADC_CH1, ADC_MAX_VOLT, ADC_READ_MAX+1, 0}, + [ADC_TEMP_SENSOR_AMB] = { "TEMP_AMB", NPCX_ADC_CH0, ADC_MAX_VOLT, + ADC_READ_MAX + 1, 0 }, + [ADC_TEMP_SENSOR_CHARGER] = { "TEMP_CHARGER", NPCX_ADC_CH1, + ADC_MAX_VOLT, ADC_READ_MAX + 1, 0 }, }; BUILD_ASSERT(ARRAY_SIZE(adc_channels) == ADC_CH_COUNT); @@ -108,8 +108,7 @@ static timestamp_t battery_last_i2c_time; static int is_battery_i2c(const int port, const uint16_t addr_flags) { - return (port == I2C_PORT_BATTERY) - && (addr_flags == BATTERY_ADDR_FLAGS); + return (port == I2C_PORT_BATTERY) && (addr_flags == BATTERY_ADDR_FLAGS); } static int is_battery_port(int port) @@ -174,7 +173,6 @@ static void set_input_limit_on_ac_removal(void) return; charger_set_input_current_limit(0, CONFIG_CHARGER_INPUT_CURRENT); - } DECLARE_HOOK(HOOK_AC_CHANGE, set_input_limit_on_ac_removal, HOOK_PRIO_DEFAULT);
clean up outgoing requests in security drivers
$them :: outbound request ?~ p.kyz =+ sud=(need (~(get by kes) hen)) - %= +>.$ + =. +>.$ + %_ +>.$ mow :_(mow [ged [%give %thus sud ~]]) q.ask (~(del by q.ask) sud) kes (~(del by kes) hen) == + :: + =/ driver=(unit [key=[user (list @t)] val=driv]) + =/ drivers ~(tap by sec) + |- ^- (unit [key=[user (list @t)] val=driv]) + ?~ drivers ~ + :: + ?~ q=req.q.q.i.drivers + $(drivers t.drivers) + :: + ?~ tip=~(top to q) + $(drivers t.drivers) + :: + ?: =(hen p.u.tip) + `i.drivers + $(drivers t.drivers) + :: + ?~ driver + +>.$ + ~(cancel-request vi u.driver) :: ~& eyre-them+(en-purl p.u.p.kyz) %= +>.$ mow :_(mow [ged [%give %thus p.ask p.kyz]]) =. liv | :: block requests until a reponse is given (eyre-them wir (slam !>(|=({$send a/hiss} a)) res)) :: + ++ cancel-request ~& %cancel-request + (dead-hiss(liv &) [leaf+"canceled"]~) + :: ++ handle-moves |= a/(list {p/term q/$-(vase _abet)}) |= b/vase
CMSIS-Core(M): Fixed ARM MPU implementation for Cortex-M0+. Cortex-M0+ does not have a dedicated memory fault and used hard fault instead.
@@ -108,7 +108,9 @@ __STATIC_INLINE void ARM_MPU_Enable(uint32_t MPU_Control) __DSB(); __ISB(); MPU->CTRL = MPU_Control | MPU_CTRL_ENABLE_Msk; +#ifdef SCB_SHCSR_MEMFAULTENA_Msk SCB->SHCSR |= SCB_SHCSR_MEMFAULTENA_Msk; +#endif } /** Disable the MPU. @@ -117,7 +119,9 @@ __STATIC_INLINE void ARM_MPU_Disable() { __DSB(); __ISB(); +#ifdef SCB_SHCSR_MEMFAULTENA_Msk SCB->SHCSR &= ~SCB_SHCSR_MEMFAULTENA_Msk; +#endif MPU->CTRL &= ~MPU_CTRL_ENABLE_Msk; }
Use printer-make-and-model value for USB gadget.
@@ -735,6 +735,45 @@ enable_usb_printer( // Get the information for this printer - vendor ID, product ID, etc. num_devid = papplDeviceParseID(printer->device_id, &devid); + if (printer->driver_data.make_and_model[0]) + { + // Get the make and model from the driver info... + char *ptr; // Pointer into make-and-model + + strlcpy(mfg, printer->driver_data.make_and_model, sizeof(mfg)); + if ((ptr = strstr(mfg, "Hewlett Packard")) != NULL) + ptr += 15; + else + ptr = strchr(mfg, ' '); + + if (ptr && *ptr) + { + // Split make from model... + while (*ptr && isspace(*ptr & 255)) + *ptr++ = '\0'; + + if (*ptr) + strlcpy(mdl, ptr, sizeof(mdl)); + else + strlcpy(mdl, "Printer", sizeof(mdl)); + } + else + { + // No whitespace so assume the make-and-model is just the make and use + // the device ID for the model (with a default of "Printer")... + val = cupsGetOption("MODEL", num_devid, devid); + if (!val) + val = cupsGetOption("MDL", num_devid, devid); + + if (val) + strlcpy(mdl, val, sizeof(mdl)); + else + strlcpy(mdl, "Printer", sizeof(mdl)); + } + } + else + { + // Get the make and model from the device ID fields. val = cupsGetOption("MANUFACTURER", num_devid, devid); if (!val) val = cupsGetOption("MFG", num_devid, devid); @@ -754,6 +793,7 @@ enable_usb_printer( strlcpy(mdl, val, sizeof(mdl)); else strlcpy(mdl, "Printer", sizeof(mdl)); + } val = cupsGetOption("SERIALNUMBER", num_devid, devid); if (!val) @@ -764,6 +804,8 @@ enable_usb_printer( val = cupsGetOption("SERN", num_devid, devid); if (!val && (val = strstr(printer->device_uri, "?serial=")) != NULL) val += 8; + if (!val && (val = strstr(printer->device_uri, "?uuid=")) != NULL) + val += 6; if (val) strlcpy(sn, val, sizeof(sn));
doc/man3: remove copy&paste leftover Fixes
@@ -51,9 +51,6 @@ X509_NAME_ENTRY_get_object() and X509_NAME_ENTRY_get_data() can be used to examine an B<X509_NAME_ENTRY> function as returned by X509_NAME_get_entry() for example. -X509_NAME_ENTRY_create_by_txt(), X509_NAME_ENTRY_create_by_NID(), -and X509_NAME_ENTRY_create_by_OBJ() create and return an - X509_NAME_ENTRY_create_by_txt(), X509_NAME_ENTRY_create_by_OBJ(), X509_NAME_ENTRY_create_by_NID() and X509_NAME_ENTRY_set_data() are seldom used in practice because B<X509_NAME_ENTRY> structures
Add num_threads to wgs64
@@ -23,6 +23,12 @@ int main(void) { { // nothing } + #pragma omp target teams distribute parallel for num_threads(64) + for (int k =0; k < n; k++) + { + // nothing + } + printf("Succeeded\n"); printf("Succeeded\n"); return fail;
config-tools: add validation to vuart widget vuart widget don't have empty line check for required fields. Added in this patch.
<label>VM name: </label> </b-col> <b-col md="4"> - <b-form-select v-model="VUARTConn.endpoint[0].vm_name" :options="vmNames"></b-form-select> + <b-form-select :state="validation(VUARTConn.endpoint[0].vm_name)" v-model="VUARTConn.endpoint[0].vm_name" :options="vmNames"></b-form-select> + <b-form-invalid-feedback> + must have value + </b-form-invalid-feedback> </b-col> </b-row> <label>VM name: </label> </b-col> <b-col md="4"> - <b-form-select v-model="VUARTConn.endpoint[1].vm_name" :options="vmNames"></b-form-select> + <b-form-select :state="validation(VUARTConn.endpoint[1].vm_name)" v-model="VUARTConn.endpoint[1].vm_name" :options="vmNames"></b-form-select> + <b-form-invalid-feedback> + must have value + </b-form-invalid-feedback> </b-col> </b-row> <label>Type: </label> </b-col> <b-col md="4"> - <b-form-select v-model="VUARTConn.type" :options="VuartType"></b-form-select> + <b-form-select :state="validation(VUARTConn.type)" v-model="VUARTConn.type" :options="VuartType"></b-form-select> + <b-form-invalid-feedback> + must have value + </b-form-invalid-feedback> </b-col> </b-row> @@ -143,6 +152,9 @@ export default { } }, methods: { + validation(value) { + return value.length != 0; + }, removeVUARTConnection(index) { this.defaultVal.splice(index, 1); },
lpc55xx_hic: Add documentation for MCU-LINK and MCU-LINK-PRO support
@@ -31,17 +31,60 @@ Reference design is based on [MCU-Link](https://www.nxp.com/design/development-b | SWDIO / TMS | I/O | PIO0_2 | 52 | | SWO / TDO | I | PIO0_3 | 53 | | TDI | O | PIO0_1 | 2 | -| nRESET | O | PIO0_19 | 58 | +| nRESET | I/O | PIO0_19 | 58 | | GNDDetect | I | PIO0_22 | 50 | | UART | | UART RX | I | PIO0_24 | 45 | | UART TX | O | PIO0_25 | 51 | -| Button | -| NF-RST But. | I | PIO0_18 | 38 | -| F-RST But. | I | PIO1_27 | 18 | | LEDs | | Con. LED | O | PIO0_5 | 56 | Additional pins are used to drive external circuitry: - SWDIO TX Enable (PIO0_28, pin 44) - nRESET Output Enable (PIO0_13, pin 46) + +## MCU-LINK and MCU-LINK-PRO support + +The `lpc55s69_mculink_bl` and `lpc55s69_mculink_if` images support both +MCU-LINK and MCU-LINK-PRO boards. Installation of the bootloader can be +done by putting the board in firmware update mode and using the NXP +`blhost` tool: + +``` +$ blhost --usb 0x1fc9,0x0021 flash-image lpc55s69_mculink_bl_crc.hex erase +``` + +### MCU-LINK "Buttoms" + +The MCU-LINK does not have amy buttons, but both board have "Disable VCOM" +and "Disable SWD" respectively mapped to non-forwarding reset and +forwarding reset functionality in DAPLink. + +| Signal | I/O | Symbol | Pin | +|-------------|:---:|---------|:---:| +| Button | +| NF-RST But. | I | PIO0_18 | 38 | +| F-RST But. | I | PIO0_27 | 18 | + +### MCU-LINK-PRO detection and LEDs + +The [MCU-LINK-PRO](https://www.nxp.com/design/microcontrollers-developer-resources/mcu-link-pro-debug-probe:MCU-LINK-PRO) +defines board type detection using `HW_VER_4` and `HW_VER_3`. When +`HW_VER_4` and `HW_VER_3` are respectively low and high, we determine that +the board is a MCU-LINK-PRO, otherwise we assume the board is a MCU-LINK. +MCU-LINK only has one red activity LED. MCU-LINK-PRO has 7 LEDs (1 red +and 6 green), 5 are currently used by DAPLink (see table below). + +| Signal | I/O | Symbol | +|---------------|:---:|---------| +| Detection | +| HW_VER_4 | I | PIO1_5 | +| HW_VER_3 | I | PIO1_4 | +| LEDs | +| Con. LED (r) | O | PIO0_5 | +| Run. LED (g) | O | PIO1_17 | +| HID LED (g) | O | PIO1_13 | +| CDC LED (g) | O | PIO1_18 | +| MSC LED (g) | O | PIO1_15 | +| N/A LED 1 (g) | O | PIO1_12 | +| N/A LED 2 (g) | O | PIO1_12 |
Rename cmd to argv This is more explicit. PR <https://github.com/Genymobile/scrcpy/pull/2405>
@@ -102,23 +102,23 @@ show_adb_err_msg(enum process_result err, const char *const argv[]) { process_t adb_execute(const char *serial, const char *const adb_cmd[], size_t len) { - const char *cmd[len + 4]; + const char *argv[len + 4]; int i; process_t process; - cmd[0] = get_adb_command(); + argv[0] = get_adb_command(); if (serial) { - cmd[1] = "-s"; - cmd[2] = serial; + argv[1] = "-s"; + argv[2] = serial; i = 3; } else { i = 1; } - memcpy(&cmd[i], adb_cmd, len * sizeof(const char *)); - cmd[len + i] = NULL; - enum process_result r = process_execute(cmd, &process); + memcpy(&argv[i], adb_cmd, len * sizeof(const char *)); + argv[len + i] = NULL; + enum process_result r = process_execute(argv, &process); if (r != PROCESS_SUCCESS) { - show_adb_err_msg(r, cmd); + show_adb_err_msg(r, argv); return PROCESS_NONE; } return process;
disable osd gesture when osd is in-active
@@ -81,12 +81,13 @@ void gestures() { ledcommand = 1; state.aux[AUX_CHANNEL_GESTURE] = 0; } + +#ifdef ENABLE_OSD if (command == GESTURE_LRL) { while (osd_pop_screen() != OSD_SCREEN_CLEAR) ; } -#ifdef ENABLE_OSD if (command == GESTURE_OSD_UP) { osd_handle_input(OSD_INPUT_UP); }