]> git.ipfire.org Git - thirdparty/systemd.git/log
thirdparty/systemd.git
4 years agoresolved: inline iterator variable declarations 19608/head
Zbigniew Jędrzejewski-Szmek [Fri, 14 May 2021 15:33:54 +0000 (17:33 +0200)] 
resolved: inline iterator variable declarations

4 years agoresolved: drop pointless bitfield on a lone bool
Zbigniew Jędrzejewski-Szmek [Fri, 14 May 2021 15:32:50 +0000 (17:32 +0200)] 
resolved: drop pointless bitfield on a lone bool

4 years agoresolved: optimize layout of DnsPacket
Zbigniew Jędrzejewski-Szmek [Fri, 14 May 2021 15:31:26 +0000 (17:31 +0200)] 
resolved: optimize layout of DnsPacket

We obviously have lots of those, so even small savings add up.

Bitfields are dropped because they don't give any memory savings due to
alignment requirements (but would still require more complex to access).

/* size: 184, cachelines: 3, members: 28 */
/* sum members: 172, holes: 1, sum holes: 4 */
/* sum bitfield members: 4 bits (0 bytes) */
/* padding: 7 */
/* bit_padding: 4 bits */
    ↓
/* size: 176, cachelines: 3, members: 28 */

4 years agoresolved: optimize layout of DnsTransaction
Zbigniew Jędrzejewski-Szmek [Fri, 14 May 2021 15:28:48 +0000 (17:28 +0200)] 
resolved: optimize layout of DnsTransaction

/* size: 296, cachelines: 5, members: 46 */
/* sum members: 278, holes: 5, sum holes: 17 */
/* sum bitfield members: 4 bits, bit holes: 1, sum bit holes: 4 bits */
    ↓
/* size: 280, cachelines: 5, members: 46 */
/* sum members: 278, holes: 1, sum holes: 1 */
/* sum bitfield members: 4 bits, bit holes: 1, sum bit holes: 4 bits */

4 years agoresolved: rearrange DnsResourceRecord for better layout
Zbigniew Jędrzejewski-Szmek [Fri, 14 May 2021 15:15:53 +0000 (17:15 +0200)] 
resolved: rearrange DnsResourceRecord for better layout

The structure is rearranged to have less holes. Also fields in the union
are rearranged not to have holes (though most variants of the union still
have some padding at the end).

The full size does not decrease a lot, but the compiler should be able to
copy less bytes when it knows the specific type of the union.

Bitfields are dropped because they don't give any memory savings due to
alignment requirements (but would still require more complex to access).

The change from the this and previous commit:
/* size: 128, cachelines: 2, members: 13 */
/* sum members: 112, holes: 3, sum holes: 15 */
/* sum bitfield members: 2 bits, bit holes: 1, sum bit holes: 6 bits */
     ↓
/* size: 112, cachelines: 2, members: 13 */
/* sum members: 108, holes: 1, sum holes: 4 */

4 years agoresolved: use narrower types for label counts in rr
Zbigniew Jędrzejewski-Szmek [Fri, 14 May 2021 15:03:30 +0000 (17:03 +0200)] 
resolved: use narrower types for label counts in rr

Order will be adjusted later to remove holes.

4 years agoresolved: shorten dns_name_count_labels()
Zbigniew Jędrzejewski-Szmek [Fri, 14 May 2021 14:47:21 +0000 (16:47 +0200)] 
resolved: shorten dns_name_count_labels()

4 years agoresolved: pahole optimization for DnsQuery
Zbigniew Jędrzejewski-Szmek [Fri, 14 May 2021 09:28:17 +0000 (11:28 +0200)] 
resolved: pahole optimization for DnsQuery

Change from the last three commits:

/* size: 312, cachelines: 5, members: 46 */
/* sum members: 296, holes: 5, sum holes: 16 */
   ↓
/* size: 288, cachelines: 5, members: 46 */
/* sum members: 286, holes: 1, sum holes: 1 */

It's not a big difference, but we might have quite a few queries in flight,
so let' make this a bit more efficient.

4 years agoresolved: make counter for redirects smaller
Zbigniew Jędrzejewski-Szmek [Fri, 14 May 2021 09:20:18 +0000 (11:20 +0200)] 
resolved: make counter for redirects smaller

It can never go above 16, so let's use a narrower type.

Order will be adjusted later to remove holes.

4 years agoresolved: make counter for n_auxiliary_queries smaller
Zbigniew Jędrzejewski-Szmek [Fri, 14 May 2021 09:12:12 +0000 (11:12 +0200)] 
resolved: make counter for n_auxiliary_queries smaller

It can never go above 64, so let's use a narrower type.

Order will be adjusted later to remove holes.

4 years agoresolved: indent tables for readability
Zbigniew Jędrzejewski-Szmek [Fri, 14 May 2021 07:04:47 +0000 (09:04 +0200)] 
resolved: indent tables for readability

Some of the tables in resolved were already doing using this convention. This
makes the rest of them do so too.

4 years agotools/make-directive-index: parallelize
Zbigniew Jędrzejewski-Szmek [Wed, 12 May 2021 09:24:25 +0000 (11:24 +0200)] 
tools/make-directive-index: parallelize

I occasionally do 'build/man/man systemd.directives' when working on man pages,
and it's annoying slow. By paralellizing the parsing of xml, we can make it a
bit faster.

This is still rather innefficient. Only the parsing part is serialized, xml is
still produced serially at the end, which is hard to avoid.

$ ninja -C build man/systemd.directives.xml
before:
8.20s user 0.21s system 99% cpu 8.460 total
8.33s user 0.18s system 98% cpu 8.619 total
8.72s user 0.19s system 98% cpu 9.019 total

after:
13.99s user 0.73s system 345% cpu 4.262 total
14.15s user 0.35s system 348% cpu 4.161 total
14.33s user 0.35s system 339% cpu 4.321 total

I.e. it uses almost twice as much cpu, but cuts the wallclock time down (on a
2-core/4-thread cpu) to about half too, which is an overall win if you're just
trying to render the man page.

The change from list and .append() to set and .add() is something that could
have been done before too, but it's noticable now. It cuts down on the
serialization/deserialization time (about .2s).

4 years agoAdd Microsoft Pro Intellimouse MOUSE_DPI to hwdb
Simon Watts [Wed, 12 May 2021 21:22:39 +0000 (22:22 +0100)] 
Add Microsoft Pro Intellimouse MOUSE_DPI to hwdb

- Internet specifications give 1600 DPI @ 1000Hz for this sensor
- Confirmed experimentally via `mouse-dpi-tool`
- vid, pid, and name match string from `mouse-dpi-tool`

4 years agoUpdate Korean translation (#19083)
Seong-ho Cho [Thu, 13 May 2021 08:19:48 +0000 (17:19 +0900)] 
Update Korean translation (#19083)

Co-authored-by: Seong-ho Cho <shcho@gnome.org>
4 years agoMerge pull request #19590 from keszybz/comments-and-service-modernization
Yu Watanabe [Thu, 13 May 2021 03:17:19 +0000 (12:17 +0900)] 
Merge pull request #19590 from keszybz/comments-and-service-modernization

Comments and service modernization

4 years agoMerge pull request #19567 from poettering/ipv4-ipv6-lowercase
Zbigniew Jędrzejewski-Szmek [Wed, 12 May 2021 10:21:58 +0000 (12:21 +0200)] 
Merge pull request #19567 from poettering/ipv4-ipv6-lowercase

various follow-ups to socket-bind logic

4 years agoresolved.conf.in: add missing Quad9 servers
Michael Catanzaro [Tue, 11 May 2021 13:24:55 +0000 (08:24 -0500)] 
resolved.conf.in: add missing Quad9 servers

The example configuration is missing half of Quad9's addresses.

4 years agoresolved: be more careful with weird links with low MTUs
Lennart Poettering [Tue, 11 May 2021 20:21:52 +0000 (22:21 +0200)] 
resolved: be more careful with weird links with low MTUs

Apparently CAN links will show up in rtnetlink with very low MTUs. We
shouldn't consider them relevant if no IP is spoken over them, since
these MTUs are irrelevant for us then.

Hence, let's check if there's an address assigned to the link before
considering its MTU.

As additional safety net filter out MTUs smaller than the minimum DNS
packet size, too.

Finally, in case we don't find any suitable interface MTU, let's default
to 1500 as the generic Ethernet MTU.

Fixes: #19396
4 years agopam: fix typo try_authtok → use_authtok
Lennart Poettering [Wed, 12 May 2021 08:33:27 +0000 (10:33 +0200)] 
pam: fix typo try_authtok → use_authtok

This was a copy/paste mistae apparently, there's not "try_authtok" and
this was supposed to copy what Fedora uses, which uses "use_authtok"
correctly. Hence adjust this.

Fixes: #19369
4 years agoMerge pull request #19533 from yuwata/network-queue
Zbigniew Jędrzejewski-Szmek [Wed, 12 May 2021 10:12:22 +0000 (12:12 +0200)] 
Merge pull request #19533 from yuwata/network-queue

network: introduce queue to configure address, route, etc

4 years agocore/service: modernization 19590/head
Zbigniew Jędrzejewski-Szmek [Mon, 10 May 2021 10:56:04 +0000 (12:56 +0200)] 
core/service: modernization

4 years agotest-bpf-foreign-programs: fix message
Zbigniew Jędrzejewski-Szmek [Mon, 10 May 2021 10:54:52 +0000 (12:54 +0200)] 
test-bpf-foreign-programs: fix message

4 years agodocs/HACKING: wrap long lines
Zbigniew Jędrzejewski-Szmek [Mon, 10 May 2021 06:35:21 +0000 (08:35 +0200)] 
docs/HACKING: wrap long lines

4 years agosd-event: tweak comments
Zbigniew Jędrzejewski-Szmek [Sat, 8 May 2021 09:40:47 +0000 (11:40 +0200)] 
sd-event: tweak comments

4 years agotimedated: make ntp_synced() static
Zbigniew Jędrzejewski-Szmek [Wed, 12 May 2021 07:39:28 +0000 (09:39 +0200)] 
timedated: make ntp_synced() static

No need to have this in basic.

4 years agoMerge pull request #18986 from poettering/oomd-varlink-fix
Zbigniew Jędrzejewski-Szmek [Wed, 12 May 2021 09:36:32 +0000 (11:36 +0200)] 
Merge pull request #18986 from poettering/oomd-varlink-fix

varlink ref fix

4 years agoMerge pull request #19506 from xnox/ship-stub-elf
Zbigniew Jędrzejewski-Szmek [Wed, 12 May 2021 07:45:36 +0000 (09:45 +0200)] 
Merge pull request #19506 from xnox/ship-stub-elf

boot/efi: install ELF linux.elf.stub in addition to PE linux.efi.stub

4 years agoMerge pull request #19581 from yuwata/specifier-refuse-too-long-results
Lennart Poettering [Wed, 12 May 2021 07:42:08 +0000 (09:42 +0200)] 
Merge pull request #19581 from yuwata/specifier-refuse-too-long-results

specifier: refuse too long results

4 years agonetlink,network: drop "const" from opaque object parameters in supposed-to-be-public...
Lennart Poettering [Tue, 11 May 2021 15:08:00 +0000 (17:08 +0200)] 
netlink,network: drop "const" from opaque object parameters in supposed-to-be-public APIs

This drops the "const" specifier from the opaque object parameters to
various functions in our API.

This effectively reverts #19292 and more.

Why drop this? Our public APIs should not leak too much information
about how stuff is implemented internally. In our public APIs we
shouldn't give too many guarantees we don#t want to necessarily keep.
Specifically: in many cases it makes sense that getters actually
generate/parse/allocate data on the fly, storing/caching the result
internally, to speed things up, do things lazily or to track memory
allocations so that they can be freed later. Doing this means we need to
change the objects, even though the getters are semantically a read
operation.

We want to retain the freedom that we can change things around
internally. By exposing the objects as "const" we remove a good chunk of
that, for little gain.

See sd_bus_creds_get_description() for a real example of a getter that
implicitly caches and thus modifies the relevant object.

This removes the "const" decorators from sd-dhcp and sd-netlink, two
APIs that we intend to make public eventually even though they still are
not, leaving us the chance to still fix this before it becomes set in
stone.

4 years agotest-network: wait for the interfaces are configured after reloading .network files 19533/head
Yu Watanabe [Wed, 5 May 2021 14:05:02 +0000 (23:05 +0900)] 
test-network: wait for the interfaces are configured after reloading .network files

4 years agotest-network: wait for the intreface is configured if it is expected
Yu Watanabe [Wed, 5 May 2021 14:04:24 +0000 (23:04 +0900)] 
test-network: wait for the intreface is configured if it is expected

4 years agonetwork: make route_configure() return all created routes
Yu Watanabe [Thu, 29 Apr 2021 14:18:29 +0000 (23:18 +0900)] 
network: make route_configure() return all created routes

4 years agonetwork: make log_route_debug() show multipath routes and Gateway=_dhcp4 or _ipv6ra
Yu Watanabe [Thu, 29 Apr 2021 14:30:51 +0000 (23:30 +0900)] 
network: make log_route_debug() show multipath routes and Gateway=_dhcp4 or _ipv6ra

4 years agonetwork: use request queue to configure addresses, routes, and nexthops
Yu Watanabe [Wed, 5 May 2021 13:46:44 +0000 (22:46 +0900)] 
network: use request queue to configure addresses, routes, and nexthops

Why is this necessary? Several examples below.

- When a route sets prefsrc, then the address must be already assigned
  (see issue #19285), and also it must be ready if IPv6.
- When a route or nexthop sets gateway, then the address must be reachable.
- When a route sets nexthop ID, then the corresponding nexthop must be
  assigned.
- When a route sets multipath routes on another interface, then the
  interface must exist and be ready to configure.
- When configuring address, the same address must not be under removing
  (see issue #18108).
Etc,. etc,...

So, this makes all requests about addresses, routes, and nethops are once
stored in the queue, and will be processed when they are ready to configure.

Fixes #18108 and #19285.

4 years agonetwork: use request queue to configure neighbors
Yu Watanabe [Fri, 7 May 2021 07:05:31 +0000 (16:05 +0900)] 
network: use request queue to configure neighbors

4 years agonetwork: use request queue to configure routing policy rules
Yu Watanabe [Fri, 7 May 2021 06:57:13 +0000 (15:57 +0900)] 
network: use request queue to configure routing policy rules

4 years agonetwork: introduce link_is_ready_to_configure() helper function
Yu Watanabe [Fri, 7 May 2021 06:45:28 +0000 (15:45 +0900)] 
network: introduce link_is_ready_to_configure() helper function

This will be used in later commits.

4 years agonetwork: add skeleton of request queue
Yu Watanabe [Fri, 7 May 2021 06:39:16 +0000 (15:39 +0900)] 
network: add skeleton of request queue

This will be used in later commits.

4 years agonetwork: nexthop: add NextHop object before sending netlink request
Yu Watanabe [Fri, 7 May 2021 11:52:49 +0000 (20:52 +0900)] 
network: nexthop: add NextHop object before sending netlink request

Otherwise, if nexthop_add() fails, then assertion about nexthop_messages in
static_nexthop_handler() will be triggered.

4 years agonetwork: split out common part of route or address handlers
Yu Watanabe [Fri, 7 May 2021 08:32:51 +0000 (17:32 +0900)] 
network: split out common part of route or address handlers

4 years agonetwork: change order of dropping network configs
Yu Watanabe [Fri, 7 May 2021 07:35:42 +0000 (16:35 +0900)] 
network: change order of dropping network configs

As routes may requires nexthops and addresses, nexthops may requires
addresses.

4 years agonetwork: simplify and rename routing_policy_rule_copy()
Yu Watanabe [Thu, 6 May 2021 20:16:32 +0000 (05:16 +0900)] 
network: simplify and rename routing_policy_rule_copy()

4 years agonetwork: introduce route_dup()
Yu Watanabe [Thu, 6 May 2021 19:47:26 +0000 (04:47 +0900)] 
network: introduce route_dup()

The function will be used in later commits.

4 years agosd-netlink: introduce multipath_route_dup()
Yu Watanabe [Thu, 6 May 2021 19:45:02 +0000 (04:45 +0900)] 
sd-netlink: introduce multipath_route_dup()

The function will be used in later commits.

4 years agonetwork: introduce manager_address_is_reachable()
Yu Watanabe [Thu, 6 May 2021 19:37:58 +0000 (04:37 +0900)] 
network: introduce manager_address_is_reachable()

The function will be used in later commits.

4 years agonetwork: introduce link_has_route()
Yu Watanabe [Thu, 6 May 2021 19:31:20 +0000 (04:31 +0900)] 
network: introduce link_has_route()

The function will be used in later commits.

4 years agonetwork: delay resolving interface specifier in MultiPathRoute=
Yu Watanabe [Thu, 6 May 2021 19:29:52 +0000 (04:29 +0900)] 
network: delay resolving interface specifier in MultiPathRoute=

The interface may not exist when .network files are loaded.

4 years agonetwork: introduce manager_has_address()
Yu Watanabe [Thu, 6 May 2021 19:03:21 +0000 (04:03 +0900)] 
network: introduce manager_has_address()

The function will be used in later commits.

4 years agoordered-set: introduce ordered_set_clear/free_with_destructor()
Yu Watanabe [Mon, 26 Apr 2021 14:52:40 +0000 (23:52 +0900)] 
ordered-set: introduce ordered_set_clear/free_with_destructor()

4 years agohashmap,set: make hashmap_clear_with_destructor() or friends safer
Yu Watanabe [Sat, 8 May 2021 06:32:52 +0000 (15:32 +0900)] 
hashmap,set: make hashmap_clear_with_destructor() or friends safer

4 years agonetwork: use IPV4_ADDRESS_FMT_STR/VAL macros and in6_addr_to_string() or friends
Yu Watanabe [Thu, 6 May 2021 08:15:01 +0000 (17:15 +0900)] 
network: use IPV4_ADDRESS_FMT_STR/VAL macros and in6_addr_to_string() or friends

4 years agoin-addr-util: move IPV4_ADDRESS_FMT_STR/VAL macros from networkd-address.h
Yu Watanabe [Thu, 6 May 2021 07:21:18 +0000 (16:21 +0900)] 
in-addr-util: move IPV4_ADDRESS_FMT_STR/VAL macros from networkd-address.h

4 years agoin-addr-util: introduce in6_addr_to_string() or friends
Yu Watanabe [Thu, 6 May 2021 07:17:47 +0000 (16:17 +0900)] 
in-addr-util: introduce in6_addr_to_string() or friends

4 years agonetwork: use in6_addr_is_link_local() or friends
Yu Watanabe [Thu, 6 May 2021 07:11:33 +0000 (16:11 +0900)] 
network: use in6_addr_is_link_local() or friends

4 years agonetwork: rename routing_policy_rule_configure_internal() and make it take callback
Yu Watanabe [Mon, 26 Apr 2021 07:10:39 +0000 (16:10 +0900)] 
network: rename routing_policy_rule_configure_internal() and make it take callback

4 years agonetwork: make nexthop_configure() take callback
Yu Watanabe [Mon, 26 Apr 2021 07:05:04 +0000 (16:05 +0900)] 
network: make nexthop_configure() take callback

4 years agonetwork: make neighbor_configure() take callback
Yu Watanabe [Mon, 26 Apr 2021 07:04:07 +0000 (16:04 +0900)] 
network: make neighbor_configure() take callback

4 years agotree-wide: refuse too long strings earlier in specifier_printf() 19581/head
Yu Watanabe [Sun, 9 May 2021 16:46:48 +0000 (01:46 +0900)] 
tree-wide: refuse too long strings earlier in specifier_printf()

We usually call specifier_printf() and then check the validity of
the result. In many cases, validity checkers, e.g. path_is_valid(),
refuse too long strings. This makes specifier_printf() refuse such
long results earlier.

Moreover, unit_full_string() and description field in sysuser now
refuse results longer than LONG_LINE_MAX. config_parse() already
refuses the line longer than LONG_LINE_MAX. Hence, it should be ok
to set the same value as the maximum length of the resolved string.

4 years agodns-domain: use DNS_LABEL_MAX at one more place
Yu Watanabe [Wed, 12 May 2021 01:12:18 +0000 (10:12 +0900)] 
dns-domain: use DNS_LABEL_MAX at one more place

4 years agocreds-util: introduce CREDENTIAL_NAME_MAX
Yu Watanabe [Wed, 12 May 2021 01:20:47 +0000 (10:20 +0900)] 
creds-util: introduce CREDENTIAL_NAME_MAX

4 years agofd-util: introduce FDNAME_MAX
Yu Watanabe [Wed, 12 May 2021 01:19:19 +0000 (10:19 +0900)] 
fd-util: introduce FDNAME_MAX

4 years agogpt: introduce GPT_LAVEL_MAX
Yu Watanabe [Wed, 12 May 2021 01:16:36 +0000 (10:16 +0900)] 
gpt: introduce GPT_LAVEL_MAX

4 years agotest: move test_specifier_printf() to test-specifier.c
Yu Watanabe [Sun, 9 May 2021 15:13:14 +0000 (00:13 +0900)] 
test: move test_specifier_printf() to test-specifier.c

4 years agospecifier: rename variable
Yu Watanabe [Sun, 9 May 2021 12:39:34 +0000 (21:39 +0900)] 
specifier: rename variable

4 years agospecifier: use SD_ID128_STRING_MAX
Yu Watanabe [Sun, 9 May 2021 12:23:32 +0000 (21:23 +0900)] 
specifier: use SD_ID128_STRING_MAX

4 years agocore: don't accidentally unref a varlink connection twice 18986/head
Lennart Poettering [Fri, 12 Mar 2021 21:21:58 +0000 (22:21 +0100)] 
core: don't accidentally unref a varlink connection twice

Let's make sure that our close handler unrefs a connection again that we
are already unreffing a few stack frames up by invalidating the pointer
first, and dropping the ref counter only after that.

Replaces: 39ad3f1c092b5dffcbb4b1d12eb9ca407f010a3c

Fixes: #18025
4 years agoRevert "varlink: avoid using dangling ref in varlink_close_unref()"
Lennart Poettering [Fri, 12 Mar 2021 21:21:40 +0000 (22:21 +0100)] 
Revert "varlink: avoid using dangling ref in varlink_close_unref()"

This reverts commit 39ad3f1c092b5dffcbb4b1d12eb9ca407f010a3c.

4 years agocgroup: drop explicit NULL comparisons 19567/head
Lennart Poettering [Mon, 10 May 2021 15:47:32 +0000 (17:47 +0200)] 
cgroup: drop explicit NULL comparisons

4 years agotree-wide: move variables to innermost scope
Lennart Poettering [Mon, 10 May 2021 15:47:19 +0000 (17:47 +0200)] 
tree-wide: move variables to innermost scope

4 years agotree-wide: use af_to_ipv4_ipv6() + af_from_ipv4_ipv6() helpers at various places
Lennart Poettering [Mon, 10 May 2021 15:24:48 +0000 (17:24 +0200)] 
tree-wide: use af_to_ipv4_ipv6() + af_from_ipv4_ipv6() helpers at various places

4 years agoaf-list: add helpers mapping AF_INET/AF_INET6 to "ipv4"/"ipv6"
Lennart Poettering [Mon, 10 May 2021 15:14:13 +0000 (17:14 +0200)] 
af-list: add helpers mapping AF_INET/AF_INET6 to "ipv4"/"ipv6"

4 years agosocket-bind: use lowercase "ipv4"/"ipv6" spelling
Lennart Poettering [Mon, 10 May 2021 14:33:24 +0000 (16:33 +0200)] 
socket-bind: use lowercase "ipv4"/"ipv6" spelling

In most of our codebase when we referenced "ipv4" and "ipv6" on the
right-hand-side of an assignment, we lowercases it (on the
left-hand-side we used CamelCase, and thus "IPv4" and "IPv6"). In
particular all across the networkd codebase the various "per-protocol
booleans" use the lower-case spelling. Hence, let's use lower-case for
SocketBindAllow=/SocketBindDeny= too, just make sure things feel like
they belong together better.

(This work is not included in any released version, hence let's fix this
now, before any fixes in this area would be API breakage)

Follow-up for #17655

4 years agobootctl: same entry path check case-insensitive
zsien [Mon, 10 May 2021 07:42:54 +0000 (15:42 +0800)] 
bootctl: same entry path check case-insensitive

Some motherboards convert the path to uppercase under certain circumstances
(e.g. after booting into the Boot Menu in the ASUS ROG STRIX B350-F GAMING).

4 years agohwdb: keyboard: D330 Touchpad toggle keymap
howl [Mon, 10 May 2021 22:24:11 +0000 (00:24 +0200)] 
hwdb: keyboard: D330 Touchpad toggle keymap

I have also seen that VIOS LTH17 has the exact same correction and it's also a SIPODEV composite hid device also through usb. In the D330 is a detachable keyboard. It's possible that a very generic way to apply this to at least affected sipodev keyboard could be found using the device ids, but needs info to do that and ensure all sipodev keyboard with the pertinent ids need it.

Signed-off-by: David Santamaría Rogado <howl.nsp@gmail.com>
4 years agohwdb: sensor: D330-IGM use pvr instead cvr
howl [Mon, 10 May 2021 22:31:28 +0000 (00:31 +0200)] 
hwdb: sensor: D330-IGM use pvr instead cvr

We use pvr match for efifb pitch and drm orientation quirk and in touchpad toggle keymap. Also seems most consistent with the devices here.

While at it, correct a typo, 81H3 and 81MD are product names not numbers, my bad.

Signed-off-by: David Santamaría Rogado <howl.nsp@gmail.com>
4 years agoMerge pull request #19562 from keszybz/flag-manips
Yu Watanabe [Tue, 11 May 2021 05:34:07 +0000 (14:34 +0900)] 
Merge pull request #19562 from keszybz/flag-manips

Fix flag manipulations in cryptsetup

4 years agounit-def: ensure UnitType enum fits any errno value
Lennart Poettering [Mon, 10 May 2021 16:43:07 +0000 (18:43 +0200)] 
unit-def: ensure UnitType enum fits any errno value

This is a follow-up for #19514 which changed unit_name_to_instance() to
return ENOMEM as a UnitType enum, even though the enum didn't
necessarily have range for that.

Let's extend the range explicitly, so that we can cover the full errno
range in it.

4 years agobootctl: extend --make-machine-id-directory= documentation a bit
Lennart Poettering [Mon, 10 May 2021 17:03:49 +0000 (19:03 +0200)] 
bootctl: extend --make-machine-id-directory= documentation a bit

The directory might not be created in the ESP but in the extended boot
loader partition, hence don#t claim otherwise.

Also, give a brief reason why the concept exists at all.

Link up machine-id man page.

Follow-up for: 6a3fff75baad94d9ebff1a6c7d1fb35448c44a81

4 years agotest-user-util: fix line break confusion
Lennart Poettering [Mon, 10 May 2021 17:19:02 +0000 (19:19 +0200)] 
test-user-util: fix line break confusion

This fixes some line-break confusion introduced by #11199
(c6cecb744b53561efd329309af7d02a3f9979ed1). It also restores a test with
GID_INVALID that was dropped, presumably by accident.

4 years agoMerge pull request #19575 from poettering/hwdb-whitespace-fix-again
Yu Watanabe [Tue, 11 May 2021 05:31:35 +0000 (14:31 +0900)] 
Merge pull request #19575 from poettering/hwdb-whitespace-fix-again

hwdb: remove trailing whitespace

4 years agoman: remove some trailing whitespace 19575/head
Lennart Poettering [Mon, 10 May 2021 21:08:58 +0000 (23:08 +0200)] 
man: remove some trailing whitespace

4 years agohwdb: remove trailing whitespace
Lennart Poettering [Mon, 10 May 2021 21:03:52 +0000 (23:03 +0200)] 
hwdb: remove trailing whitespace

4 years agohwdb: add accel matrix for One-netbook OneMix 3s (#19549)
gitm0 [Mon, 10 May 2021 20:20:58 +0000 (16:20 -0400)] 
hwdb: add accel matrix for One-netbook OneMix 3s (#19549)

4 years agoMerge pull request #19570 from poettering/userdb-followup-fixlets
Lennart Poettering [Mon, 10 May 2021 20:06:32 +0000 (22:06 +0200)] 
Merge pull request #19570 from poettering/userdb-followup-fixlets

two minor userdb fixes

4 years agoMerge pull request #19568 from poettering/userdbctl-dropin
Lennart Poettering [Mon, 10 May 2021 20:06:07 +0000 (22:06 +0200)] 
Merge pull request #19568 from poettering/userdbctl-dropin

userdbctl: add new --with-varlink= and --with-drop-in= flags

4 years agotest-efi-create-disk: support /boot/efi 19506/head
Zbigniew Jędrzejewski-Szmek [Mon, 10 May 2021 18:35:31 +0000 (20:35 +0200)] 
test-efi-create-disk: support /boot/efi

Most of our tools allow EFI mount to be on /boot/efi. Do the same here.

4 years agotest-efi-create-disk: shellcheckify
Zbigniew Jędrzejewski-Szmek [Mon, 10 May 2021 18:29:08 +0000 (20:29 +0200)] 
test-efi-create-disk: shellcheckify

4 years agomeson: rework test-efi-disk.img creation to not require variables
Zbigniew Jędrzejewski-Szmek [Mon, 10 May 2021 18:28:14 +0000 (20:28 +0200)] 
meson: rework test-efi-disk.img creation to not require variables

The primary goal is to make the name of the custom_target() rule match
the output file again. Having them different is confusing.

4 years agocryptsetup: fix flags check 19562/head
Zbigniew Jędrzejewski-Szmek [Mon, 10 May 2021 13:04:10 +0000 (15:04 +0200)] 
cryptsetup: fix flags check

FLAGS_SET() checks if *all* the bits are set. In this case we want to check
if *any* are. FLAGS_SET() was added in cde2f8605e0c3842f9a87785dd758f955f2d04ba,
but not a bug then yet, because with just one bit, both options are equivalent.
But when more bits were added later, this stopped being correct.

4 years agocryptsetup: initialize variable
Zbigniew Jędrzejewski-Szmek [Mon, 10 May 2021 13:02:34 +0000 (15:02 +0200)] 
cryptsetup: initialize variable

Fixup for cde2f8605e0c3842f9a87785dd758f955f2d04ba. Use PIN+PV because the
status quo ante was that we turned off "uv" and left "up" and "clientPin" in
its default values, which with yubikeys (i.e. the most popular hardware) meant
both "up" and "clientPin" were enabled by default.

Coverity CID#1453085.

4 years agouserdb: initialize .synthesize_root/.synthesize_nobody in generic code 19570/head
Lennart Poettering [Wed, 5 May 2021 20:27:37 +0000 (22:27 +0200)] 
userdb: initialize .synthesize_root/.synthesize_nobody in generic code

Let's initialize this at the same place for any iterator allocated. (Yes
not all types of iterator objects need this, but it's still nice to
share this trivial code at one place).

4 years agouserdb: return ESRCH if we didn't find a single varlink service
Lennart Poettering [Wed, 5 May 2021 20:06:34 +0000 (22:06 +0200)] 
userdb: return ESRCH if we didn't find a single varlink service

Clearly communicate to callers that we didn't find a single varlink
service, when a lookup is attempted. Note that the fallback's to NSS,
drop-ins and synthesis might eat up this error again, but we should
really make this case reasonably recognizable, in particular as our
various tools already handle this condition correctly and print a nice
message then.

4 years agoman: document new userdbctl features 19568/head
Lennart Poettering [Fri, 7 May 2021 10:18:07 +0000 (12:18 +0200)] 
man: document new userdbctl features

4 years agouserdbctl: add two new switches --with-dropin=/--with-varlink=
Lennart Poettering [Thu, 6 May 2021 14:38:38 +0000 (16:38 +0200)] 
userdbctl: add two new switches --with-dropin=/--with-varlink=

These directly correspond to the underlying flags. They are useful for
testing.

4 years agoMerge pull request #19548 from poettering/userdb-dropin
Lennart Poettering [Mon, 10 May 2021 15:53:45 +0000 (17:53 +0200)] 
Merge pull request #19548 from poettering/userdb-dropin

userdb: add support for loading user/group records from JSON drop-ins

4 years agodocs: link info about static user/group drop-in files from the relevant specs 19548/head
Lennart Poettering [Mon, 10 May 2021 12:57:18 +0000 (14:57 +0200)] 
docs: link info about static user/group drop-in files from the relevant specs

4 years agoman: document new userdbd features
Lennart Poettering [Fri, 7 May 2021 10:17:57 +0000 (12:17 +0200)] 
man: document new userdbd features

4 years agoman: update nss-systemd documentation with new features
Lennart Poettering [Fri, 7 May 2021 10:16:49 +0000 (12:16 +0200)] 
man: update nss-systemd documentation with new features

4 years agouserdbd: also listen on a varlink socket io.systemd.DropIn
Lennart Poettering [Thu, 6 May 2021 14:38:28 +0000 (16:38 +0200)] 
userdbd: also listen on a varlink socket io.systemd.DropIn

Let's explicitly support looking things up via dropin as a varlink
service.

4 years agouserdb: optionally read user/group/membership "dropins", too
Lennart Poettering [Fri, 30 Apr 2021 21:10:59 +0000 (23:10 +0200)] 
userdb: optionally read user/group/membership "dropins", too