Sorry

This feed does not validate.

In addition, interoperability with the widest range of feed readers could be improved by implementing the following recommendations.

Source: https://www.haiku-os.org/index.xml

  1. <rss version="2.0" xmlns:atom="https://www.w3.org/2005/Atom"><channel><title>Haiku Project</title><link>https://www.haiku-os.org/</link><language>en-US</language><author>Haiku Inc.</author><rights>(C) 2001-2025 Haiku, Inc. All rights reserved.</rights><updated>Sat, 20 Jun 2026 19:04:24 +0000</updated><item><title>Haiku Activity &amp; Contract Report, May 2025</title><link>https://www.haiku-os.org/blog/waddlesplash/2025-06-13-haiku_activity_contract_report_may_2025/</link><author>waddlesplash</author><pubDate>Fri, 13 Jun 2025 22:30:00 -0400</pubDate><guid>https://www.haiku-os.org/blog/waddlesplash/2025-06-13-haiku_activity_contract_report_may_2025/</guid><description>&lt;p>This report covers hrev58848 through hrev58897.&lt;/p>
  2. &lt;h3 id="applications">Applications&lt;/h3>
  3. &lt;p>PawanYr added code to HaikuDepot for when no search results appear in the &amp;ldquo;Featured packages&amp;rdquo; tab, to show a &amp;ldquo;Click here to search all packages&amp;rdquo; message. This should hopefully allow new users to more easily figure out how to use HaikuDepot, rather than seeing no results and assuming the packages must not be there.&lt;/p>
  4. &lt;p>waddlesplash fixed a crash in Tracker when using the keyboard to navigate the Desktop view.&lt;/p>
  5. &lt;p>OscarL added support for basic glob filtering to TextSearch (based on grep&amp;rsquo;s &lt;code>--include &amp;lt;glob&amp;gt;&lt;/code> option.) humdinger came by later and added keyboard navigation for history, along with a &amp;ldquo;Clear history&amp;rdquo; option.&lt;/p>
  6. &lt;p>jackburton79 fixed a potential double-lock in Terminal&amp;rsquo;s clipboard handling code, that could happen when running Terminal as a replicant.&lt;/p>
  7. &lt;p>humdinger fixed a missing translation (for &amp;ldquo;Preferences&amp;rdquo;) in Tracker.&lt;/p>
  8. &lt;p>humdinger fixed &amp;ldquo;Close and set to&amp;hellip;&amp;rdquo; for multiple mails at a time.&lt;/p>
  9. &lt;p>jscipione (after a first attempt by humdinger) fixed the shortcut for &amp;ldquo;Select&amp;rdquo; in Tracker.&lt;/p>
  10. &lt;h3 id="command-line-tools">Command line tools&lt;/h3>
  11. &lt;p>Anarchos improved RemoteDesktop&amp;rsquo;s argument parsing for handling the optional SSH port argument. He also set it to reuse ports by default, avoiding the need to wait for timeouts.&lt;/p>
  12. &lt;p>PulkoMandy and kallisti5 made some tweaks to Time to print a help message and exit if started with unrecognized command line flags.&lt;/p>
  13. &lt;p>humdinger fixed the download URL in the &amp;ldquo;install-wifi-firmwares.sh&amp;rdquo; script (though this script is very rarely needed, because it only applies to a few very old WiFi devices. Most WiFi firmware for any system of the past ~15 years that Haiku supports is already bundled with the OS.)&lt;/p>
  14. &lt;h3 id="kits">Kits&lt;/h3>
  15. &lt;p>waddlesplash reverted some changes from earlier this year to BTextView&amp;rsquo;s word-wise/line-wise shortcuts, restoring the older (and more familiar) behavior.&lt;/p>
  16. &lt;p>PulkoMandy merged a change to significantly rework how the &lt;code>BUrl&lt;/code> class handles URL encoding: it now stores URLs always in encoded form, simplifying a lot of logic. This unfortunately meant that the API had to be broken, but as this is a Haiku-introduced class not a BeOS-derived one, that&amp;rsquo;s not quite so difficult as it could be. After updating the implementation and documentation, PulkoMandy followed up with a change adjusting all consumers of the API in the Haiku tree.&lt;/p>
  17. &lt;p>X512 fixed some incompatibilities in the flattened &lt;code>BPicture&lt;/code> format (a format that records and replays Be/Haiku-native drawing commands) between Haiku and BeOS.&lt;/p>
  18. &lt;h3 id="servers">Servers&lt;/h3>
  19. &lt;p>OscarL made a number of improvements to the Latin-American and Spanish keymaps, mostly to &lt;code>OPT+&amp;lt;key&amp;gt;&lt;/code> combinations.&lt;/p>
  20. &lt;h3 id="drivers">Drivers&lt;/h3>
  21. &lt;p>PulkoMandy upgraded ACPICA, the library used to interface with hardware ACPI, to a newer version.&lt;/p>
  22. &lt;p>korli fixed the TCP implementation not retransmitting packets during connection startup, which was causing connections to fail to initialize when communications were unreliable.&lt;/p>
  23. &lt;p>DigitalBox98 added support for Intuos4-series devices to the Wacom driver.&lt;/p>
  24. &lt;h3 id="file-systems">File systems&lt;/h3>
  25. &lt;p>Jim906 fixed the NFSv4 driver to not delete internal &lt;code>Inode&lt;/code> objects when unlinking files, allowing some more tests (from external NFSv4 testsuites) to pass. He also fixed a number of issues in the driver&amp;rsquo;s internal caching logic in various corner-cases, fixing incorrect behaviors or instabilities and other issues.&lt;/p>
  26. &lt;p>korli enabled the &amp;ldquo;checksum-seed&amp;rdquo; feature in the EXT4 driver (it seems to be enabled by default on recent Linux, so this allows the EXT4 driver to once again read and write partitions created with the default settings from Linux.)&lt;/p>
  27. &lt;p>waddlesplash fixed some crashes related to the creation of large files, and the overwriting of hardlinked files, in the &amp;ldquo;RAMFS&amp;rdquo; filesystem.&lt;/p>
  28. &lt;h3 id="libroot--kernel">libroot &amp;amp; kernel&lt;/h3>
  29. &lt;p>waddlesplash fixed another instance of the &amp;ldquo;Failed to acquire spinlock for a long time&amp;rdquo; kernel panic that could occur when onscreen debug output was enabled.&lt;/p>
  30. &lt;p>waddlesplash added code to the BIOS (x86) bootloader to automatically zero all registers before making BIOS calls.&lt;/p>
  31. &lt;p>waddlesplash enhanced an assertion failure message in the virtual memory layer, to help with diagnosing some issues.&lt;/p>
  32. &lt;p>waddlesplash fixed a number of crashes in the updated &lt;code>libio&lt;/code> code (from upstream &lt;code>glibc&lt;/code>) on the legacy (GCC2) ABI.&lt;/p>
  33. &lt;p>kallisti5 added more debug prints to some ELF loading failure conditions in the bootloader.&lt;/p>
  34. &lt;p>Habbie fixed the compilation of the BIOS bootloader with some extra disk-device-related tracing enabled.&lt;/p>
  35. &lt;p>waddlesplash switched back from the musl-based &lt;code>strtol&lt;/code>, &lt;code>strtod&lt;/code>, etc. routines to the glibc ones. It seems that while the musl ones work fine for musl&amp;rsquo;s usecases, Haiku&amp;rsquo;s greater support for C internationalization combined with musl&amp;rsquo;s more limited support confuses applications and was causing problems. musl seems to be working on adding more support to these and other routines, so perhaps in the future we will be able to switch to musl&amp;rsquo;s code once more and stick to it. (This revert doesn&amp;rsquo;t affect the other musl-related code in libroot, nor the other upgrades to the glibc-based code.)&lt;/p>
  36. &lt;p>waddlesplash fixed validation that the requested locale in &lt;code>setlocale()&lt;/code> really exists (and to bail out if it doesn&amp;rsquo;t.) Previously any string was accepted, even ones for completely bogus locales, which was causing crashes in some rare circumstances later on.&lt;/p>
  37. &lt;h3 id="documentation">Documentation&lt;/h3>
  38. &lt;p>waddlesplash made the new &lt;code>BQuery::SetFlags&lt;/code> method behave like the other &lt;code>Set...()&lt;/code> methods in &lt;code>BQuery&lt;/code>, and wrote documentation for it.&lt;/p>
  39. &lt;p>jscipione added some more explanations about &lt;code>BControl&lt;/code>&amp;rsquo;s status as an abstract class to its documentation.&lt;/p>
  40. &lt;h3 id="build-system">Build system&lt;/h3>
  41. &lt;p>PulkoMandy fixed an &amp;ldquo;unused variable&amp;rdquo; warning. X512 deleted some unneeded code.&lt;/p>
  42. &lt;p>PulkoMandy dropped a number of redundant build rules for binaries from Jam (&lt;code>Server&lt;/code>, &lt;code>Preference&lt;/code>, etc.) and consolidated most of them to all use the &lt;code>Application&lt;/code> rule. waddlesplash followed up later with another change finishing the rest.&lt;/p>
  43. &lt;p>OscarL added &lt;code>INSTALL_DIR&lt;/code> and &lt;code>TARGET_DIR&lt;/code> to the Makefile-Engine&amp;rsquo;s example Makefile, along with comments explaining how they can be used to define where &lt;code>make&lt;/code> and &lt;code>make install&lt;/code> place the binaries.&lt;/p>
  44. &lt;p>kallisti5 made some preliminary changes for GCC 15 support in the system headers.&lt;/p>
  45. &lt;h3 id="risc-v">RISC-V&lt;/h3>
  46. &lt;p>kallisti5 fixed a linker script and updated a package for RISC-V, which should make the port boot once more.&lt;/p>
  47. &lt;h3 id="thats-all-folks">That&amp;rsquo;s all, folks!&lt;/h3>
  48. &lt;p>This month was a bit lighter than usual, it seems most of the developers (myself included) were busy with other things&amp;hellip; however, HaikuPorts remained quite active: most months, at this point, there are more commits to HaikuPorts than Haiku, and sometimes by a significant margin, too (for May, it was 52 in Haiku vs. &lt;em>258&lt;/em> in HaikuPorts!). I think overall this is a sign of Haiku&amp;rsquo;s growing maturity: the system seems stable enough that the porters can do their work without uncovering too many bugs in Haiku that interrupt or halt their progress.&lt;/p>
  49. &lt;p>Thanks again to all who contribute to Haiku, and especially those donors who make my contract possible!&lt;/p></description></item><item><title>Journées du Logiciel Libre (JDLL)</title><link>https://www.haiku-os.org/conference/2025_journ%C3%A9es_du_logiciel_libre_jdll/</link><pubDate>Thu, 22 May 2025 01:00:00 +0000</pubDate><guid>https://www.haiku-os.org/conference/2025_journ%C3%A9es_du_logiciel_libre_jdll/</guid><description>&lt;p>Free software booths, and a lot of talks for both the general public and developers. Also games for kids, and 3D printing and other demos by the local fablab.&lt;/p>
  50. &lt;p>French speaking event.&lt;/p>
  51. &lt;hr>
  52. &lt;ul>
  53. &lt;li>Event Dates: 2025-05-24 - 2025-05-25&lt;/li>
  54. &lt;li>Event Homepage: &lt;a href="http://www.jdll.org/">http://www.jdll.org/&lt;/a>&lt;/li>
  55. &lt;li>Activities:
  56. &lt;ul>
  57. &lt;li>&lt;strong>No&lt;/strong> Haiku booth this year as PulkoMandy can&amp;rsquo;t attend to help.&lt;/li>
  58. &lt;li>A talk by mmu_man about &amp;ldquo;What&amp;rsquo;s new in Haiku?&amp;rdquo; (news from the last year in Haiku development).&lt;/li>
  59. &lt;/ul>
  60. &lt;/li>
  61. &lt;/ul>
  62. &lt;h2 id="location">Location&lt;/h2>
  63. &lt;p>&lt;a href="https://jdll.org/contact-and-informations">ENS site Descartes&lt;/a>,&lt;br/>
  64. 19 allée de Fontenay,&lt;br/>
  65. 69007 Lyon&lt;br/>
  66. France&lt;/p>
  67. &lt;h2 id="event-report">Event report:&lt;/h2>
  68. &lt;p>TODO&lt;/p></description></item><item><title>Haiku Activity &amp; Contract Report, April 2025</title><link>https://www.haiku-os.org/blog/waddlesplash/2025-05-12-haiku_activity_contract_report_april_2025/</link><author>waddlesplash</author><pubDate>Mon, 12 May 2025 20:30:00 -0400</pubDate><guid>https://www.haiku-os.org/blog/waddlesplash/2025-05-12-haiku_activity_contract_report_april_2025/</guid><description>&lt;p>This report covers hrev58788 through hrev58847.&lt;/p>
  69. &lt;h3 id="applications">Applications&lt;/h3>
  70. &lt;p>jackburton79 fixed a case where the cursor color in Terminal wouldn&amp;rsquo;t be initialized, especially notable when running Terminal as a replicant. He also added support for executing commands in Terminal using the scripting API, and made the cursor when the view isn&amp;rsquo;t focused empty instead of filled.&lt;/p>
  71. &lt;p>ilzu made a number of improvements to session management on startup in WebPositive, including restoring the previous session even if launched to open a link, saving and restoring workspaces, and more.&lt;/p>
  72. &lt;p>OscarL adjusted StyledEdit to block most ASCII control characters from being typed.&lt;/p>
  73. &lt;p>humdinger adjusted LaunchBox to make an error message translatable.&lt;/p>
  74. &lt;p>humdinger added checks to Sounds to more gracefully handle the &amp;ldquo;sounds&amp;rdquo; directory not existing.&lt;/p>
  75. &lt;p>waddlesplash made a number of fixes to Tracker, including: fixing a memory leak of menu items, avoiding rebuilding menus when not necessary, avoiding rescanning templates on every rebuild of the context menu, caching add-ons&amp;rsquo; supported mimetypes rather than re-scanning them frequently, watching a directory and all its child nodes at once rather than each node individually, and other changes to significantly improve performance and responsiveness when opening menus, selecting files, or using queries along with code cleanups and other improvements.&lt;/p>
  76. &lt;p>PawanYr contributed a large change to add area selection support to the Screenshot application.&lt;/p>
  77. &lt;h3 id="command-line-tools">Command line tools&lt;/h3>
  78. &lt;p>jmairboeck modified &lt;code>listusb&lt;/code> so that the &amp;ldquo;port status&amp;rdquo; information is properly aligned in the printed output.&lt;/p>
  79. &lt;p>waddlesplash made the &lt;code>leak_analyser&lt;/code> tool ignore everything allocated inside the internal Locale Kit initialization routine, as this isn&amp;rsquo;t destroyed on close.&lt;/p>
  80. &lt;h3 id="kits">Kits&lt;/h3>
  81. &lt;p>waddlesplash added some more NULL checks to &lt;code>BString&lt;/code>, fixing crashes in out-of-memory situations.&lt;/p>
  82. &lt;p>A patch from bitigchi to make &lt;code>BDecimalSpinner&lt;/code> use &lt;code>BNumberFormat&lt;/code>, for locale-aware number formatting and parsing, was merged.&lt;/p>
  83. &lt;p>augiedoggie added a MIME definition for the generic &amp;ldquo;flattened BMessage&amp;rdquo; type, so that such files have more information shown about them in Tracker than just &amp;ldquo;file&amp;rdquo;.&lt;/p>
  84. &lt;p>waddlesplash made some cleanups to the dispatch of shortcuts without the &lt;code>Cmd&lt;/code> key.&lt;/p>
  85. &lt;p>X512 fixed a bug in &lt;code>BPopUpMenu&lt;/code> that was setting up shortcuts in the wrong window. This fixes a number of regressions (since beta5) in shortcut handling that had been quite annoying.&lt;/p>
  86. &lt;h3 id="servers">Servers&lt;/h3>
  87. &lt;p>waddlesplash made a number of changes to the HID drivers and input_server device handlers to make &amp;ldquo;interruptions&amp;rdquo; (i.e. &lt;code>SIGINT&lt;/code>) be handled properly, allowing input_server to be exited instead of hanging forever.&lt;/p>
  88. &lt;h3 id="drivers">Drivers&lt;/h3>
  89. &lt;p>ilzu added support to the Wacom driver for the &amp;ldquo;Cintiq13HD&amp;rdquo; device.&lt;/p>
  90. &lt;p>kuku929 tried to add support for more than one PCI bus on x86 (needed for certain kinds of bridge devices), but unfortunately the change caused boot regressions and had to be reverted.&lt;/p>
  91. &lt;p>Captain0xFF added device IDs for more Polaris10-series GPUs to the &lt;code>radeon_hd&lt;/code> driver.&lt;/p>
  92. &lt;p>waddlesplash fixed a boot failure regression in the NVMe driver after last month&amp;rsquo;s changes to activate power-saving, and korli fixed an oversight that was not passing the right parameters down to the device for power saving.&lt;/p>
  93. &lt;p>waddlesplash added another check to the &lt;code>acpi_battery&lt;/code> driver that fixed the boot on at least one machine.&lt;/p>
  94. &lt;h3 id="file-systems">File systems&lt;/h3>
  95. &lt;p>waddlesplash reworked some unused code in the query parser/evaluator to add a &lt;code>B_QUERY_WATCH_ALL&lt;/code> flag, which makes the query send node monitoring notifications for all changes to files within the query, not just changes that result in a file getting added or removed from the query results. (This is now used in Tracker to considerably improve the efficiency of queries with large numbers of results.) For now, the flag is private, but it could easily be made public in the future. He also made changes to avoid sending duplicate rename notifications when this flag is set.&lt;/p>
  96. &lt;h3 id="libroot--kernel">libroot &amp;amp; kernel&lt;/h3>
  97. &lt;p>waddlesplash changed libroot to call thread-exit hooks after C++ destructors during exit, fixing some crashes in certain applications.&lt;/p>
  98. &lt;p>PulkoMandy added a declaration for &lt;code>MAP_FILE&lt;/code> to the headers, which some applications want to use with &lt;code>mmap&lt;/code> &amp;ldquo;just to be sure&amp;rdquo; (it&amp;rsquo;s not needed on Haiku and is defined to &lt;code>0&lt;/code>.)&lt;/p>
  99. &lt;p>waddlesplah replaced the (very old) glibc string to integer/float conversion routines in libroot with musl&amp;rsquo;s (and then deleted the glibc versions.)&lt;/p>
  100. &lt;p>zeldakatze made some tweaks to the PowerPC paging code to make it build after recent refactors.&lt;/p>
  101. &lt;p>waddlesplash made a number of changes to the page-freeing logic in the new &lt;code>malloc&lt;/code>&amp;rsquo;s global cache to better handle &amp;ldquo;fragmented&amp;rdquo; frees and avoid creating thousands of areas unnecessarily.&lt;/p>
  102. &lt;p>trungnt2910 added call-frame information annotations to the syscall wrapper routines, so that they can be handled properly by &lt;code>libunwind&lt;/code> and other such tools.&lt;/p>
  103. &lt;p>trungnt2910 added support for &lt;code>RTLD_NOLOAD&lt;/code>, an extension that&amp;rsquo;s not in POSIX but is broadly available on other OSes that support &lt;code>dlopen&lt;/code>. He also made &lt;code>dladdr&lt;/code> work on &lt;code>commpage&lt;/code> symbols, which will allow &lt;code>libunwind&lt;/code> to properly unwind exceptions even through signal frames.&lt;/p>
  104. &lt;p>korli added UNIX-style load-average tracking (i.e. &lt;code>getloadavg(3)&lt;/code>) to the kernel and &lt;code>libbsd.so&lt;/code>, allowing some build and test tools to more intelligently schedule jobs.&lt;/p>
  105. &lt;p>jmairboeck changed the &lt;code>fenv.h&lt;/code> headers so that the standard &lt;code>_DEFAULT_SOURCE&lt;/code> definition (automatically defined in &lt;code>&amp;lt;features.h&amp;gt;&lt;/code>) suffices to enable non-standard extension functions and definitions.&lt;/p>
  106. &lt;p>waddlesplash adjusted handling of double-faults on x86, fixing an incorrect GS (that was making the kernel debugger useless) on 32-bit, calling the double-fault-specific kernel debugger entry point on 64-bit, and adding more safety checks around the &amp;ldquo;detect double fault CPU&amp;rdquo; method. He also added some bounds checking and fixed error handling in the kernel debugger command execution path.&lt;/p>
  107. &lt;p>waddlesplash fixed the build of the &amp;ldquo;video text console&amp;rdquo; for the bootloader (a console implementation that uses the same framebuffer-based console facility as the kernel debugger does), made it usable in more situations, and more. He also wrote up a hack (not committed to the main Haiku repository) to build BIOS loaders with it enabled by default, for experimental use on hardware (e.g. Chromebooks) that faults when trying to use the standard text mode console.&lt;/p>
  108. &lt;p>waddlesplash sychronized the &lt;code>stdio&lt;/code>, &lt;code>printf&lt;/code>, and &lt;code>sscanf&lt;/code> implementations with a much newer version of upstream glibc than they had been using, fixing some corner-case bugs in the process. This initially caused some regressions, but those were fixed in relatively short order.&lt;/p>
  109. &lt;h3 id="build-system">Build system&lt;/h3>
  110. &lt;p>PulkoMandy updated the version of &lt;code>m4&lt;/code> used in bootstrap builds.&lt;/p>
  111. &lt;p>waddlesplash added missing PCI modules from the bootstrap build declarations.&lt;/p>
  112. &lt;h3 id="documentation">Documentation&lt;/h3>
  113. &lt;p>PulkoMandy updated some of the documentation around bootstrapping and fixed some links in the package management internals documentation.&lt;/p>
  114. &lt;h3 id="thats-all-folks">That&amp;rsquo;s all, folks!&lt;/h3>
  115. &lt;p>Thanks again to all who contribute to Haiku, and especially those donors who make my contract possible!&lt;/p></description></item><item><title>Haiku Activity &amp; Contract Report, March 2025</title><link>https://www.haiku-os.org/blog/waddlesplash/2025-04-10-haiku_activity_contract_report_march_2025/</link><author>waddlesplash</author><pubDate>Thu, 10 Apr 2025 23:20:00 -0400</pubDate><guid>https://www.haiku-os.org/blog/waddlesplash/2025-04-10-haiku_activity_contract_report_march_2025/</guid><description>&lt;p>This report covers hrev58697 through hrev58787.&lt;/p>
  116. &lt;h3 id="applications">Applications&lt;/h3>
  117. &lt;p>jscipione did some minor code cleanups in Tracker.&lt;/p>
  118. &lt;p>humdinger added some more translator credits to AboutSystem.&lt;/p>
  119. &lt;p>OscarL adjusted ProcessController to display &amp;ldquo;system resources&amp;rdquo; before &amp;ldquo;caches&amp;rdquo; in the memory menu, making it much easier to understand what the numbers mean (and bringing it more in line with other items in the memory menu.) waddlesplash cleaned up the kernel memory accounting code in ProcessController to actually work properly, fixing some long-standing TODOs. He also did some other code cleanup around return types and string handling as well.&lt;/p>
  120. &lt;p>bitigchi made Terminal use the Unicode &amp;ldquo;multiplication sign&amp;rdquo; character instead of ASCII &amp;ldquo;x&amp;rdquo; in some more places (in the GUI).&lt;/p>
  121. &lt;p>AkashKumar7902 contributed a change to make the time tooltip on the seek slider in MediaPlayer display on hover, not just on drag. waddlesplash then made some more improvements to the tooltip to make it update much more smoothly. X512 added a &amp;ldquo;25% scale&amp;rdquo; video playback menu option.&lt;/p>
  122. &lt;p>apl merged a very large refactor of HaikuDepot to improve the application&amp;rsquo;s performance and responsiveness.&lt;/p>
  123. &lt;h3 id="command-line-tools">Command line tools&lt;/h3>
  124. &lt;p>OscarL tweaked the &lt;code>keymap&lt;/code> tool to show help with &lt;code>-h&lt;/code>, and use &lt;code>-H&lt;/code> for the &amp;ldquo;header&amp;rdquo; option instead.&lt;/p>
  125. &lt;p>humdinger rewrote &lt;code>waitfor&lt;/code> to use a &lt;code>BApplication&lt;/code>, and added an option to wait for the network being active.&lt;/p>
  126. &lt;h3 id="kits">Kits&lt;/h3>
  127. &lt;p>apl added a way to add and remove items from &lt;code>BColumnListView&lt;/code> in bulk.&lt;/p>
  128. &lt;p>waddlesplash made some fixes to the tooltip management code, making it much more possible for controls specify specific tooltip positions and have them be respected. (This made the MediaPlayer changes work much more nicely.)&lt;/p>
  129. &lt;p>waddlesplash fixed a use-after-free discovered by the guarded heap in &lt;code>BSlider&lt;/code>.&lt;/p>
  130. &lt;p>PulkoMandy added some missing macros to &lt;code>elf.h&lt;/code> needed by WebKit.&lt;/p>
  131. &lt;h3 id="servers">Servers&lt;/h3>
  132. &lt;p>madmax fixed the build of the &lt;code>test_app_server&lt;/code> setup after recent refactors.&lt;/p>
  133. &lt;p>korli fixed handling of failed condition checks in &lt;code>launch_daemon&lt;/code>, implemented the &amp;ldquo;file created&amp;rdquo; event, and added support for &amp;ldquo;driver settings&amp;rdquo; file format for conditions (fixing some old bugs in the driver settings code along the way). He also fixed stopping services, and added some missing documentation comments.&lt;/p>
  134. &lt;p>nipos fixed some code duplication in &lt;code>app_server&lt;/code> font rendering code.&lt;/p>
  135. &lt;p>madmax add some tests for &lt;code>app_server&lt;/code> text rendering, and made some fixes to check glyph bounding boxes, correctly draw text with a clipping path, and text decoration lines being drawn with transforms.&lt;/p>
  136. &lt;p>augiedoggie added a &lt;code>syslog_max_history&lt;/code> option to the kernel settings file, to control how many old syslog files are kept: the default is 1, but that default can now be increased if you want to keep more old syslogs.&lt;/p>
  137. &lt;h3 id="drivers">Drivers&lt;/h3>
  138. &lt;p>waddlesplash merged changes to the &lt;code>iaxwifi200&lt;/code> driver (&lt;code>iwx&lt;/code> on the BSDs) from OpenBSD to add support for another device.&lt;/p>
  139. &lt;p>waddlesplash merged changes to the &lt;code>atheros813x&lt;/code> ethernet driver from upstream FreeBSD to fix operation on some newer devices.&lt;/p>
  140. &lt;p>waddlesplash tweaked the SCSI bus and drivers to use &lt;code>NotifyOne&lt;/code> not &lt;code>NotifyAll&lt;/code> on its condition variables. (This doesn&amp;rsquo;t change behavior, because there&amp;rsquo;s only ever one waiter on these variables, but it&amp;rsquo;s important to be clear here because some other threads may destroy the variable immediately after being woken up.)&lt;/p>
  141. &lt;p>waddlesplash cleaned up the interrupts glue code in &lt;code>ralinkwifi&lt;/code>, potentially fixing some bugs. He then imported a driver for &lt;code>MT7601U&lt;/code> devices from FreeBSD, however it isn&amp;rsquo;t clear if this driver actually works properly on Haiku yet.&lt;/p>
  142. &lt;p>waddlesplash added some logic to &lt;code>ram_disk&lt;/code> missed in recent refactors, and fixed a hang in its &amp;ldquo;TRIM&amp;rdquo; routine.&lt;/p>
  143. &lt;p>korli implemented &amp;ldquo;autonomous power save&amp;rdquo; in &lt;code>nvme_disk&lt;/code>, reducing power usage by ~1W on one of his systems.&lt;/p>
  144. &lt;p>X512 made some changes to input drivers to allow &lt;code>input_server&lt;/code> to actually be interrupted/restarted.&lt;/p>
  145. &lt;p>X512 made the &lt;code>framebuffer&lt;/code> driver not attempt to map the whole PCI BAR, but only just enough for the framebuffer itself. (This was a holdover from the VESA driver, which does want to do that for various reasons, but the dumb framebuffer driver should not.)&lt;/p>
  146. &lt;h3 id="file-systems">File systems&lt;/h3>
  147. &lt;p>waddlesplash added checks, first to &lt;code>devfs&lt;/code> and then to many other filesystems, for the &lt;code>O_DIRECTORY&lt;/code> flag on opening files, fixing &lt;code>cp file /dev/some/block/device&lt;/code> among other things.&lt;/p>
  148. &lt;p>Jim906 contributed a patch to handle stale inodes much better in the NFS4 (client) driver, fixing a number of common kernel panics it caused, and also made inode fetching allowed to fail for removed nodes and fixed a locking problem in the read routine, fixing more kernel panics. He also wrote a number of debug output routines to help with diagnosing problems in the driver.&lt;/p>
  149. &lt;h3 id="libroot--kernel">libroot &amp;amp; kernel&lt;/h3>
  150. &lt;p>waddlesplash refactored the kernel &lt;code>Thread&lt;/code> structure to use the standard linked-list template classes, instead of manually managed ones, and switched it to use doubly-linked lists instead of singly-linked ones, making removals of thread structures O(1) instead of O(N). He also fixed a bug that was preventing correct &lt;code>time&lt;/code> accounting for living child teams, a small memory leak in a corner case in thread destruction, and a TODO about when IDs wrap in &lt;code>get_next_thread_info&lt;/code>.&lt;/p>
  151. &lt;p>waddlesplash made the &lt;code>mutex_destroy&lt;/code> &amp;ldquo;not owned&amp;rdquo; assertion print a backtrace of the actually owning thread automatically.&lt;/p>
  152. &lt;p>waddlesplash added another invocation of &lt;code>cpu_pause&lt;/code> in a spin loop in the condition variables code, to avoid burning CPU cycles unnecessarily.&lt;/p>
  153. &lt;p>waddlesplash adjusted the generic &lt;code>memcmp&lt;/code> implementation to compare &lt;code>size_t&lt;/code>s (which are 64-bit on 64-bit architectures) instead of &lt;code>uint32_t&lt;/code>s, added the same multiple-bytes optimization to &lt;code>strncmp&lt;/code> as &lt;code>strcmp&lt;/code> already had, and avoided unnecessary subtractions in &lt;code>memcmp&lt;/code>, &lt;code>strcmp&lt;/code>, and &lt;code>strncmp&lt;/code>.&lt;/p>
  154. &lt;p>waddlesplash cleaned up a lot of file organization and build rules for the &amp;ldquo;strings&amp;rdquo; code (&lt;code>memcmp&lt;/code>, &lt;code>strcmp&lt;/code>, etc.), especially the architecture-specific files. He then rewrote the generic &lt;code>memcpy&lt;/code> and &lt;code>memset&lt;/code> implementations (applying more optimizations to &lt;code>memset&lt;/code> in particular), made the generic versions always used in the bootloader, and replaced the homegrown x86 &lt;code>memcpy&lt;/code> and &lt;code>memset&lt;/code> assembly implementations with NetBSD&amp;rsquo;s (which seems to have been the upstream for FreeBSD and others.) (The homegrown x86_64 &lt;code>memcpy&lt;/code> and &lt;code>memset&lt;/code> appear to be better optimized than any of the BSD&amp;rsquo;s implementations, so they remain as-is.)&lt;/p>
  155. &lt;p>waddlesplash fixed a race condition in the new FIFO implementation, fixing some lock-related KDLs. He also added an assertion to the common locking code that would&amp;rsquo;ve made the problem easier to find.&lt;/p>
  156. &lt;p>waddlesplash fixed &lt;code>write()&lt;/code> in libroot not handling values outside the 32-bit range properly on 64-bit architectures, and also fixed displaying such large values in &lt;code>strace&lt;/code> properly (for all syscalls that return &lt;code>ssize_t&lt;/code>, not just &lt;code>read&lt;/code> and &lt;code>write&lt;/code>, too.)&lt;/p>
  157. &lt;p>waddlesplash made a number of fixes to FPU context state handling in the kernel on x86_64, including resetting the state properly on all thread entries, storing the userspace FPU state in the kernel thread structure instead of the kernel thread stack (which is also a small performance optimization), sending the proper &lt;code>FPE_*&lt;/code> code corresponding to faults with &lt;code>SIGFPE&lt;/code>, properly handling control words on context switch, and more. This fixes a number of corner-case KDLs and application crashes.&lt;/p>
  158. &lt;p>waddlesplash adjusted the kernel to not report protection flags for kernel areas to any user except root, so that ProcessController can be sure it can make use of them. He also fixed the slab memory manager (which backs the kernel &lt;code>malloc&lt;/code> and &lt;code>object_cache&lt;/code>s) to report its areas as writable (which they always are), which fixes the memory counts for the kernel in ProcessController.&lt;/p>
  159. &lt;p>waddlesplash renamed many of the basic interrupt functions in the kernel to use &amp;ldquo;intr&amp;rdquo; (if not &amp;ldquo;interrupt&amp;rdquo;) rather than the abbreviation &amp;ldquo;int&amp;rdquo;, which could be confused with &amp;ldquo;integer&amp;rdquo;. (BeOS used &amp;ldquo;interrupt&amp;rdquo;, the abbreviation &amp;ldquo;int&amp;rdquo; was a holdover from NewOS.)&lt;/p>
  160. &lt;p>waddlesplash fixed &amp;ldquo;LA57&amp;rdquo; (5-level paging) mode support in the kernel to properly free its page tables, which were previously getting leaked. (There are some users running Haiku in KVM on systems with LA57 support now, so it&amp;rsquo;s more important that this works than it was a few years ago.)&lt;/p>
  161. &lt;p>waddlesplash fixed a deadlock reported by korli in the filesystem caching code related to page wait behavior (found by running the &lt;code>gVisor&lt;/code> tests on Haiku.)&lt;/p>
  162. &lt;p>waddlesplash improved handling of invalid pointers in the guarded heap, printing more verbose messages for them instead of just &amp;ldquo;generic segfault&amp;rdquo;.&lt;/p>
  163. &lt;p>waddlesplash made &lt;code>dup3&lt;/code> return &lt;code>EINVAL&lt;/code> if the old and new file descriptors are the same, bringing it in line with POSIX.&lt;/p>
  164. &lt;p>waddlesplash added &lt;code>qsort_r&lt;/code> to libroot (it&amp;rsquo;s in the newest version of POSIX.)&lt;/p>
  165. &lt;p>waddlesplash did a large number of cleanups to the remaining &lt;code>glibc&lt;/code>-derived code in libroot (and also the legacy &lt;code>libstdc++&lt;/code>): dropping private definitions from public headers, removing functions already defined elsewhere, deleting unneeded files, replacing more files with musl or BSD equivalents, adding the &lt;code>stdio_ext&lt;/code> routines as found in musl and elsewhere (and needed by Gnulib after the removal of the private definitions), dropped many unused math files, dropped glibc locale structures and made it interface with Haiku locale structures directly, and much more.&lt;/p>
  166. &lt;p>waddlesplash upgraded &lt;code>getopt&lt;/code> to the version found in glibc 2.41.&lt;/p>
  167. &lt;p>korli fixed the kernel &lt;code>vsnprintf&lt;/code> to correctly print fractions smaller than &lt;code>0.1&lt;/code>.&lt;/p>
  168. &lt;p>korli fixed the &lt;code>create_dir&lt;/code> syscall to return &lt;code>EEXIST&lt;/code> if a node already exists, before &lt;code>EROFS&lt;/code>.&lt;/p>
  169. &lt;p>Anarchos made some improvements to the bootloader menu for PXE boot, displaying &amp;ldquo;Network&amp;rdquo; as the boot method, displaying the IP address of the boot volume, etc.&lt;/p>
  170. &lt;h3 id="build-system">Build system&lt;/h3>
  171. &lt;p>waddlesplash fixed a build regression on macOS by disabling some unneeded code on all platforms but Haiku in the Support Kit.&lt;/p>
  172. &lt;p>waddlesplash fixed the libroot stubs generator (a rarely-used tool that regenerates some files needed for bootstrapping) to work on Python 3.&lt;/p>
  173. &lt;p>korli made some minor changes to fix warnings from AddressSanitizer.&lt;/p>
  174. &lt;h3 id="thats-all-folks">That&amp;rsquo;s all, folks!&lt;/h3>
  175. &lt;p>Thanks again to all who contribute to Haiku, and especially those donors who make my contract possible!&lt;/p></description></item><item><title>Haiku Activity &amp; Contract Report, February 2025</title><link>https://www.haiku-os.org/blog/waddlesplash/2025-03-11-haiku_activity_contract_report_february_2025/</link><author>waddlesplash</author><pubDate>Tue, 11 Mar 2025 14:20:00 -0400</pubDate><guid>https://www.haiku-os.org/blog/waddlesplash/2025-03-11-haiku_activity_contract_report_february_2025/</guid><description>&lt;p>This report covers hrev58584 through hrev58696.&lt;/p>
  176. &lt;h3 id="applications">Applications&lt;/h3>
  177. &lt;p>jscipione fixed opening folders by double-clicking the &amp;ldquo;Location&amp;rdquo; column in query results in Tracker. He also fixed hard-coded values for certain menu item metrics, bringing them in line with standard menu metrics, cleaned up some parts of drag &amp;amp; drop support, refactored some of the drawing logic, made some fixes to add-on loading, and more.&lt;/p>
  178. &lt;p>nephele removed Gopher from the declared list of supported protocols in WebPositive. (It was supported when we used the Haiku-native network backend, but now that WebPositive uses CURL again, it isn&amp;rsquo;t supported.)&lt;/p>
  179. &lt;p>waddlesplash made some changes to HaikuDepot (inspired by patches from oco) to improve performance somewhat when searching for items.&lt;/p>
  180. &lt;p>captain0xff (a new contributor!) removed some duplicate code from Screen preferences.&lt;/p>
  181. &lt;p>waddlesplash fixed some memory-management problems and race conditions in Tracker, fixing at least one crash.&lt;/p>
  182. &lt;h3 id="command-line-tools">Command line tools&lt;/h3>
  183. &lt;p>korli added support to &lt;code>strace&lt;/code> to dump the arguments of &lt;code>rlimit&lt;/code> syscalls, and the &amp;ldquo;type&amp;rdquo; argument of &lt;code>mmap&lt;/code> syscalls.&lt;/p>
  184. &lt;p>OscarL merged the &amp;ldquo;filteredquery&amp;rdquo; command-line tool into the &amp;ldquo;query&amp;rdquo; tool, meaning that &amp;ldquo;query&amp;rdquo; can now filter results by directory.&lt;/p>
  185. &lt;h3 id="kits">Kits&lt;/h3>
  186. &lt;p>jscipione implemented support for keyboard shortcuts without the &lt;code>Cmd&lt;/code> key in the Interface Kit. (Previously all menu shortcuts, no matter what other modifier keys they used, were also required to have &lt;code>Cmd&lt;/code> as one of them.) He then modified some applications to make use of this feature, such as MediaPlayer&amp;rsquo;s Playlist window, Tracker&amp;rsquo;s &amp;ldquo;move to trash&amp;rdquo;, and others.&lt;/p>
  187. &lt;p>jscipione fixed some background color management problems in &lt;code>BTextView&lt;/code>.&lt;/p>
  188. &lt;p>nipos contributed a fix to &lt;code>BControlLook&lt;/code> to use the &amp;ldquo;panel text&amp;rdquo; color for scrollbar arrows, fixing contrast in some color schemes. nephele came by later and fixed an oversight in the original change.&lt;/p>
  189. &lt;p>PulkoMandy added the remaining missing ASCII control character definitions to &lt;code>InterfaceDefs.h&lt;/code>.&lt;/p>
  190. &lt;p>waddlesplash refactored &lt;code>BObjectList&amp;lt;&amp;gt;&lt;/code> to take &lt;code>bool owning&lt;/code> as a template parameter rather than a constructor parameter. This will make static code analysis of modules that use this class much easier (as there were a lot of &amp;ldquo;double free/use-after-free&amp;rdquo; false positives before that just had to be ignored), and also make memory leaks harder to inadvertently cause. He also cleaned up some code to use the more optimal &lt;code>BStringList&lt;/code> instead of &lt;code>BObjectList&amp;lt;BString&amp;gt;&lt;/code> at the same time.&lt;/p>
  191. &lt;p>nephele fixed &lt;code>BFilePanel&lt;/code> to handle non-existent target directories more gracefully.&lt;/p>
  192. &lt;p>korli added checks to &lt;code>BMenuField::SetLabel&lt;/code> to better handle &lt;code>NULL&lt;/code> labels.&lt;/p>
  193. &lt;p>waddlesplash made some changes to &lt;code>BList&lt;/code>, &lt;code>BMessage&lt;/code>, and some of their consumers (like the registrar) to avoid allocating memory in more cases, and just use the stack (or defer it till later) instead.&lt;/p>
  194. &lt;p>waddlesplash adjusted and added some checks in &lt;code>BScrollView&lt;/code> and &lt;code>BColumnListView&lt;/code> to not redraw unnecessarily in more cases, improving performance in HaikuDepot somewhat.&lt;/p>
  195. &lt;p>ilzu fixed an error report in a corner-case the JSON message writer.&lt;/p>
  196. &lt;p>jscipione cleaned up the ownership of the &amp;ldquo;menu semaphore&amp;rdquo; in BWindow.&lt;/p>
  197. &lt;p>waddlesplash adjusted &lt;code>BBlockCache&lt;/code> (a memory chunk cache) to not cache anything when a debug/guarded allocator is in use.&lt;/p>
  198. &lt;h3 id="servers">Servers&lt;/h3>
  199. &lt;p>korli added a hook to the VirtualKeyboard input panel (which is still disabled by default) to handle screen(mode) changes properly, and made it automatically refresh when the system keymap changes.&lt;/p>
  200. &lt;p>augiedoggie reworked screensavers to support using the &amp;ldquo;system&amp;rdquo; (i.e. UNIX user) password to unlock the screen after the screensaver run, and added a command-line argument to launch and lock the screen immediately instead of after a delay.&lt;/p>
  201. &lt;p>madmax fixed the name of a private method in &lt;code>input_server&lt;/code>.&lt;/p>
  202. &lt;p>X512 removed an unnecessary argument from internal &lt;code>draw_bezier&lt;/code> functions.&lt;/p>
  203. &lt;h3 id="drivers">Drivers&lt;/h3>
  204. &lt;p>Lt-Henry added support for AMD I2C busses to the &lt;code>pch_i2c&lt;/code> driver.&lt;/p>
  205. &lt;p>waddlesplash reworked the &amp;ldquo;IA32 BIOS&amp;rdquo; bootloader to report the ACPI root pointer (same as the EFI bootloader), and to always use this in ACPI initialization rather than trying to re-find it.&lt;/p>
  206. &lt;p>waddlesplash fixed some corner-cases and added missing checks to XHCI initialization.&lt;/p>
  207. &lt;p>korli modified the &lt;code>virtio_pci&lt;/code> bus driver to handle the device revisions more according to the specification.&lt;/p>
  208. &lt;p>waddlesplash adjusted the SCSI bus manager to use the proper maximum values for DMA attributes.&lt;/p>
  209. &lt;h3 id="file-systems">File systems&lt;/h3>
  210. &lt;p>waddlesplash optimized block fetching in B+tree iteration to not &amp;ldquo;put&amp;rdquo; and &amp;ldquo;get&amp;rdquo; the same block over and over again unnecessarily, speeding up &amp;ldquo;git status&amp;rdquo; performance with cold disk caches a bit (but there&amp;rsquo;s still a lot more work to be done there.)&lt;/p>
  211. &lt;p>augiedoggie changed &lt;code>userlandfs_server&lt;/code> to use &lt;code>B_MULTIPLE_LAUNCH&lt;/code>, allowing multiple userlandfs/FUSE filesystems to be mounted at the same time.&lt;/p>
  212. &lt;p>waddlesplash added some missing locks to BFS&amp;rsquo; checkfs operations, potentially fixing some rare KDLs.&lt;/p>
  213. &lt;h3 id="libroot--kernel">libroot &amp;amp; kernel&lt;/h3>
  214. &lt;p>korli disabled &amp;ldquo;C5&amp;rdquo; and &amp;ldquo;C6&amp;rdquo; C-states on Intel &amp;ldquo;Skylake&amp;rdquo; microarchitecture, fixing the boot on some systems.&lt;/p>
  215. &lt;p>waddlesplash fixed the &amp;ldquo;guarded heap object cache&amp;rdquo; (a debug allocation facility) in the kernel after recent refactors.&lt;/p>
  216. &lt;p>waddlesplash added some sanity checks in &lt;code>create_sem&lt;/code> to return errors when requesting a semaphore with a negative count, same as BeOS apparently did.&lt;/p>
  217. &lt;p>waddlesplash added checks in the file cache to validate that the size of the underlying file didn&amp;rsquo;t shrink past the end of the request between when the read or write was issued and after actually acquiring the lock (and to bail out if it did). He also cleaned up some code related to page reservations.&lt;/p>
  218. &lt;p>korli adjusted runtime_loader to make &lt;code>dlsym(RTLD_NEXT)&lt;/code> search all loaded ELF regions for the caller&amp;rsquo;s address, not just the first ones. waddlesplash followed this up with some similar fixes to other parts of runtime_loader.&lt;/p>
  219. &lt;p>waddlesplash continued his ongoing memory management improvements, fixes, and cleanups, implementing more cases of resizing (expanding/shrinking) memory areas when there&amp;rsquo;s a virtual memory reservation adjacent to them (and writing tests for these cases) in the kernel. These changes were the last remaining piece needed before the new &lt;code>malloc&lt;/code> implementation for userland (mostly based on OpenBSD&amp;rsquo;s malloc, but with a few additional optimizations and a Haiku-specific process-global cache added) could be merged and turned on by default. There were a number of followup fixes to the kernel and the new allocator&amp;rsquo;s &amp;ldquo;glue&amp;rdquo; and global caching logic since, but the allocator has been in use in the nightlies for a few weeks with no serious issues. It provides modest performance improvements over the old allocator in most cases, and in some cases that were pathological for the old allocator (GCC LTO appears to have been one), provides order-of-magnitude (or mode) performance improvements.&lt;/p>
  220. &lt;p>korli fixed &lt;code>pthread_key&lt;/code> destructor invocation to iterate over the keys for at least &lt;code>PTHREAD_DESTRUCTOR_ITERATIONS&lt;/code>, as the specification indicates. waddlesplash made a small optimization to avoid syscalls in some cases of &lt;code>pthread_cond_signal&lt;/code>.&lt;/p>
  221. &lt;p>waddlesplash added some more mutex acquisitions before spinlock acquisitions in the syslog code, avoiding some assertion failure panics when &amp;ldquo;onscreen debug output&amp;rdquo; is enabled for a boot.&lt;/p>
  222. &lt;p>waddlesplash refactored x86 APIC timer initialization, moving the calibration from the bootloader into the kernel, making it somewhat more accurate, and reading the value from CPUID on hypervisors rather than computing it from scratch.&lt;/p>
  223. &lt;p>waddlesplash added code to handle a corner-case in &lt;code>mprotect&lt;/code>, fixing the last known kernel panic (assertion failure) that &amp;ldquo;Iceweasel&amp;rdquo; was regularly triggering on nightly builds.&lt;/p>
  224. &lt;p>waddlesplash fixed the kernel and bootloaders on x86 to not hang forever if the default serial line is dead or nonexistent. (On specialized or very new x86 hardware, like the Steam Deck, it doesn&amp;rsquo;t exist, and trying to write to it without timeouts will just result in infinite hangs.)&lt;/p>
  225. &lt;p>phcoder contributed fixes to make &lt;code>x86_{read|write}_msr&lt;/code> an inline function on 32-bit x86 (it already was on 64-bit), add X2APIC support to the EFI bootloader (needed on very recent hardware), use a separate allocation function to make sure that the &amp;ldquo;PML4&amp;rdquo; page is always allocated in the 32-bit region (which waddlesplash refactored and merged after memory management cleanups to other parts of the bootloader), and to support the GDT being above 4GB.&lt;/p>
  226. &lt;p>waddlesplash replaced some more implementations of standard C functions with versions from musl, including &lt;code>memmove&lt;/code>, &lt;code>strlen&lt;/code>, &lt;code>strlcat&lt;/code>, and more. He also synchronized the &lt;code>glob&lt;/code> implementation with upstream FreeBSD, added some more optimizations to &lt;code>memcmp&lt;/code>, and more.&lt;/p>
  227. &lt;p>korli moved partial-zero-fill-pages logic from the file cache into VMCache, fixing &lt;code>mmap&lt;/code> behavior in some corner cases involving RAMFS.&lt;/p>
  228. &lt;p>waddlesplash rewrote the kernel FIFO (&lt;code>pipe(2)&lt;/code>) implementation to use more atomics and fewer locks, improving the performance of &lt;code>stress-ng --pipe 1&lt;/code> (in a VM) from ~230 MB/s to ~2.5 GB/s.&lt;/p>
  229. &lt;h3 id="build-system">Build system&lt;/h3>
  230. &lt;p>korli fixed some miscellaneous warnings.&lt;/p>
  231. &lt;p>waddlesplash made a number of fixes to make it possible to build Haiku on FreeBSD, and Linux distributions that use musl. He also deleted some unneeded source files from the copy of &lt;code>unzip&lt;/code> used as part of the build tools.&lt;/p>
  232. &lt;p>korli adjusted the stack protection options in the build system (which are disabled by default) to apply to more parts of the source tree.&lt;/p>
  233. &lt;p>nephele changed a usage of the &lt;code>which&lt;/code> command to use the shell builtin &lt;code>command -v&lt;/code> instead.&lt;/p>
  234. &lt;h3 id="documentation">Documentation&lt;/h3>
  235. &lt;p>waddlesplash dropped some obsolete internals documentation on merging patches from NetBSD trunk for &lt;code>netresolv&lt;/code>, as the procedure described there doesn&amp;rsquo;t apply anymore. Following some discussion on the mailing list, PulkoMandy wrote up a new page describing the general procedure for merging code from other sources into Haiku and keeping it up-to-date.&lt;/p>
  236. &lt;p>kuku929 (a new contributor!) contributed a graph showing an example of the kernel device manager&amp;rsquo;s node tree.&lt;/p>
  237. &lt;p>PulkoMandy moved syscalls documentation from the website to the internals documentation, and imported oco&amp;rsquo;s article on profiling applications.&lt;/p>
  238. &lt;p>dalmemail fixed a typo in a documentation comment for &lt;code>VMCache&lt;/code>.&lt;/p>
  239. &lt;p>madmax added a missing &amp;ldquo;end comment&amp;rdquo; to the Haiku Book that was preventing the &amp;ldquo;Synchronization Primitives&amp;rdquo; page from being rendered.&lt;/p>
  240. &lt;h3 id="thats-all-folks">That&amp;rsquo;s all, folks!&lt;/h3>
  241. &lt;p>Thanks again to all who contribute to Haiku, and especially those donors who make my contract possible!&lt;/p></description></item><item><title>Haiku Activity &amp; Contract Report, January 2025</title><link>https://www.haiku-os.org/blog/waddlesplash/2025-02-10-haiku_activity_contract_report_january_2025/</link><author>waddlesplash</author><pubDate>Mon, 10 Feb 2025 23:20:00 -0500</pubDate><guid>https://www.haiku-os.org/blog/waddlesplash/2025-02-10-haiku_activity_contract_report_january_2025/</guid><description>&lt;p>This report covers hrev58487 through hrev58583.&lt;/p>
  242. &lt;h3 id="applications">Applications&lt;/h3>
  243. &lt;p>omesh-barhate contributed a patch to add a context menu to WebPositive&amp;rsquo;s bookmark bar items, to allow them to be edited more easily. humdinger cleaned up the strings in the new context menu and enhanced its functionality, and removed the &amp;ldquo;move to front&amp;rdquo; logic in the Downloads window.&lt;/p>
  244. &lt;p>digitalbox98 (a new contributor!) contributed a change to add a &amp;ldquo;Remove&amp;rdquo; menu for Transformers in Icon-O-Matic. Zardshard cleaned up some variable names in Icon-O-Matic as well.&lt;/p>
  245. &lt;p>PawanYr (a new contributor!) made TeamMonitor group child teams under their parents. (This makes multiprocess web browsers and terminals easier to deal with.)&lt;/p>
  246. &lt;p>PawanYr made Backgrounds preferences update the view whenever the X/Y coordinate boxes are modifed.&lt;/p>
  247. &lt;p>PawanYr fixed a crash related to query templates in Tracker. jscipione adjusted Tracker to disallow control characters in the file name edit box. nephele fixed the button color in file panels.&lt;/p>
  248. &lt;p>jscipione cleaned up and added more invocations of &lt;code>AdoptSystemColors&lt;/code> and the like in multiple applications and classes: Deskbar, Tracker, HaikuDepot, BTextView, and more.&lt;/p>
  249. &lt;p>nipos made the analog clock display in Time use the &amp;ldquo;document&amp;rdquo; color rather than a hard-coded white color.&lt;/p>
  250. &lt;p>jscipione completed and merged a very large refactor of menu items and shortcuts handling in Tracker. This touches nearly every item displayed in menu bars and context menus in Tracker, and implements live updating of menus when modifier keys change, adds Cut/Copy/Paste to context menus, and more.&lt;/p>
  251. &lt;p>nipos added an option to strikeout text in StyledEdit.&lt;/p>
  252. &lt;p>PawanYr added speed, acceleration, and scroll settings to Touchpad preferences.&lt;/p>
  253. &lt;p>nephele deleted a bunch of obsolete and unused code from Appearance preferences, and renamed some classes to match Haiku conventions.&lt;/p>
  254. &lt;h3 id="command-line-tools">Command line tools&lt;/h3>
  255. &lt;p>augiedoggie fixed &lt;code>rc -d&lt;/code> to correctly decompile &lt;code>app_version&lt;/code> resources that were built on Haiku as well as on BeOS.&lt;/p>
  256. &lt;p>catmeow72 (a new contributor!) added a &lt;code>-B&lt;/code> / &lt;code>--get-brightness&lt;/code> option to &lt;code>screenmode&lt;/code> to retrive the current brightness (instead of just setting it.)&lt;/p>
  257. &lt;h3 id="kits">Kits&lt;/h3>
  258. &lt;p>waddlesplash moved the system colormap to a shared area, avoiding all GUI applications needing to fetch and store it in their own memory.&lt;/p>
  259. &lt;p>nipos fixed tooltips in &amp;ldquo;channel slider&amp;rdquo; controls to display the expected values (rather than the &amp;ldquo;raw&amp;rdquo; values, which were 1000x larger.)&lt;/p>
  260. &lt;p>jscipione made BColorControl call &lt;code>SetValue()&lt;/code> and &lt;code>Invoke()&lt;/code> on color drops, if the control was enabled.&lt;/p>
  261. &lt;p>jscipione moved the ColorPreview classes to the private &amp;ldquo;shared&amp;rdquo; kit, deleting duplicate code between Appearance preferences and Terminal.&lt;/p>
  262. &lt;p>wadlesplash cleaned up the handling of ELF segments in the Debug Kit, fixing a lot of logic that did not handle multiple TEXT segments correctly (and Clang/LLD generate binaries with multiple TEXT segments by default, while GCC/LD can be configured to do so.) He also restored support for lookup of symbols based on remote memory access (instead of only ELF files), among other things. This fixes the generation of stack traces in debug reports for applications compiled with Clang (including most of the web browser ports.)&lt;/p>
  263. &lt;p>daveslusher (a new contributor!) fixed some potential buffer truncation problems when looking up MIME types.&lt;/p>
  264. &lt;h3 id="servers">Servers&lt;/h3>
  265. &lt;p>X512 cleaned up some error handling code in app_server.&lt;/p>
  266. &lt;p>nipos implemented &lt;code>B_STRIKEOUT_FACE&lt;/code> in app_server.&lt;/p>
  267. &lt;h3 id="drivers">Drivers&lt;/h3>
  268. &lt;p>waddlesplash improved the device probing logic in the FreeBSD compatibility layer to not perform so many string comparisons, and to avoid allocating and freeing big chunks of memory so often.&lt;/p>
  269. &lt;p>Lt-Henry adjusted the HID layer to parse &amp;ldquo;feature&amp;rdquo; reports (as well as &amp;ldquo;input&amp;rdquo; reports.)&lt;/p>
  270. &lt;p>kallisti5 adjusted radeon_hd to work properly after area cloning changes in the kernel (detailed below.)&lt;/p>
  271. &lt;p>DruSatori (a new contributor!) contributed support for &amp;ldquo;Alder Lake&amp;rdquo; chipsets to the &lt;code>intel_extreme&lt;/code> modesetting driver.&lt;/p>
  272. &lt;p>korli added an &lt;code>amd_thermal&lt;/code> driver to fetch temperatures on AMD systems, cleaned up the &lt;code>pch_thermal&lt;/code> driver, and added both of those as well as the &lt;code>acpi_thermal&lt;/code> driver to the default builds.&lt;/p>
  273. &lt;p>ilzu contributed support for the CTH-470 to the Wacom driver.&lt;/p>
  274. &lt;h3 id="file-systems">File systems&lt;/h3>
  275. &lt;p>waddlesplash added a missing check for parent directores in packagefs, fixing a rare KDL.&lt;/p>
  276. &lt;p>Jim906 contributed changes to make the NFSv4 driver build under the &amp;ldquo;userlandfs&amp;rdquo; infrastructure, which should make it much easier to debug. He also fixed some port buffer sizing problems in the userlandfs layer itself.&lt;/p>
  277. &lt;p>waddlesplash added support for &amp;ldquo;special&amp;rdquo; files (like FIFOs or UNIX sockets) to RAMFS. He also cleaned up some duplicate code, reduced lock contention, made the &lt;code>readdir()&lt;/code> hook return more than one &lt;code>dirent&lt;/code> at a time, and fixed some other bugs as well.&lt;/p>
  278. &lt;h3 id="libroot--kernel">libroot &amp;amp; kernel&lt;/h3>
  279. &lt;p>waddlesplash&amp;rsquo;s work on memory management logic in the kernel (and elsewhere) continued in January, with more fixes and improvements to page mapping, memory reservation accounting, kernel malloc block sizes, kernel stack allocation, cache fault counting, and much more. He also got OpenBSD&amp;rsquo;s malloc up to performance par with libroot&amp;rsquo;s current malloc (or better, in many cases) even under multithreaded workloads, though there&amp;rsquo;s still more that needs to be done before it can be merged.&lt;/p>
  280. &lt;p>waddlesplash made some changes to avoid holding the &amp;ldquo;hot vnodes&amp;rdquo; lock too long in the VFS low-memory handler, fixing deadlocks.&lt;/p>
  281. &lt;p>waddlesplash adjusted the FD table creation logic in the kernel, shrinking the initial table size and breaking up some large allocations to make it much more likely to hit fast-paths.&lt;/p>
  282. &lt;p>cmeerw submitted a patch to libroot to fix an infinite loop in &lt;code>pipe2&lt;/code> with Emacs/GNUlib.&lt;/p>
  283. &lt;p>waddlesplash added a fast path in the kernel thread code for when a thread is fetching its own &lt;code>Thread&lt;/code> structure.&lt;/p>
  284. &lt;p>waddlesplash merged the bootloader and runtime_loader heap (malloc) implementations, as they were mostly copies of one another with differences in glue code only. He also fixed and implemented some tests for this heap, improved the glue code in runtime_loader, and did a bit of optimization of memory usage in the bootloader while at it.&lt;/p>
  285. &lt;p>waddlesplash fixed some mishandling of &lt;code>errno&lt;/code> in the filesystem block cache that was leading to KDLs in some circumstances.&lt;/p>
  286. &lt;p>waddlesplash added an error definition for &lt;code>ESOCKTNOSUPPORT&lt;/code>, which is in POSIX-2024.&lt;/p>
  287. &lt;p>waddlesplash adjusted permissions checks in the kernel to block teams from cloning areas they don&amp;rsquo;t own with more permissions than the source area has (write permissions, specifically), and also to block non-root teams from inspecting other teams&amp;rsquo; memory properties.&lt;/p>
  288. &lt;p>waddlesplash moved the default selection of &lt;code>B_RANDOMIZED_*&lt;/code> area types (i.e. ASLR) to libroot, so that it can be overridden for individual areas (if necessary).&lt;/p>
  289. &lt;p>waddlesplash added a &lt;code>CLONE_AREA&lt;/code> message to the userspace debugger support in the kernel (used by the Debug Kit fixes described above), and added some more permissions checks to the user_debugger logic in general.&lt;/p>
  290. &lt;p>waddlesplash improved a permissions check in the &lt;code>area_for&lt;/code> implementation, and made it distinguish between regular and &amp;ldquo;reserved&amp;rdquo; areas.&lt;/p>
  291. &lt;p>waddlesplash refactored the kernel&amp;rsquo;s userspace symbol lookup logic to rely on the &lt;code>extended_image_info&lt;/code> structures (which the &lt;code>runtime_loader&lt;/code> reports to the kernel) rather than cloning the runtime_loader&amp;rsquo;s debug information area. He also switched the &lt;code>image_info&lt;/code> structures to use the standard &lt;code>DoublyLinkedList&lt;/code> class, and cleaned up some other code related to linked-lists as well.&lt;/p>
  292. &lt;p>waddlesplash cleaned up code in runtime_loader, and then made it properly respect the &lt;code>PF_EXECUTE&lt;/code> program header flag. Previously it just made all non-writable regions executable (which matched what GCC/LD generally generated by default anyway, but Clang/LLD binaries actually do have a non-executable TEXT section in most cases.) He also cleaned up the kernel ELF loader to not set user protections (based on &lt;code>PF_*&lt;/code> flags) until the very end.&lt;/p>
  293. &lt;p>waddlesplash cleaned up a redundant &lt;code>wait_for_thread&lt;/code> syscall.&lt;/p>
  294. &lt;p>waddlesplash improved the address-space blocking for uninitialized/freed memory. Under &lt;code>PARANOID_KERNEL_MALLOC&lt;/code> (which is enabled for nightly builds), this reserves the virtual addresses most likely to be hit if &amp;ldquo;uninitialized&amp;rdquo; (&lt;code>0xcccccccc&lt;/code>) or freed (&lt;code>0xdeadbeef&lt;/code>) memory is touched. It only tried to reserve the 32-bit versions of the addresses, which wasn&amp;rsquo;t very useful on 64-bit systems; now it reserves the 64-bit addresses as well.&lt;/p>
  295. &lt;p>waddlesplash changed page fault behavior to always insert new (clean) pages into the &lt;em>topmost&lt;/em> cache object on page faults, rather than the lowest (deepest) cache object. In the case of a read fault, they would in some circumstances be inserted into the deepest cache instead. This behavior dated all the way back to NewOS, but now that Haiku has rather advanced copy-on-write, fork(), and cache resizing support, it was conflicting with other features (and probably isn&amp;rsquo;t an optimization anyway as it would just cause more copy-on-writes when writes did occur.) This problem manifested in an extremely race-sensitive KDL, and after tracking it down and fixing it, waddlesplash added a new ASSERT that would have caught the problem immediately and without waiting for any races (and which has caught some other related problems already).&lt;/p>
  296. &lt;p>waddlesplash made the &amp;ldquo;I/O context root&amp;rdquo; lock (which must be held when &lt;code>chroot&lt;/code>ing, among other things) an R/W lock, since the vast majority of the time an application&amp;rsquo;s root path only needs to be read, not set, reducing lock contention.&lt;/p>
  297. &lt;p>waddlesplash reintroduced an &amp;ldquo;aligned pointers&amp;rdquo; optimization for &lt;code>strcmp&lt;/code>, reducing CPU time/usage especially for longer strings as up to 4 bytes can be compared at a time now. He also replaced some other string functions with their musl equivalents.&lt;/p>
  298. &lt;h3 id="arm--risc-v">ARM &amp;amp; RISC-V&lt;/h3>
  299. &lt;p>kallisti5 fixed some logic in the bootloader and serial code to fail properly if clock frequencies can&amp;rsquo;t be fetched or are invalid.&lt;/p>
  300. &lt;h3 id="build-system">Build system&lt;/h3>
  301. &lt;p>kallisti5 made some various fixes and improved support for architectures other than x86_64 in the build-cross-compiler Docker scripts.&lt;/p>
  302. &lt;p>waddlesplash fixed some missing build dependency declarations in the packagefs rules.&lt;/p>
  303. &lt;p>waddlesplash deleted some no-longer-needed license text files and cleaned up some of the remaining ones.&lt;/p>
  304. &lt;p>waddlesplash improved some error messages around Python detection in &lt;code>./configure&lt;/code>.&lt;/p>
  305. &lt;p>daveslusher fixed some regular expression errors in Awk code that processes USB and PCI device lists.&lt;/p>
  306. &lt;h3 id="documentation">Documentation&lt;/h3>
  307. &lt;p>nipos deleted some old and unused configuration files from the documentation directories, and replaced the remaining references to &amp;ldquo;OpenBeOS&amp;rdquo; with &amp;ldquo;Haiku&amp;rdquo;.&lt;/p>
  308. &lt;p>jscipione reordered the keys enum in InterfaceDefs, and PulkoMandy added the missing elements (ASCII control codes and characters) for clarity and completeness.&lt;/p>
  309. &lt;h3 id="thats-all-folks">That&amp;rsquo;s all, folks!&lt;/h3>
  310. &lt;p>Thanks again to all who contribute to Haiku, and especially those donors who make my contract possible!&lt;/p></description></item><item><title>Haiku, Inc. Financial Report for 2024 is now available</title><link>https://www.haiku-os.org/news/2025-02-01_2024_financial_report/</link><author>leavengood</author><pubDate>Sat, 01 Feb 2025 11:00:00 -0500</pubDate><guid>https://www.haiku-os.org/news/2025-02-01_2024_financial_report/</guid><description>&lt;p>The Haiku, Inc. &lt;a href="https://www.haiku-inc.org/docs/haiku_inc-financial-report-2024.pdf">financial report for 2024&lt;/a>
  311. is now available on the &lt;a href="https://www.haiku-inc.org/documents/">Haiku, Inc. Documents page&lt;/a>.&lt;/p>
  312. &lt;p>Our donations for 2024 were higher than any other year, breaking all previous
  313. records by almost $10,000! Even with some reasonably high expenses we still
  314. managed to have a net positive year.&lt;/p>
  315. &lt;p>In 2024 our contractor waddlesplash worked the whole year, and we had a new beta
  316. release.&lt;/p>
  317. &lt;p>We had some very generous large donations this year, which is part of what made
  318. this a record setting year. One individual in particular donated a total of
  319. $7,500 through GitHub Sponsors, which is extremely generous!&lt;/p>
  320. &lt;p>We appreciate every donation, big and small, and every donor plays a role in
  321. helping to keep Haiku moving forward, so again: &lt;strong>thank you so much!&lt;/strong>&lt;/p>
  322. &lt;p>Bitcoin is at record highs, and so therefore is our Coinbase balance. Though as
  323. noted in the report we still have to sort out details of our Coinbase account to
  324. make those funds more accessible.&lt;/p>
  325. &lt;p>Finally, while this is a news item about the financial report, I want to extend
  326. a thanks to all our volunteers as well. While our donors play their part, so do
  327. our volunteers, continuing to improve Haiku on their own time, year after year.
  328. Not just developers, we also have volunteers who help with documentation,
  329. answering questions in the forum, and working on translations. Plus maybe that
  330. person who manages the finances and works on the financial reports&amp;hellip;&lt;/p>
  331. &lt;p>Thanks to all who help keep Haiku moving forward!&lt;/p></description></item><item><title>Haiku Activity &amp; Contract Report, December 2024 (ft. Iceweasel)</title><link>https://www.haiku-os.org/blog/waddlesplash/2025-01-13-haiku_activity_contract_report_december_2024/</link><author>waddlesplash</author><pubDate>Mon, 13 Jan 2025 23:30:00 -0500</pubDate><guid>https://www.haiku-os.org/blog/waddlesplash/2025-01-13-haiku_activity_contract_report_december_2024/</guid><description>&lt;p>This report covers hrev58369 through hrev58486.&lt;/p>
  332. &lt;h2 id="iceweasel">Iceweasel&lt;/h2>
  333. &lt;p>The biggest piece of news from last month is the arrival of &amp;ldquo;Iceweasel&amp;rdquo;, a web browser built from Mozilla Firefox source code but without any official branding or registered trademarks, in the software depots (for x86_64 only, at the moment.) We&amp;rsquo;ve been &amp;ldquo;slow-rolling&amp;rdquo; the announcements on this one, in part because the browser was quite unstable at first and prone to cause kernel assertion failures on the nightly builds, but after a month of work it&amp;rsquo;s in much better shape and is relatively stable.&lt;/p>
  334. &lt;p>There are still some kernel assertion failures that happen intermittently on the nightly builds with it (but not on beta5, as assertions are disabled there; you may get suboptimal performance or over-reservations of memory by the web browser processes, but the problems causing the failed assertions shouldn&amp;rsquo;t be any more serious than that), and there are a lot of issues or missing features with the port itself still to resolve (e.g. WebRTC isn&amp;rsquo;t implemented at all, pop-up windows/menus from browser extensions may not accept any mouse input, etc.), but these and other issues are slowly being worked on.&lt;/p>
  335. &lt;h2 id="memory-management-changes">Memory management changes&lt;/h2>
  336. &lt;p>Motivated in large part by Iceweasel, I (waddlesplash) spent a significant amount of time in December (and still ongoing, in fact) working on various parts of the kernel virtual memory management facilities. Many of these changes were aimed at fixing problems exposed or suggested by investigating matters in Iceweasel and other memory-management-intensive tests, such as the Boehm garbage collector.&lt;/p>
  337. &lt;p>The changes in this area are probably too many (dozens) and too technical to reasonably detail all of them here (so check the commit logs if you&amp;rsquo;re particularly interested), but among these are: optimizations to batch page writes in some cases, more safety checks in the area resize logic, removal of obsolete fields and comments, many fixes to memory reservation (commitment) behavior (especially in areas with per-page protections), more testcases in the test suite for corner-cases, better handling of reporting initially available memory, fixing of some softlocks that could occur on low-memory conditions, fixes to swap support, enforcement of more protection restrictions, major consolidation of page unmapping code from per-architecture files into architecture-independent files, and many more.&lt;/p>
  338. &lt;h3 id="applications">Applications&lt;/h3>
  339. &lt;p>nipos contributed a fix to Backgrounds to ignore color drops if the color picker is disabled.&lt;/p>
  340. &lt;p>apl did some significant refactoring to HaikuDepot&amp;rsquo;s data models to pave the way for future improvements. He also adjusted the logic around package installation to report a &amp;ldquo;pending&amp;rdquo; state more rapidly, and hid the ratings UI when a package can&amp;rsquo;t be rated for any reason.&lt;/p>
  341. &lt;p>PulkoMandy enhanced the Cortex &amp;ldquo;LoggingConsumer&amp;rdquo;, a media node that logs details about whatever media buffers were sent to it, to report more details.&lt;/p>
  342. &lt;p>jscipione added back spacing at the bottom of the Expander main window. He also made some improvements to the font selection view in Appearance preferences, and nephele deleted some dead code from them as well.&lt;/p>
  343. &lt;p>jscipione made a number of changes to Tracker to fix &amp;ldquo;Escape&amp;rdquo; key behavior in file panels when &amp;ldquo;typeahead filtering&amp;rdquo; is enabled, and cleaned up the display of &amp;ldquo;selections&amp;rdquo; in the Find window. He made a number of coding style cleanups as well.&lt;/p>
  344. &lt;p>waddlesplash made a number of cleanups to the battery display in PowerStatus, making its display more intuitive and easier to tell at a glance what&amp;rsquo;s going on when looking at it in Deskbar.&lt;/p>
  345. &lt;p>nephele made a number of improvements to the error log window in &lt;code>mail_daemon&lt;/code>, such as support for dark mode and better scrollbar proportions.&lt;/p>
  346. &lt;p>jackburton79 fixed a potential memory leak on error and added some sane initialization defaults to Terminal.&lt;/p>
  347. &lt;p>humdinger made Sounds preferences remember the file panel location, and show only files and not folders in menus. He also added a mechanism to preview sound files in the file panel, and cleaned up a few of the names of notification sounds.&lt;/p>
  348. &lt;h3 id="command-line-tools">Command line tools&lt;/h3>
  349. &lt;p>waddlesplash (with some help from madmax) implemented &lt;code>pkgman search -i --not-required&lt;/code>, a mode that shows only installed packages that are not required by any other installed package (i.e. &amp;ldquo;leaf&amp;rdquo; packages.)&lt;/p>
  350. &lt;p>kallisti5 adjusted the &lt;code>route&lt;/code> command to accept an empty network address to mean &amp;ldquo;default&amp;rdquo;, which OpenVPN uses to set up the default route.&lt;/p>
  351. &lt;h3 id="kits">Kits&lt;/h3>
  352. &lt;p>waddlesplash adjusted BTimedEventQueue (used for all audio output and other media operations on Haiku) to properly flush events on destruction, and a few other minor improvements.&lt;/p>
  353. &lt;p>waddlesplash adjusted the naming of the new &lt;code>input_pointing_device_subtype&lt;/code> enum, which is used to report what kind of device generated pointer input events.&lt;/p>
  354. &lt;p>PulkoMandy implemented custom baudrates for serial output from the POSIX APIs all the way down into the USB serial driver.&lt;/p>
  355. &lt;p>nipos improved the legibility of text labels in the media controls display.&lt;/p>
  356. &lt;h3 id="servers">Servers&lt;/h3>
  357. &lt;p>X512 contributed changes to drop the legacy &amp;ldquo;2D acceleration&amp;rdquo; and batched-buffer-copies logic from app_server. This was not enabled (or even compiled in) for many years; it&amp;rsquo;s obsolete even for the old hardware that supported these features (as CPU routines to do the same are faster much of the time anyway, it seems), and &amp;ldquo;modern&amp;rdquo; 2D-accelerated graphics just go through the 3D pipelines, so if app_server ever gained such code it would share practically nothing with these anyway.&lt;/p>
  358. &lt;p>jscipione redid the notification panel sizing to be properly font-size-aware. He adjusted the notification icons sizing in various servers as well.&lt;/p>
  359. &lt;h3 id="drivers">Drivers&lt;/h3>
  360. &lt;p>korli fixed some problems with the handling of queue numbers in the &lt;code>virtio-pci&lt;/code> bus driver, fixing a number of intermittent issues with virtio devices (they would sometimes fail to initialize, among other problems.)&lt;/p>
  361. &lt;p>waddlesplash sychronized the &lt;code>realtekwifi&lt;/code> driver and WiFi stack with upstream FreeBSD, bringing in a number of bugfixes and other enhancements. He also tweaked the compiler flags to drop more unused or unneeded code at compile time.&lt;/p>
  362. &lt;p>waddlesplash restored the use of &amp;ldquo;uncached&amp;rdquo; memory for the ACPI module on x86(_64) by default, fixing boot failures on a few devices.&lt;/p>
  363. &lt;p>mtl1979 contributed checks to the usb_disk driver to return errors immediately rather than trying to read or write if there&amp;rsquo;s a status of &amp;ldquo;no media present&amp;rdquo;.&lt;/p>
  364. &lt;p>Lt-Henry added a new device ID to the Intel modesetting graphics driver.&lt;/p>
  365. &lt;p>PulkoMandy fixed some compiler warnings and enabled &lt;code>-Werror&lt;/code> in various drivers. He also added more error checking to the PS/2 driver, to allow long timeouts to be avoided in another case.&lt;/p>
  366. &lt;p>waddlesplash fixed a race condition in the SCSI bus manager&amp;rsquo;s (relatively new) request notification logic, and added some flags to make sure that we don&amp;rsquo;t wait for memory in the critical path.&lt;/p>
  367. &lt;p>PulkoMandy enabled VESA BIOS patching (to inject more video modes) by default on hardware where it is known to work.&lt;/p>
  368. &lt;p>waddlesplash fixed a memory leak in the network stack when &amp;ldquo;raw&amp;rdquo; sockets were closed, and added an &lt;code>ASSERT&lt;/code> that would have caught the problem.&lt;/p>
  369. &lt;h3 id="file-systems">File systems&lt;/h3>
  370. &lt;p>Jim906 contributed a fix to the FAT filesystem&amp;rsquo;s entry-caching logic: previously, multiple instances of the same filename with different casing could wind up in the entry cache when the file was not present, but these weren&amp;rsquo;t properly cleared when a file with one of those cases was created. Now, such incorrect &amp;ldquo;missing&amp;rdquo; entries aren&amp;rsquo;t created at all, fixing some corner-cases around file copying in Tracker and allowing some FAT-specific code to be deleted.&lt;/p>
  371. &lt;p>waddlesplash moved handling of &lt;code>open(O_RDONLY | O_TRUNC)&lt;/code> from filesystems into the VFS, and changed its behavior to return an error rather than truncating the file. What these flags specified together do is &amp;ldquo;undefined&amp;rdquo; in POSIX, but the Linux manpages ominously state &amp;ldquo;On many systems the file is actually truncated&amp;rdquo;, and indeed on Linux, using this open mode actually truncates files most of the time! That&amp;rsquo;s a rather surprising result, and there doesn&amp;rsquo;t seem to be much reason to support it, so Haiku now does the saner thing and refuses to do anything in this case.&lt;/p>
  372. &lt;p>waddlesplash adjusted the filesystem query parser to not try to read the key size of invalid indexes in a corner case.&lt;/p>
  373. &lt;p>waddlesplash adjusted the filesystems logging during disk scanning and mounting to only print errors when a disk at least partially looks like a particular filesystem but is otherwise invalid, rather than printing a lot of noisy error messages for every failed identification. He also cleaned up some code related to initializing filesystems, and fixed the logic around initializing NTFS disks.&lt;/p>
  374. &lt;p>Jim906 fixed &lt;code>file_cache_read&lt;/code> under userlandfs; previously it would return errors when reaching the end of files rather than handling them correctly.&lt;/p>
  375. &lt;p>waddlesplash added allocation of &amp;ldquo;scratch&amp;rdquo; buffers to the packagefs memory cache systems, avoiding frequent allocation and deallocation of temporary buffers.&lt;/p>
  376. &lt;h3 id="libroot--kernel">libroot &amp;amp; kernel&lt;/h3>
  377. &lt;p>waddlesplash added a missing call to a base method in the &lt;code>FileDiskDevice&lt;/code> class (used for handling files registered as virtual disks), fixing a file descriptor leak. He also cleaned up the code style a bit and fixed some minor TODOs while at it.&lt;/p>
  378. &lt;p>waddlesplash cleaned up some code in the &amp;ldquo;synchronous I/O&amp;rdquo; routines in the kernel (which are used when asynchronous I/O isn&amp;rsquo;t possible at the lowest level), and fixed an assertion check that wasn&amp;rsquo;t accounting for all possible error conditions, fixing some assertions when using files as disk devices.&lt;/p>
  379. &lt;p>waddlesplash fixed a bug in the logic that handled opening symlinks to nonexistent files with &lt;code>O_CREAT&lt;/code> in the VFS. He also added a testcase for this and another related issue.&lt;/p>
  380. &lt;p>waddlesplash fixed some minor bugs in the &amp;ldquo;scheduling recorder&amp;rdquo; (kernel subsystem that records when threads are scheduled/descheduled, for performance analysis) and &amp;ldquo;DebugAnalyzer&amp;rdquo; (the GUI app that analyzes such reports).&lt;/p>
  381. &lt;p>waddlesplash fixed an unlocking-order problem in a VFS low-resource hook that occasionally caused kernel panics on high memory usage.&lt;/p>
  382. &lt;p>waddlesplash dropped the &lt;code>*rand48_r&lt;/code> methods from &lt;code>stdlib.h&lt;/code>. They&amp;rsquo;re kept in &lt;code>libroot&lt;/code> for ABI compatibility, but as they&amp;rsquo;re nonstandard extensions provided only by glibc (not even the BSDs have them), we don&amp;rsquo;t need to export them in public headers anymore.&lt;/p>
  383. &lt;p>waddlesplash renamed the &lt;code>MoveFrom&lt;/code> primitive in the kernel &lt;code>LinkedList&lt;/code> to be called &lt;code>TakeFrom&lt;/code> instead. It doesn&amp;rsquo;t have &amp;ldquo;move semantics&amp;rdquo;, but rather appends the contents of the other list onto the current one, so we should avoid using the word &amp;ldquo;move&amp;rdquo; in such cases to avoid confusion.&lt;/p>
  384. &lt;p>waddlesplash adjusted &lt;code>vfork()&lt;/code> to not call any fork hooks. (We don&amp;rsquo;t implement a &amp;ldquo;true&amp;rdquo; &lt;code>vfork&lt;/code>, but we can at least avoid doing most of the things that &lt;code>fork&lt;/code> does in it, and we now do.)&lt;/p>
  385. &lt;p>korli implemented &lt;code>pthread_getcpuclockid&lt;/code>, which retrieves a CPU time clock ID for a specific thread rather than a whole process.&lt;/p>
  386. &lt;p>waddlesplash enabled more &lt;code>printf&lt;/code>-related warnings for bootloader code.&lt;/p>
  387. &lt;p>Anarchos contributed a change to increase the size of the memory region used for decompressing the boot tar archive, which is used when booting from certain types of media (like network devices).&lt;/p>
  388. &lt;h3 id="build-system">Build system&lt;/h3>
  389. &lt;p>waddlesplash added some sanity checks to the core build rules to prevent setting of &lt;code>ConfigVar&lt;/code>s with no value, and also to remove the &lt;code>@profile&lt;/code> from &lt;code>JAM_TARGETS&lt;/code> to avoid spurious warnings/errors later on.&lt;/p>
  390. &lt;p>kallisti5 added handling for ARM and RISC-V &lt;code>HOST_CPU&lt;/code>s in the core build rules.&lt;/p>
  391. &lt;h3 id="documentation">Documentation&lt;/h3>
  392. &lt;p>OscarL fixed a typo in the &amp;ldquo;Introduction to the &lt;code>launch_daemon&lt;/code>&amp;rdquo; documentation.&lt;/p>
  393. &lt;p>jscipione added documentation for &lt;code>BTextView::{GetFontAndColor,SetFontAndColor}&lt;/code>.&lt;/p>
  394. &lt;p>cafeina contributed documentation for &lt;code>BShelf&lt;/code> and &lt;code>BGameSound&lt;/code>.&lt;/p>
  395. &lt;h3 id="thats-all-folks">That&amp;rsquo;s all, folks!&lt;/h3>
  396. &lt;p>Thanks again to all who contribute to Haiku, and especially those donors who make my contract possible! Haiku, Inc. collected around $30,000 of donations in 2024; if we get even just that much this year, I&amp;rsquo;ll be able to spend more paid time on Haiku without exhausting the Inc.&amp;rsquo;s funds too quickly.&lt;/p></description></item><item><title>Haiku Activity &amp; Contract Report, November 2024</title><link>https://www.haiku-os.org/blog/waddlesplash/2024-12-10-haiku_activity_contract_report_november_2024/</link><author>waddlesplash</author><pubDate>Tue, 10 Dec 2024 23:45:00 -0500</pubDate><guid>https://www.haiku-os.org/blog/waddlesplash/2024-12-10-haiku_activity_contract_report_november_2024/</guid><description>&lt;p>This report covers hrev58292 through hrev58368.&lt;/p>
  397. &lt;h3 id="applications">Applications&lt;/h3>
  398. &lt;p>apl added an &amp;ldquo;installed&amp;rdquo; indicator to icons in HaikuDepot&amp;rsquo;s list view, and continued the refactoring of its internal data model. humdinger contributed icons for the &amp;ldquo;native&amp;rdquo; indicator, and apl added this to HaikuDepot&amp;rsquo;s display as well.&lt;/p>
  399. &lt;p>korli fixed an occasional crash in Screen preferences.&lt;/p>
  400. &lt;h3 id="kits">Kits&lt;/h3>
  401. &lt;p>X512 fixed an incorrect port deletion in &lt;code>BApplication&lt;/code>.&lt;/p>
  402. &lt;p>X512 added move constructor and assignment support to &lt;code>BRegion&lt;/code> and &lt;code>BShape&lt;/code>, and added a 2-argument constructor variant to BRect.&lt;/p>
  403. &lt;p>waddlesplash restored some special casing for &lt;code>B_RGB32&lt;/code> data in &lt;code>BBitmap::SetBits&lt;/code>, fixing some compatibility with BeOS, and korli adjusted it a bit for correctness.&lt;/p>
  404. &lt;p>linkmauve fixed a typo in an assertion in &lt;code>BTimeSource&lt;/code>.&lt;/p>
  405. &lt;p>waddlesplash completely rewrote &lt;code>BTimedEventQueue&lt;/code>. The new implementation avoids &lt;code>malloc&lt;/code> (necessary as this is in the &amp;ldquo;hot path&amp;rdquo; for media playback) and uses a templated linked-list rather than a manual one. Multiple users have reported that media playback seems smoother, especially on lower-end hardware, after this change.&lt;/p>
  406. &lt;h3 id="servers">Servers&lt;/h3>
  407. &lt;p>Hanicef (a new contributor!) contributed fixes to PadBlocker (the input_server filter that handles blocking touchpad events when keyboards are in use) to handle key repeat properly, and also to avoid blocking events from non-touchpad devices at all.&lt;/p>
  408. &lt;p>waddlesplash adjusted net_server to always remove the &amp;ldquo;autoconfiguration client&amp;rdquo; (usually the DHCP client) when a network link goes inactive, rather than just retry forever when there&amp;rsquo;s no way to send data at all.&lt;/p>
  409. &lt;h3 id="drivers">Drivers&lt;/h3>
  410. &lt;p>waddlesplash fixed some old bugs in the SCSI layer where flags were reset on the wrong request, which was the cause of many &amp;ldquo;no such range!&amp;rdquo; KDLs. He then removed a number of unneeded fields from internal data structures, and removed the need for the &lt;code>locked_pool&lt;/code> memory allocation module, saving some memory and slightly increasing efficiency. The SCSI driver was the only consumer of the &lt;code>locked_pool&lt;/code> system, which is now totally obsoleted by the kernel&amp;rsquo;s own memory management routines, so it was deleted entirely.&lt;/p>
  411. &lt;p>korli fixed some memory management code in the es1370 and auvia drivers, fixing crashes and audio output on some systems that use them.&lt;/p>
  412. &lt;p>waddlesplash refactored the network stack to return &amp;ldquo;ancillary data&amp;rdquo; (mostly relevant for UNIX domain sockets, as this allows file descriptors to b shared across processes) all in one chunk if possible, rather than separate chunks. The POSIX specification doesn&amp;rsquo;t seem to require this, but Firefox&amp;rsquo;s IPC code (which was taken from Chromium) seems to expect it.&lt;/p>
  413. &lt;p>waddlesplash made some adjustments to the network stack and the FreeBSD compatibility layer to report traffic statistics much more reliably (and to report driver-level statistics at all.)&lt;/p>
  414. &lt;p>waddlesplash added a missing cancellation of queued transfers to the USB disk driver, fixing KDLs on failures to attach to USB floppy drives.&lt;/p>
  415. &lt;p>waddlesplash added another USB device ID to the &lt;code>realtekwifi&lt;/code> driver, and later synchronized it (and the net80211 stack) with FreeBSD. He also adjusted some routines in the compatibility layer for correctness, allowing a Haiku-specific patch to be dropped from the stack.&lt;/p>
  416. &lt;p>waddlesplash added a missing NULL check and some missing deletions in the USB stack, fixing some (long-standing) memory leaks and (more recent) assertion failures.&lt;/p>
  417. &lt;p>PulkoMandy reworked the (incomplete) USB webcam driver to use standard headers rather than redefining constants from the UVC specification itself, and added support for decoding more information from UVC descriptors to &lt;code>listusb&lt;/code>.&lt;/p>
  418. &lt;p>PulkoMandy fixed handling of unplugs and canceled transfers in the RNDIS network driver (used for USB tethering.)&lt;/p>
  419. &lt;p>waddlesplash (following analysis by PulkoMandy) increased the default timeout used in PS/2 mouse resets, fixing initialization on some hardware.&lt;/p>
  420. &lt;h3 id="file-systems">File systems&lt;/h3>
  421. &lt;p>korli restored the FAT driver reporting volume names with lowercase letters (the behavior from before the driver was refactored.)&lt;/p>
  422. &lt;p>waddlesplash fixed some memory assertion failures in RAMFS and ram_disk, and did some minor cleanups as well.&lt;/p>
  423. &lt;p>Jim906 implemented prefetching in the block_cache, and adjusted the FAT driver to make use of it, greatly speeding up mounts of larger FAT partitions.&lt;/p>
  424. &lt;p>dalme contributed a patch to clarify the meaning of some fields in BFS initialization.&lt;/p>
  425. &lt;p>waddlesplash fixed BFS&amp;rsquo;s asynchronous I/O routine to keep references to inodes properly (and also fixed similar issues in the FAT and EXFAT drivers as well), fixing a very old assertion failure ticket.&lt;/p>
  426. &lt;p>waddlesplash fixed handling of the &amp;ldquo;last modified&amp;rdquo; index in BFS queries, and adjusted type coercion in the query parser to behave correctly for &amp;ldquo;time&amp;rdquo; types (and avoid re-converting types when unneeded.)&lt;/p>
  427. &lt;p>waddlesplash reworked how query terms are &amp;ldquo;scored&amp;rdquo; (in order to pick what index to run the query off of), signficantly improving efficiency by picking smaller indexes in many cases.&lt;/p>
  428. &lt;p>OscarL and waddlesplash reworked how partitions are matched in mount_server, reducing the number of &amp;ldquo;false positives&amp;rdquo; and partitions automounted erroneously.&lt;/p>
  429. &lt;h3 id="libroot--kernel">libroot &amp;amp; kernel&lt;/h3>
  430. &lt;p>waddlesplash fixed some corner-cases in handling of FD arrays for &lt;code>select&lt;/code>, and moved some definitions from &lt;code>sys/select.h&lt;/code> to private headers.&lt;/p>
  431. &lt;p>korli added a number of functions specified in POSIX-2024, mostly to open FDs with &lt;code>O_CLOEXEC&lt;/code> set automatically, such as &lt;code>pipe3&lt;/code>, &lt;code>dup2&lt;/code>, and memory management routines, like &lt;code>reallocarray&lt;/code>, &lt;code>memmem&lt;/code>, and some miscellaneous methods besides.&lt;/p>
  432. &lt;p>waddlesplash fixed an issue in the kernel &lt;code>object_cache&lt;/code> arena allocation system where the &amp;ldquo;minimum object reserve&amp;rdquo; setting wasn&amp;rsquo;t always respected properly.&lt;/p>
  433. &lt;p>waddlesplash added code to the bootloader to display the size of the bootable partitions in the menus, if that information can be retrieved.&lt;/p>
  434. &lt;p>waddlesplash added a necessary x86-specific stub to the libroot stubs files, which are used when &amp;ldquo;bootstrapping&amp;rdquo; (building a system fully from source with no built dependencies.)&lt;/p>
  435. &lt;p>waddlesplash did some cleanup to code in libroot, making one function return &lt;code>PTHREAD_CANCELED&lt;/code> as the spec says it should, and using more common methods for wait time conversion where possible.&lt;/p>
  436. &lt;p>X512 added &lt;code>posix_devctl&lt;/code> to libroot, a new POSIX-2024 method intended to replace the variable-argument &lt;code>ioctl&lt;/code>. Meanwhile, waddlesplash refactored the &lt;code>ioctl&lt;/code> declaration to use macros rather than struct initializers to avoid using the variable-argument &lt;code>ioctl&lt;/code> when possible.&lt;/p>
  437. &lt;p>waddlesplash unified the bitmap blitting routines and image placement computations used for displaying the startup splash between the bootloader and the kernel.&lt;/p>
  438. &lt;p>korli added support for RGB16 framebuffers in the EFI loader.&lt;/p>
  439. &lt;p>waddlesplash refactored the &amp;ldquo;unused vnodes&amp;rdquo; system in the kernel VFS layer to use an inline template linked-list, and a spinlock to protect it rather than a (heavily contended, during busy FS operations like &lt;code>git status&lt;/code>) mutex, which requires use of linked-lists anyway. He also adjusted the &lt;code>io_context&lt;/code> structure to be R/W-locked, and added a fast path out of the vnode lookup routine. Put together, these changes significantly improve &lt;code>git status&lt;/code> performance, at least when there&amp;rsquo;s a hot disk cache.&lt;/p>
  440. &lt;p>waddlesplash refactored and cleaned up some parts of the &lt;code>do_iterative_fd_io&lt;/code> and &lt;code>do_fd_io&lt;/code> routines in the kernel VFS layer (which are used in filesystems to implement kernel-level asynchronous and vectored I/O), to fix some corner cases and handle references more correctly. This was then used to clean up the block_cache&amp;rsquo;s new prefetcher a bit more.&lt;/p>
  441. &lt;p>waddlesplash fixed the default buffer size in &lt;code>KPath&lt;/code>, the kernel path buffer handling class.&lt;/p>
  442. &lt;p>waddlesplash added a mechanism for the &amp;ldquo;framebuffer console&amp;rdquo;, used to display KDLs, to be initialized much earlier in the kernel startup process, allowing kernel panics from virtual memory initialization (among other things) to be displayed onscreen, not just written to the syslog.&lt;/p>
  443. &lt;p>waddlesplash cleaned up and added more commands for dealing with I/O schedulers in the kernel debugger.&lt;/p>
  444. &lt;p>waddlesplash made a number of fixes to the virtual memory system&amp;rsquo;s handling of &lt;code>mprotect&lt;/code> and related functions, fixing assertion failures and other issues when these are used in certain circumstances, especially in conjunction with &lt;code>fork&lt;/code>. He also turned down the logging of a variety of the page fault methods.&lt;/p>
  445. &lt;p>PulkoMandy added mkostemp (specified in POSIX-2024.)&lt;/p>
  446. &lt;h3 id="documentation">Documentation&lt;/h3>
  447. &lt;p>PulkoMandy added documentation for some of the implementation details of &lt;code>ioctl&lt;/code> and &lt;code>posix_devctl&lt;/code> on Haiku.&lt;/p>
  448. &lt;h3 id="thats-all-folks">That&amp;rsquo;s all, folks!&lt;/h3>
  449. &lt;p>Thanks again to all who contribute to Haiku, and especially those donors who make my contract possible.&lt;/p></description></item><item><title>Haiku Activity &amp; Contract Report, October 2024</title><link>https://www.haiku-os.org/blog/waddlesplash/2024-11-06-haiku_activity_contract_report_october_2024/</link><author>waddlesplash</author><pubDate>Tue, 05 Nov 2024 17:30:00 -0500</pubDate><guid>https://www.haiku-os.org/blog/waddlesplash/2024-11-06-haiku_activity_contract_report_october_2024/</guid><description>&lt;p>This report covers hrev58188 through hrev58291.&lt;/p>
  450. &lt;h3 id="applications">Applications&lt;/h3>
  451. &lt;p>nipos adjusted Icon-O-Matic to open file panels in the same folder as the current file, fixed a bug in FontDemo that was preventing direct selection of font families, fixed Terminal to not change view sizes when changing font sizes, fixed text colors in Screen and ScreenSaver preferences, and more.&lt;/p>
  452. &lt;p>apl fixed the &amp;ldquo;Open&amp;rdquo; button in HaikuDepot not displaying application names in some circumstances, refactored HaikuDepot&amp;rsquo;s user ratings code, improved default the logic around default icons, and more.&lt;/p>
  453. &lt;p>waddlesplash added &lt;code>MoveOnScreen()&lt;/code> calls to a number of applications and preferences, to avoid having windows start offscreen after screen sizes changed. pinaraf contributed a similar fix for the Printers preflet.&lt;/p>
  454. &lt;p>sen (a new contributor!) made a number of improvements to the PowerStatus application to better support systems with multiple batteries, including proper handling for unused batteries, computing of time-left and low battery alerts when there&amp;rsquo;s more than one battery available, and handling of battery disconnects while running.&lt;/p>
  455. &lt;p>jscipione made some code changes to Tracker related to a work-in-progress refactor of the shortcuts code. waddlesplash made a number of cleanups to the Find panel, deleting unneeded and unwanted code especially around the &amp;ldquo;clean up old queries&amp;rdquo; feature, and reinstating the draggable query icon. jscipione fixed a variety of issues around various parts of Tracker, including automatically closing extra windows when switching to &amp;ldquo;spatial&amp;rdquo; mode, fixing crashes related to popup menus, and more.&lt;/p>
  456. &lt;p>CodeforEvolution implemented clearing the scrollback via an ANSI control sequence in Terminal (a feature already supported by xterm, Konsole, and others.)&lt;/p>
  457. &lt;h3 id="kits">Kits&lt;/h3>
  458. &lt;p>nipos fixed the Calendar view to vertically center date labels.&lt;/p>
  459. &lt;p>waddlesplash added some checks in BMessage to prevent more crashes when deserializing corrupt messages.&lt;/p>
  460. &lt;p>mt fixed some argument naming inconsistencies spotted by cppcheck.&lt;/p>
  461. &lt;p>X512 cleaned up some code in BView to use a utility function for sending &lt;code>BShape&lt;/code> data to app_server.&lt;/p>
  462. &lt;p>ayu-ch changed &lt;code>BPoint::PrintToStream&lt;/code> to actually print some decimal places.&lt;/p>
  463. &lt;p>nephele changed &lt;code>BTextControl&lt;/code> to make the background of controls in an &amp;ldquo;invalid&amp;rdquo; state turn red.&lt;/p>
  464. &lt;h3 id="drivers">Drivers&lt;/h3>
  465. &lt;p>waddlesplash adjusted the &lt;code>broadcom570x&lt;/code> driver to use MSIs for interrupts when possible, fixing support for various devices.&lt;/p>
  466. &lt;p>CodeforEvolution ported the &lt;code>vmxnet&lt;/code> driver from FreeBSD, to support VMware&amp;rsquo;s &lt;code>VMXNET&lt;/code> paravirtualized networking interface.&lt;/p>
  467. &lt;p>waddlesplash adjusted how reference counting for USB objects works, fixing some bugs and adding more robust assertions (though this introduced some new KDLs which could either be old bugs or just new regressions which haven&amp;rsquo;t been solved just yet.)&lt;/p>
  468. &lt;p>gscrain added some missing definitions from the USB Audio v2 specification to the headers, and added more dumping of its descriptors to &lt;code>listusb&lt;/code>. (The USB audio driver itself hasn&amp;rsquo;t been modified yet to support this.)&lt;/p>
  469. &lt;p>waddlesplash renamed the &lt;code>intel_cstates&lt;/code> CPU idle driver to &lt;code>x86_cstates&lt;/code>, as it also works on modern AMD hardware, and adjusted some fallback behavior in it. (He also modified another spin-loop in the kernel to make use of it.)&lt;/p>
  470. &lt;p>waddlesplash added some more sanity assertions to the network stack.&lt;/p>
  471. &lt;p>waddlesplash removed some duplicated code from the AHCI (SATA) driver, making it use common routines instead. He also fixed a 32/64-bit address mixup, which was causing boot failures on some 32-bit systems with more than 4GB of RAM.&lt;/p>
  472. &lt;p>waddlesplash reduced some log spam from the HDA driver.&lt;/p>
  473. &lt;p>waddlesplash fixed the SCSI stack to more properly respect DMA address restrictions.&lt;/p>
  474. &lt;h3 id="file-systems">File systems&lt;/h3>
  475. &lt;p>waddlesplash optimized searching for the next free block in the BFS block bitmap code, greatly speeding up creation and resizing of files on especially fragmented partitions.&lt;/p>
  476. &lt;p>waddlesplash reworked packagefs to have only installed directory nodes be r/w-locked, instead of &lt;em>all&lt;/em> nodes. This saves 40 bytes (on 64-bit systems) per installed package file, which adds up to multiple MB on a system with lots of packages installed.&lt;/p>
  477. &lt;p>waddlesplash cleaned up some unused parameters in the block cache APIs.&lt;/p>
  478. &lt;h3 id="libroot--kernel">libroot &amp;amp; kernel&lt;/h3>
  479. &lt;p>waddlesplash cleaned up the bootloader&amp;rsquo;s heap memory allocation logic, and then increased the size of maximum &amp;ldquo;standard&amp;rdquo; heap allocations to be large enough for packagefs buffers to fit. This massively reduces after-boot memory usage when booting with the BIOS loader, as not all bootloader heap memory is properly cleaned up yet, it seems. (The EFI loader is also affected, but not nearly as badly.) He also tried to refactor some of the bootloader memory management code to make memory cleanups on exit more feasible, but encountered a number of difficulties and only partially succeeded.&lt;/p>
  480. &lt;p>VoloDroid fixed the re-initialization of serial output in the EFI bootloader on x86_64.&lt;/p>
  481. &lt;p>waddlesplash turned down tracing in the SMP code in the BIOS bootloader.&lt;/p>
  482. &lt;p>waddlesplash adjusted the bootloader to display the system package version with the latest state, making it clearer what will actually be booted.&lt;/p>
  483. &lt;p>waddlesplash relaxed a check in the virtual memory types logic when legacy MTRRs are enabled, avoiding KDLs in some situations.&lt;/p>
  484. &lt;p>waddlesplash made the kernel discard swap space on-disk when swap is disabled.&lt;/p>
  485. &lt;p>waddlesplash added an assertion in the core virtual memory code to check that we don&amp;rsquo;t commit (reserve) more memory than we need for any given region, and fixed a number of places in the code where the accounting for this wasn&amp;rsquo;t quite correct (though some still linger.) He also fixed interaction between the &amp;ldquo;set memory protection&amp;rdquo; (&lt;code>mprotect&lt;/code>) and &amp;ldquo;set area protection&amp;rdquo; APIs. He also cleaned up some of the assertions and KDL commands, implemented some more debugging methods, and moved some source code around for better organization.&lt;/p>
  486. &lt;p>waddlesplash did some refactors and cleanups to the early boot memory allocation code in the kernel, fixing the boot on some systems with large amounts of RAM (or systems with unusual memory layouts.)&lt;/p>
  487. &lt;p>waddlesplash (re)added some more assertions to the kernel r/w locking code, fixed some logic errors in the low resource manager, and added a missing vnode reference acquisition in the file cache.&lt;/p>
  488. &lt;p>mmlr implemented Ctrl+D as a shortcut to exit KDL (when it&amp;rsquo;s possible to do so, that is.)&lt;/p>
  489. &lt;p>nipos and waddlesplash fixed some bugs in the ICU time conversion code for dates in the future (or past).&lt;/p>
  490. &lt;p>waddlesplash adjusted more parts of libroot to use the common utility function for converting &lt;code>timespec&lt;/code> structures.&lt;/p>
  491. &lt;p>waddlesplash cleaned up macros in some headers, including &lt;code>&amp;lt;sys/select.h&amp;gt;&lt;/code>, to avoid namespace pollution and duplicate definitions.&lt;/p>
  492. &lt;p>korli adjusted FIFOs to honor &lt;code>O_NONBLOCK&lt;/code> on &lt;code>open()&lt;/code> correctly.&lt;/p>
  493. &lt;p>korli changed driver loading to prefer loading from the non-packaged / &amp;ldquo;user&amp;rdquo; directories over the packaged ones (unless loading drivers from non-packaged is disabled entirely.)&lt;/p>
  494. &lt;h3 id="documentation">Documentation&lt;/h3>
  495. &lt;p>drea233 fixed a typo in the Keyboard documentation.&lt;/p>
  496. &lt;h3 id="build-system">Build system&lt;/h3>
  497. &lt;p>jessicah made &lt;code>./configure&lt;/code> detect the system &lt;code>wget&lt;/code>&amp;rsquo;s supported retry flags. waddlesplash adjusted how a Python interpreter can be specified to &lt;code>./configure&lt;/code> to match other tools, and fixed its version checks. OscarL made &lt;code>./configure&lt;/code> automatically choose the right GCC when running on &lt;code>x86_gcc2h&lt;/code> platforms.&lt;/p>
  498. &lt;p>CodeforEvolution removed an obsolete definition from the &lt;code>package_repo&lt;/code> Jamfile.&lt;/p>
  499. &lt;p>waddlesplash rehabilitated the build of the &lt;code>DiskDeviceManagerTest&lt;/code>.&lt;/p>
  500. &lt;h3 id="arm">ARM&lt;/h3>
  501. &lt;p>oanderso implemented instruction cache synchronization, fixed some double-locking problems, implemented &lt;code>VMTranslationMap::MaxPagesNeededToMap&lt;/code>,&lt;/p>
  502. &lt;h3 id="thats-all-folks">That&amp;rsquo;s all, folks!&lt;/h3>
  503. &lt;p>Thanks again to all who contribute to Haiku, and especially those donors who make my contract possible.&lt;/p></description></item><item><title>Haiku Activity &amp; Contract Report, September 2024 (ft. packagefs memory usage optimization)</title><link>https://www.haiku-os.org/blog/waddlesplash/2024-10-11-haiku_activity_contract_report_september_2024/</link><author>waddlesplash</author><pubDate>Fri, 11 Oct 2024 15:30:00 -0400</pubDate><guid>https://www.haiku-os.org/blog/waddlesplash/2024-10-11-haiku_activity_contract_report_september_2024/</guid><description>&lt;p>This report covers hrev58043 through hrev58187.&lt;/p>
  504. &lt;p>We&amp;rsquo;re now back to development &amp;ldquo;as usual&amp;rdquo; after the release of R1/beta5 (though some of the changes in this report did make it in to the release itself.)&lt;/p>
  505. &lt;h3 id="packagefs-memory-usage-optimization">packagefs memory usage optimization&lt;/h3>
  506. &lt;p>While waiting for beta5-related rebuilds and other work to be completed last month, I spent a bunch of time trying to optimize packagefs&amp;rsquo;s memory usage. There were a variety of changes here, such as: use singly- instead of doubly-linked lists where no performance penalty would be incurred, drop unused or constant fields from classes, inline reference counts for more optimal structure packing, eliminate unneeded padding, drop &amp;ldquo;object depots&amp;rdquo; from allocation arenas, make more use of allocation areas where it makes sense to, reduce locking granularity, implement and use a &amp;ldquo;bump allocator&amp;rdquo; for very short-lived objects, and more.&lt;/p>
  507. &lt;p>(Also while working on packagefs, I noticed our default string hashing routine was a somewhat outdated one; I replaced it with the now-common &lt;code>hashdjb2&lt;/code> not just for packagefs but for most of the kernel, and then all of userspace as well.)&lt;/p>
  508. &lt;p>The final result is savings of somewhere around (or possibly more than) 20% of total packagefs memory usage, excluding file data caches, which amounts to at least 15 MB on my system.&lt;/p>
  509. &lt;p>Now, on to the rest of the report.&lt;/p>
  510. &lt;h3 id="applications">Applications&lt;/h3>
  511. &lt;p>jscipione cleaned up some code in Tracker, and fixed both Deskbar and Tracker to use the &amp;ldquo;Menu&amp;rdquo; font in more menus. OscarL fixed a Tracker crash on screen resolution changes. humdinger made the text input column in Tracker&amp;rsquo;s Find panel wider, and jscipione removed an extra prompt to the user when dragging items out of query windows.&lt;/p>
  512. &lt;p>apl fixed the text colors in the &amp;ldquo;Usage conditions&amp;rdquo; window in HaikuDepot. jscipione fixed a crash when clicking on the conditions window before it&amp;rsquo;s finished loading.&lt;/p>
  513. &lt;p>waddlesplash updated the list of maintainers in AboutSystem&amp;rsquo;s credits.&lt;/p>
  514. &lt;p>nipos adjusted WebPositive&amp;rsquo;s font settings preferences to support word wrapping. He also adjusted Keymap&amp;rsquo;s buttons to use the standard system control colors, fixed Mail to make quoted text colors readable in dark mode, and fixed the text color in Tracker&amp;rsquo;s &amp;ldquo;File permissions&amp;rdquo; and &amp;ldquo;Status&amp;rdquo; views.&lt;/p>
  515. &lt;p>korli adjusted the Intel partition map editor to automatically enable the &amp;ldquo;Active&amp;rdquo; checkbox for the first primary partition.&lt;/p>
  516. &lt;p>korli adjusted the default &amp;ldquo;Mute&amp;rdquo; media key shortcut to toggle mute on and off instead of just muting.&lt;/p>
  517. &lt;p>dovsienko fixed the Clock desktop applet pointing its hands imprecisely.&lt;/p>
  518. &lt;p>korli fixed ActivityMonitor to not start offscreen after restoring its position.&lt;/p>
  519. &lt;p>humdinger fixed quoting of partition names in some DriveSetup messages.&lt;/p>
  520. &lt;h3 id="command-line-tools">Command line tools&lt;/h3>
  521. &lt;p>An old patch from kallisti5 to improve &lt;code>launch_roster&lt;/code>&amp;rsquo;s output (displaying more information by default, in a table format, including service status) was revamped and merged by waddlesplash.&lt;/p>
  522. &lt;p>waddlesplash added support for printing the mutex option flags (e.g. &lt;code>MUTEX_SHARED&lt;/code>, for mutexes shared across processes) to &lt;code>strace&lt;/code>.&lt;/p>
  523. &lt;p>waddlesplash added a &lt;code>-f&lt;/code> option to &lt;code>package_repo list&lt;/code> to print the canonical filenames of packages in a given &lt;code>repo&lt;/code> file. (This is useful for certain tools that want to download packages outside of Haiku.)&lt;/p>
  524. &lt;h3 id="servers">Servers&lt;/h3>
  525. &lt;p>jscipione fixed the colors of the &amp;ldquo;problem&amp;rdquo; and &amp;ldquo;results&amp;rdquo; windows in package_daemon (the ones that appear when there are problems installing or updating packages in HaikuDepot or SoftwareUpdater.)&lt;/p>
  526. &lt;p>waddlesplash added some more checks to the audio mixer startup, to avoid hangs in more cases.&lt;/p>
  527. &lt;p>madmax adjusted input_server to avoid locking the device list in more cases, fixing hangs and deadlocks when device threads hang.&lt;/p>
  528. &lt;p>madmax fixed single-clicks on the resize corner of windows erroneously minimizing the window.&lt;/p>
  529. &lt;h3 id="kits">Kits&lt;/h3>
  530. &lt;p>jscipione fixed live updating of text colors in Spinner controls, adjusted how parent colors are adopted across most controls, and tweaked the button background color in &amp;ldquo;dark mode.&amp;rdquo;&lt;/p>
  531. &lt;p>waddlesplash made some adjustments to the Locale Kit to avoid crashing if ICU failed to initialize in more cases.&lt;/p>
  532. &lt;p>waddlesplash added another assertion to &lt;code>BTimeSource&lt;/code> that published times don&amp;rsquo;t have negative drift.&lt;/p>
  533. &lt;h3 id="drivers">Drivers&lt;/h3>
  534. &lt;p>tmtfx enabled support for &amp;ldquo;Gemini Lake&amp;rdquo; and &amp;ldquo;Ice Lake&amp;rdquo; devices in the &lt;code>intel_extreme&lt;/code> modesetting driver. PulkoMandy added some more code to support &amp;ldquo;Tiger Lake&amp;rdquo;, and ilzu added some more &amp;ldquo;Tiger Lake&amp;rdquo; devices.&lt;/p>
  535. &lt;p>waddlesplash reduced the syslog spam of the &lt;code>usb_audio&lt;/code> driver.&lt;/p>
  536. &lt;p>oanderso adjusted the ACPI driver to map its physical memory as &amp;ldquo;write-back&amp;rdquo; instead of &amp;ldquo;uncached&amp;rdquo;. This was necessary for the ARM64 port to work (as otherwise we get faults on unaligned addresses), but it is supported on x86 as well. This exposed some other bugs in Haiku related to double-mapping of such physical memory, which must use the same memory type in order to not encounter problems (as if we don&amp;rsquo;t, we&amp;rsquo;ll get &amp;ldquo;machine check exception&amp;quot;s.)&lt;/p>
  537. &lt;p>mmlr fixed some bugs related to allocation of queues in the virtio drivers, and added more error checks and handling. korli added a check for the device status when resetting virtio devices, and fixed an out-of-bounds read in the virtio_pci driver.&lt;/p>
  538. &lt;h3 id="file-systems">File systems&lt;/h3>
  539. &lt;p>waddlesplash did some minor code and terminology cleanup in BFS.&lt;/p>
  540. &lt;p>Jim906 fixed a crash in FAT when disk I/O fails in some cases. He also enabled R/W access to volumes up to 2 TB in size, and added checks to prevent overflowing the sector count.&lt;/p>
  541. &lt;h3 id="libroot--kernel">libroot &amp;amp; kernel&lt;/h3>
  542. &lt;p>Some minor fixes and performance improvements to the kernel derived from changes by jpelczar were merged by waddlesplash, including to the kernel &lt;code>malloc&lt;/code>, locking granularity in the VM, page reservation leaks and dangling reference detection, and more. He cleaned up some of the code around the merged changes, while at it.&lt;/p>
  543. &lt;p>waddlesplash fixed an offset computation bug in the kernel IORequest subsystem that was leading to failed I/O operations spuriously being reported as successful.&lt;/p>
  544. &lt;p>waddlesplash cleaned up the &lt;code>*at&lt;/code> (e.g. &lt;code>linkat&lt;/code>) function implementations in &lt;code>libroot&lt;/code> and related modules, making them use the &lt;code>AT_FDCWD&lt;/code> constant rather than hard-coding values and reducing code duplication. He then adjusted the kernel to only accept &lt;code>AT_FDCWD&lt;/code> and &lt;code>-1&lt;/code> (the old value of &lt;code>AT_FDCWD&lt;/code>) for such syscalls, rather than any negative value.&lt;/p>
  545. &lt;p>waddlesplash replaced some custom-written libroot I/O code with glibc&amp;rsquo;s. (Eventually we want to switch entirely to musl, but the stdio implementation is still from glibc, so we should use glibc&amp;rsquo;s code here to be consistent for the moment.)&lt;/p>
  546. &lt;p>waddlesplash fixed &lt;code>gmtime()&lt;/code> to return the proper &amp;ldquo;GMT&amp;rdquo; timezone string.&lt;/p>
  547. &lt;p>waddlesplash fixed conversion of surrogate pairs in &lt;code>mbrtowc&lt;/code>.&lt;/p>
  548. &lt;p>waddlesplash made a number of fixes to the pthreads implementation, including adjusting error codes to be more in line with the POSIX specification, suppressing &lt;code>EINTR&lt;/code> in rwlocks, fixing deadlocks in barriers, and more. He also fixed invalid timeouts being passed to the POSIX unnamed semaphore routines, and fixed a logic error leading to shared unnamed semaphores not working properly.&lt;/p>
  549. &lt;p>korli adjusted the kernel&amp;rsquo;s linker scripts to warn or error if there are unexpected or unhandled sections.&lt;/p>
  550. &lt;p>waddlesplash fixed accounting for a currently running thread&amp;rsquo;s CPU time, which should improve the display of thread CPU usage in various applications.&lt;/p>
  551. &lt;p>waddlesplash refactored syscall runtime accounting, to count only the time actually spent in the syscall, and not its total overhead (which we can&amp;rsquo;t easily measure from within the kernel, anyway.) This makes the times in &lt;code>strace&lt;/code> output much more useful to work with.&lt;/p>
  552. &lt;p>waddlesplash reduced the maximum size of dirent buffers allocated by the kernel to 8 KB. (Most things that read dirents never read anything as large as the old or new limits, and the things that did should actually be faster this way anyway, as we now always go through a faster allocation facility in the kernel instead of a slower one.) He adjusted the few places in the tree that used such large buffers to use the new limit instead.&lt;/p>
  553. &lt;p>waddlesplash adjusted the &amp;ldquo;low resource&amp;rdquo; subsystem to not timeout due to a race condition when waiting for a single run to complete.&lt;/p>
  554. &lt;p>waddlesplash added some more assertions to the kernel mutex facilities to catch more spurious wakeups. He also fixed lock ABI compatibility between KDEBUG and non-KDEBUG builds, which had been a problem for many years. Now, drivers and kernel add-ons built against KDEBUG kernels should work with non-KDEBUG ones, while drivers built against non-KDEBUG kernels will encounter &amp;ldquo;missing symbol&amp;rdquo; errors when you try to use them against KDEBUG kernels. (Previously one would just get hangs, deadlocks, or crashes when attempting to do either of those things.)&lt;/p>
  555. &lt;p>waddlesplash adjusted the &lt;code>kqueue&lt;/code> implementation to use a common facility for converting timespecs, and added a check for invalid timespecs.&lt;/p>
  556. &lt;p>waddlesplash fixed a race condition leading to spurious wakeups in the thread unblock-after-timeout logic (a recent regression).&lt;/p>
  557. &lt;p>waddlesplash made some improvements to the VFS entry cache, most notably including caching of hash values, allowing the cache to skip string comparisons when the hash values don&amp;rsquo;t match. On one simple benchmark (rebuilding HaikuDepot) it saved about 10,000 string comparisons.&lt;/p>
  558. &lt;p>waddlesplash added some more debugging information to the &lt;code>slab_object&lt;/code> KDL command.&lt;/p>
  559. &lt;p>waddlesplash made some more adjustments to the rwlocks debugging code, including adding another &amp;ldquo;wasn&amp;rsquo;t locked&amp;rdquo; assertion (that code isn&amp;rsquo;t enabled by default even on &lt;code>KDEBUG&lt;/code> builds, as it&amp;rsquo;s part of the checks that are rather expensive to run) as well as a &amp;ldquo;isn&amp;rsquo;t read-locked&amp;rdquo; assertion (on destruction, which is enabled on all builds.) He fixed a few minor issues these assertions uncovered.&lt;/p>
  560. &lt;p>waddlesplash re-enabled the &amp;ldquo;initialize TSC from CPUID&amp;rdquo; code for hypervisors. (It was already enabled for bare metal.)&lt;/p>
  561. &lt;p>waddlesplash adjusted &lt;code>runtime_loader&lt;/code> to be built without &lt;code>-fno-builtin&lt;/code>, the same as most of libroot, providing a small performance improvement.&lt;/p>
  562. &lt;p>mmlr implemented PAT (Page Attribute Table) support for x86, which supersedes MTRRs and allows us to disable them entirely on supported hardware. He also cleaned up some of the code surrounding MTRRs and PAT, added some new debug commands, and added assertions to detect overlapping memory regions with differing types, which fixed most of the issues uncovered/caused by the ACPI memory type change. waddlesplash then renamed the &lt;code>B_MTR_*&lt;/code> constants to &amp;ldquo;something more meaningful&amp;rdquo; (as an old TODO comment indicated they should be).&lt;/p>
  563. &lt;p>korli implemented printing of more x86 CPU features in the debug output.&lt;/p>
  564. &lt;p>waddlesplash changed most remaining non-POSIX include/feature guards in standard headers to be &lt;code>_DEFAULT_SOURCE&lt;/code>, so that our &lt;code>&amp;lt;features.h&amp;gt;&lt;/code> can turn them on automatically in most cases.&lt;/p>
  565. &lt;p>waddlesplash added a missed check for the new-style &lt;code>BlockedEntries&lt;/code> settings in the bootloader.&lt;/p>
  566. &lt;p>waddlesplash cleaned up some code and adjusted how locking works in some parts of the PS/2 driver, to try and fix some race conditions.&lt;/p>
  567. &lt;p>waddlesplash added some more information to the &amp;ldquo;supposed to be free page&amp;rdquo; panic, and adjusted the &amp;ldquo;page&amp;rdquo; KDL command to use proper debug facilities for enumerating over address spaces rather than brute-force iteration (which is too slow to work well on 64-bit address spaces.)&lt;/p>
  568. &lt;p>kallisti5 fixed the build of the kernel guarded heap.&lt;/p>
  569. &lt;h3 id="documentation">Documentation&lt;/h3>
  570. &lt;p>kallisti5 updated the instructions for generating Google Cloud Platform instances for Haiku.&lt;/p>
  571. &lt;h3 id="build-system">Build system&lt;/h3>
  572. &lt;p>oanderso fixed building the DNS resolver under Clang.&lt;/p>
  573. &lt;p>waddlesplash adjusted the build system to only build the &lt;code>haiku_source&lt;/code> package if &lt;code>HAIKU_INCLUDE_SOURCES&lt;/code> is set, decreasing the time of full &lt;code>@nightly&lt;/code>-profile image builds.&lt;/p>
  574. &lt;p>waddlesplash synchronized the set of packages from HaikuPorts that Haiku is built against (primarily for the sake of the R1/beta5 release.)&lt;/p>
  575. &lt;p>jessicah added some missing checks and options for the Python tool in &lt;code>./configure&lt;/code>, plus some sanity checks for cross-tools options.&lt;/p>
  576. &lt;p>waddlesplash moved the libroot malloc implementations to their own subdirectory (to pave the way for the addition of more allocator(s) in the future, most notably OpenBSD&amp;rsquo;s malloc, which is a current candidate for replacing hoard2.)&lt;/p>
  577. &lt;p>PulkoMandy added Wonderbrush to the release images on all architectures, not just x86 32-bit.&lt;/p>
  578. &lt;p>waddlesplash unified the BeOS ABI compatibility preprocessor definitions to a single definition, and adjusted all code to match. He also disabled &amp;ldquo;BeOS compatible types&amp;rdquo; (for &lt;code>int32&lt;/code>, etc.) in kernel mode, and fixed the code that had depended on this.&lt;/p>
  579. &lt;p>waddlesplash cleaned up the base C/C++ compiler flags in ArchitectureRules and streamlined the comments around them.&lt;/p>
  580. &lt;h3 id="arm">ARM&lt;/h3>
  581. &lt;p>oanderson continued his work on ARM64 support, refactoring and implementing many missing parts of the VM translation map, exception handling, and TLBs, among other things.&lt;/p>
  582. &lt;p>waddlesplash added some &amp;ldquo;unimplemented&amp;rdquo; prints to the default base class implementation of certain VM debug methods, to aid in finding where missing functionality needs to be implemented.&lt;/p>
  583. &lt;h3 id="thats-all-folks">That&amp;rsquo;s all, folks!&lt;/h3>
  584. &lt;p>Thanks again to all who contribute to Haiku, and especially those donors who make my contract possible.&lt;/p></description></item><item><title>Haiku Activity &amp; Contract Report, August 2024</title><link>https://www.haiku-os.org/blog/waddlesplash/2024-09-17-haiku_activity_contract_report_august_2024/</link><author>waddlesplash</author><pubDate>Tue, 17 Sep 2024 23:30:00 -0400</pubDate><guid>https://www.haiku-os.org/blog/waddlesplash/2024-09-17-haiku_activity_contract_report_august_2024/</guid><description>&lt;p>This report covers hrev57901 through hrev58042.&lt;/p>
  585. &lt;p>R1/beta5 was of course &lt;a href="https://www.haiku-os.org/news/2024-09-13_haiku_r1_beta5/">released&lt;/a> just a few days ago, and many (though not all) of the changes in this report made it in to the release.&lt;/p>
  586. &lt;h3 id="applications">Applications&lt;/h3>
  587. &lt;p>madmax fixed a crash in AboutSystem caused by an incorrectly added copyright entry.&lt;/p>
  588. &lt;p>apl made a number of refactors to HaikuDepot&amp;rsquo;s code, including to the language model, path handling, package data fetching, the display of publishers, and more.&lt;/p>
  589. &lt;p>nipos and nephele submitted fixes to the ColumnListView, Debugger, WebPositive, ResEdit, FontDemo, Cortex, Sudoku, and more to remove hard-coded colors and make things look better in &amp;ldquo;dark mode&amp;rdquo;. (They also adjusted the computation used in Appearance for some colors in &amp;ldquo;dark mode&amp;rdquo; to make them fit in better.)&lt;/p>
  590. &lt;p>waddlesplash fixed the disassembler used by Debugger to handle addresses coming from registers in address computations (and submitted the fix upstream, as this is a third-party library.)&lt;/p>
  591. &lt;p>jscipione adjusted Tracker to repopulate menus when entering or leaving volumes, and to properly enable and disable some items in the &amp;ldquo;New&amp;rdquo; menu whenever menus are updated. He also fixed the &amp;ldquo;Copy&amp;rdquo; and &amp;ldquo;Cut&amp;rdquo; actions to not alter the selection (and fixed some other issues around Move and Copy, related to redraws), fixed some issues with colors in the &amp;ldquo;Open with&amp;hellip;&amp;rdquo; window, and made drag-and-drops from virtual folders create symbolic links (instead of copying the underlying file.)&lt;/p>
  592. &lt;p>humdinger fixed some bugs in Tracker relating to the naming of duplicating or creating new files, including around locale awareness. He also added an option to create a &amp;ldquo;New template folder&amp;rdquo;.&lt;/p>
  593. &lt;p>humdinger tweaked some GUI strings in various applications.&lt;/p>
  594. &lt;p>CalistoMathias (a GSoC &amp;lsquo;24 student)&amp;rsquo;s changes to implement basic folder filtering in Tracker queries were merged (however, this was done after the beta5 release was branched, so this feature isn&amp;rsquo;t in the release.) jscipione later came by did a few cleanups to it.&lt;/p>
  595. &lt;p>nephele fixed the build of &amp;ldquo;Switcher&amp;rdquo;.&lt;/p>
  596. &lt;p>OscarL fixed Clock to ensure that the first draw uses the current time (not some default time.)&lt;/p>
  597. &lt;p>jscipione fixed status icons not appearing in the &amp;ldquo;Modifier Keys&amp;rdquo; window in Keymap.&lt;/p>
  598. &lt;h3 id="command-line-tools">Command line tools&lt;/h3>
  599. &lt;p>waddlesplash added logic to &lt;code>profile&lt;/code> to report the count of events dropped by the system profiler.&lt;/p>
  600. &lt;p>mmlr added an argument to &lt;code>package_repo&lt;/code>&amp;rsquo;s &amp;ldquo;update&amp;rdquo; command that allows it to be used in an environment where not all packages in the repository are locally present (e.g. they might be stored in S3 buckets instead.)&lt;/p>
  601. &lt;h3 id="servers">Servers&lt;/h3>
  602. &lt;p>madmax added some missing locks of the font manager to app_server, and fortified the logic around addition and removal of fonts. He also fixed the font manager to not scan all directories twice on startup.&lt;/p>
  603. &lt;p>waddlesplash fixed a (probably harmless) broken timeout computation in app_server (uncovered in the process of working on the kernel timers change mentioned below.)&lt;/p>
  604. &lt;p>jscipione fixed window tab invalidation logic in app_server, fixing some very old &amp;ldquo;tab still appears after being removed from the stack&amp;rdquo; redraw glitches.&lt;/p>
  605. &lt;p>waddlesplash fixed a number of time computation bugs in the media mixer (uncovered by the &lt;code>BTimeSource&lt;/code> assertions change mentioned below), which fixed many (if not most or all) of the cases of the &amp;ldquo;no audio immediately after boot, only some time later&amp;rdquo; bug. He also improved its event scheduling efficiency, fixed some of its logic around disconnecting/reconnecting to outputs, and fixed some crashes in the multi-audio node caused by certain audio devices reporting invalid control types. (He also experimented with adding logic to switch sound outputs without restarting the media services, but this doesn&amp;rsquo;t work quite yet.)&lt;/p>
  606. &lt;p>waddlesplash added a check in registrar that clipboard download messages are sent properly, and added error handling for when they don&amp;rsquo;t. (This, along with a corresponding change in &lt;code>libbe&lt;/code>, fixes some application hangs on low-memory conditions when there&amp;rsquo;s an especially large clipboard.)&lt;/p>
  607. &lt;p>madmax added some checks in input_server to avoid invalid mouse settings files causing the mouse to not work at all.&lt;/p>
  608. &lt;p>waddlesplash moved some of the font-management code around in &lt;code>app_server&lt;/code> to avoid unnecessary waits for the font manager&amp;rsquo;s thread during startup, when possible.&lt;/p>
  609. &lt;p>PulkoMandy and X512 fixed a conflict between the &amp;ldquo;power&amp;rdquo; keycode and the Japanese &lt;code>\_&lt;/code> key, and adjusted the keymap documentation.&lt;/p>
  610. &lt;p>waddlesplash changed Debugger to not query the Package Kit in non-interactive mode at all (and fixed some other bugs, in Debugger and the Package Kit, related to this that were causing crashes or even hangs in various circumstances.)&lt;/p>
  611. &lt;p>mmlr fixed a use of uninitialized memory in the DHCP client (discovered by using the guarded heap.)&lt;/p>
  612. &lt;h3 id="kits">Kits&lt;/h3>
  613. &lt;p>Zardshard made a change to have BBitmaps with the &lt;code>ACCEPTS_VIEWS&lt;/code> flag set not be cleared automatically, fixing a compatibility issue with BeOS (as well as making the use of such bitmaps more convenient in multiprocess applications like WebKit.)&lt;/p>
  614. &lt;p>waddlesplash added an assertion in &lt;code>BTimeSource&lt;/code> in the Media Kit to prevent applications and services from trying to publish times with &amp;ldquo;drift&amp;rdquo; factors of 0. The &amp;ldquo;drift&amp;rdquo; value is used as a multipler and a divisor to correct for time/clock drift, so a value of zero (or negative) produces broken results. This was uncovered by the kernel timers change mentioned below, and it in turn uncovered more bugs in the media add-ons code.&lt;/p>
  615. &lt;p>waddlesplash fixed an API compatibility regression in &lt;code>BListView&lt;/code> that was causing stack overflow crashes on drag-and-scroll in certain applications (like WonderBrush). jscipione adjusted &lt;code>BListView&lt;/code> to not update selections on mouse up when dragging.&lt;/p>
  616. &lt;p>PulkoMandy fixed &lt;code>BMenu&lt;/code> to draw checkmarks properly on matrix-layout menus.&lt;/p>
  617. &lt;h3 id="drivers">Drivers&lt;/h3>
  618. &lt;p>waddlesplash implemented receive checksum offloading for IP, TCP, and UDP in &lt;code>virtio_net&lt;/code>, and fixed some logic and buffer sizing errors in the driver as well.&lt;/p>
  619. &lt;p>korli added definitions and logic for &amp;ldquo;SuperSpeedPlus&amp;rdquo;, a revision of USB3 that allows for 10 Gbps connections.&lt;/p>
  620. &lt;p>waddlesplash revised some of the out-of-order ACK logic in the TCP module, adjusted some debugging code to help with diagnosing some intermittent KDLs that some users have reported, and tweaked the window-update sending logic to avoid sending window updates unnecessarily. This was all in preparation for the implementation of dynamic receive window sizing, which was also merged last month (along with related fixes to the round-trip-time calculation), resulting in massively improved TCP throughput (as much as 10x or more depending on the connection.) Users who have previously seen slow download speeds on Haiku over long-distance connections should see very significant improvements now.&lt;/p>
  621. &lt;p>waddlesplash cleaned up some code and constants around ethernet MTUs, fixing some incorrect sizing in a few places. He then disabled MTUs larger than the ethernet maximum, as these aren&amp;rsquo;t handled properly at the moment and just caused traffic loss. (In order to handle these properly, we need to implement &amp;ldquo;Path MTU Discovery&amp;rdquo;, which at present we don&amp;rsquo;t.)&lt;/p>
  622. &lt;p>PulkoMandy fixed boundary checks and adjusted read/write logic in the &amp;ldquo;Enhanced&amp;rdquo; (generally ACPI) PCI bus&amp;rsquo;s configuration space code, to resolve &amp;ldquo;boot failure&amp;rdquo; regressions following the PCI refactors.&lt;/p>
  623. &lt;p>waddlesplash turned down some tracing constants to avoid syslog spam in some drivers.&lt;/p>
  624. &lt;p>waddlesplash fixed some bugs in the allocation of DMA buffers for FreeBSD/OpenBSD network drivers. He also fixed an incorrect buffer size in the receive path, which was a recent regression that was causing certain drivers not to work at all on some hardware.&lt;/p>
  625. &lt;p>waddlesplash made some slight efficiency improvements to the NVMe driver.&lt;/p>
  626. &lt;p>PulkoMandy updated ACPICA to a version from this March, and fixed a few minor issues in our code that interfaces with it.&lt;/p>
  627. &lt;p>waddlesplash cleaned up a variety of code related to ancillary data in the UNIX domain sockets module, and fixed some minor memory leaks in the network stack related to it. He also fixed a relatively rare KDL that sometimes happened when closing such sockets.&lt;/p>
  628. &lt;h3 id="file-systems">File systems&lt;/h3>
  629. &lt;p>waddlesplash unified some previously duplicated code between &lt;code>ramfs&lt;/code> and &lt;code>ram_disk&lt;/code>, made a few minor adjustments for efficiency, and then fixed it to allocate &amp;ldquo;cleared&amp;rdquo; pages. This fixes a violation of the POSIX specification that Clang depended on when working with memory-mapped files off &lt;code>ramfs&lt;/code>. He also cleaned up and unified some code, adjusted the memory reservation priority (to avoid whole-system hangs on low-memory conditions), and fixed some missing sets in &lt;code>ramfs&lt;/code> that were leading to KDLs.&lt;/p>
  630. &lt;p>waddlesplash added some more locking assertions to packagefs (and fixed the minor bugs they uncovered), and then added better diagnostic messages for the case where conflicting packages are requested to be mounted.&lt;/p>
  631. &lt;p>Jim906 fixed the initialization of media bytes in the FAT driver, made a change to speed up mounting of large volumes, and fixed errors in the handling of volume labels.&lt;/p>
  632. &lt;p>waddlesplash turned a kernel panic in the common query parser into a properly reported error.&lt;/p>
  633. &lt;p>waddlesplash started cleaning up the use of memory arenas (&lt;code>object_cache&lt;/code>s) in packagefs, in preparation for changes reducing its overall memory usage.&lt;/p>
  634. &lt;h3 id="libroot--kernel">libroot &amp;amp; kernel&lt;/h3>
  635. &lt;p>waddlesplash cleaned up some of the code in &lt;code>WeakReferenceable&lt;/code>, an intrusive reference-counting class that allows for &amp;ldquo;weak&amp;rdquo; references.&lt;/p>
  636. &lt;p>waddlesplash cleaned up some logic in the kernel thread code to not rely on certain return values to cancel timeouts (though this change introduced a regression that wasn&amp;rsquo;t fixed till this month.) He also fixed the scheduling of &amp;ldquo;absolute-real-time timeouts&amp;rdquo;; timeouts that have a time relative to the real time clock (instead of the system uptime clock.) These had previously only worked by chance (and probably in some cases would&amp;rsquo;ve gotten stuck for longer periods of time than they should have randomly). He performed some cleanups of the timer code at the same time.&lt;/p>
  637. &lt;p>waddlesplash fixed a check in the kernel&amp;rsquo;s user-debugger code (the kernel interface used by the Debugger application) that was leading to whole-system hangs when the &lt;code>debug_server&lt;/code> crashed or hung in certain circumstances (such as low memory.)&lt;/p>
  638. &lt;p>waddlesplash added some more sanity checks in the VFS to catch misbehaving filesystem drivers earlier, rather than causing cryptic KDLs later.&lt;/p>
  639. &lt;p>waddlesplash added a new mode to the &amp;ldquo;boot profiler&amp;rdquo; to allow the &lt;code>scheduling_recorder&lt;/code> to capture the boot process, allowing thread latencies and lock contention during it to be analyzed. (He also fixed some other miscellaneous issues surrounding this feature in the various tools related to it: scrollbars in DebugAnalyzer, kernel permissions in &lt;code>transfer_area&lt;/code>, etc.)&lt;/p>
  640. &lt;p>waddlesplash removed an unneeded scan of the SCSI bus and drivers from the device manager, reducing boot times somewhat.&lt;/p>
  641. &lt;p>waddlesplash fixed a major oversight in the kernel&amp;rsquo;s &lt;code>IORequest&lt;/code> API that was leading to mixups between the total size of a request and the last offset it transferred (i.e. the starting offset plus the total size.) This was leading to buffer overruns in the file cache, causing KDLs and other problems with cryptic errors about page structures. (He later added more assertions to the page code to catch misuses of the page structures like this more easily in the future.)&lt;/p>
  642. &lt;p>waddlesplash added an assertion to the kernel&amp;rsquo;s interrupt handling logic to catch a bug in VM integration driver, and some checks in the global areas tree to catch duplicate area IDs.&lt;/p>
  643. &lt;p>waddlesplash fixed a bug in the &lt;code>kqueue&lt;/code> implementation that was leading to &lt;code>libevent&lt;/code>&amp;rsquo;s &lt;code>kqueue&lt;/code> backend hanging on startup.&lt;/p>
  644. &lt;p>waddlesplash made a change to the kernel on 32-bit x86 to report syscall return values to &lt;code>strace&lt;/code> more correctly (however, it wound up introducing a bug that caused intermittent crashes of many applications which wasn&amp;rsquo;t discovered and fixed till near the end of the month.)&lt;/p>
  645. &lt;p>waddlesplash fixed some crashes in &lt;code>runtime_loader&lt;/code> that could happen when not all the dependencies of a dynamically-loaded library were present. He also fixed some reference counting and cache management bugs between &lt;code>ramfs&lt;/code> and the kernel VFS. (These two issues were uncovered by the unstable, experimental port of Firefox.)&lt;/p>
  646. &lt;p>waddlesplash renamed some architecture-specific functions introduced on x86 to have more generic names, as they&amp;rsquo;re now declared and used on other architectures as well.&lt;/p>
  647. &lt;p>waddlesplash cleaned up some BeOS compatibility code in &lt;code>libnetwork&lt;/code>, and adjusted things so that it&amp;rsquo;s not even compiled in on most architectures.&lt;/p>
  648. &lt;p>waddlesplash implemented the one portable case of &lt;code>mknod&lt;/code>/&lt;code>mknodat&lt;/code> (the one where it&amp;rsquo;s equivalent to &lt;code>mkfifo&lt;/code>), as defined in POSIX.&lt;/p>
  649. &lt;p>mmlr made some fixes and cleanups to the guarded heap in &lt;code>libroot_debug&lt;/code>, allowing it to be used in more scenarios (potentially on the whole system at once.)&lt;/p>
  650. &lt;h3 id="documentation">Documentation&lt;/h3>
  651. &lt;p>waddlesplash adjusted the definition of &lt;code>B_INFINITE_TIMEOUT&lt;/code> to make clearer that it&amp;rsquo;s &lt;code>INT64_MAX&lt;/code> (and cleaned up some code related to it.)&lt;/p>
  652. &lt;p>humdinger added a section to the HIG on &amp;ldquo;Recently Used Files&amp;rdquo;.&lt;/p>
  653. &lt;p>waddlesplash renamed the &amp;ldquo;Release Milestones&amp;rdquo; developer documentation page to &amp;ldquo;Release Cookbook&amp;rdquo;, which was what it used to be called when it was on Trac (and more accurately reflects what&amp;rsquo;s in it.) He then updated some of its sections for clarity.&lt;/p>
  654. &lt;h3 id="build-system">Build system&lt;/h3>
  655. &lt;p>X512 submitted a patch to put each build target on a separate line, in large part to make rebases and resolving merge conflicts in these files easier.&lt;/p>
  656. &lt;p>PulkoMandy, waddlesplash, and kallisti5 upgraded Haiku and its dependencies to be built against OpenSSL 3, Python 3.10, and a variety of other newer versions of standard packages.&lt;/p>
  657. &lt;p>PulkoMandy added a missing include of &lt;code>&amp;lt;features.h&amp;gt;&lt;/code> in &lt;code>&amp;lt;sched.h&amp;gt;&lt;/code>, to allow applications to use its extra features without needing to define any extra preprocessor macros.&lt;/p>
  658. &lt;p>waddlesplash updated the &amp;ldquo;WebPositive bookmarks&amp;rdquo; files, fixing some bugs in their redirections.&lt;/p>
  659. &lt;p>korli added the &lt;code>linprog&lt;/code> library headers to the &lt;code>haiku_devel&lt;/code> package. jmairboeck fixed some typos in comments in various compatibility headers, and waddlesplash fixed a C89 compatibility issue in one.&lt;/p>
  660. &lt;p>jscipione updated the size of nightly images to 650MB, so that there&amp;rsquo;s a bit more free space available.&lt;/p>
  661. &lt;p>waddlesplash made a variety of changes around the tree and the build system to get Clang builds much closer to a working state again (and also cleaned up some code while at it.)&lt;/p>
  662. &lt;h3 id="arm--powerpc">ARM &amp;amp; PowerPC&lt;/h3>
  663. &lt;p>zeldakatze fixed the text console in the OpenFirmware bootloader.&lt;/p>
  664. &lt;p>archeYR fixed the ARM kernel arch code to use the correct instruction for CPU idling.&lt;/p>
  665. &lt;p>oanderso fixed some bugs with cache and MMU maintenance in the ARM64 bootloader, allowing the boot to get into the kernel under virtualization on the Apple M1, then fixed the kernel timer code to work in a virtualized environment, and started making changes and implementing missing features in the MMU code.&lt;/p>
  666. &lt;h3 id="thats-all-folks">That&amp;rsquo;s all, folks!&lt;/h3>
  667. &lt;p>August was quite a busy month! Thanks again to all who contribute to Haiku, and especially those donors who make my contract possible.&lt;/p></description></item><item><title>Haiku R1/beta5 has been released!</title><link>https://www.haiku-os.org/news/2024-09-13_haiku_r1_beta5/</link><pubDate>Fri, 13 Sep 2024 12:00:00 +0000</pubDate><guid>https://www.haiku-os.org/news/2024-09-13_haiku_r1_beta5/</guid><description>&lt;p>After about a year and a half since the last beta, Haiku R1/beta5 has been released. See &amp;ldquo;&lt;strong>&lt;a href="./get-haiku/r1beta5/release-notes/">Release Notes&lt;/a>&lt;/strong>&amp;rdquo; for the release notes, &amp;ldquo;&lt;a href="./get-haiku/r1beta5/release-notes/#press-contact">Press contact&lt;/a>&amp;rdquo;, for press inquiries &amp;hellip; and &amp;ldquo;&lt;strong>&lt;a href="./get-haiku/r1beta5/">Get Haiku!&lt;/a>&lt;/strong>&amp;rdquo; to skip all that and just download the release (or upgrade to it from an existing install!)&lt;/p></description></item><item><title>[GSoC 2024]: Implementing Incremental Search [Final Report]</title><link>https://www.haiku-os.org/blog/calisto-mathias/2024-08-24_gsoc_2024_implementing_incremental_search_final_report/</link><author>calisto-mathias</author><pubDate>Sat, 24 Aug 2024 01:46:45 +0530</pubDate><guid>https://www.haiku-os.org/blog/calisto-mathias/2024-08-24_gsoc_2024_implementing_incremental_search_final_report/</guid><description>&lt;h2 id="introduction">Introduction&lt;/h2>
  668. &lt;p>The goal of this post is to document the changes I’ve successfully made during the GSoC period, the current state of the project, future enhancement goals, and a few other topics. I also want to extend my thanks to the Haiku developers and community for the opportunity to work on this fantastic operating system.&lt;/p>
  669. &lt;h2 id="background">Background&lt;/h2>
  670. &lt;p>Haiku is a truly innovative operating system. One of its most interesting approaches to a filesystem lies in the fact that it makes metadata a primary characteristic of the filesystem. In fact, this was one of the core features that it carried over from its predecessor BeOS.&lt;/p>
  671. &lt;p>So, what was my project about? Despite Haiku’s fast search capabilities, the Find Panel was outdated and lacked several features that could improve user experience. My research identified a few missing functionalities that could greatly enhance file searching:&lt;/p>
  672. &lt;ol>
  673. &lt;li>The ability to limit searches to specific directories.&lt;/li>
  674. &lt;li>The option to pause a running query.&lt;/li>
  675. &lt;li>A more user-friendly Find Panel interface, with search columns aligned to the attributes being queried.&lt;/li>
  676. &lt;li>Support for incremental search, allowing users to see search results update as they modify their search terms.&lt;/li>
  677. &lt;/ol>
  678. &lt;p>These improvements are designed to make searching in Haiku even more powerful and intuitive.&lt;/p>
  679. &lt;h2 id="incremental-search-a-bit-more-of-an-explanation">Incremental Search: A Bit More of an Explanation&lt;/h2>
  680. &lt;p>Have you ever run a search and wanted to tweak your search terms repeatedly while seeing updates in real time? That’s what incremental search offers. It allows you to adjust search terms and see results update automatically, without having to start a new search or manually re-run the current one. Instead of executing and adjusting queries repeatedly, incremental search lets you type and modify terms in one go, updating results on the fly.&lt;/p>
  681. &lt;p>This was the central focus of my project and where I dedicated most of my efforts!&lt;/p>
  682. &lt;h2 id="what-i-accomplished-during-my-google-summer-of-code-period">What I Accomplished During My Google Summer of Code Period&lt;/h2>
  683. &lt;h3 id="cleaning-up-the-user-interface-of-the-find-panel">Cleaning Up the User Interface of the Find Panel&lt;/h3>
  684. &lt;p>My first task was to reorganize the cluttered options in the Find Panel into a dedicated menu bar. This introductory task helped me get acquainted with Haiku’s development style. Although progress was slow initially due to my inexperience, I learned a lot from this process. Here’s a look at the initial changes and their appearance:&lt;/p>
  685. &lt;p>Following is the Old Find Panel present in the Haiku Operating System:
  686. &lt;br>&lt;br>
  687. &lt;img src="./files/blog/calisto-mathias/Final-Report/old-find-panel.png" alt="Old Find panel">
  688. &lt;br>&lt;br>
  689. And here is the new one:
  690. &lt;br>&lt;br>
  691. &lt;img src="./files/blog/calisto-mathias/Final-Report/new-find-panel.png" alt="New Find Panel" width="598px">
  692. &lt;br>&lt;br>&lt;/p>
  693. &lt;h3 id="adding-folder-filtering-abilities-to-searches-executed-through-the-find-panel">Adding Folder Filtering Abilities to Searches Executed Through the Find Panel&lt;/h3>
  694. &lt;p>The second task involved adding folder-based filtering to searches via the Find Panel. This enhancement was implemented at the application layer rather than the file system level. It maintains high search speeds while limiting results to selected directories. Users can now select multiple directories and merge the search results within the results panel. This functionality is accessible through the third drop-down menu from the left.&lt;/p>
  695. &lt;p>Users can select directories using the last option in this drop-down menu. This action opens a file panel where they can choose one or more directories (or symbolic links to directories). The selected directories then appear in a clearly visible section within the same drop-down menu. Users also have the option to unselect any directories they no longer want to include.&lt;/p>
  696. &lt;p>We can now select these directories for search through the following drop-down menu as shown in the pictures below
  697. &lt;br>&lt;br>
  698. &lt;img src="./files/blog/calisto-mathias/Final-Report/find-panel-with-directory-selectors.png" alt="New Find Panel Directory Selector" width="598px">
  699. &lt;br>&lt;br>
  700. &lt;img src="./files/blog/calisto-mathias/Final-Report/Selecting-Directories.png" alt="New Find Panel Directory Selector" width="598px">
  701. &lt;br>&lt;br>
  702. &lt;img src="./files/blog/calisto-mathias/Final-Report/directories-entries-in-menu.png" alt="New Find Panel Directory Selector" width="598px">&lt;/p>
  703. &lt;h3 id="adding-the-design-for-an-incremental-search-find-panel">Adding the Design for an Incremental Search Find Panel&lt;/h3>
  704. &lt;p>The most crucial and challenging aspect of my project was implementing the design for the incremental search find panel, which associates attribute columns with their corresponding search columns. While I managed to implement the core functionality, there are a few limitations that need to be addressed in the future.&lt;/p>
  705. &lt;p>Currently, the incremental find panel integrated into the Find Panel results window is under review on &lt;a href="https://review.haiku-os.org/c/haiku/+/8096">Gerrit&lt;/a>. It will take some time before it is merged into the main codebase. Despite the challenges, I managed to get the core functionality working, allowing users to pause and restart their queries, as well as adjust search terms, all within the results window without switching back and forth repeatedly.&lt;/p>
  706. &lt;img src="./files/blog/calisto-mathias/Final-Report/incremental-search-first-look.png" alt="Incremental Search panel">
  707. &lt;br>&lt;br>
  708. The user can select the various methods of combination in the same column. This combination follows the same rules as the searcy "by-attribute" mode in the old find panel.
  709. &lt;img src="./files/blog/calisto-mathias/Final-Report/selecting-combination-options.png" alt="Incremental Search Panel">
  710. &lt;br>&lt;br>
  711. &lt;p>Apart from this, users can pause and re-execute their queries on the file-system without any hassle now. The columns can also be moved around with each other, in order to set more powerful combination modes. The only caveat at the moment is that the two different combination modes for the incremental find panel hasn&amp;rsquo;t been completed. As of now, the columns are always combined using the &amp;ldquo;AND&amp;rdquo; operator (so the order does not matter, but this is temporary!)&lt;/p>
  712. &lt;h2 id="whats-still-left-to-do">What’s Still Left to Do?&lt;/h2>
  713. &lt;p>Implementing this project in one go was quite challenging. Initially, I hoped to complete everything by the project deadline, but that proved unrealistic. It took me some time to grasp the technical details involved. However, I believe I can complete the remaining work with a bit more time and by tackling it in smaller steps.&lt;/p>
  714. &lt;p>Here’s what remains to be done in the incremental find panel:&lt;/p>
  715. &lt;ol>
  716. &lt;li>&lt;strong>Incremental Search with Keystrokes:&lt;/strong> The goal was to refresh results with each keystroke. Although I implemented this, it turned out to be unstable due to the high load from frequent clearing, refreshing, and restarting of queries. I had planned to develop a debouncer to manage this load but didn’t manage to complete it. This will be my primary focus after the GSoC’24 period ends. A possible strategy to implement this that a future developer could look into with this could be to use a thread that continuously polls the predicate string. This would make use of synchronisation primitives and might be one way that we could tackle this issue. During my time in the GSoC period, I tried to make use of the BMessageRunner and BLooper classes to try this but I was unable to find a working strategy. I will keep working on this as well!&lt;/li>
  717. &lt;li>&lt;strong>Folder Filtering Integration:&lt;/strong> Folder filtering is not yet functional in the incremental search panel within the results window. This should be a straightforward addition, and I plan to incorporate it as soon as the initial code is merged.&lt;/li>
  718. &lt;/ol>
  719. &lt;h2 id="learning-experience-from-gsoc24">Learning Experience from GSoC’24&lt;/h2>
  720. &lt;p>GSoC’24 with Haiku has been an incredibly rewarding experience. Before starting, I was relatively new to C++ and struggled with using git effectively. Thanks to GSoC, I’ve gained confidence and skills. Although I still have a long way to go, working on Haiku has inspired me to explore further and contribute more to both Haiku and other open-source projects.&lt;/p>
  721. &lt;p>Interacting with the Haiku community and receiving their advice has been invaluable. I feel like I’ve made some great friends along the way, which has made the experience even more enjoyable.
  722. files/blog/calisto-mathias/Final-Report/
  723. Here are some key lessons I’ve learned during my time with Haiku:&lt;/p>
  724. &lt;ol>
  725. &lt;li>&lt;strong>Git:&lt;/strong> Initially, I struggled with git, having only used it for small projects. Working with Gerrit taught me how to use git more effectively for collaboration. Special thanks to zardshard and waddlesplash for their guidance and resources. I particularly appreciated waddlesplash’s detailed explanation of git fundamentals.&lt;/li>
  726. &lt;li>&lt;strong>Importance of Style Guidelines:&lt;/strong> I never used a style guideline for my personal projects, but I’ve learned how crucial they are for development speed. The Haiku style guide has proven to be highly effective, and I plan to adopt it for all my future C++ projects.&lt;/li>
  727. &lt;li>&lt;strong>Navigating Large Codebases:&lt;/strong> At first, I found it challenging to work with a large codebase. I felt overwhelmed by its size and complexity. However, over time, I improved my ability to navigate and contribute to the codebase, including adding a new view to the Haiku Results panel.&lt;/li>
  728. &lt;li>&lt;strong>Communication Skills:&lt;/strong> This project has significantly enhanced my ability to communicate effectively with community members.&lt;/li>
  729. &lt;/ol>
  730. &lt;h2 id="conclusion">Conclusion&lt;/h2>
  731. &lt;p>I’m deeply grateful to the Haiku community and development team for giving me the chance to contribute to Haiku. This project has not only improved my programming skills but also made me a fan of the Haiku operating system. I’m eager to keep contributing and learning as I continue my journey with Haiku.&lt;/p>
  732. &lt;p>A big thank you to my mentors, Niels Sascha Reedijk and Humdinger, for their ongoing support and guidance throughout the GSoC project. Their timely responses and insightful advice made the process smoother and helped me overcome many challenges and self-doubt.&lt;/p>
  733. &lt;p>I’m excited to keep contributing to the Haiku operating system and look forward to future opportunities to grow and learn.&lt;/p>
  734. &lt;h2 id="keeping-track-of-this-project">Keeping Track of this Project&lt;/h2>
  735. &lt;p>Haiku uses the Gerrit Revision Control system for keeping track of changes and commits. You can find the current status of my project on this changeset: &lt;a href="https://review.haiku-os.org/c/haiku/+/8096">Haiku Review&lt;/a>!&lt;/p></description></item><item><title>[GSoC 2024] Virtio Sound: Final Report</title><link>https://www.haiku-os.org/blog/diegoroux/2024-08-22_gsoc_2024_final_report/</link><author>diegoroux</author><pubDate>Thu, 22 Aug 2024 18:39:13 -0600</pubDate><guid>https://www.haiku-os.org/blog/diegoroux/2024-08-22_gsoc_2024_final_report/</guid><description>&lt;h1 id="gerrit-submission">Gerrit Submission.&lt;/h1>
  736. &lt;p>Check out my final Pull Request here: &lt;a href="https://review.haiku-os.org/c/haiku/+/8141">8141&lt;/a>&lt;/p>
  737. &lt;h1 id="overview">Overview&lt;/h1>
  738. &lt;p>During this GSoC period, I focused on developing the virtio sound driver for Haiku,
  739. aiming to enhance its performance as a guest OS in virtualized environments.
  740. This journey began with some challenges, for example, initially, I missed a small
  741. detail in the driver module path, which prevented the driver from loading.&lt;/p>
  742. &lt;p>One of the significant setbacks, I had, was understanding hmulti_audio.
  743. With little to no documentation available, it felt like working with a black box.
  744. I had to dive into existing audio drivers to piece together how things worked, but
  745. even then, some aspects remained hidden to me.&lt;/p>
  746. &lt;p>Throughout the development, I encountered various bugs, such as SMAP faults and
  747. unexpected crashes linked to hmulti_audio&amp;rsquo;s undocumented requirements. But we
  748. continued! And as of now, the driver supports playback but with some limitations.
  749. High bitrates (e.g., 384 kHz, 192 kHz) are not fully functional, so playback for these
  750. has been disabled. Recording, while partially successful at very low bitrates, has been
  751. disabled due to quality concerns. I plan to continue refining these aspects post-GSoC,
  752. with a focus on achieving reliable playback at high bitrates and reliable recording for
  753. all bitrates.&lt;/p>
  754. &lt;h1 id="why-wont-you-play-at-normal-speed">Why won&amp;rsquo;t you play at normal speed?&lt;/h1>
  755. &lt;p>VirtIO Sound relies on four queues: the control queue, the rx queue, the tx queue,
  756. and the event queue (currently unused). Configuration and stream discovery occur
  757. through the control queue, where we identify the supported bitrates, formats, and
  758. other stream characteristics. Once the streams are discovered, we configure them by
  759. selecting the highest supported bitrate, which hmulti_audio defaults to, and initiate
  760. the buffer_exchange process. Sounds simple? It it simple, but after this&amp;hellip; (ugh)&lt;/p>
  761. &lt;p>The VirtIO specification leaves room for interpretation, particularly regarding how
  762. and when buffers are considered &amp;ldquo;consumed.&amp;rdquo; While the spec suggests that a device should
  763. not return until audio buffers have been consumed, it doesn&amp;rsquo;t clarify if this means the
  764. buffers have been played or simply handed off to the host&amp;rsquo;s audio system.
  765. This ambiguity presented a challenge since hmulti_audio expects that once buffer_exchange
  766. indicates a new buffer cycle, the buffer has been played.&lt;/p>
  767. &lt;p>To manage this, we implemented a solution where we wait the amount of time it would take
  768. for the buffer to be played, aligning with hmulti_audio&amp;rsquo;s expectations.
  769. However, this isn&amp;rsquo;t foolproof, as there&amp;rsquo;s no reliable method to confirm playback—only
  770. consumption. Events in this setup signal the completion of a full cycle, which just
  771. results in the same behaviour. See commit &lt;a href="https://github.com/diegoroux/haiku/commit/01f627fcd2c7994103431aa5dc3e5faf631cbe88">01f627f&lt;/a>.&lt;/p>
  772. &lt;h1 id="unofficial-hmulti_audio-guide">Unofficial hmulti_audio Guide&lt;/h1>
  773. &lt;p>I suffered through not having an idea on what should I expect to
  774. implement and in what order. So here&amp;rsquo;s a concise guide based on my experience:&lt;/p>
  775. &lt;p>In order to get loaded and recognized by hmulti_audio, the MODULE_NAME for both drivers
  776. and devices must start with &lt;code>drivers/audio/hmulti/{name}&lt;/code>. For example:
  777. &lt;code>drivers/audio/hmulti/virtio_sound/driver_v1&lt;/code> and &lt;code>drivers/audio/hmulti/virtio_sound/device_v1&lt;/code>.
  778. The last part signals support for the new driver version.&lt;/p>
  779. &lt;p>hmulti_audio communicates with drivers primarily through ioctl calls (using codes that
  780. look like: &lt;code>B_MULTI_...&lt;/code>). All valid ioctl codes (as well as the structs used for them) can
  781. be found in &lt;a href="https://github.com/haiku/haiku/blob/master/headers/private/audio/hmulti_audio.h">headers/private/audio/hmulti_audio.h&lt;/a> under the first enum.&lt;/p>
  782. &lt;div class="alert alert-info">&lt;p>
  783. For this point on, we&amp;rsquo;ll treat sending an specific code through ioctl as calling a function.
  784. &lt;/p>
  785. &lt;/div>
  786. &lt;p>The init procedure hmulti_audio goes through for a device can be read &lt;a href="https://github.com/haiku/haiku/blob/master/src/add-ons/media/media-add-ons/multi_audio/MultiAudioDevice.cpp#L118">here&lt;/a>.
  787. To start, hmulti_audio retrieves the device information, such as supported formats, bitrates,
  788. input/output channels, and the channel maps through &lt;code>B_MULTI_GET_DESCRIPTION&lt;/code>.&lt;/p>
  789. &lt;div class="alert alert-info">&lt;p>
  790. bus_channels, can generate a bit of a confusion, at first glance, but they do not represent an
  791. extra channel but rather the physical input/output.
  792. &lt;/p>
  793. &lt;/div>
  794. &lt;p>Secondly, hmulti_audio will try to get and set enabled channels through &lt;code>B_MULTI_GET_ENABLED_CHANNELS&lt;/code>
  795. and &lt;code>B_MULTI_GET_ENABLED_CHANNELS&lt;/code>, respectively. Even if you can&amp;rsquo;t disable/enable channels on your
  796. device, you must reply to both calls.&lt;/p>
  797. &lt;p>hmulti_audio, using the information given at the &lt;code>B_MULTI_GET_DESCRIPTION&lt;/code> step, will pick
  798. the highest supported bitrate and format for each stream. &lt;code>B_MULTI_SET_GLOBAL_FORMAT&lt;/code> will
  799. be called with a &lt;code>multi_format_info&lt;/code> argument, which will contain the requested format and
  800. bitrate for both input and output (if both supported). Immediately after, &lt;code>B_MULTI_GET_GLOBAL_FORMAT&lt;/code>
  801. will be called, to obtain the formats and bitrates, on which the device is currently
  802. operating under, this means one can ignore the initial request as &lt;code>B_MULTI_GET_GLOBAL_FORMAT&lt;/code>
  803. will take precedent.&lt;/p>
  804. &lt;p>hmulti_audio then needs to know where to send the buffers for playback or where to retrieve
  805. recorded buffers. This is done via &lt;code>B_MULTI_GET_BUFFERS&lt;/code>, where we provide buffer details such
  806. as the buffer size (in frames per buffer, rather than bytes), the number of buffer cycles,
  807. and the buffers themselves. Inside &lt;code>multi_buffer_list&lt;/code>, an array for a set number of buffers
  808. is given, this array (separate arrays for playback and recording exist, but are the same
  809. in structure) allows us to specify the starting address of this buffer, for one channel,
  810. one must give the starting point for each channel, and stride (size in bytes of a single frame)
  811. repating this for N buffers. To illustrate this point, for one buffer:&lt;/p>
  812. &lt;div class="highlight">&lt;pre tabindex="0" style="color:#d0d0d0;background-color:#202020;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-c" data-lang="c">&lt;span style="display:flex;">&lt;span>&lt;span style="color:#6ab825;font-weight:bold">for&lt;/span> (uint32 ch_id = &lt;span style="color:#3677a9">0&lt;/span>; ch_id &amp;lt; stream-&amp;gt;channels; ch_id++) {
  813. &lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> buf_desc[ch_id].base = buf_ptr + (format_size * ch_id);
  814. &lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> buf_desc[ch_id].stride = format_size * stream-&amp;gt;channels;
  815. &lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>}
  816. &lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>Finally, &lt;code>B_MULTI_LIST_MIX_CONTROLS&lt;/code> is called by hmulti_audio to query the driver
  817. for any user-facing controls that should be displayed in the Media Preferences. It is
  818. acceptable to return 0 controls and B_OK if none are available.&lt;/p>
  819. &lt;p>The call to &lt;code>B_MULTI_BUFFER_EXCHANGE&lt;/code> signifies the start of playback/recording,
  820. although it is possible no actual audio data is sent at this stage. If the user
  821. changes preferences (such as the bitrate), hmulti_audio will cycle through calling
  822. &lt;code>B_MULTI_SET_GLOBAL_FORMAT&lt;/code> and &lt;code>B_MULTI_GET_BUFFERS&lt;/code> again.&lt;/p>
  823. &lt;div class="alert alert-info">&lt;p>
  824. B_MULTI_BUFFER_FORCE_STOP is never called, one should never assume that
  825. playback/recording will be explicitly stopped.
  826. &lt;/p>
  827. &lt;/div>
  828. &lt;p>All the other ioctl codes, may remain unimplemented at your discretion.&lt;/p>
  829. &lt;div class="alert alert-info">&lt;p>
  830. Remember all structs given, live in userspace. Act accordingly.
  831. &lt;/p>
  832. &lt;/div>
  833. &lt;h1 id="so-what-did-you-do-this-summer">So, what did you do this summer?&lt;/h1>
  834. &lt;p>I focused on implementing the VirtIO sound specification and
  835. integrating it with Haiku&amp;rsquo;s hmulti_audio system.&lt;/p>
  836. &lt;p>I successfully implemented playback, created a driver that&amp;rsquo;s flexible and easy
  837. to update, with potential for multi-stream support in the future.&lt;/p>
  838. &lt;p>This wasn&amp;rsquo;t as straighforward as it might seem, see &lt;a href="https://github.com/diegoroux/haiku/issues/1">#1&lt;/a>,
  839. &lt;a href="https://github.com/diegoroux/haiku/issues/2">#2&lt;/a>, &lt;a href="https://github.com/diegoroux/haiku/issues/3">#3&lt;/a>.&lt;/p>
  840. &lt;p>Issue &lt;a href="https://github.com/diegoroux/haiku/issues/1">#1&lt;/a>, given that I forgot
  841. that structs came from userspace, I constantly violated SMAP in all replies
  842. to hmulti_audio.&lt;/p>
  843. &lt;p>Issue &lt;a href="https://github.com/diegoroux/haiku/issues/2">#2&lt;/a>, wanting to have &amp;lsquo;clean&amp;rsquo;
  844. replies I decided to memset (0x00) some structs before writing our reply on them. Doing
  845. that in &lt;code>get_description&lt;/code> caused the array pointer, where the channel map was
  846. expected to be, to be wiped to NULL. See how we &lt;a href="https://github.com/diegoroux/haiku/commit/b3a98e80c4b5b05d331d0b4b6ad1dcc14d1e58d6">fixed this&lt;/a>.&lt;/p>
  847. &lt;p>Issue &lt;a href="https://github.com/diegoroux/haiku/issues/3">#3&lt;/a>.&lt;/p>
  848. &lt;p>&lt;img src="../page_fault.png" alt="page fault image">&lt;/p>
  849. &lt;p>The longest (in time being opened to fixed) to exist. A page fault was occuring, randomly.
  850. This made it harder to debug, as it sometimes it appeared to be fixed but one hour later
  851. coming back. It was actually caused by not having values in the buffer_exchange for
  852. the recording. It was fixed by a ~three line change. This was frustrating, but I&amp;rsquo;m
  853. glad it got fixed.&lt;/p>
  854. &lt;p>I dedicated a significant portion of my time to understanding and troubleshooting issues,
  855. especially around high-bitrate playback and recording. Although high-bitrate playback is
  856. still a work in progress, and recording has been temporarily disabled, these are areas
  857. I plan to continue improving post-GSoC.&lt;/p>
  858. &lt;p>Looking ahead, my goals include fixing high-bitrate playback, re-enabling recording,
  859. and optimizing the driver&amp;rsquo;s performance, particularly in terms of CPU usage.
  860. This project is something I plan to continue developing well beyond the GSoC period.&lt;/p>
  861. &lt;h1 id="the-end">the end?&lt;/h1>
  862. &lt;p>This GSoC journey has been an incredible learning experience.
  863. I want to endlessly thank Jérôme Duval (@korli) and Scott McCreary (@scottmc) for their
  864. invaluable guidance, patience and valuable lessons; as well as to the community, everyone who
  865. took the time to read my blog posts, those who offered help in the IRC during the early stages.
  866. Your support made this possible, and I look forward to continuing my work with Haiku
  867. in the future.&lt;/p>
  868. &lt;p>It&amp;rsquo;s not the end, at least not for the VirtIO Sound driver.&lt;/p>
  869. &lt;p>If you want to have a more detailed view of all of my work, click &lt;a href="https://github.com/diegoroux/haiku/pull/4">here&lt;/a>.&lt;/p>
  870. &lt;p>Thank you all!&lt;/p>
  871. &lt;ul>
  872. &lt;li>Diego Roux&lt;/li>
  873. &lt;/ul></description></item></channel></rss>
Copyright © 2002-9 Sam Ruby, Mark Pilgrim, Joseph Walton, and Phil Ringnalda