message
stringlengths
6
474
diff
stringlengths
8
5.22k
Apache Mynewt NimBLE 1.3.0 release
@@ -22,8 +22,8 @@ repo.versions: "0.0.0": "master" "0-dev": "0.0.0" - "0-latest": "1.2.0" - "1-latest": "1.2.0" + "0-latest": "1.3.0" + "1-latest": "1.3.0" "1.0.0": "nimble_1_0_0_tag" "1.1.0": "nimble_1_1_0_tag"
groups: Fix <user> left <group> notifications
:: %remove-members :- ~ - :* (snoc ships text+(rap 3 ' joined ' title.u.meta ~)) + :* (snoc ships text+(rap 3 ' left ' title.u.meta ~)) ~ now.bowl /
eyre: clean up old +load code Removes pre-breach state adapter logic and touches up code style.
:: ++ load => |% - +$ channel-old - $: state=(each timer duct) - next-id=@ud - events=(qeu [id=@ud lines=wall]) - subscriptions=(map wire [ship=@p app=term =path duc=duct]) - == - +$ channel-state-old - $: session=(map @t channel-old) - duct-to-key=(map duct @t) - == - ++ axle-2019-1-7 - %+ cork - axle - |= =axle - axle(date %~2019.1.7, channel-state.server-state (channel-state-old)) - :: +$ axle-2019-10-6 [date=%~2019.10.6 =server-state] -- - |= old=$%(axle axle-2019-10-6 axle-2019-1-7) + |= old=$%(axle axle-2019-10-6) ^+ ..^$ :: ~! %loading ?- -.old - %~2019.1.7 - =/ add-heartbeat - %- ~(run by session.channel-state.server-state.old) - |= [c=channel-old] - ^- channel - [state.c next-id.c events.c subscriptions.c ~] - :: - =/ new - %= old - date %~2019.10.6 - session.channel-state.server-state add-heartbeat - == - $(old new) + %~2020.5.29 ..^$(ax old) :: %~2019.10.6 %_ $ date.old %~2020.5.29 sessions.authentication-state.server-state.old ~ == - :: - %~2020.5.29 ..^$(ax old) == :: +stay: produce current state
expand poke-noun to accept ~ or ~collection
::[~ ..prep(+<+ u.old)] :: ++ poke-noun - |= @ + |= a=?(~ @da) ^- (quip move _+>) ~& %poked - ta-done:(ta-write-config:ta now.bol ['a description' pub=& vis=& [~palzod ~ ~]]) + ?~ a + ta-done:(ta-create:ta %fora ['a description' pub=& vis=& [~palzod ~ ~]]) + ta-done:(ta-submit:ta a 'a topic' ~['with contents']) :: ++ writ |= {wir/wire rit/riot:clay}
factor out logic for mapping in kernel heap
@@ -247,6 +247,34 @@ void force_frame(page_t *page, int is_kernel, int is_writeable, unsigned int add set_bit_frame(addr); } +static void create_heap_page_tables(page_directory_t* dir) { + //here, we call get_page but not alloc_frame + //this causes page_table_t's to be alloc'd if not already existing + //we call this function before identity map so all page tables needed to alloc + //heap pages will be mapped into the address space. + for (uint32_t i = KHEAP_START; i < KHEAP_START + KHEAP_INITIAL_SIZE; i += PAGE_SIZE) { + get_page(i, 1, dir); + } +} + +static void map_heap_pages(page_directory_t* dir) { + //all of the page tables necessary have already been alloc'd and identity mapped thanks + //to the loop just before the identity map + uint32_t heap_end = KHEAP_START + KHEAP_INITIAL_SIZE; + //figure out how much memory is being reserved for heap + uint32_t heap_kb = (heap_end - KHEAP_START) / 1024; + float heap_mb = heap_kb / 1024.0; + printf_info("reserving %x MB for kernel heap", heap_mb); + for (uint32_t i = KHEAP_START; i < heap_end; i += PAGE_SIZE) { + page_t* page = get_page(i, 1, dir); + alloc_frame(page, 1, 0); + unsigned char* ptr = (unsigned char*)dir->tables; + if (*ptr == 0xff) { + printf("broken! %x %x %x\n", KHEAP_START, KHEAP_INITIAL_SIZE, heap_end); + } + } +} + void paging_install() { printf_info("Initializing paging..."); @@ -266,15 +294,9 @@ void paging_install() { memset(kernel_directory, 0, sizeof(page_directory_t)); kernel_directory->physicalAddr = (uint32_t)kernel_directory->tablesPhysical; - //map pages in kernel heap area - //we call get_page but not alloc_frame - //this causes page_table_t's to be created where necessary - //don't alloc the frames yet, they need to be identity - //mapped below first. - uint32_t i = 0; - for (i = KHEAP_START; i < KHEAP_START + KHEAP_INITIAL_SIZE; i += PAGE_SIZE) { - get_page(i, 1, kernel_directory); - } + //reference kernel heap page tables, + //forcing them to be alloc'd before we identity map all alloc'd memory + create_heap_page_tables(kernel_directory); //we need to identity map (phys addr = virtual addr) from //0x0 to end of used memory, so we can access this @@ -290,17 +312,8 @@ void paging_install() { } printf_info("Kernel VirtMem identity mapped up to %x", placement_address); - - //allocate pages we mapped earlier - uint32_t heap_end = KHEAP_START + KHEAP_INITIAL_SIZE; - for (i = KHEAP_START; i < heap_end; i += PAGE_SIZE) { - page_t* page = get_page(i, 1, kernel_directory); - alloc_frame(page, 1, 0); - unsigned char* ptr = (unsigned char*)kernel_directory->tables; - if (*ptr == 0xff) { - printf("broken! %x %x %x\n", KHEAP_START, KHEAP_INITIAL_SIZE, heap_end); - } - } + //allocate initial heap pages + map_heap_pages(kernel_directory); //before we enable paging, register page fault handler register_interrupt_handler(14, page_fault);
[util/string] remove TRetVal protocol for TInputRangeAdaptor; [part 4];
@@ -48,7 +48,6 @@ namespace NPrivate { template <class It> struct TStlIteratorFace: public It, public TInputRangeAdaptor<TStlIteratorFace<It>> { - using TRetVal = decltype(std::declval<It>().Next()); using TStrBuf = decltype(std::declval<It>().Next()->Token()); template <typename... Args>
pybricks/common/LightGrid: add pixel method
@@ -35,6 +35,11 @@ static void set_light_grid_full(pbdrv_pwm_dev_t *pwm, const uint8_t *image) { } } +// FIXME: pbio will have a light grid interface. Use that when ready. +static void set_pixel_brightness(pbdrv_pwm_dev_t *pwm, uint8_t row, uint8_t col, int32_t brightness) { + pb_assert(pwm->funcs->set_duty(pwm, channels[row][col], brightness * brightness * UINT16_MAX / 10000)); +} + // pybricks._common.LightGrid class object typedef struct _common_LightGrid_obj_t { mp_obj_base_t base; @@ -123,12 +128,39 @@ STATIC mp_obj_t common_LightGrid_number(size_t n_args, const mp_obj_t *pos_args, } STATIC MP_DEFINE_CONST_FUN_OBJ_KW(common_LightGrid_number_obj, 1, common_LightGrid_number); +// pybricks._common.LightGrid.pixel +STATIC mp_obj_t common_LightGrid_pixel(size_t n_args, const mp_obj_t *pos_args, mp_map_t *kw_args) { + PB_PARSE_ARGS_METHOD(n_args, pos_args, kw_args, + common_LightGrid_obj_t, self, + PB_ARG_REQUIRED(row), + PB_ARG_REQUIRED(column), + PB_ARG_DEFAULT_INT(brightness, 100)); + + // Get the position + mp_int_t r = mp_obj_get_int(row); + mp_int_t c = mp_obj_get_int(column); + if (r < 0 || r > self->size || c < 0 || c > self->size) { + // Print outsize of canvas, so return + return mp_const_none; + } + + // Get the brightness + mp_int_t b = pb_obj_get_pct(brightness); + + // Set pixel + set_pixel_brightness(self->pwm, r, c, b); + + return mp_const_none; +} +STATIC MP_DEFINE_CONST_FUN_OBJ_KW(common_LightGrid_pixel_obj, 1, common_LightGrid_pixel); + // dir(pybricks.builtins.LightGrid) STATIC const mp_rom_map_elem_t common_LightGrid_locals_dict_table[] = { { MP_ROM_QSTR(MP_QSTR_char), MP_ROM_PTR(&common_LightGrid_char_obj) }, { MP_ROM_QSTR(MP_QSTR_on), MP_ROM_PTR(&common_LightGrid_on_obj) }, { MP_ROM_QSTR(MP_QSTR_off), MP_ROM_PTR(&common_LightGrid_off_obj) }, { MP_ROM_QSTR(MP_QSTR_number), MP_ROM_PTR(&common_LightGrid_number_obj) }, + { MP_ROM_QSTR(MP_QSTR_pixel), MP_ROM_PTR(&common_LightGrid_pixel_obj) }, }; STATIC MP_DEFINE_CONST_DICT(common_LightGrid_locals_dict, common_LightGrid_locals_dict_table);
ifname shortcut
@@ -213,11 +213,13 @@ fail: } void lpd_setup( void ) { + const char *ifname = gconf->dht_ifname; + if( gconf->lpd_disable ) { return; } - if( gconf->dht_ifname && (gconf->af == AF_UNSPEC || gconf->af == AF_INET) ) { + if( ifname && (gconf->af == AF_UNSPEC || gconf->af == AF_INET) ) { log_warn( "LPD: ifname setting not supported for IPv4" ); } @@ -225,11 +227,11 @@ void lpd_setup( void ) { addr_parse( &g_lpd6.mcast_addr, LPD_ADDR6, LPD_PORT, AF_INET6 ); // Setup IPv4 sockets - g_lpd4.sock_listen = create_receive_socket( &g_lpd4.mcast_addr, gconf->dht_ifname ); + g_lpd4.sock_listen = create_receive_socket( &g_lpd4.mcast_addr, ifname ); g_lpd4.sock_send = create_send_socket( AF_INET, ifname ); // Setup IPv6 sockets - g_lpd6.sock_listen = create_receive_socket( &g_lpd6.mcast_addr, gconf->dht_ifname ); + g_lpd6.sock_listen = create_receive_socket( &g_lpd6.mcast_addr, ifname ); g_lpd6.sock_send = create_send_socket( AF_INET6, ifname ); if( g_lpd4.sock_listen >= 0 && g_lpd4.sock_send >= 0 ) {
Use safe multiplication for calculating context_size
#include <openenclave/internal/utils.h> #include "arena.h" #include "handle_ecall.h" +#include "openenclave/internal/safemath.h" #include "platform_t.h" // The number of host thread workers. Initialized by host through ECALL @@ -114,7 +115,8 @@ oe_result_t oe_sgx_init_context_switchless_ecall( OE_RAISE(OE_ALREADY_INITIALIZED); } - contexts_size = sizeof(oe_host_worker_context_t) * num_host_workers; + OE_CHECK(oe_safe_mul_u64( + sizeof(oe_host_worker_context_t), num_host_workers, &contexts_size)); // Ensure the contexts are outside of enclave if (!oe_is_outside_enclave(host_worker_contexts, contexts_size) ||
Don't count key words when determining if the file count evenly divides the block count in the .visit file format
@@ -2374,6 +2374,11 @@ avtDatabase::NumStagesForFetch(avtDataRequest_p) // Jim Eliot, Wed 18 Nov 11:30:58 GMT 2015 // Fixed bug (2461) with reading DOS formatted files which uses '\'r // newline character +// +// Burlen Loring, Fri Apr 28 10:21:30 PDT 2017 +// Don't count key words when determining if the file count evenly divides +// the block count. +// // **************************************************************************** bool @@ -2398,8 +2403,9 @@ avtDatabase::GetFileListFromTextFile(const char *textfile, vector<char *> list; char str_auto[1024]; char str_with_dir[2048]; - int count = 0; - int badCount = 0; + int goodCount = 0; // number of valid lines, keywords and files + int badCount = 0; // number of empty and comment lines + int fileCount = 0; // number of non empty, non comment, non keyword, lines int bang_nBlocks = -1; bool failed = false; while (!ifile.eof() && !failed && badCount < 10000) @@ -2432,7 +2438,7 @@ avtDatabase::GetFileListFromTextFile(const char *textfile, if (str_auto[0] != '\0' && str_auto[0] != '#') { char *bnbp = strstr(str_auto, "!NBLOCKS "); - if (bnbp && bnbp == str_auto && !count) + if (bnbp && bnbp == str_auto && !goodCount) { errno = 0; bang_nBlocks = strtol(str_auto + strlen("!NBLOCKS "), 0, 10); @@ -2454,6 +2460,8 @@ avtDatabase::GetFileListFromTextFile(const char *textfile, if (str_auto[0] == VISIT_SLASH_CHAR || str_auto[0] == '!' || (str_auto_len > 2 && str_auto[1] == ':')) { + // already have an absolute path like /something or C:\something, + // or a keyword like !SOMETHING strcpy(str_with_dir, str_auto); } else @@ -2462,7 +2470,12 @@ avtDatabase::GetFileListFromTextFile(const char *textfile, } char *str_heap = CXX_strdup(str_with_dir); list.push_back(str_heap); - ++count; + ++goodCount; + + // lines of the file starting with ! are keywords and + // are not part of the block count + if (str_auto[0] != '!') + ++fileCount; } else ++badCount; @@ -2470,10 +2483,11 @@ avtDatabase::GetFileListFromTextFile(const char *textfile, if (bang_nBlocks > 0 && !failed) { - if (count % bang_nBlocks) + if (fileCount % bang_nBlocks) { failed = true; - debug1 << "File count of " << count << " not evenly divided by !NBLOCKS value of " << bang_nBlocks << endl; + debug1 << "File count of " << fileCount << " not evenly divided by " + "!NBLOCKS value of " << bang_nBlocks << endl; } } @@ -2487,7 +2501,7 @@ avtDatabase::GetFileListFromTextFile(const char *textfile, } else { - filelist = new char*[count]; + filelist = new char*[goodCount]; filelistN = 0; for (it = list.begin() ; it != list.end() ; ++it) {
refactor(hid): Replace modifier usage values with their cpp definitions Improves readability of the HID reports.
@@ -37,10 +37,10 @@ static const u8_t zmk_hid_report_desc[] = { HID_USAGE_KEY, /* USAGE_MINIMUM (Keyboard LeftControl) */ HID_LI_USAGE_MIN(1), - 0xE0, + HID_USAGE_KEY_KEYBOARD_LEFTCONTROL, /* USAGE_MAXIMUM (Keyboard Right GUI) */ HID_LI_USAGE_MAX(1), - 0xE7, + HID_USAGE_KEY_KEYBOARD_RIGHT_GUI, /* LOGICAL_MINIMUM (0) */ HID_GI_LOGICAL_MIN(1), 0x00,
Make 102_non_standby_recovery.pl less likely to fail. The test will now wait until the restored node has finished recovery before trying to query the node, which causes a test failure. Authored-by: Brent Doil
@@ -31,6 +31,9 @@ $node->safe_psql( INSERT INTO co select i, i FROM generate_series(1,10)i; COMMIT;"); +my $lsn = + $node->safe_psql('postgres', "SELECT pg_current_wal_lsn();"); + # Stop the PostgreSQL server $node->stop; @@ -43,7 +46,12 @@ $restored_node->init_from_backup($node, 'testbackup', has_restoring => 1, standb # Start the PostgreSQL server $restored_node->start; -# Make sure that the server is up and running +# Wait until restored node has replayed the data. +my $caughtup_query = + "SELECT '$lsn'::pg_lsn <= pg_last_wal_replay_lsn()"; +$restored_node->poll_query_until('postgres', $caughtup_query) + or die "Timed out while waiting for restored node to catch up"; + is($restored_node->safe_psql('postgres', 'SELECT count(*) from ao'), '10', 'AO table read check'); is($restored_node->safe_psql('postgres', 'SELECT count(*) from co'), '10', 'AOCS table read check'); is($restored_node->safe_psql('postgres', 'SELECT count(*) from heap'), '10', 'Heap table read check');
comment out future link in docs
@@ -6,7 +6,7 @@ title: Working With AppScope These docs explain how to "drive" AppScope directly. You can also "drive" AppScope from Cribl Stream or Cribl Edge. -<!--> +<!-- : see Cribl's documentation about the [AppScope Source](https://docs.cribl.io/stream/sources-appscope) and the [AppScope Config Editor](https://docs.cribl.io/stream/4.0/appscope-configs). -->
pg_rewind: parse bitmap wal records.
#include <unistd.h> +#include "access/bitmap.h" #include "access/heapam_xlog.h" #include "access/gin_private.h" #include "access/gist_private.h" @@ -332,6 +333,7 @@ extractPageInfo(XLogRecord *record) case RM_MULTIXACT_ID: case RM_STANDBY_ID: case RM_RELMAP_ID: + case RM_DISTRIBUTEDLOG_ID: break; case RM_HEAP_ID: @@ -985,6 +987,64 @@ extractPageInfo(XLogRecord *record) } } break; + + case RM_BITMAP_ID: + switch (info) + { + case XLOG_BITMAP_INSERT_LOVITEM: + { + xl_bm_lovitem *xlrec = (xl_bm_lovitem *) XLogRecGetData(record); + pageinfo_add(xlrec->bm_fork, xlrec->bm_node, xlrec->bm_lov_blkno); + break; + } + case XLOG_BITMAP_INSERT_META: + { + xl_bm_metapage *xlrec = (xl_bm_metapage *) XLogRecGetData(record); + /* bitmap always uses block 0 as meta-page */ + pageinfo_add(xlrec->bm_fork, xlrec->bm_node, 0); + break; + } + case XLOG_BITMAP_INSERT_BITMAP_LASTWORDS: + { + xl_bm_bitmap_lastwords *xlrec = (xl_bm_bitmap_lastwords *) XLogRecGetData(record); + pageinfo_add(MAIN_FORKNUM, xlrec->bm_node, xlrec->bm_lov_blkno); + break; + } + case XLOG_BITMAP_INSERT_WORDS: + { + xl_bm_bitmapwords *xlrec = (xl_bm_bitmapwords *) XLogRecGetData(record); + pageinfo_add(MAIN_FORKNUM, xlrec->bm_node, xlrec->bm_lov_blkno); + for (int bmpageno = 0; bmpageno < xlrec->bm_num_pages; bmpageno++) + { + xl_bm_bitmapwords_perpage *xlrec_perpage; + if (bmpageno == 0 && !xlrec->bm_init_first_page && record->xl_info & XLR_BKP_BLOCK(1)) + continue; + xlrec_perpage = (xl_bm_bitmapwords_perpage *) xlrec; + pageinfo_add(MAIN_FORKNUM, xlrec->bm_node, xlrec_perpage->bmp_blkno); + } + break; + } + case XLOG_BITMAP_UPDATEWORD: + { + xl_bm_updateword *xlrec = (xl_bm_updateword *) XLogRecGetData(record); + pageinfo_add(MAIN_FORKNUM, xlrec->bm_node, xlrec->bm_blkno); + break; + } + case XLOG_BITMAP_UPDATEWORDS: + { + xl_bm_updatewords *xlrec = (xl_bm_updatewords*) XLogRecGetData(record); + pageinfo_add(MAIN_FORKNUM, xlrec->bm_node, xlrec->bm_first_blkno); + if (xlrec->bm_two_pages) + pageinfo_add(MAIN_FORKNUM, xlrec->bm_node, xlrec->bm_second_blkno); + if (xlrec->bm_new_lastpage) + pageinfo_add(MAIN_FORKNUM, xlrec->bm_node, xlrec->bm_lov_blkno); + break; + } + default: + fprintf(stderr, "unrecognized bitmap index wal record type %d\n", info); + exit(1); + } + break; default: /* * It's important that we error out, not ignore, records that we
Added some ScePaf functions
@@ -5724,3 +5724,17 @@ modules: ksceMotionDevSamplingStart: 0xC02C85AB ksceMotionDevSetSamplingMode: 0xDBAF611A ksceMotionDevSamplingStop: 0xFD0B0785 + ScePaf: + nid: 0xCD679177 + libraries: + ScePafStdc: + kernel: false + nid: 0xA7D28DAE + functions: + sce_paf_private_free: 0x1B77082E + sce_paf_private_memset: 0xE148AF94 + sce_paf_private_strcmp: 0x5CD08A47 + sce_paf_private_malloc: 0xFC5CD359 + sce_paf_private_strlen: 0xF5A2AA0C + sce_paf_private_snprintf: 0x4E0D907E + sce_paf_private_strchr: 0x1A22784C
dshot: continue operation right away after dir switch
@@ -362,9 +362,9 @@ void motor_write(float *values) { const uint16_t value = motor_dir == MOTOR_REVERSE ? DSHOT_CMD_ROTATE_REVERSE : DSHOT_CMD_ROTATE_NORMAL; make_packet_all(value, true); counter++; - } else { - make_packet_all(0, false); + } + if (counter == 24) { counter = 0; dir_change_time = 0; last_motor_dir = motor_dir;
fix mixgo adc
@@ -148,9 +148,10 @@ class led: class ADCSensor: def __init__(self,pin): - self.pin=pin + self.adc=ADC(Pin(pin)) + self.adc.atten(ADC.ATTN_11DB) def read(self): - return ADC(Pin(self.pin)).read() + return self.adc.read() class RGB: def __init__(self, pin, num):
Conditionally leave out bits of LAPACK to be overridden by ReLAPACK
@@ -53,7 +53,7 @@ set(BLAS2_COMPLEX_ONLY_MANGLED_SOURCES # these do not have separate 'z' sources set(BLAS3_SOURCES gemm.c symm.c - trsm.c syrk.c syr2k.c + trsm.c syrk.c syr2k.c gemmt.c ) set(BLAS3_MANGLED_SOURCES @@ -189,7 +189,16 @@ if (NOT DEFINED NO_LAPACK) ) GenerateNamedObjects("${LAPACK_SOURCES}") + if (NOT RELAPACK_REPLACE) GenerateNamedObjects("${LAPACK_MANGLED_SOURCES}" "" "" 0 "" "" 0 3) + else () + GenerateNamedObjects("lapack/getrs.c" "" "" 0 "" "" 0 3) + GenerateNamedObjects("lapack/getf2.c" "" "" 0 "" "" 0 3) + GenerateNamedObjects("lapack/potf2.c" "" "" 0 "" "" 0 3) + GenerateNamedObjects("lapack/laswp.c" "" "" 0 "" "" 0 3) + GenerateNamedObjects("lapack/lauu2.c" "" "" 0 "" "" 0 3) + GenerateNamedObjects("lapack/trti2.c" "" "" 0 "" "" 0 3) + endif() endif () if ( BUILD_COMPLEX AND NOT BUILD_SINGLE)
Fixing Go program crash. Go request registration should be removed before C request memory freed. C request address used as a key in Go map. Freed memory can be instantly reused for other request and older request registration should removed at this point to avoid collisions.
@@ -107,10 +107,10 @@ func (r *request) response() *response { } func (r *request) done() { - C.nxt_go_request_done(r.c_req) - remove_request(r) + C.nxt_go_request_done(r.c_req) + for _, m := range r.msgs { m.Close() }
Add some docs on debugging
@@ -109,3 +109,19 @@ This example extends the default test harness and creates new ``Overlays`` to co .. Note:: Remember that since whenever a new test harness is created (or the config. changes, or the config. packages changes, or...), you need to modify the make invocation. For example, ``make SUB_PROJECT=vcu118 CONFIG=MyNewVCU118Config CONFIG_PACKAGE=this.is.my.scala.package bit``. See :ref:`Making a Bitstream` for information on the various make variables. + +Debugging with ILAs +~~~~~~~~~~~~~~~~~~~ + +Adding an ILA can be added to the design for debugging relevant signals. +First, open up the post synthesis checkpoint located in the build directory for your design in Vivado (it should be labeled ``post_synth.dcp``). +Then using Vivado, add ILAs (and other debugging tools) for your design (search online for more information on how to add an ILA). +After the changes are made, save the checkpoint and run the make invocation with the ``debug-bitstream`` target: +be done by modifying the post synthesis checkpoint, saving it, and running ``make ... debug-bitstream``. +For example, running the bitstream build for an added ILA for a BOOM config.: + +.. code-block:: shell + + make SUB_PROJECT=vcu118 CONFIG=BoomVCU118Config debug-bitstream + +For more extensive debugging tools for FPGA simulations including printf synthesis, assert synthesis, instruction traces, ILAs, out-of-band profiling, co-simulation, and more, please refer to the :ref:`FireSim` platform.
sasuke : change LED gpio setting Change LED Gpio Setting from Open drain to push-pull BRANCH=None TEST=make -j BOARD=sasuke
@@ -61,9 +61,9 @@ GPIO(EN_SLP_Z, PIN(8, 3), GPIO_OUT_LOW) GPIO(EN_BL_OD, PIN(D, 3), GPIO_ODR_LOW) GPIO(IMVP9_PE, PIN(E, 0), GPIO_OUT_LOW) GPIO(ECH1_PACKET_MODE, PIN(7, 5), GPIO_OUT_LOW) -GPIO(LED_R_ODL, PIN(C, 4), GPIO_ODR_HIGH) -GPIO(LED_G_ODL, PIN(C, 3), GPIO_ODR_HIGH) -GPIO(LED_B_ODL, PIN(C, 2), GPIO_ODR_HIGH) +GPIO(LED_R_ODL, PIN(C, 4), GPIO_OUT_HIGH) +GPIO(LED_G_ODL, PIN(C, 3), GPIO_OUT_HIGH) +GPIO(LED_B_ODL, PIN(C, 2), GPIO_OUT_HIGH) /* Power Sequencing */ GPIO(EC_AP_PSYS, PIN(B, 7), GPIO_OUT_LOW)
efuse: revert EARLY_LOGD to LOGD introduced in
@@ -68,7 +68,7 @@ esp_err_t esp_efuse_utility_process(const esp_efuse_desc_t* field[], void* ptr, if ((bits_counter + num_bits) > req_size) { // Limits the length of the field. num_bits = req_size - bits_counter; } - ESP_EARLY_LOGD(TAG, "In EFUSE_BLK%d__DATA%d_REG is used %d bits starting with %d bit", + ESP_LOGD(TAG, "In EFUSE_BLK%d__DATA%d_REG is used %d bits starting with %d bit", (int)field[i]->efuse_block, num_reg, num_bits, start_bit); err = func_proc(num_reg, field[i]->efuse_block, start_bit, num_bits, ptr, &bits_counter); ++i_reg;
Guard against NPE in native code
@@ -492,8 +492,10 @@ namespace carto { } element = cluster.clusterElement; } + if (element) { addRendererElement(element); } + } bool billboardsChanged = refreshRendererElements();
posix: Fix getline
@@ -1016,8 +1016,6 @@ ssize_t getdelim(char **line, size_t *n, int delim, FILE *stream) { return -1; } - constexpr size_t chunk = 1024; - char *buffer = *line; size_t capacity = *n, nwritten = 0; @@ -1034,7 +1032,7 @@ ssize_t getdelim(char **line, size_t *n, int delim, FILE *stream) { while (true) { // Fill the buffer - while (capacity > 0 && nwritten < capacity - 1) { + while (buffer && capacity > 0 && nwritten < capacity - 1) { auto c = fgetc_unlocked(stream); if (ferror(stream)) { return -1; @@ -1053,7 +1051,7 @@ ssize_t getdelim(char **line, size_t *n, int delim, FILE *stream) { // Double the size of the buffer (but make sure it's at least 1024) capacity = (capacity >= 1024) ? capacity * 2 : 1024; - buffer = reinterpret_cast<char *>(getAllocator().reallocate(*line, capacity)); + buffer = reinterpret_cast<char *>(realloc(*line, capacity)); if (!buffer) { errno = ENOMEM; return -1;
build: adds urcrypt to top-level shell.nix
@@ -23,7 +23,7 @@ let # # Typically the inputs listed here also have a shell.nix in their respective # source directory you can use, to avoid the Haskell/GHC dependencies. - inputsFrom = with pkgsLocal; [ ent herb urbit ]; + inputsFrom = with pkgsLocal; [ ent herb urbit urcrypt ]; # Collect the named attribute from all dependencies listed in inputsFrom. mergeFrom = name: pkgs.lib.concatLists (pkgs.lib.catAttrs name inputsFrom);
Fix issue with yr_scanner_set_timeout. Now that the time is measured in nanoseconds, the timeout must be converted to nanoseconds too.
@@ -289,7 +289,7 @@ YR_API void yr_scanner_set_timeout( YR_SCANNER* scanner, int timeout) { - scanner->timeout = timeout * 1000000L; // convert timeout to microseconds. + scanner->timeout = timeout * 1000000000L; // convert timeout to nanoseconds. }
rpi-base.inc: Add MCP3008 ADC overlay
@@ -39,6 +39,7 @@ RPI_KERNEL_DEVICETREE_OVERLAYS ?= " \ overlays/iqaudio-dacplus.dtbo \ overlays/mcp2515-can0.dtbo \ overlays/mcp2515-can1.dtbo \ + overlays/mcp3008.dtbo \ overlays/miniuart-bt.dtbo \ overlays/pitft22.dtbo \ overlays/pitft28-capacitive.dtbo \
nvhw/pgraph_celsius: Nailed down float-to-unorm8 color conversion.
@@ -69,16 +69,16 @@ uint8_t pgraph_celsius_xfrm_f2b(uint32_t val) { return 0xff; if (exp < 0x76) return 0; - uint32_t fr = extr(val, 0, 23); - fr |= 1 << 23; - fr <<= exp - 0x76; - uint8_t res = fr >> 24; - if (res >= 0x80) - res--; - uint32_t target = res * 0x01010101 + 0x00808080; - if (fr > target) - res++; - return res; + uint32_t fr = extr(val, 10, 13); + fr |= 1 << 13; + fr <<= exp - 0x74; + fr *= 0xff; + fr >>= 23; + fr++; + fr >>= 1; + if (fr > 0xff) + fr = 0xff; + return fr; } uint32_t pgraph_celsius_xfrm_mul(uint32_t a, uint32_t b) { @@ -583,13 +583,13 @@ void pgraph_celsius_xfrm(struct pgraph_state *state, int idx) { uint32_t optsz; uint32_t ifog, ofog; uint8_t ocol[2][4]; - icol[0][0] = state->celsius_pipe_vtx[1*4+0] & 0xfffffc00; - icol[0][1] = state->celsius_pipe_vtx[1*4+1] & 0xfffffc00; - icol[0][2] = state->celsius_pipe_vtx[1*4+2] & 0xfffffc00; - icol[0][3] = state->celsius_pipe_vtx[1*4+3] & 0xfffffc00; - icol[1][0] = state->celsius_pipe_vtx[2*4+0] & 0xfffffc00; - icol[1][1] = state->celsius_pipe_vtx[2*4+1] & 0xfffffc00; - icol[1][2] = state->celsius_pipe_vtx[2*4+2] & 0xfffffc00; + icol[0][0] = pgraph_celsius_convert_light_v(state->celsius_pipe_vtx[1*4+0]); + icol[0][1] = pgraph_celsius_convert_light_v(state->celsius_pipe_vtx[1*4+1]); + icol[0][2] = pgraph_celsius_convert_light_v(state->celsius_pipe_vtx[1*4+2]); + icol[0][3] = state->celsius_pipe_vtx[1*4+3]; + icol[1][0] = pgraph_celsius_convert_light_v(state->celsius_pipe_vtx[2*4+0]); + icol[1][1] = pgraph_celsius_convert_light_v(state->celsius_pipe_vtx[2*4+1]); + icol[1][2] = pgraph_celsius_convert_light_v(state->celsius_pipe_vtx[2*4+2]); ifog = pgraph_celsius_convert_light_sx(state->celsius_pipe_vtx[2*4+3]); struct pgraph_celsius_xf_res xf;
SOVERSION bump to version 2.2.2
@@ -63,7 +63,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 2) -set(LIBYANG_MICRO_SOVERSION 1) +set(LIBYANG_MICRO_SOVERSION 2) set(LIBYANG_SOVERSION_FULL ${LIBYANG_MAJOR_SOVERSION}.${LIBYANG_MINOR_SOVERSION}.${LIBYANG_MICRO_SOVERSION}) set(LIBYANG_SOVERSION ${LIBYANG_MAJOR_SOVERSION})
OcBootServicesTableLib: Fix not registering protocols
@@ -26,7 +26,7 @@ EFI_BOOT_SERVICES *gBS = NULL; STATIC EFI_CONNECT_CONTROLLER mConnectController = NULL; STATIC EFI_LOCATE_PROTOCOL mLocateProtocol = NULL; -STATIC OC_REGISTERED_PROTOCOL mRegisteredProtocols[8]; +STATIC OC_REGISTERED_PROTOCOL mRegisteredProtocols[16]; STATIC UINTN mRegisteredProtocolCount = 0; STATIC @@ -141,6 +141,8 @@ OcRegisterBootServicesProtocol ( mRegisteredProtocols[mRegisteredProtocolCount].ProtocolInstance = ProtocolInstance; mRegisteredProtocols[mRegisteredProtocolCount].Override = Override; + ++mRegisteredProtocolCount; + return EFI_SUCCESS; }
Fix custom MODEL feature Previously, the TestDriver would set MODEL to TestHarness if unset. This fixes the feature to let us set MODEL from the makefile.
@@ -50,6 +50,7 @@ PREPROC_DEFINES = \ +define+RESET_DELAY=$(RESET_DELAY) \ +define+PRINTF_COND=$(TB).printf_cond \ +define+STOP_COND=!$(TB).reset \ + +define+MODEL=$(MODEL) \ +define+RANDOMIZE_MEM_INIT \ +define+RANDOMIZE_REG_INIT \ +define+RANDOMIZE_GARBAGE_ASSIGN \
pbio/math: Fix docstring for interpolation.
@@ -96,14 +96,16 @@ static const point_t atan_points[] = { }; /** - * Interpolates a constant set of (X, Y) sample points to find y for given x. + * Interpolates a constant set of (X, Y) sample points on a curve y = f(x) + * to estimate y for given input value x. * * If x < x[first] then it returns y[first]. * If x >= x[last] then it returns y[last]. * - * @param [out] a Angle a. - * @param [in] input Value to convert. - * @param [in] scale Ratio between high resolution angle and input. + * @param [in] points Data points between which to interpolate. + * @param [in] len Number of data points. + * @param [in] x Value for which to estimate y = f(x) + * @return Estimated value for y = f(x) */ static int32_t pbio_math_interpolate(const point_t *points, size_t len, int32_t x) {
dratini/dragonair: add new SKU add unprovisioned SKUID to support kblight and convertible for pre-flash cbi. add SKU ID: 23 (Convertible, TS, Stylus) BRANCH=none TEST=make buildall -j.
@@ -366,8 +366,11 @@ static bool board_is_convertible(void) { uint8_t sku_id = get_board_sku(); - /* Dragonair (SKU 21 and 22) is a convertible. Dratini is not. */ - return sku_id == 21 || sku_id == 22; + /* + * Dragonair (SKU 21 ,22 and 23) is a convertible. Dratini is not. + * Unprovisioned SKU 255. + */ + return sku_id == 21 || sku_id == 22 || sku_id == 23 || sku_id == 255; } static void board_update_sensor_config_from_sku(void) @@ -413,8 +416,9 @@ bool board_has_kb_backlight(void) * SKUs have keyboard backlight. * Dratini: 2, 3 * Dragonair: 22 + * Unprovisioned: 255 */ - return sku_id == 2 || sku_id == 3 || sku_id == 22; + return sku_id == 2 || sku_id == 3 || sku_id == 22 || sku_id == 255; } uint32_t board_override_feature_flags0(uint32_t flags0)
lwip - Fix "defined but not used" warnings.
#define file_NULL (struct fsdata_file *) NULL -static const unsigned int dummy_align__img_sics_gif = 0; static const unsigned char data__img_sics_gif[] = { /* /img/sics.gif (14 chars) */ 0x2f,0x69,0x6d,0x67,0x2f,0x73,0x69,0x63,0x73,0x2e,0x67,0x69,0x66,0x00,0x00,0x00, @@ -75,7 +74,6 @@ static const unsigned char data__img_sics_gif[] = { 0x82,0x0c,0x36,0xe8,0xe0,0x83,0x10,0x46,0x28,0xe1,0x84,0x14,0x56,0x68,0xa1,0x10, 0x41,0x00,0x00,0x3b,}; -static const unsigned int dummy_align__404_html = 1; static const unsigned char data__404_html[] = { /* /404.html (10 chars) */ 0x2f,0x34,0x30,0x34,0x2e,0x68,0x74,0x6d,0x6c,0x00,0x00,0x00, @@ -134,7 +132,6 @@ static const unsigned char data__404_html[] = { 0x3e,0x0d,0x0a,0x3c,0x2f,0x62,0x6f,0x64,0x79,0x3e,0x0d,0x0a,0x3c,0x2f,0x68,0x74, 0x6d,0x6c,0x3e,0x0d,0x0a,}; -static const unsigned int dummy_align__index_html = 2; static const unsigned char data__index_html[] = { /* /index.html (12 chars) */ 0x2f,0x69,0x6e,0x64,0x65,0x78,0x2e,0x68,0x74,0x6d,0x6c,0x00,
Additionl extensions GL_MGL_packed_pixels (old Amiga flavour of GL_EXT_packed_pixels) and GL_EXT_compiled_vertex_arrays (note the s at the end, a common typo...)
@@ -68,8 +68,12 @@ void BuildExtensionsList() { glstate->extensions = (GLubyte*)malloc(5000); // arbitrary size... strcpy(glstate->extensions, "GL_EXT_abgr " + #ifdef AMIGAOS4 + "GL_MGL_packed_pixels " // same as GL_EXT_packed_pixels, but older, some old Amiga games may check for this + #endif "GL_EXT_packed_pixels " "GL_EXT_compiled_vertex_array " + "GL_EXT_compiled_vertex_arrays " // yes, at least on AmigaOS there are progs which check for this wrong string; reason is an old typo in the MiniGL driver. "GL_ARB_vertex_buffer_object " "GL_ARB_vertex_array_object " "GL_ARB_vertex_buffer "
demux,IsValidExtendedFormat: remove unused variable quiets -Wunused-but-set-variable frame_count has been unused in this function since: demux, Frame: remove is_fragment_ field
@@ -614,7 +614,6 @@ static int IsValidExtendedFormat(const WebPDemuxer* const dmux) { while (f != NULL) { const int cur_frame_set = f->frame_num_; - int frame_count = 0; // Check frame properties. for (; f != NULL && f->frame_num_ == cur_frame_set; f = f->next_) { @@ -649,8 +648,6 @@ static int IsValidExtendedFormat(const WebPDemuxer* const dmux) { dmux->canvas_width_, dmux->canvas_height_)) { return 0; } - - ++frame_count; } } return 1;
out_bigquery: use new upstream prototype for tls handling
@@ -306,7 +306,7 @@ static int cb_bigquery_init(struct flb_output_instance *ins, * (no oauth2 service) */ ctx->u = flb_upstream_create_url(config, FLB_BIGQUERY_URL_BASE, - io_flags, &ins->tls); + io_flags, ins->tls); if (!ctx->u) { flb_plg_error(ctx->ins, "upstream creation failed"); return -1;
Comments adjustment
@@ -108,7 +108,7 @@ AjaxFranceLabs.DateSelectorFacetModule = AjaxFranceLabs.AbstractModule.extend({ $("#" + this.id + "-date-selector").find(".go").show(); }, - // Validates that the input string is a valid date formatted as "mm/dd/yyyy" + // Validates that the input string is a valid date formatted as "dd/mm/yyyy" isValidDate : function(dateString) { // First check for the pattern
zephyr: Include i2c_map.h for I2C enabled boards BRANCH=none TEST=zmake build for volteer and zmake test for ec and i2c
#include "gpio_map.h" #endif +/* Include board specific i2c mapping if I2C is enabled. */ +#if defined(CONFIG_I2C) && !defined(CONFIG_ZTEST) +#include "i2c_map.h" +#endif + #endif /* __BOARD_H */
dm: resize the vm_config buffer in 'vm_get_config()' resize vm_config buffer from 16KB to 32KB, as 16KB is not enough on EHL platform, which will result in crash when accessing this memory.
@@ -713,7 +713,7 @@ vm_irqfd(struct vmctx *ctx, struct acrn_irqfd *args) int vm_get_config(struct vmctx *ctx, struct acrn_vm_config *vm_cfg) { -#define VM_CFG_BUFF_SIZE 0x4000 +#define VM_CFG_BUFF_SIZE 0x8000 int i, err = 0; uint8_t *configs_buff; struct acrn_vm_config *pcfg; @@ -735,6 +735,7 @@ vm_get_config(struct vmctx *ctx, struct acrn_vm_config *vm_cfg) pr_err("%s, failed: get platform info.\n", __func__); goto exit; } + assert(VM_CFG_BUFF_SIZE > (platform_info.max_vms * platform_info.vm_config_entry_size)); for (i = 0; i < platform_info.max_vms; i++) { pcfg = (struct acrn_vm_config *)(configs_buff + (i * platform_info.vm_config_entry_size));
console: Fix typo Fix typo that led to the following error: ``` repos/apache-mynewt-core/sys/console/minimal/src/console.c:135:19: error: 'promot' undeclared (first use in this function); did you mean 'prompt'? console_write(promot, strlen(prompt)); ```
@@ -132,7 +132,7 @@ console_out(int c) void console_prompt_set(const char *prompt, const char *line) { - console_write(promot, strlen(prompt)); + console_write(prompt, strlen(prompt)); if (line) { console_write(line, strlen(line)); }
docs: fix typo for openmpi install
@@ -40,7 +40,7 @@ OpenMPI & \multicolumn{1}{c}{\checkmark} & \multicolum % ohpc_command if [[ ${enable_mpi_defaults} -eq 1 && ${enable_pmix} -eq 0 ]];then % ohpc_indent 5 \begin{lstlisting}[language=bash] -[sms](*\#*) (*\install*) openmpi9-gnu9-ohpc mpich-gnu9-ohpc +[sms](*\#*) (*\install*) openmpi4-gnu9-ohpc mpich-gnu9-ohpc \end{lstlisting} % ohpc_indent 0 % ohpc_command elif [[ ${enable_mpi_defaults} -eq 1 && ${enable_pmix} -eq 1 ]];then
Update Zig demo cart to use wrapper API
@@ -12,27 +12,23 @@ export fn BOOT() void { } export fn TIC() void { - if (tic.btn(0) != 0) { + if (tic.btn(0)) { mascot.y -= 1; } - if (tic.btn(1) != 0) { + if (tic.btn(1)) { mascot.y +=1; } - if (tic.btn(2) != 0) { + if (tic.btn(2)) { mascot.x -= 1; } - if (tic.btn(3) != 0) { + if (tic.btn(3)) { mascot.x += 1; } tic.cls(13); - var trans_color = [_]u8 {14}; - tic.spr(@as(i32, 1+t%60/30*2),mascot.x,mascot.y,&trans_color,1,3,0,0,2,2); - _ = tic.print("HELLO WORLD!", 84, 84, 15, true, 1, false); + tic.spr(@as(i32, 1+t%60/30*2),mascot.x,mascot.y,.{.w=2, .h=2, .transparent=&.{14}, .scale=3}); + _ = tic.print("HELLO WORLD!", 84, 84, .{}); - // cls(13) - // spr() - // print("HELLO WORLD!",84,84) t += 1; }
boot: zephyr: select GPIO when MCUBOOT_SERIAL is enabled Select GPIO when MCUBOOT_SERIAL is enabled.
@@ -143,8 +143,9 @@ menuconfig MCUBOOT_SERIAL bool "MCUboot serial recovery" default n select REBOOT - select UART_INTERRUPT_DRIVEN + select GPIO select SERIAL + select UART_INTERRUPT_DRIVEN select BASE64 select TINYCBOR help
Change receive buffer
#endif static int result = 0; -static uint32_t config_rcv_buffer_size = 16*1024*1024; // 1MB rcv buffer +static uint32_t config_rcv_buffer_size = 32*1024*1024; // 32MB rcv buffer static uint32_t config_max_flows = 50; static uint8_t config_log_level = 0; static char request[512];
doc: add some notes in tutorial
@@ -30,7 +30,10 @@ following benefits arise: - The administrator can choose: - the configuration file syntax (e.g. XML or JSON) - notification and logging on configuration changes + - defaults on absence of values using specifications - and all other features [that plugins provide](/src/plugins/) +- The parsing result is guaranteed to be the same because the same + parser will be used. - Other applications can use your configuration as override or as fallback (see below)
options/posix: Implement execle
@@ -97,9 +97,24 @@ int execl(const char *path, const char *arg0, ...) { return execve(path, argv, environ); } -int execle(const char *, const char *, ...) { - __ensure(!"Not implemented"); - __builtin_unreachable(); +// This function is taken from musl. +int execle(const char *path, const char *arg0, ...) { + int argc; + va_list ap; + va_start(ap, arg0); + for(argc = 1; va_arg(ap, const char *); argc++); + va_end(ap); + + int i; + char *argv[argc + 1]; + char **envp; + va_start(ap, arg0); + argv[0] = (char *)argv; + for(i = 1; i <= argc; i++) + argv[i] = va_arg(ap, char *); + envp = va_arg(ap, char **); + va_end(ap); + return execve(path, argv, envp); } int execlp(const char *, const char *, ...) {
Fix documentation per Christian Huitema's comments
@@ -5,7 +5,7 @@ The sample program is a simple QUIC client/server demo. Building -------- -picoquic\_sample is built as part of the compilation process of picoquic. It is +picoquic\_sample is built as part of the compilation process of picoquic. It will be available in the root folder. Usage @@ -20,8 +20,8 @@ Example Generate the certificates: ``` -openssl req -x509 -newkey rsa:4096 -days 365 -keyout ca-key.pem -out ca-cert.pem -openssl req -newkey rsa:4096 -keyout server-key.pem -out server-req.pem +openssl req -x509 -newkey rsa:2048 -days 365 -keyout ca-key.pem -out ca-cert.pem +openssl req -newkey rsa:2048 -keyout server-key.pem -out server-req.pem ``` These commands will prompt a few questions, you don't need to put actual data for this simple test. @@ -34,10 +34,10 @@ echo "Hello world!" >> ./server_files/index.htm And run the server: ``` -sudo ./picoquic_sample server 443 ./ca-cert.pem ./server-key.pem ./server_files +./picoquic_sample server 4433 ./ca-cert.pem ./server-key.pem ./server_files ``` Then, test if you can reach it using the client: ``` -sudo ./picoquic_sample client localhost 443 /tmp index.htm +./picoquic_sample client localhost 4433 /tmp index.htm ```
add _XTAL_FREQ macro.
/***** Feature test switches ************************************************/ /***** System headers *******************************************************/ +#ifndef _XTAL_FREQ +#define _XTAL_FREQ 10000000 +#endif #ifndef FCY #define FCY (_XTAL_FREQ/2) #endif #include <libpic30.h> /***** Local headers ********************************************************/ -#include "../mcc_generated_files/clock.h" - /***** Constant values ******************************************************/ /***** Macros ***************************************************************/ #if !defined(MRBC_TICK_UNIT)
VERSION bump to version 0.11.42
@@ -32,7 +32,7 @@ set(CMAKE_C_FLAGS_DEBUG "-g -O0") # set version set(LIBNETCONF2_MAJOR_VERSION 0) set(LIBNETCONF2_MINOR_VERSION 11) -set(LIBNETCONF2_MICRO_VERSION 41) +set(LIBNETCONF2_MICRO_VERSION 42) set(LIBNETCONF2_VERSION ${LIBNETCONF2_MAJOR_VERSION}.${LIBNETCONF2_MINOR_VERSION}.${LIBNETCONF2_MICRO_VERSION}) set(LIBNETCONF2_SOVERSION ${LIBNETCONF2_MAJOR_VERSION}.${LIBNETCONF2_MINOR_VERSION})
fix: ws->me no longer overwritten by every event
@@ -550,8 +550,6 @@ on_dispatch_message( size_t nids = ntl_length((void**) buf); uint64_t *ids = (uint64_t*)malloc(nids * sizeof(uint64_t)); - ASSERT_S(NULL != ids, "Out of memory"); - for(size_t i = 0; i < nids; i++) { orka_strtoull(buf[i]->start, buf[i]->size, ids + i); } @@ -565,8 +563,6 @@ on_dispatch_message( } channel::message::dati *msg = channel::message::dati_alloc(); - ASSERT_S(NULL != msg, "Out of memory"); - channel::message::dati_from_json(payload->event_data, sizeof(payload->event_data), msg); @@ -637,8 +633,6 @@ on_dispatch_guild_member( struct payload_s *payload) { guild::member::dati *member = guild::member::dati_alloc(); - ASSERT_S(NULL != member, "Out of memory"); - guild::member::dati_from_json(payload->event_data, sizeof(payload->event_data), member); @@ -704,9 +698,6 @@ on_dispatch(void *p_ws, void *curr_iter_data) dati *ws = (dati*)p_ws; struct payload_s *payload = (struct payload_s*)curr_iter_data; - user::dati_from_json(payload->event_data, - sizeof(payload->event_data), ws->me); - /* Ratelimit check */ pthread_mutex_lock(&ws->lock); if ((ws_timestamp(&ws->common) - ws->session.event_tstamp) < 60) {
Gamma correct colors correctly;
#include "loaders/font.h" #include "event/event.h" #include "filesystem/filesystem.h" +#include "math/math.h" #include "math/mat4.h" #include "math/vec3.h" #include "util.h" @@ -24,6 +25,14 @@ static void onCloseWindow(GLFWwindow* window) { } } +static void gammaCorrectColor(Color* color) { + if (state.gammaCorrect) { + color->r = lovrMathGammaToLinear(color->r); + color->g = lovrMathGammaToLinear(color->g); + color->b = lovrMathGammaToLinear(color->b); + } +} + // Base void lovrGraphicsInit() { @@ -115,8 +124,10 @@ void lovrGraphicsPrepare(float* pose) { } // Color - float color[4] = { state.color.r, state.color.g, state.color.b, state.color.a }; - lovrShaderSetFloat(shader, "lovrColor", color, 4); + Color color = state.color; + gammaCorrectColor(&color); + float data[4] = { color.r, color.g, color.b, color.a }; + lovrShaderSetFloat(shader, "lovrColor", data, 4); // Point size lovrShaderSetFloat(shader, "lovrPointSize", &state.pointSize, 1); @@ -135,6 +146,7 @@ void lovrGraphicsPrepare(float* pose) { for (int i = 0; i < MAX_MATERIAL_COLORS; i++) { Color color = lovrMaterialGetColor(material, i); + gammaCorrectColor(&color); float data[4] = { color.r, color.g, color.b, color.a }; lovrShaderSetFloat(shader, lovrShaderColorUniforms[i], data, 4); } @@ -241,6 +253,7 @@ Color lovrGraphicsGetBackgroundColor() { void lovrGraphicsSetBackgroundColor(Color color) { state.backgroundColor = color; + gammaCorrectColor(&color); glClearColor(color.r, color.g, color.b, color.a); }
Update test to work with different collations. The data returned by the protocol has not been sorted yet so it is vulnerable to differences in collation. Multiple records are not needed for this test so limit it to one path to solve this issue.
@@ -291,7 +291,14 @@ testRun(void) "check content"); // ------------------------------------------------------------------------------------------------------------------------- - TEST_TITLE("check protocol function directly with a file"); + TEST_TITLE("check protocol function directly with a path"); + + // Remove the file since ordering cannot be guaranteed in the protocol results + storageRemoveP(storageRemote, STRDEF("test"), .errorOnMissing = true); + + // Path timestamp must be set after file is removed since file removal updates it + utimeTest = (struct utimbuf){.actime = 1000000000, .modtime = 1555160000}; + THROW_ON_SYS_ERROR(utime(strZ(storagePathP(storageRemote, NULL)), &utimeTest) != 0, FileWriteError, "unable to set time"); VariantList *paramList = varLstNew(); varLstAdd(paramList, varNewStrZ(hrnReplaceKey("{[path]}/repo"))); @@ -302,7 +309,6 @@ testRun(void) strNewBuf(serverWrite), hrnReplaceKey( ".\".\"\n.1\n.1555160000\n.{[user-id]}\n.\"{[user]}\"\n.{[group-id]}\n.\"{[group]}\"\n.488\n" - ".\"test\"\n.0\n.1555160001\n.6\n.{[user-id]}\n.\"{[user]}\"\n.{[group-id]}\n.\"{[group]}\"\n.416\n" ".\n" "{\"out\":true}\n"), "check result");
stm32/make-stmconst.py: Allow "[]" chars when parsing source comments. For STM32WB MCUs, EXTI offset addresses were not parsed due to the appearance of "[31:0]" in a comment in the .h file.
@@ -46,7 +46,7 @@ class LexerError(Exception): class Lexer: re_io_reg = r"__IO uint(?P<bits>8|16|32)_t +(?P<reg>[A-Z0-9]+)" - re_comment = r"(?P<comment>[A-Za-z0-9 \-/_()&:]+)" + re_comment = r"(?P<comment>[A-Za-z0-9 \-/_()&:\[\]]+)" re_addr_offset = r"Address offset: (?P<offset>0x[0-9A-Z]{2,3})" regexs = ( (
fixed a small initialization issue
@@ -110,6 +110,10 @@ void VDP_init() pw = (u16 *) GFX_CTRL_PORT; for (i = 0x00; i < 0x13; i++) *pw = 0x8000 | (i << 8) | regValues[i]; + maps_addr = 0; + // update minimum address of all tilemap/table (default is plane B) + updateMapsAddress(); + // clear VRAM, reset palettes / default tiles / font and scroll mode VDP_resetScreen(); // reset sprite struct @@ -122,10 +126,6 @@ void VDP_init() // internal curTileInd = TILE_USERINDEX; - - maps_addr = 0; - // update minimum address of all tilemap/table (default is plane B) - updateMapsAddress(); }
[core] set min srv->max_fds = 32 (sanity check) (server load checks will fail if value is too low)
@@ -1735,6 +1735,8 @@ static int server_main_setup (server * const srv, int argc, char **argv) { #endif srv->max_fds = (int)srv->srvconf.max_fds; + if (srv->max_fds < 32) /*(sanity check; not expected)*/ + srv->max_fds = 32; /*(server load checks will fail if too low)*/ srv->ev = fdevent_init(srv->srvconf.event_handler, &srv->max_fds, &srv->cur_fds, srv->errh); if (NULL == srv->ev) { log_error(srv->errh, __FILE__, __LINE__, "fdevent_init failed");
honggfuzz: better exit loop
@@ -54,9 +54,11 @@ honggfuzz_t hfuzz; static void exitWithMsg(const char* msg, int exit_code) { HF_ATTR_UNUSED ssize_t sz = write(STDERR_FILENO, msg, strlen(msg)); + for (;;) { exit(exit_code); abort(); } +} static bool showDisplay = true; void sigHandler(int sig) {
media: Add debug msg when PlayerWorker is dead If the PlayerWorker is not alive when calling Media APIs, debug messages are printed
@@ -80,6 +80,7 @@ player_result_t MediaPlayerImpl::destroy() PlayerWorker& mpw = PlayerWorker::getWorker(); if (!mpw.isAlive()) { + meddbg("PlayerWorker is not alive\n"); return PLAYER_ERROR; } @@ -124,7 +125,8 @@ player_result_t MediaPlayerImpl::prepare() PlayerWorker& mpw = PlayerWorker::getWorker(); if (!mpw.isAlive()) { - return ret; + meddbg("PlayerWorker is not alive\n"); + return PLAYER_ERROR; } mpw.getQueue().enQueue(&MediaPlayerImpl::preparePlayer, shared_from_this(), std::ref(ret)); @@ -189,7 +191,8 @@ player_result_t MediaPlayerImpl::unprepare() PlayerWorker& mpw = PlayerWorker::getWorker(); if (!mpw.isAlive()) { - return ret; + meddbg("PlayerWorker is not alive\n"); + return PLAYER_ERROR; } mpw.getQueue().enQueue(&MediaPlayerImpl::unpreparePlayer, shared_from_this(), std::ref(ret)); @@ -237,6 +240,7 @@ player_result_t MediaPlayerImpl::start() PlayerWorker& mpw = PlayerWorker::getWorker(); if (!mpw.isAlive()) { + meddbg("PlayerWorker is not alive\n"); return PLAYER_ERROR; } @@ -271,6 +275,7 @@ player_result_t MediaPlayerImpl::stop() PlayerWorker& mpw = PlayerWorker::getWorker(); if (!mpw.isAlive()) { + meddbg("PlayerWorker is not alive\n"); return PLAYER_ERROR; } @@ -300,6 +305,7 @@ player_result_t MediaPlayerImpl::pause() PlayerWorker& mpw = PlayerWorker::getWorker(); if (!mpw.isAlive()) { + meddbg("PlayerWorker is not alive\n"); return PLAYER_ERROR; } @@ -328,6 +334,7 @@ int MediaPlayerImpl::getVolume() PlayerWorker& mpw = PlayerWorker::getWorker(); if (!mpw.isAlive()) { + meddbg("PlayerWorker is not alive\n"); return -1; } @@ -362,6 +369,7 @@ player_result_t MediaPlayerImpl::setVolume(int vol) PlayerWorker& mpw = PlayerWorker::getWorker(); if (!mpw.isAlive()) { + meddbg("PlayerWorker is not alive\n"); return PLAYER_ERROR; } @@ -413,6 +421,7 @@ player_result_t MediaPlayerImpl::setDataSource(std::unique_ptr<stream::InputData PlayerWorker& mpw = PlayerWorker::getWorker(); if (!mpw.isAlive()) { + meddbg("PlayerWorker is not alive\n"); return PLAYER_ERROR; } @@ -452,6 +461,7 @@ player_result_t MediaPlayerImpl::setObserver(std::shared_ptr<MediaPlayerObserver PlayerWorker& mpw = PlayerWorker::getWorker(); if (!mpw.isAlive()) { + meddbg("PlayerWorker is not alive\n"); return PLAYER_ERROR; }
Use Joe's suggested change to u3_pier_snap().
@@ -524,33 +524,11 @@ _pier_work_save(u3_pier* pir_u) u3_disk* log_u = pir_u->log_u; u3_save* sav_u = pir_u->sav_u; - // This is wrong? We can have requested that the worker should snapshot - // between when the worker was given a compute request and when the worker - // returns a compute response. (See the c3_max() call in u3_pier_snap().) I - // don't know what the semantics are supposed to be here. - // - // Let's say we're in replay of the event log from nothing. We might have - // u3_pier_snap() called from a timer. I've seen crashes when: - // - // god_u->dun_d: 24, sav_u->req_d: 25, log_u->com_d: 31 - // - // com_d is greater than req_d is greater than dun_d because we're waiting - // for the worker to complete replay of already committed events. And this - // seems OK because we can totally request that the worker produce a snapshot - // of event 25 even though we haven't marked it as done because we know that - // it committed previously? - // - // No! This breaks because it ignores the req_d and instead tells the worker - // to go with what was req_d. - // - // c3_assert( god_u->dun_d == sav_u->req_d ); - + c3_assert( god_u->dun_d == sav_u->req_d ); c3_assert( log_u->com_d >= god_u->dun_d ); { - // TODO: Verify change to req_d is correct during code review. - // - u3_noun mat = u3ke_jam(u3nc(c3__save, u3i_chubs(1, &sav_u->req_d))); + u3_noun mat = u3ke_jam(u3nc(c3__save, u3i_chubs(1, &god_u->dun_d))); u3_newt_write(&god_u->inn_u, mat, 0); // XX wait on some report of success before updating? @@ -1771,7 +1749,8 @@ u3_pier_snap(u3_pier* pir_u) // save eagerly if all computed events are already committed // - if ( log_u->com_d >= top_d ) { + if ( (log_u->com_d >= top_d) && + (god_u->dun_d == top_d) ) { _pier_work_save(pir_u); } }
Retransmit lastPayload instead of resetting the whole process.
@@ -124,7 +124,6 @@ void cjoin_retransmission_cb(opentimer_id_t id) { } void cjoin_retransmission_task_cb() { - cjoin_vars.lastPayload = NUMBER_OF_EXCHANGES - 1; // get around the bug of starting with 1 after retransmit cjoin_sendPut(cjoin_vars.lastPayload); }
Fixed duplicaiton in struct
@@ -418,7 +418,6 @@ typedef struct libxsmm_matcopy_kernel_config_struct { unsigned int alu_cmp_instruction; unsigned int alu_jmp_instruction; unsigned int alu_mov_instruction; - unsigned int prefetch_instruction; char vector_name; } libxsmm_matcopy_kernel_config;
ExtendedTools: Add workaround for upstream PresentMon memory corruption on Windows 8.1
@@ -1348,6 +1348,39 @@ void HandleDWMEvent(EVENT_RECORD* pEventRecord) break; } + if (PhWindowsVersion > WINDOWS_7 && PhWindowsVersion < WINDOWS_10) + { + EventDataDesc desc[] = { + { L"ulFlipChain" }, + { L"ulSerialNumber" }, + { L"hwnd" }, + }; + mMetadata.GetEventData(pEventRecord, desc, _countof(desc)); + auto ulFlipChain = desc[0].GetData<uint64_t>(); + auto ulSerialNumber = desc[1].GetData<uint64_t>(); + auto hwnd = desc[2].GetData<uint64_t>(); + + // Lookup the present using the 64-bit token data from the PHT + // submission, which is actually two 32-bit data chunks corresponding + // to a flip chain id and present id. + auto tokenData = ((uint64_t)ulFlipChain << 32ull) | ulSerialNumber; + auto flipIter = mPresentByDxgkPresentHistoryTokenData.find(tokenData); + if (flipIter != mPresentByDxgkPresentHistoryTokenData.end()) { + auto present = flipIter->second; + + TRACK_PRESENT_PATH(present); + + //DebugModifyPresent(present.get()); + present->DxgkPresentHistoryTokenData = 0; + present->DwmNotified = true; + + mLastPresentByWindow[hwnd] = present; + + mPresentByDxgkPresentHistoryTokenData.erase(flipIter); + } + } + else + { EventDataDesc desc[] = { { L"ulFlipChain" }, { L"ulSerialNumber" }, @@ -1376,9 +1409,34 @@ void HandleDWMEvent(EVENT_RECORD* pEventRecord) mPresentByDxgkPresentHistoryTokenData.erase(flipIter); } - break; } + } + break; case Microsoft_Windows_Dwm_Core::SCHEDULE_SURFACEUPDATE_Info::Id: + { + if (PhWindowsVersion > WINDOWS_7 && PhWindowsVersion < WINDOWS_10) + { + EventDataDesc desc[] = { + { L"luidSurface" }, + { L"OutOfFrameDirectFlipPresentCount" }, + { L"bindId" }, + }; + mMetadata.GetEventData(pEventRecord, desc, _countof(desc)); + auto luidSurface = desc[0].GetData<uint64_t>(); + auto PresentCount = desc[1].GetData<uint64_t>(); + auto bindId = desc[2].GetData<uint64_t>(); + + Win32KPresentHistoryToken key(luidSurface, PresentCount, bindId); + auto eventIter = mPresentByWin32KPresentHistoryToken.find(key); + if (eventIter != mPresentByWin32KPresentHistoryToken.end() && eventIter->second->SeenInFrameEvent) { + TRACK_PRESENT_PATH(eventIter->second); + //DebugModifyPresent(eventIter->second.get()); + eventIter->second->DwmNotified = true; + mPresentsWaitingForDWM.emplace_back(eventIter->second); + eventIter->second->PresentInDwmWaitingStruct = true; + } + } + else { EventDataDesc desc[] = { { L"luidSurface" }, @@ -1399,8 +1457,9 @@ void HandleDWMEvent(EVENT_RECORD* pEventRecord) mPresentsWaitingForDWM.emplace_back(eventIter->second); eventIter->second->PresentInDwmWaitingStruct = true; } - break; } + } + break; default: //assert(!mFilteredEvents || // Assert that filtering is working if expected // hdr.ProviderId == Microsoft_Windows_Dwm_Core::Win7::GUID);
plugins: in_tcp: make TLS optional
@@ -200,5 +200,5 @@ struct flb_input_plugin in_tcp_plugin = { .cb_flush_buf = NULL, .cb_exit = in_tcp_exit, .config_map = config_map, - .flags = FLB_INPUT_NET | FLB_IO_TLS, + .flags = FLB_INPUT_NET | FLB_IO_OPT_TLS, };
[examples] fix occ_slider_crank.py
@@ -142,17 +142,20 @@ with Hdf5() as io: io.addJoint('joint1', 'part1', points=[[0., 0., 0.]], axes=[[0., 1., 0.]], - joint_class='PivotJointR') + joint_class='PivotJointR', + absolute=True) io.addJoint('joint2', 'part2', 'slider', - points=[[0.5*l2, 0., 0.]], + points=[[l1+l2, 0., 0.]], axes=[[0., 1., 0]], - joint_class='PivotJointR') + joint_class='PivotJointR', + absolute=True) io.addJoint('joint3', 'part1', 'part2', points=[[l1, 0., 0.]], axes=[[0., 1., 0.]], - joint_class='PivotJointR') + joint_class='PivotJointR', + absolute=True) io.addInteraction('contact10', body1_name='slider', contactor1_name='Contact_b_f0',
Improve Card decoding.
@@ -169,11 +169,11 @@ static void snap_version(void *handle) snap_card_ioctl(handle, GET_CARD_TYPE, (unsigned long)&ioctl_data); VERBOSE1("SNAP on "); switch (ioctl_data) { - case 0: VERBOSE1("ADKU3"); break; - case 1: VERBOSE1("N250S"); break; - case 2: VERBOSE1("S121B"); break; - case 3: VERBOSE1("AD8K5"); break; - case 16: VERBOSE1("N250SP"); break; + case ADKU3_CARD: VERBOSE1("ADKU3"); break; + case N250S_CARD: VERBOSE1("N250S"); break; + case S121B_CARD: VERBOSE1("S121B"); break; + case AD8K5_CARD: VERBOSE1("AD8K5"); break; + case N250SP_CARD: VERBOSE1("N250SP"); break; default: VERBOSE1("Unknown"); break; } VERBOSE1(" Card, NVME ");
[CI] Use cache key with a prebuilt toolchain
@@ -37,7 +37,7 @@ jobs: path: | x86_64-toolchain axle-sysroot - key: libc-and-toolchain + key: libc-and-toolchain-2 - name: Build libc and toolchain shell: bash
Testing: Change packing in threads test
@@ -54,6 +54,7 @@ static int encode_file(char* input_file, char* output_file) grib_handle* source_handle = NULL; const void* buffer = NULL; int err = 0; + size_t str_len = 0; FILE* in = fopen(input_file, "rb"); FILE* out = fopen(output_file, "wb"); @@ -86,6 +87,10 @@ static int encode_file(char* input_file, char* output_file) count++; } GRIB_CHECK(grib_set_long(clone_handle, "bitsPerValue", 16), 0); + + /*GRIB_CHECK(grib_set_string(clone_handle, "packingType", "grid_ccsds", &str_len), 0);*/ + GRIB_CHECK(grib_set_string(clone_handle, "packingType", "grid_simple", &str_len), 0); + GRIB_CHECK(grib_set_double_array(clone_handle, "values", values, values_len), 0); /* get the coded message in a buffer */
pm: add lock for pm_auto_updatestate_cb()
@@ -42,9 +42,14 @@ static void pm_auto_updatestate_cb(FAR void *arg) { int domain = (uintptr_t)arg; enum pm_state_e newstate; + irqstate_t flags; + + flags = pm_lock(domain); newstate = pm_checkstate(domain); pm_changestate(domain, newstate); + + pm_unlock(domain, flags); } /****************************************************************************
Update oc_obt.h
@@ -742,11 +742,11 @@ int oc_obt_provision_identity_certificate(oc_uuid_t *uuid, * @see oc_obt_add_roleid * @see oc_obt_free_roleid */ - int oc_obt_pki_add_identity_cert(size_t device, const unsigned char *cert, size_t cert_size, const unsigned char *key, size_t key_size, oc_sec_credusage_t credusage); #endif /* OC_OSCORE */ + /** * Provision a role certificate to a Client application. *
Added links to the Cortex-A7 and -A9 reference manuals to documentation overview.
@@ -41,8 +41,8 @@ CMSIS supports a selected subset of <a href="http://www.arm.com/products/process The Cortex-A Reference Manuals are generic user guides for devices that implement the various ARM Cortex-A processors. These manuals contain the programmers model and detailed information about the core peripherals. -- <a nohref target="_blank"><b>Cortex-A7</b></a> (ARMv7-A architecture) -- <a nohref target="_blank"><b>Cortex-A9</b></a> (ARMv7-A architecture) +- <a href="http://infocenter.arm.com/help/topic/com.arm.doc.ddi0464f/DDI0464F_cortex_a7_mpcore_r0p5_trm.pdf" target="_blank"><b>Cortex-A7</b></a> (ARMv7-A architecture) +- <a href="http://infocenter.arm.com/help/topic/com.arm.doc.100511_0401_10_en/arm_cortexa9_trm_100511_0401_10_en.pdf" target="_blank"><b>Cortex-A9</b></a> (ARMv7-A architecture) <hr>
Extend test of passing parser as userData
@@ -1728,7 +1728,10 @@ START_TEST(test_user_parameters) "<?xml version='1.0' encoding='us-ascii'?>\n" "<!-- Primary parse -->\n" "<!DOCTYPE doc SYSTEM 'foo'>\n" - "<doc>&entity;</doc>"; + "<doc>&entity;"; + const char *epilog = + "<!-- Back to primary parser -->\n" + "</doc>"; comment_count = 0; XML_SetParamEntityParsing(parser, XML_PARAM_ENTITY_PARSING_ALWAYS); @@ -1737,10 +1740,16 @@ START_TEST(test_user_parameters) XML_UseParserAsHandlerArg(parser); XML_SetUserData(parser, (void *)1); handler_data = parser; - if (_XML_Parse_SINGLE_BYTES(parser, text, strlen(text), XML_TRUE) == XML_STATUS_ERROR) + if (_XML_Parse_SINGLE_BYTES(parser, text, strlen(text), + XML_FALSE) == XML_STATUS_ERROR) xml_failure(parser); if (comment_count != 2) fail("Comment handler not invoked enough times"); + if (_XML_Parse_SINGLE_BYTES(parser, epilog, strlen(epilog), + XML_TRUE) == XML_STATUS_ERROR) + xml_failure(parser); + if (comment_count != 3) + fail("Comment handler not invoked enough times"); } END_TEST
added keepalive for dynomite listen connection
@@ -234,6 +234,13 @@ rstatus_t conn_listen(struct context *ctx, struct conn *p) { return DN_ERROR; } + status = dn_set_keepalive(p->sd, 1); + if (status != DN_OK) { + log_error("set keepalive on p %d on addr '%.*s' failed: %s", p->sd, + p->pname.len, p->pname.data, strerror(errno)); + // Continue since this is not catastrophic + } + status = conn_event_add_conn(p); if (status < 0) { log_error("event add conn p %d on addr '%.*s' failed: %s", p->sd,
I corrected a typo in the visit closed build script for building on shark.
@@ -375,7 +375,7 @@ gunzip -c $dist.tar.gz | tar xvf - > buildlog 2>&1 cd $dist/src ver=\`cat VERSION\` ver2=\`echo \$ver | tr "." "_"\` -/usr/workspace/ws1/visit/visit/thirdparty_shared/2.13.0/blueos3/cmake/3.8.1/linux-ppc64le_gcc-4.9/bin/cmake . -DCMAKE_BUILD_TYPE:STRING=Release -DVISIT_INSTALL_THIRD_PARTY:BOOL=ON >> ../../buildlog 2>&1 +/usr/workspace/ws1/visit/visit/thirdparty_shared/2.13.3/blueos3/cmake/3.8.1/linux-ppc64le_gcc-4.9/bin/cmake . -DCMAKE_BUILD_TYPE:STRING=Release -DVISIT_INSTALL_THIRD_PARTY:BOOL=ON >> ../../buildlog 2>&1 make -j 6 >> ../../buildlog 2>&1 make -j 6 package >> ../../buildlog 2>&1 mv visit\$ver2.linux-intel.tar.gz ../..
tests: skip whitespace on vendor/*
@@ -11,7 +11,7 @@ push(@exempted, glob("m4/*backport*m4")); my %exempted_hash = map { $_ => 1 } @exempted; my @stuff = split /\0/, `git ls-files -z -c -m -o --exclude-standard`; -my @files = grep { ! $exempted_hash{$_} } @stuff; +my @files = grep { ! $exempted_hash{$_} && $_ !~ m/^vendor\// } @stuff; unless (@files) { warn "ERROR: You don't seem to be running this from a git checkout\n";
fix(memory leak): add exception catch to fiscobcos demo.
@@ -219,7 +219,7 @@ BOAT_RESULT fiscobcos_helloworld(BoatFiscobcosWallet *wallet_ptr) int main(int argc, char *argv[]) { BOAT_RESULT result = BOAT_SUCCESS; - + boat_try_declare; /* step-1: Boat SDK initialization */ BoatIotSdkInit(); @@ -235,12 +235,14 @@ int main(int argc, char *argv[]) result = fiscobcos_loadPersistWallet("fiscobcos.cfg"); #else //BoatLog(BOAT_LOG_NORMAL, ">>>>>>>>>> none wallet type selected."); - return -1; + //return -1; + result = BOAT_ERROR; #endif if (result != BOAT_SUCCESS) { //BoatLog(BOAT_LOG_CRITICAL, "fiscobcosWalletPrepare_create failed : %d.", result); - return -1; + //return -1; + boat_throw(result, fiscobcos_demo_catch); } /* step-3: execute 'fiscobcos_call_helloworld' */ @@ -253,7 +255,9 @@ int main(int argc, char *argv[]) { //BoatLog(BOAT_LOG_NORMAL, "fiscobcos helloworld access Passed."); } - + boat_catch(fiscobcos_demo_catch) + { + } /* step-4: Boat SDK Deinitialization */ BoatIotSdkDeInit();
[DeviceDrivers][SFUD] Add LOCAL_CCFLAGS to SFUD SConscript.
from building import * +import rtconfig cwd = GetCurrentDir() src = ['spi_core.c', 'spi_dev.c'] CPPPATH = [cwd, cwd + '/../include'] +LOCAL_CCFLAGS = '' src_device = [] @@ -32,9 +34,13 @@ if GetDepend('RT_USING_SFUD'): CPPPATH += [cwd + '/sfud/inc'] if GetDepend('RT_SFUD_USING_SFDP'): src_device += ['sfud/src/sfud_sfdp.c'] + if rtconfig.CROSS_TOOL == 'gcc': + LOCAL_CCFLAGS += ' -std=c99' + elif rtconfig.CROSS_TOOL == 'keil': + LOCAL_CCFLAGS += ' --c99' src += src_device -group = DefineGroup('DeviceDrivers', src, depend = ['RT_USING_SPI'], CPPPATH = CPPPATH) +group = DefineGroup('DeviceDrivers', src, depend = ['RT_USING_SPI'], CPPPATH = CPPPATH, LOCAL_CCFLAGS = LOCAL_CCFLAGS) Return('group')
Fix some comments in xlogreader.h segment_open and segment_close were mentioned with incorrect names. Discussion:
* XLogReadRecord or XLogFindNextRecord; it can be passed in as NULL * otherwise. The WALRead function can be used as a helper to write * page_read callbacks, but it is not mandatory; callers that use it, - * must supply open_segment callbacks. The close_segment callback + * must supply segment_open callbacks. The segment_close callback * must always be supplied. * * After reading a record with XLogReadRecord(), it's decomposed into
tutorial: bump version
@@ -50,7 +50,7 @@ This basic tutorial shows you how to compile and run a very basic Elektra applic -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done - -- Elektra 0.9.0 found + -- Elektra 0.9.1 found -- Configuring done -- Generating done -- Build files have been written to: Hello/build
Fix openmv-fb.py script.
-#!/usr/bin/env python +#!/usr/bin/env python2 import sys # import usb.core # import usb.util @@ -33,13 +33,38 @@ if 'darwin' in sys.platform: portname = "/dev/cu.usbmodem14221" else: portname = "/dev/openmvcam" -openmv.init(portname) + +connected = False +openmv.disconnect() +for i in range(10): + try: + # opens CDC port. + # Set small timeout when connecting + openmv.init(portname, baudrate=921600, timeout=0.050) + connected = True + break + except Exception as e: + connected = False + sleep(0.100) + +if not connected: + print ( "Failed to connect to OpenMV's serial port.\n" + "Please install OpenMV's udev rules first:\n" + "sudo cp openmv/udev/50-openmv.rules /etc/udev/rules.d/\n" + "sudo udevadm control --reload-rules\n\n") + sys.exit(1) + +# Set higher timeout after connecting for lengthy transfers. +openmv.set_timeout(1*2) # SD Cards can cause big hicups. +openmv.stop_script() +openmv.enable_fb(True) openmv.exec_script(script) # init screen running = True Clock = pygame.time.Clock() font = pygame.font.SysFont("monospace", 15) + while running: Clock.tick(100)
notifications: update count on archive
@@ -386,5 +386,7 @@ function archive(json: any, state: HarkState) { notifIdxEqual(index, idxNotif.index) ); state.notifications.set(time, unarchived); + const newlyRead = archived.filter(x => !x.notification.read).length; + updateNotificationStats(state, index, 'notifications', (x) => x - newlyRead); } }
docs - removed analyze step for recovering a failed master.
<codeph>Active</codeph>. When a standby master is not configured, the command displays <codeph>No master standby configured</codeph> for the standby master status. If you configured a new standby master, its status is <codeph>Passive</codeph>. </p></li> - <li id="ki169625">After switching to the newly active master host, run - <codeph>ANALYZE</codeph> on it. For - example:<codeblock>$ psql <codeph>dbname</codeph> -c 'ANALYZE;'</codeblock></li> <li id="ki155823">Optional: If you have not already done so while activating the prior standby master, you can run <codeph>gpinitstandby</codeph> on the active master host to configure a new standby master.
Fix build failure for ub18-relassert
@@ -172,7 +172,7 @@ verify(struct mtf_test_info *lcl_ti, void *cur, struct nkv_tab *vtab, int vc, in val = vc ? vtab[0].val1 : 0; while (1) { - struct kvs_kvtuple kvt; + struct kvs_kvtuple kvt = {0}; const int * ip; cn_cursor_read_internal(lcl_ti, cur, &kvt, &eof);
dev-tools/scipy: bump to v1.1.0
@@ -43,7 +43,7 @@ Requires: openblas-%{compiler_family}%{PROJ_DELIM} %define PNAME %(echo %{pname} | tr [a-z] [A-Z]) Name: %{python_prefix}-%{pname}-%{compiler_family}-%{mpi_family}%{PROJ_DELIM} -Version: 1.0.0 +Version: 1.1.0 Release: 1%{?dist} Summary: Scientific Tools for Python License: BSD-3-Clause
Require at least base 4.7 (i.e. GHC 7.8) Older GHC versions are not tested, so no compatibility is claimed.
@@ -42,7 +42,8 @@ flag luajit default: False library - build-depends: base == 4.*, bytestring >= 0.10.2.0 && < 0.11 + build-depends: base >= 4.7 && < 5, + bytestring >= 0.10.2 && < 0.11 exposed-modules: Scripting.Lua, Scripting.Lua.Raw hs-source-dirs: src ghc-options: -Wall -O2
add hoverclient
@@ -1475,8 +1475,12 @@ drawbar(Monitor *m) if (m->sel == c) { //background color rectangles to draw circle on - if (!c->issticky) + if (!c->issticky) { + if (c == selmon->hoverclient && !selmon->gesture) + drw_setscheme(drw, scheme[SchemeHoverTags]); + else drw_setscheme(drw, scheme[SchemeTags]); + } else drw_setscheme(drw, scheme[SchemeActive]); @@ -1517,10 +1521,12 @@ drawbar(Monitor *m) if (HIDDEN(c)) { scm = SchemeHid; } else{ - if (!c->issticky) - scm = SchemeNorm; - else + if (c->issticky) scm = SchemeAddActive; + else if (c == selmon->hoverclient && !selmon->gesture) + scm = SchemeHover; + else + scm = SchemeNorm; } drw_setscheme(drw, scheme[scm]); if (TEXTW(c->name) < (1.0 / (double)n) * w){ @@ -2129,8 +2135,9 @@ motionnotify(XEvent *e) { static Monitor *mon = NULL; Monitor *m; + Client *c; XMotionEvent *ev = &e->xmotion; - + int x; int i; if (ev->window != root) @@ -2173,12 +2180,12 @@ motionnotify(XEvent *e) spawn(&((Arg) { .v = caretinstantswitchcmd })); topdrag = 1; } - if (!tagwidth) - tagwidth = gettagwidth(); } else if (topdrag) { topdrag = 0; } + if (!tagwidth) + tagwidth = gettagwidth(); // hover over close button if (selmon->sel) { if (ev->x_root > selmon->activeoffset && ev->x_root < (selmon->activeoffset + 32)) { @@ -2203,14 +2210,37 @@ motionnotify(XEvent *e) } } } + + if (selmon->stack) { + x = selmon->mx + tagwidth + 60; + c = selmon->clients; + + do { + if (!ISVISIBLE(c)) + continue; + else + x += (1.0 / (double)selmon->bt) * selmon->btw; + } while (ev->x_root > x && (c = c->next)); + + if (c) { + if (c != selmon->hoverclient) { + selmon->hoverclient = c; + selmon->gesture = 0; + drawbar(selmon); + } + } + } else { + selmon->hoverclient = NULL; + } } if (altcursor == 2) { resetcursor(); } } else { - if (selmon->gesture) { + if (selmon->gesture || selmon->hoverclient) { selmon->gesture = 0; + selmon->hoverclient = NULL; drawbar(selmon); }
Nuget: Store files in correct RID.
@@ -1252,17 +1252,33 @@ if(${TINYSPLINE_WITH_CSHARP}) get_filename_component(TINYSPLINE_NUGET_INTERFACE_FILE ${TINYSPLINE_CSHARP_INTERFACE_FILE} NAME) + if(${TINYSPLINE_PLATFORM_NAME} STREQUAL "linux") + set(TINYSPLINE_NUGET_RID "linux") + elseif(${TINYSPLINE_PLATFORM_NAME} STREQUAL "macosx") + set(TINYSPLINE_NUGET_RID "osx") + elseif(${TINYSPLINE_PLATFORM_NAME} STREQUAL "windows") + set(TINYSPLINE_NUGET_RID "win") + else() + message(FATAL_ERROR "Unable to determine Nuget RID (platform)") + endif() + if(${TINYSPLINE_PLATFORM_ARCH} STREQUAL "x86_64") + set(TINYSPLINE_NUGET_RID "${TINYSPLINE_NUGET_RID}-x64") + elseif(${TINYSPLINE_PLATFORM_ARCH} STREQUAL "x86") + set(TINYSPLINE_NUGET_RID "${TINYSPLINE_NUGET_RID}-x86") + else() + message(FATAL_ERROR "Unable to determine Nuget RID (arch)") + endif() set(TINYSPLINE_NUGET_FILES "<file \ src=\"${TINYSPLINE_LIB_DIR}/${TINYSPLINE_NUGET_INTERFACE_FILE}\" \ target=\"lib/${TINYSPLINE_CSHARP_FRAMEWORK_NAME}\" />") set(TINYSPLINE_NUGET_FILES "${TINYSPLINE_NUGET_FILES}\n\t\t<file \ src=\"${TINYSPLINE_LIB_DIR}/*${TINYSPLINE_CSHARP_CMAKE_TARGET}.*\" \ -target=\"runtimes/${TINYSPLINE_PLATFORM}/lib/native\" />") +target=\"runtimes/${TINYSPLINE_NUGET_RID}/lib/native\" />") foreach(lib ${TINYSPLINE_RUNTIME_LIBS}) set(TINYSPLINE_NUGET_FILES "${TINYSPLINE_NUGET_FILES}\n\t\t<file \ src=\"${TINYSPLINE_LIB_DIR}/${lib}\" \ -target=\"runtimes/${TINYSPLINE_PLATFORM}/lib/native\" />") +target=\"runtimes/${TINYSPLINE_NUGET_RID}/lib/native\" />") endforeach() configure_file( "${CMAKE_CURRENT_SOURCE_DIR}/pkg/.nuspec.in"
fix(discord-restapi.c): discord_get_channel_invites() should be REQUEST_ATTR_LIST_INIT()
@@ -908,7 +908,8 @@ discord_get_channel_invites(struct discord *client, u64_snowflake_t channel_id, struct discord_invite ***ret) { - struct discord_request_attr attr = REQUEST_ATTR_INIT(discord_invite, ret); + struct discord_request_attr attr = + REQUEST_ATTR_LIST_INIT(discord_invite, ret); ORCA_EXPECT(client, channel_id != 0, ORCA_BAD_PARAMETER); ORCA_EXPECT(client, ret != NULL, ORCA_BAD_PARAMETER); @@ -2170,8 +2171,7 @@ discord_edit_original_interaction_response( } ORCAcode -discord_delete_original_interaction_response( - struct discord *client, +discord_delete_original_interaction_response(struct discord *client, u64_snowflake_t interaction_id, const char interaction_token[]) { @@ -2605,8 +2605,7 @@ discord_modify_webhook_with_token( } ORCAcode -discord_delete_webhook(struct discord *client, - u64_snowflake_t webhook_id) +discord_delete_webhook(struct discord *client, u64_snowflake_t webhook_id) { ORCA_EXPECT(client, webhook_id != 0, ORCA_BAD_PARAMETER);
apps/progs.pl: use SOURCE_DATE_EPOCH if defined for copyright year As with use SOURCE_DATE_EPOCH for the copyright year if it is defined, to avoid reproducibility problems. CLA: trivial
@@ -21,7 +21,7 @@ die "Unrecognised option, must be -C or -H\n" my %commands = (); my $cmdre = qr/^\s*int\s+([a-z_][a-z0-9_]*)_main\(\s*int\s+argc\s*,/; my $apps_openssl = shift @ARGV; -my $YEAR = [localtime()]->[5] + 1900; +my $YEAR = [gmtime($ENV{SOURCE_DATE_EPOCH} || time())]->[5] + 1900; # because the program apps/openssl has object files as sources, and # they then have the corresponding C files as source, we need to chain
Add default handlers to character entity tests to extend coverage
@@ -580,6 +580,13 @@ START_TEST(test_latin1_umlauts) run_character_check(text, utf8); XML_ParserReset(parser, NULL); run_attribute_check(text, utf8); + /* Repeat with a default handler */ + XML_ParserReset(parser, NULL); + XML_SetDefaultHandler(parser, dummy_default_handler); + run_character_check(text, utf8); + XML_ParserReset(parser, NULL); + XML_SetDefaultHandler(parser, dummy_default_handler); + run_attribute_check(text, utf8); } END_TEST
Fix init MCPWM Fault line via config struct Merges Closes
@@ -149,8 +149,8 @@ esp_err_t mcpwm_set_pin(mcpwm_unit_t mcpwm_num, const mcpwm_pin_config_t *mcpwm_ mcpwm_gpio_init(mcpwm_num, MCPWM_SYNC_1, mcpwm_pin->mcpwm_sync1_in_num); //SYNC1 mcpwm_gpio_init(mcpwm_num, MCPWM_SYNC_2, mcpwm_pin->mcpwm_sync2_in_num); //SYNC2 mcpwm_gpio_init(mcpwm_num, MCPWM_FAULT_0, mcpwm_pin->mcpwm_fault0_in_num); //FAULT0 - mcpwm_gpio_init(mcpwm_num, MCPWM_FAULT_0, mcpwm_pin->mcpwm_fault1_in_num); //FAULT1 - mcpwm_gpio_init(mcpwm_num, MCPWM_FAULT_0, mcpwm_pin->mcpwm_fault2_in_num); //FAULT2 + mcpwm_gpio_init(mcpwm_num, MCPWM_FAULT_1, mcpwm_pin->mcpwm_fault1_in_num); //FAULT1 + mcpwm_gpio_init(mcpwm_num, MCPWM_FAULT_2, mcpwm_pin->mcpwm_fault2_in_num); //FAULT2 mcpwm_gpio_init(mcpwm_num, MCPWM_CAP_0, mcpwm_pin->mcpwm_cap0_in_num); //CAP0 mcpwm_gpio_init(mcpwm_num, MCPWM_CAP_1, mcpwm_pin->mcpwm_cap1_in_num); //CAP1 mcpwm_gpio_init(mcpwm_num, MCPWM_CAP_2, mcpwm_pin->mcpwm_cap2_in_num); //CAP2
soapy lms - removed duplicate hooks for loopback gain
@@ -426,11 +426,6 @@ void SoapyLMS7::setGain(const int direction, const size_t channel, const std::st rfic->SetRFELoopbackLNA_dB(value); } - else if (direction == SOAPY_SDR_RX and name == "LB_LNA") - { - rfic->SetRFELoopbackLNA_dB(value); - } - else if (direction == SOAPY_SDR_RX and name == "TIA") { rfic->SetRFETIA_dB(value); @@ -451,11 +446,6 @@ void SoapyLMS7::setGain(const int direction, const size_t channel, const std::st rfic->SetTRFLoopbackPAD_dB(value); } - else if (direction == SOAPY_SDR_TX and name == "LB_PAD") - { - rfic->SetTRFLoopbackPAD_dB(value); - } - else throw std::runtime_error("SoapyLMS7::setGain("+name+") - unknown gain name"); SoapySDR::logf(SOAPY_SDR_DEBUG, "Actual %s%s[%d] gain %g dB", dirName, name.c_str(), int(channel), this->getGain(direction, channel, name));
input: initialize events structures
@@ -472,7 +472,7 @@ int flb_input_set_collector_time(struct flb_input_instance *in, collector->nanoseconds = nanoseconds; collector->instance = in; collector->running = FLB_FALSE; - MK_EVENT_NEW(&collector->event); + MK_EVENT_ZERO(&collector->event); mk_list_add(&collector->_head, &config->collectors); mk_list_add(&collector->_head_ins, &in->collectors); @@ -497,7 +497,7 @@ int flb_input_set_collector_event(struct flb_input_instance *in, collector->nanoseconds = -1; collector->instance = in; collector->running = FLB_FALSE; - MK_EVENT_NEW(&collector->event); + MK_EVENT_ZERO(&collector->event); mk_list_add(&collector->_head, &config->collectors); mk_list_add(&collector->_head_ins, &in->collectors); @@ -744,7 +744,7 @@ int flb_input_set_collector_socket(struct flb_input_instance *in, collector->nanoseconds = -1; collector->instance = in; collector->running = FLB_FALSE; - MK_EVENT_NEW(&collector->event); + MK_EVENT_ZERO(&collector->event); mk_list_add(&collector->_head, &config->collectors); mk_list_add(&collector->_head_ins, &in->collectors);
bricks/virtualhub: Add -rdynamic linker option. This fixes this runtime error: ImportError: ~/.pyenv/versions/3.8.2/lib/python3.8/lib-dynload/math.cpython-38-x86_64-linux-gnu.so: undefined symbol: PyFloat_Type And similar for Python 3.10.4.
@@ -191,9 +191,8 @@ LIB_SRC_C += $(addprefix lib/,\ LIB += -lrt # embedded Python - -EMBEDED_PYTHON ?= python3.10 -PYTHON_CONFIG := $(EMBEDED_PYTHON)-config +EMBEDDED_PYTHON ?= python3.10 +PYTHON_CONFIG := $(EMBEDDED_PYTHON)-config INC += $(shell $(PYTHON_CONFIG) --includes) -LDFLAGS += $(shell $(PYTHON_CONFIG) --ldflags --embed) +LDFLAGS += -rdynamic $(shell $(PYTHON_CONFIG) --ldflags --embed)
iokernel: fix uninitialized variable
@@ -81,6 +81,7 @@ static struct proc *control_create_proc(mem_key_t key, size_t len, pid_t pid, p->sched_cfg = hdr.sched_cfg; p->thread_count = hdr.thread_count; p->uniqid = rdtsc(); + p->max_overflows = 0; p->permanent_index = bitmap_find_next_cleared(proc_map, IOKERNEL_MAX_PROC, 0); bitmap_set(proc_map, p->permanent_index); p->mac = mac_template;
added long_controls_allowed tests in GM
@@ -138,9 +138,14 @@ class TestGmSafety(unittest.TestCase): self.safety.gm_rx_hook(self._brake_msg(False)) def test_disengage_on_gas(self): + for long_controls_allowed in [0, 1]: + self.safety.set_long_controls_allowed(long_controls_allowed) self.safety.set_controls_allowed(1) self.safety.gm_rx_hook(self._gas_msg(True)) + if long_controls_allowed: self.assertFalse(self.safety.get_controls_allowed()) + else: + self.assertTrue(self.safety.get_controls_allowed()) self.safety.gm_rx_hook(self._gas_msg(False)) def test_allow_engage_with_gas_pressed(self): @@ -151,22 +156,28 @@ class TestGmSafety(unittest.TestCase): self.safety.gm_rx_hook(self._gas_msg(False)) def test_brake_safety_check(self): + for long_controls_allowed in [0, 1]: + self.safety.set_long_controls_allowed(long_controls_allowed) for enabled in [0, 1]: for b in range(0, 500): self.safety.set_controls_allowed(enabled) - if abs(b) > MAX_BRAKE or (not enabled and b != 0): + if abs(b) > MAX_BRAKE or ((not enabled or not long_controls_allowed) and b != 0): self.assertFalse(self.safety.gm_tx_hook(self._send_brake_msg(b))) else: self.assertTrue(self.safety.gm_tx_hook(self._send_brake_msg(b))) + self.safety.set_long_controls_allowed(True) def test_gas_safety_check(self): + for long_controls_allowed in [0, 1]: + self.safety.set_long_controls_allowed(long_controls_allowed) for enabled in [0, 1]: for g in range(0, 2**12-1): self.safety.set_controls_allowed(enabled) - if abs(g) > MAX_GAS or (not enabled and g != MAX_REGEN): + if abs(g) > MAX_GAS or ((not enabled or not long_controls_allowed) and g != MAX_REGEN): self.assertFalse(self.safety.gm_tx_hook(self._send_gas_msg(g))) else: self.assertTrue(self.safety.gm_tx_hook(self._send_gas_msg(g))) + self.safety.set_long_controls_allowed(True) def test_steer_safety_check(self): for enabled in [0, 1]:
doc: prettify FSP Code update docs
Code Update on FSP based machine ================================ -There are three OPAL calls for code update on FSP based machine: :: +There are three OPAL calls for code update. These are currently only +implemented on FSP based machines. + +.. code-block::c #define OPAL_FLASH_VALIDATE 76 #define OPAL_FLASH_MANAGE 77 #define OPAL_FLASH_UPDATE 78 +.. _OPAL_FLASH_VALIDATE: + OPAL_FLASH_VALIDATE ------------------- +.. code-block:: c + + #define OPAL_FLASH_VALIDATE 76 + + int64_t fsp_opal_validate_flash(uint64_t buffer, uint32_t *size, uint32_t *result); + + Validate new image is valid for this platform or not. We do below validation in OPAL: @@ -48,9 +60,17 @@ Return value ^^^^^^^^^^^^ Validation status +.. _OPAL_FLASH_MANAGE: OPAL_FLASH_MANAGE ----------------- + +.. code-block:: c + + #define OPAL_FLASH_MANAGE 77 + + int64_t fsp_opal_manage_flash(uint8_t op); + Commit/Reject image. - We can commit new image (T -> P), if system is running with T side image. @@ -69,8 +89,17 @@ op Return value Commit operation status (0 : Success) +.. _OPAL_FLASH_UPDATE: + OPAL_FLASH_UPDATE ------------------- +----------------- + +.. code-block:: c + + #define OPAL_FLASH_UPDATE 78 + + int64_t fsp_opal_update_flash(struct opal_sg_list *list); + Update new image. It only sets the flag, actual update happens during system reboot/shutdown.
remove blackbox_override
@@ -117,7 +117,7 @@ void blackbox_update() { return; } - if (blackbox_enabled == 0 && blackbox_override == 0) + if (blackbox_enabled == 0) return; blackbox.time = timer_millis(); @@ -144,7 +144,7 @@ void blackbox_update() { blackbox.pid_output = state.pidoutput; if (blackbox_enabled != 0 && (loop_counter % blackbox_rate) == 0) { - data_flash_write_backbox(&state); + data_flash_write_backbox(&blackbox); } loop_counter++;
test-suite: update ld_preload for fixed intel tau
@@ -5,7 +5,7 @@ unset OMP_NUM_THREADS export OMP_NUM_THREADS=10 if [ "x$ARCH" == "xx86_64" ];then if [ "x$LMOD_FAMILY_COMPILER" == "xintel" ];then - lib=callpath-param-papi-pdt-openmp-profile-trace + lib=callpath-param-icpc-papi-pdt-openmp-profile-trace else lib=callpath-param-papi-pdt-openmp-opari-profile-trace fi
Add a CHANGES entry for CVE-2019-1551
Changes between 1.1.1 and 3.0.0 [xx XXX xxxx] + *) Fixed an an overflow bug in the x64_64 Montgomery squaring procedure + used in exponentiation with 512-bit moduli. No EC algorithms are + affected. Analysis suggests that attacks against 2-prime RSA1024, + 3-prime RSA1536, and DSA1024 as a result of this defect would be very + difficult to perform and are not believed likely. Attacks against DH512 + are considered just feasible. However, for an attack the target would + have to re-use the DH512 private key, which is not recommended anyway. + Also applications directly using the low level API BN_mod_exp may be + affected if they use BN_FLG_CONSTTIME. + (CVE-2019-1551) + [Andy Polyakov] + *) Introduced a new method type and API, OSSL_SERIALIZER, to represent generic serializers. An implementation is expected to be able to serialize an object associated with a given name (such
arch/arm/src/stm32f7/stm32_otg.h: fix stm32_otghost_initialize definition
@@ -84,7 +84,7 @@ extern "C" #endif /**************************************************************************** - * Name: stm32_otghost_initialize + * Name: stm32_otgfshost_initialize * * Description: * Initialize USB host device controller hardware. @@ -110,7 +110,7 @@ extern "C" #ifdef CONFIG_USBHOST struct usbhost_connection_s; -struct usbhost_connection_s *stm32_otghost_initialize(int controller); +struct usbhost_connection_s *stm32_otgfshost_initialize(int controller); #endif /****************************************************************************