aboutsummaryrefslogtreecommitdiff
path: root/backend/session/session.c
AgeCommit message (Collapse)Author
2021-04-11backend/session: Remove logind backendKenny Levinsen
This is instead delegated to libseat.
2021-02-28backend/session: fix KMS device filteringSimon Ser
As explained in [1], user-space should perform a drmModeGetResources call to figure out whether a device supports KMS. [1]: https://gitlab.freedesktop.org/mesa/drm/-/merge_requests/127
2021-02-05Make implementation function lists static constManuel Stoeckl
This requires a change to the type of `struct wlr_tablet` and `wlr_tablet_init` signature, both of which are part of the unstable API.
2021-01-04backend/session: allow wlr_session_find_gpus to return an errorSimon Ser
Sometimes wlr_session_find_gpus will encounter an error. This is different from finding zero GPUs. On error, wlr_session_find_gpus already returns -1. However, this is casted to size_t, so callers uncorrectly assume this is a success. Instead, make wlr_session_find_gpus return a ssize_t and allow callers to handle the error accordingly.
2020-11-19backend/session: add a timeout waiting for GPUsSimon Ser
If a GPU doesn't show up in 10s, bail out and return zero GPUs.
2020-11-19backend/session: replace session_signal with events.activeSimon Ser
This is more idiomatic wlroots API. The new name makes it clear that the signal is emitted when wlr_session.active changes.
2020-11-19backend/session: wait for DRM device if none foundSimon Ser
Wait for a DRM device if none is found in wlr_session_find_gpus. This can happen if the compositor is loaded before the display kernel driver. This supersedes the logind CanGraphical property. To test, e.g. with i915 and sway: rmmod -f i915 sway & modprobe i915 Closes: https://github.com/swaywm/wlroots/issues/2093
2020-11-19backend/session: introduce wlr_session.events.add_drm_cardSimon Ser
This is triggered when a new DRM card is added. An easy way to test this patch is `modprobe vkms`.
2020-11-19backend/session: filter udev events by sysnameSimon Ser
We're only interested in card devices. The loop over wlr_session.devices would take care of ignoring non-card events, but a future patch will listen to udev "add" events as well.
2020-11-19backend/session: operate on wlr_deviceSimon Ser
Instead of operating on FDs in {open,close}_device, operate on wlr_devices. This avoids the device lookup in wlr_session and allows callers to have access to wlr_device fields. For now, we use it to remove wlr_session_signal_add and replace it with a more idiomatic wlr_session.events.change field. In the future, other events will be added.
2020-11-19backend/session: don't return FD on failure in open_fileSimon Ser
When wlr_session_open_file fails, don't return the FD, otherwise the caller will think the call succeeded.
2020-08-24session: Add libseat backendKenny Levinsen
2020-02-17backend/session: allow GPU enumeration on FreeBSDJan Beich
https://github.com/FreeBSDDesktop/libudev-devd/commit/f11ee5b418c740ba6fd4c946ab10b0d89702e4d0
2019-08-12backend/session: non-void function should return a valueAntonin Décimo
With assertions disabled, it should make sense to return NULL.
2019-07-27Remove all wayland-server.h includesSimon Ser
The documentation for wayland-server.h says: > Use of this header file is discouraged. Prefer including > wayland-server-core.h instead, which does not include the server protocol > header and as such only defines the library PI, excluding the deprecated API > below. Replacing wayland-server.h with wayland-server-core.h allows us to drop the WL_HIDE_DEPRECATED declaration.
2019-03-02backend/session: add noop sessionemersion
This is the first step towards being able to run via DRM leasing and on render nodes. Test with: export WLR_BACKENDS=drm export WLR_SESSION=noop export WLR_DRM_DEVICES=/dev/dri/renderD128
2018-11-12Use #if instead of #ifdef for wlroots config dataemersion
This prevents some annoying issues when e.g. not including wlr/config.h or making a typo in the guard name.
2018-09-18Add support for WLR_SESSION env variablerandom human
Valid values are "logind"/"systemd" and "direct". If WLR_SESSION is set, only its value is potentially tried; it will not try any other option.
2018-08-27Init the new destroy signals added by #1200Alexander Bakker
2018-08-26Add destroy signals to types that are destroyed by wl_display_destroyAlexander Bakker
2018-08-08session: load GPU devices even if they have zero crtcs/connectors/encodersIlia Bozhinov
On some systems (most notably laptops with two GPUs) there are GPUs that don't have attached outputs. However, we still want to load those GPUs because they could still be used by the compositor for rendering.
2018-07-21Revert "Merge pull request #1153 from emersion/include-config"Drew DeVault
This reverts commit ef0a6ea4d2934ec014d791150c42348061ec4f7f, reversing changes made to 8d03bc9178d8544cbcd24293ece6ac9f1698e602.
2018-07-21Always include config.hemersion
2018-07-09util: add wlr_ prefix to log symbolsemersion
2018-06-14Multiseat fixesScott Anderson
2018-02-19Revert "ELF Visibility"Drew DeVault
2018-02-19Explicitly export EFL symbolsScott Anderson
2018-02-12Reformat all #include directivesemersion
2018-02-12Make wlr_signal_emit_safe privateemersion
2018-02-12Add wlr_signal_emit_safeemersion
2018-01-21style: include brackets for if/while/for, even if it's a single statementJohannes Schramm
2018-01-02fix build without systemdPoroCYon
2017-12-27config: Avoid clash with other config-headersBjörn Esser
2017-12-26config: Put all defines into config.hBjörn Esser
2017-12-08Listen to display destroy in sessionemersion
It's not the backend's responsibility to destroy the session anymore.
2017-11-16Fix a bunch of mistakes detected with scan-buildemersion
2017-11-10Remove VLA from session.hEric Molitor
VLAs are optional C11 features and not supported by C++.
2017-10-11Add FreeBSD compatibilityGreg V
2017-10-02Check for fd failure properlyScott Anderson
2017-10-02Add explicitly picking GPUs with environment varScott Anderson
2017-10-01Change wlr_session to open every GPUScott Anderson
2017-09-22Add elogind supportdudemanguy
Resolves SirCmpwn/wlroots#146
2017-08-26Remove single GPU assumptions from wlr_sessionScott Anderson
2017-08-26Merge wlr_udev into wlr_sessionScott Anderson
2017-08-26Rename functions to be consistent with #93Scott Anderson
2017-08-06Changed header paths.Scott Anderson
2017-08-06Moved session/ into backend/Scott Anderson