Commit Graph

58445 Commits

Author SHA1 Message Date
Augustin Cavalier
ace07f7051 freebsd11_wlan: Adapt _haiku module for FreeBSD 11.
Mostly just additions of new primitives and hook functions that are
relatively straightforward and mostly copied from FreeBSD. The one
notable set of changes is the ones relating to gDevices, as the hacks
we used previously to hide the base device are now no longer needed
(as the previous commit noted.)
2018-06-27 20:14:35 -04:00
Augustin Cavalier
2ed3d6d1b5 freebsd11_network: Remove IFT_IEEE80211 logic.
Previous versions of FreeBSD created a base ifp of type IFT_IEEE80211
in addition to the ifp created for each VAP. We ignored these, so that
the devices we displayed (/dev/.../0, etc.) were numbered properly.

FreeBSD 11 no longer does this and instead uses an ieee80211com as its base
type, so this logic is not needed.
2018-06-27 20:14:35 -04:00
Augustin Cavalier
83fee6c8b6 freebsd11_network: Even more changes for freebsd11_wlan.
The net80211 code now fully compiles with -Werror=implicit-function-declaration,
however, it is not yet fully patched for Haiku usage.
2018-06-27 20:14:35 -04:00
Humdinger
cbadcae1d0 Small string changes in HaikuDepot GUI
* Don't translate internally used names in BMenuBars.
* Use presentable strings for the title of BAlerts.
* Make the wording a bit less technical.
  Should the HaikuServer URL be part of the update/remove rating alert?

Change-Id: I0a984082eadbc5834ac6b8b2b1955e66098d1c8a
2018-06-27 22:54:40 +00:00
John Scipione
e79c33c93f BResources SetToImage docs: update variable name in retval (tiny) 2018-06-27 10:05:52 -07:00
Augustin Cavalier
69d3ef8233 AboutSystem: kPublicDomain is not presently used, #if 0 it out.
Fixes the build (sure, GCC, a static unused global constant is worth
throwing a warning over.)
2018-06-26 18:34:39 -04:00
Augustin Cavalier
5807f2981b AboutSystem: Copyright cleanups.
* netcat is now provided via a package and is not required by the
   'haiku' package
 * Display the full name of ACPICA and update copyright year
 * Update copyrights for libpng.
2018-06-26 18:20:14 -04:00
Augustin Cavalier
5ec8aa426a AboutSystem: Combine Intel Wi-Fi firmware credits.
The first two have the same license and are also now covered by
intellinuxwireless.org. The second two also share a license among
themselves, and also with following (not-yet-imported) firmware,
e.g. from idualwifi3160.
2018-06-26 17:50:56 -04:00
Augustin Cavalier
a7999984fc Remove last references to tcpdump.
It hasn't been in the Haiku repository or provided by the Haiku package
for over a year.
2018-06-26 17:39:06 -04:00
Augustin Cavalier
f81f6999ee Remove private vmware driver headers.
Not used since the VMware drivers were migrated out of the tree
a few years ago.
2018-06-26 17:23:23 -04:00
Niels Sascha Reedijk
f98e331cf5 Small spelling fixes. Reported by mazbrili through Pootle. Thanks! 2018-06-26 21:26:45 +02:00
David Murphy
3d86db178e Backgrounds preflet limited to 10 recent folders
Added recent folder limit as class member but
defaulted the value to 10.
Stopped using index to keep track of selected
path and folder menu item. Instead use BMessage to send
clicked folder path to the folder bg image loader.

Change-Id: I6b1809ff782db839ef43eb7169a7f6e77fb4ec70
Fixes #5026
2018-06-26 00:56:51 +00:00
Augustin Cavalier
abb59d7351 intel_extreme: Fix instances of user memory creation and access.
You still cannot boot to desktop under SMAP on intel_extreme, however,
as the agp_gart bus has not been patched properly. Doing so breaks the
intel_extreme accelerant, so more investigation is needed.
2018-06-24 23:52:09 -04:00
Augustin Cavalier
14ec6c8b23 intel_extreme: Remove some non-Haiku cases from device_ioctl. 2018-06-24 23:52:09 -04:00
Augustin Cavalier
b31cb92f29 3rdparty/qtcreator: Support for multiple directories in one project. 2018-06-24 23:52:09 -04:00
Augustin Cavalier
32b50a8831 configure: Add missing word-boundary marker to test invocation.
Fixes specifying a secondary cross-arch that is a substring of the first
(e.g. "x86_gcc2"+"x86".) Thanks to nielx for noticing!
2018-06-23 17:13:24 -04:00
Autocomitter
c2b58737a1 Update translations from Pootle 2018-06-23 19:16:38 +00:00
Augustin Cavalier
79dba05004 HaikuDepot: Fix a -Wuninitialized in server client code.
If result is not a success, then we use hasData without initializing it.
2018-06-21 22:06:27 -04:00
Augustin Cavalier
4215eb6003 Debugger: Fix some broken comparisons.
* Missing parentheses in integer comparison inversion
 * !=, not ! at the beginning of expression

Spotted by Clang.
2018-06-21 22:05:27 -04:00
Augustin Cavalier
582afd9a7f interface & app_server: Fix missing parentheses near ternary operators.
+ has greater operator precendence than ?, so we need parentheses when
using both in expressions. Both of these look like actual bugs.

Spotted by Clang.
2018-06-21 22:04:31 -04:00
Augustin Cavalier
b9491db99c ACPI: Remove useless if-test. 2018-06-21 22:02:46 -04:00
Augustin Cavalier
f4b42b518a drivers: Deduplify joystick_driver.h.
Now there is only the one copy in headers/private/device.
2018-06-21 18:46:30 -04:00
Augustin Cavalier
9b83a2a043 BJoystick: Fix fJoystickInfo initialization.
joystick_info contains BLists which initialize themselves upon new(),
and Clang warned (correctly) that using memset() overwites that, as well as
RTTI and other data that they contain. So instead, only memset the first
part of the struct, and then manually initialize the other members.

Fixes #14217.
2018-06-21 17:52:39 -04:00
Augustin Cavalier
09c7b1526f freebsd11_network: Fix MLEN/MHLEN macros after mbufq changes.
In 02cb8503d2, I added the m_next and
m_nextpkt structures to mbuf, as per FreeBSD's mbufq system that
FreeBSD 11.1's net80211 code uses. What I didn't realize (and
korli and PulkoMandy who reviewed my code didn't notice either)
is that the data fields in mbuf are sometimes dealt with through
these LEN macros, which were now incorrect after such changes.

This caused an out-of-bounds memory write for data above a certain
size that was attempting to be written into an mbuf that under the
old sizing would have been fine, but under this new sizing was invalid,
and this manifested itself as a KDL under the guarded_heap (#14207).
It possibly also manifested itself as a stack-smash with the new net80211
code (uncommitted on a local machine, and the reason I tried using
the guarded heap in the first place.)

Now we use FreeBSD 11's macros, which use offsetof instead of raw
integer math. This means that we can't specify the struct size in mbuf
as these structs are computed from mbuf's definition, and thus have
to rely on the allocator giving mbuf the correct size (as FreeBSD
does also.)
2018-06-20 21:26:21 -04:00
Augustin Cavalier
e4104854c3 if_dl: Increase size of sdl_data from 20 to 46 bytes.
FreeBSD's is presently 46 bytes. CID 1422869 warns that it can get overrun
in if_attach() in copying if_xname which is IF_NAMESIZE bytes (32).

This breaks ABI, but BeOS did not have sockaddr_dl, it is only a modern-GCC
ABI break. Since most applications assume that sockaddr_dl is variable-length
and is null-terminated, as well as not used very often, hopefully this will
require relatively few rebuilds.
2018-06-20 21:26:21 -04:00
Augustin Cavalier
2a3a847f82 HPGSTranslator: Remove from the tree.
Not included in the build and not referenced anywhere else. Now lives at
HaikuArchives.
2018-06-19 23:43:53 -04:00
Augustin Cavalier
0a23d1fb23 jam: Remove InstallOptionalHaikuImagePackage; unused following previous commit. 2018-06-19 23:15:34 -04:00
Augustin Cavalier
571def7114 WebPositive: Store default bookmarks in git instead of downloading them.
No functional change. Ideally we would create these via ResAttr like we do
the mail-providers, but these have attributes on their directories and not
just the files, so that will be slightly trickier, so for now just keep them
in their zip format.
2018-06-19 23:11:58 -04:00
Augustin Cavalier
9b326aa287 mail: Store mode flags by-value, not by-reference.
They are passed into the constructor by-value, and Clang warns that
we are taking the reference of a temporary.
2018-06-18 23:20:18 -04:00
Augustin Cavalier
a309b7c3a1 bin: Clang warning fixes.
* Functions that call exit() should return void
 * char* -> const char*
 * main returns int, not bool.
2018-06-18 23:18:34 -04:00
Augustin Cavalier
9b29611fb8 ACPI: Set handle to NULL.
There is a (probably non-viable) case where it might not get initialized
by the function and then potentially used, so set it to NULL to silence
Clang.
2018-06-18 23:17:38 -04:00
Augustin Cavalier
9216fc0178 More class/struct mixup fixes.
Spotted by Clang.
2018-06-18 23:16:50 -04:00
Augustin Cavalier
fe17f0df1f scsi: Use _res and not res in MK_ERROR.
Some users of MK_ERROR pass in parameters from a variable called "res",
which is obviously not what they want to do, as that will use this "res"
and not theirs.

Spotted by Clang.
2018-06-18 22:05:45 -04:00
Augustin Cavalier
b2f22ba09f build: Actually disable non-useful Clang warnings.
* The if-case was appending to gccBaseFlags after the rest of the file
   was done using it, so it was ineffective. Now we set it with the rest
   of the baseFlags.
 * We already pass no-integrated-as in configure, no need to do it in
   MainBuildRules.
 * B_USE_BUILTIN_ATOMIC_FUNCTIONS isn't used anymore, so get rid of it.
2018-06-18 22:04:48 -04:00
Augustin Cavalier
c124995713 configure: Cleaner grouping of compiler settings.
Now, instead of breaking them up, all settings related to or gleaned
from the compiler are listed first (except for BOOT_CXXFLAGS_...).
No functional change intended.
2018-06-18 19:32:14 -04:00
Augustin Cavalier
6c5fcb4f14 configure: Move deduplifying targetArchs to where HAIKU_PACKAGING_ARCHS is built.
If one specifies a cross-tools path instead of --build-cross-tools along
with --use-clang, then the specified architecture winds up in the list twice,
as the first test looks for the arch name where only "unknown" exists
(since in the case of cross-tools paths, we delay fetching the arch.)
So we need to move this check to there instead.
2018-06-18 19:32:13 -04:00
Augustin Cavalier
ddf7f64365 configure: If set, pass the cross-tools-prefix when invoking Clang.
This lets clang use our linker and other binutils instead of its own.
Now clang builds produce a working bootloader and get all the way
to the "rocket" icon, at which point userland init fails.
2018-06-18 19:32:13 -04:00
Augustin Cavalier
9ac3062734 kernel: Small fixes for Clang. 2018-06-18 19:32:13 -04:00
Augustin Cavalier
29a21a63cb ArchitectureRules: Enable -ftree-vrp, but use -fno-delete-null-pointer-checks everywhere.
Most of the problems with tree-vrp stemmed from its deletion of null-pointer
checks (see linked commit in the source.) Now, GCC has a flag to control that,
and with it enabled I can boot to the desktop even with tree-vrp enabled.
2018-06-18 19:32:13 -04:00
Augustin Cavalier
b06628148f HaikuPorts: Update nano to not depend on libmagic. 2018-06-17 15:37:05 -04:00
Jessica Hamilton
7f7f3618dd webpositive: force download window on screen.
* When Download window is initially shown, it is correctly
  fully onscreen; however, adding a download resizes the
  window such that it becomes partially offscreen. Now,
  when the frame is resized, reposition the window onscreen
  again.

Fixes #12704
2018-06-17 17:00:47 +00:00
Augustin Cavalier
c1f451fa9b HaikuPorts: Sync packages with latest buildmaster (most notably, WebKit.) 2018-06-17 12:58:36 -04:00
Kacper Kasper
c49f045421 Link WebPositive with libWebKitLegacy on x86_64
Signed-off-by: Augustin Cavalier <waddlesplash@gmail.com>
2018-06-17 12:58:19 -04:00
Augustin Cavalier
4a459f066d :kernel: Fix stack alignment in syscall entry on x86_64.
The user iframe and associated data that the syscall entry pushes to the
stack directly were causing the stack to be mis-aligned by 8 bytes. Since
we re-aligned %rsp afterwards, for most usecases this wasn't a problem.
However, since we stored the pre-realinged %rsp in %rbp (as we need it to
access the iframe data), this also meant that anything which depended on
%rbp being 16-byte-aligned would run into serious problems.

As it turned out, GCC 7 assumed that %rbp was indeed 16-byte-aligned, and
so optimized certain accesses to use SSE instructions that depended on this
alignment. Since inside any callstack begining with a syscall this was not
the case, a "General Protection Exception" resulted (see #14160 for an example)
at the first usage of such an instruction. I wasn't really sure what was going
on when it first came up, and so "fixed" it by disabling the GCC optimization
that used such instructions. Replacing the -fdisable... with -mstackrealign thus
also "fixes" the problem, as I discovered earlier today, as it forces GCC to
realign the stack in function prologues.

So instead of rounding %rsp down to the nearest aligned address after the
pushes are complete, we offset %rsp by the amount the pushes are not,
thus fixing both %rsp and %rbp in syscall handling routines. This of course
depends on syscall_rsp being already aligned, which it is.

Thanks to PulkoMandy and js for the advice and guidance (and PulkoMandy
for the ASCII art), as this is essentially my first time working with
kernel assembly.
2018-06-16 17:24:33 -04:00
Jessica Hamilton
77c8afb47f libroot_build: don't define system_time() on Haiku host.
* On x86_64, this was causing an infinite loop between
  libroot & libroot_build in the host unzip tool.
2018-06-16 10:08:56 +00:00
Jessica Hamilton
d284524815 libroot_build: replace void* with addr_t for hidden functions.
* Using attribute visibility hidden doesn't get applied if a
  function returns a non-class pointer type, so the functions
  weren't being hidden for gcc4+ builds, resulting in stack
  overflows. Using addr_t, which should be the same size as
  void* works around this restriction.
2018-06-16 10:08:56 +00:00
Alexander von Gluck IV
64d4515abf kernel: Only apply rtl-stv1 hack to x86 & x86_64
Change-Id: I971f7bf3bb95ee466a59ab777c2f6fc56fbcbd43
2018-06-15 13:43:13 +00:00
Augustin Cavalier
4f7b9506fd Revert the rest of the COMPAT_MODE changes (back to hrev52003.)
This reverts commit 458e758f37.
This reverts commit ce5eb94a82.
This reverts commit aac8d4c317.
This reverts commit c70cba914a.
This reverts commit 2ffbe7aaca
This reverts commit c6e120e2d2.
2018-06-15 00:20:56 -04:00
Augustin Cavalier
513403d420 Revert team and thread changes for COMPAT_MODE (hrev52010 & hrev52011).
This reverts commit c558f9c8fe.
This reverts commit 44f24718b1.
This reverts commit a69cb33030.
This reverts commit 951182620e.

There have been multiple reports that these changes break mounting NTFS partitions
(on all systems, see #14204), and shutting down (on certain systems, see #12405.)
Until they can be fixed, they are being backed out.
2018-06-14 22:25:06 -04:00
Rene Gollent
211cb77acf Debugger: don't auto-download packages non-interactively.
- When in non-interactive mode, i.e. saving a crash report, don't
  allow the image debug info loader to automatically grab missing but
  available info packages. Otherwise we potentially download very large
  packages with the user being entirely unaware, i.e. the 200MB debug
  information package now present by default for gcc7's libgcc. This
  should eventually be made a configurable preference though.
2018-06-14 16:51:32 -04:00