diff --git a/hwdb.d/60-input-id.hwdb b/hwdb.d/60-input-id.hwdb index 802ed9a1e70..1c84777fe07 100644 --- a/hwdb.d/60-input-id.hwdb +++ b/hwdb.d/60-input-id.hwdb @@ -75,3 +75,7 @@ id-input:modalias:input:b0003v046Dp4066e0111* id-input:modalias:input:b0003v068Ep00F2e0100* ID_INPUT_ACCELEROMETER=0 ID_INPUT_JOYSTICK=1 + +# TEX Shinobi Trackpoint +id-input:modalias:input:b0003v04D9p0407e0111-e0,1,2,4* + ID_INPUT_POINTINGSTICK=1 diff --git a/hwdb.d/60-keyboard.hwdb b/hwdb.d/60-keyboard.hwdb index 87d592d2cd5..32252c6a109 100644 --- a/hwdb.d/60-keyboard.hwdb +++ b/hwdb.d/60-keyboard.hwdb @@ -173,6 +173,10 @@ evdev:atkbd:dmi:*:svnPackardBell:pndots:*:rvnPackardBell:rnSJE01_CT:* KEYBOARD_KEY_ce=unknown # Brightness Up, also emitted by acpi-video, ignore KEYBOARD_KEY_ef=unknown # Brightness Down, also emitted by acpi-video, ignore +# Predator PT314-52s +evdev:atkbd:dmi:bvn*:bvr*:bd*:svnAcer*:pnPredator*PT314-52s:pvr* + KEYBOARD_KEY_66=micmute # Microphone mute button + # Predator PH 315-52 evdev:atkbd:dmi:bvn*:bvr*:bd*:svnAcer*:pnPredator*PH*315-52:* KEYBOARD_KEY_ef=kbdillumup # Fn+F10 @@ -605,6 +609,11 @@ evdev:atkbd:dmi:bvn*:bvr*:bd*:svnHewlett-Packard*:pn*[pP][aA][vV][iI][lL][iI][oO KEYBOARD_KEY_d9=unknown KEYBOARD_KEY_d2=sysrq # Fn+Print = SYSRQ +# Pavilion gaming 15-dk1* (lid keys) +evdev:atkbd:dmi:bvn*:bvr*:bd*:br*:efr*:svnHP:pnHPPavilionGamingLaptop15-dk1*:* + KEYBOARD_KEY_d7=unknown + KEYBOARD_KEY_d8=unknown + # Spectre x360 13 (Prevents random airplane mode activation) evdev:atkbd:dmi:bvn*:bvr*:bd*:svnHewlett-Packard*:pn*[sS][pP][eE][cC][tT][rR][eE]*x360*13*:* evdev:atkbd:dmi:bvn*:bvr*:bd*:svnHP*:pn*[sS][pP][eE][cC][tT][rR][eE]*x360Convertible*:* @@ -1050,6 +1059,9 @@ evdev:input:b0003v04B3p301B* evdev:name:SIPODEV Lenovo HID Device:dmi:*:svnLENOVO:*:pvrLenovoideapadD330-10IGM:* KEYBOARD_KEY_70073=f21 # Fn+Supr (Touchpad toggle) +evdev:name:SIPODEV Lenovo HID Device Consumer Control:dmi:*:svnLENOVO:*:pvrLenovoideapadD330-10IGM:* + KEYBOARD_KEY_c00ff=fn_esc # Fn+Tab (FnLk toggle) + ########################################################### # LG ########################################################### diff --git a/hwdb.d/60-sensor.hwdb b/hwdb.d/60-sensor.hwdb index 4fb7387f60a..e78c7952412 100644 --- a/hwdb.d/60-sensor.hwdb +++ b/hwdb.d/60-sensor.hwdb @@ -209,6 +209,14 @@ sensor:modalias:acpi:KIOX010A:*:dmi:*:svnAMI:*:skuH2M6:* ACCEL_MOUNT_MATRIX=-1, 0, 0; 0, -1, 0; 0, 0, -1 ACCEL_LOCATION=display +######################################### +# BUSH +######################################### + +# Bush Windows tablet +sensor:modalias:acpi:KIOX000A*:dmi:*:svnBUSH*:pnBushWindowstablet:* + ACCEL_MOUNT_MATRIX=1, 0, 0; 0, -1, 0; 1, 0, 0 + ######################################### # Chuwi ######################################### @@ -395,6 +403,7 @@ sensor:modalias:acpi:KIOX000A*:dmi:bvnAmericanMegatrendsInternational,LLC.:bvrJP # T11 / Juno Tablet 2 sensor:modalias:acpi:NSA2513*:dmi:*:svnDigitek:* +sensor:modalias:acpi:NSA2513*:dmi:*:svnDefaultstring:* ACCEL_MOUNT_MATRIX=0, -1, 0; 1, 0, 0; 0, 0, 1 ######################################### @@ -925,6 +934,12 @@ sensor:modalias:acpi:SMO8500*:dmi:*:svnProwise:pnPT301:* sensor:modalias:acpi:SMO8500*:dmi:*:rvnReeder:rnA8iW-Rev.A:* ACCEL_MOUNT_MATRIX=1, 0, 0; 0, -1, 0; 0, 0, 1 +######################################### +# RCA +######################################### +sensor:modalias:acpi:KIOX000A*:dmi:*:svnRCA:pnW101SA23T1:* + ACCEL_MOUNT_MATRIX=0, -1, 0; -1, 0, 0; 0, 0, 1 + ######################################### # Schneider ######################################### @@ -953,6 +968,10 @@ sensor:modalias:acpi:KIOX020A*:dmi:*:svnTECLAST:pnF6Pro:* sensor:modalias:acpi:KIOX000A*:dmi:*:svnTECLAST:pnTbooK11:* ACCEL_MOUNT_MATRIX=1, 0, 0; 0, -1, 0; 0, 0, 1 +# Teclast X3 Plus (G4K3) +sensor:modalias:acpi:KIOX000A*:dmi:*svnTECLAST:pnX3Plus:*:skuG4K3_A1:* + ACCEL_MOUNT_MATRIX=1, 0, 0; 0, -1, 0; 0, 0, 1 + # Teclast X4 2-in-1 (G4M6) sensor:modalias:acpi:KIOX000A*:dmi:*:svnTECLAST:pnX4:* ACCEL_MOUNT_MATRIX=0, 1, 0; 1, 0, 0; 0, 0, 1 diff --git a/hwdb.d/70-mouse.hwdb b/hwdb.d/70-mouse.hwdb index 46d723a92e5..7d1370ea9be 100644 --- a/hwdb.d/70-mouse.hwdb +++ b/hwdb.d/70-mouse.hwdb @@ -397,9 +397,13 @@ mouse:usb:v046dpc08b:name:Logitech G502 HERO SE:* mouse:usb:v046dpc08b:name:Logitech G502 HERO Gaming Mouse:* MOUSE_DPI=1200@1000 *2400@1000 3200@1000 6400@1000 -# Logitech G502 X (Wired) +# Logitech G502 X +mouse:usb:v046dpc099:name:Logitech G502 X:* + MOUSE_DPI=800@1000 1200@1000 *1600@1000 2400@1000 3200@1000 + +# Logitech G502 X LIGHTSPEED (Wired) mouse:usb:v046dpc098:name:Logitech, Inc. G502 X LIGHTSPEED:* -# Logitech G502 X (Wireless) +# Logitech G502 X LIGHTSPEED (Wireless) # The USB receiver is also used by other mice. See #27118. # If you want to enable the entry, please copy below to your custom hwdb file. #mouse:usb:v046dpc547:name:Logitech USB Receiver:* diff --git a/hwdb.d/80-ieee1394-unit-function.hwdb b/hwdb.d/80-ieee1394-unit-function.hwdb index cf55f5524c3..e49e78f2188 100644 --- a/hwdb.d/80-ieee1394-unit-function.hwdb +++ b/hwdb.d/80-ieee1394-unit-function.hwdb @@ -629,6 +629,16 @@ ieee1394:ven0000022Emo00800007sp0000A02Dver00010001 IEEE1394_UNIT_FUNCTION_AUDIO=1 IEEE1394_UNIT_FUNCTION_VIDEO=0 +# Please take an extra care since the vendor ID (0x0030E0) is for Oxford Semiconductor Ltd. and the +# model ID (0x00f970) is commonly in the other OXFW970 models. +ieee1394:node:ven0x0030e0mo0x00f970units0x00a02d:0x010001 +ieee1394:ven000030E0mo0000F970sp0000A02Dver00010001 + ID_VENDOR_FROM_DATABASE=Miglia Technology + ID_MODEL_FROM_DATABASE=Harmony Audio + IEEE1394_UNIT_FUNCTION_MIDI=0 + IEEE1394_UNIT_FUNCTION_AUDIO=1 + IEEE1394_UNIT_FUNCTION_VIDEO=0 + # # TC Applied Technologies. Digital Interface Communication Engine (DICE). # @@ -903,7 +913,7 @@ ieee1394:ven00001C6Amo00000002sp00001C6Aver00000001 ieee1394:node:ven0x001c6amo0x000003units0x001c6a:0x000001 ieee1394:ven00001C6Amo00000003sp00001C6Aver00000001 ID_VENDOR_FROM_DATABASE=Weiss Engineering - ID_MODEL_FROM_DATABASE=Minerva + ID_MODEL_FROM_DATABASE=DAC2/Minerva IEEE1394_UNIT_FUNCTION_AUDIO=1 ieee1394:node:ven0x001c6amo0x000004units0x001c6a:0x000001 @@ -912,16 +922,14 @@ ieee1394:ven00001C6Amo00000004sp00001C6Aver00000001 ID_MODEL_FROM_DATABASE=AFI1 IEEE1394_UNIT_FUNCTION_AUDIO=1 -ieee1394:node:ven0x001c6amo0x000005units0x001c6a:0x000001 -ieee1394:ven00001C6Amo00000005sp00001C6Aver00000001 - ID_VENDOR_FROM_DATABASE=Weiss Engineering - ID_MODEL_FROM_DATABASE=DAC1 - IEEE1394_UNIT_FUNCTION_AUDIO=1 - +# Starting from the middle of life time of INT203, the same firmware as +# INT202 is compatible. The firmware dynamically switches its functionality +# based on the state of internal jumper pins. Additionally, the design of +# FireWire option card for DAC1 is something like embedded-INT203. ieee1394:node:ven0x001c6amo0x000006units0x001c6a:0x000001 ieee1394:ven00001C6Amo00000006sp00001C6Aver00000001 ID_VENDOR_FROM_DATABASE=Weiss Engineering - ID_MODEL_FROM_DATABASE=INT202 + ID_MODEL_FROM_DATABASE=INT202/INT203/DAC1 IEEE1394_UNIT_FUNCTION_AUDIO=1 ieee1394:node:ven0x001c6amo0x000007units0x001c6a:0x000001 @@ -930,6 +938,20 @@ ieee1394:ven00001C6Amo00000007sp00001C6Aver00000001 ID_MODEL_FROM_DATABASE=DAC202 IEEE1394_UNIT_FUNCTION_AUDIO=1 +ieee1394:node:ven0x001c6amo0x000008units0x001c6a:0x000001 +ieee1394:ven00001C6Amo00000008sp00001C6Aver00000001 + ID_VENDOR_FROM_DATABASE=Weiss Engineering + ID_MODEL_FROM_DATABASE=DAC202/Maya + IEEE1394_UNIT_FUNCTION_AUDIO=1 + +# The older version of firmware for INT203. Additionally, the design of +# FireWire option card for DAC1 is something like embedded-INT203. +ieee1394:node:ven0x001c6amo0x00000aunits0x001c6a:0x000001 +ieee1394:ven00001C6Amo0000000Asp00001C6Aver00000001 + ID_VENDOR_FROM_DATABASE=Weiss Engineering + ID_MODEL_FROM_DATABASE=INT203/DAC1 + IEEE1394_UNIT_FUNCTION_AUDIO=1 + # # Digidesign Digi00x family. # @@ -1387,3 +1409,19 @@ ieee1394:ven000001F2mo*sp000001F2ver00000024 ID_VENDOR_FROM_DATABASE=MOTU ID_MODEL_FROM_DATABASE=MOTU V4HD IEEE1394_UNIT_FUNCTION_VIDEO=1 + +# Weiss Engineering MAN301 (DICE application): unit 0: AV/C devices 1.0. +ieee1394:node:ven0x001c6amo0x00000bunits*0x00a02d:0x010001* +ieee1394:ven00001C6Amo0000000Bsp0000A02Dver00010001 + ID_VENDOR_FROM_DATABASE=Weiss Engineering Ltd. + ID_MODEL_FROM_DATABASE=MAN301 + IEEE1394_UNIT_FUNCTION_AUDIO=1 + IEEE1394_UNIT_FUNCTION_VIDEO=0 + +# Weiss Engineering MAN301 (DICE application): unit 1: TCAT general protocol. +ieee1394:node:ven0x001c6amo0x00000bunits*0x001c6a:0x000001* +ieee1394:ven00001C6Amo0000000Bsp00001C6Aver00000001 + ID_VENDOR_FROM_DATABASE=Weiss Engineering Ltd. + ID_MODEL_FROM_DATABASE=MAN301 + IEEE1394_UNIT_FUNCTION_AUDIO=1 + IEEE1394_UNIT_FUNCTION_VIDEO=0 diff --git a/man/kernel-command-line.xml b/man/kernel-command-line.xml index 368783d6fee..2e60beb98bf 100644 --- a/man/kernel-command-line.xml +++ b/man/kernel-command-line.xml @@ -54,7 +54,6 @@ systemd.unit= rd.systemd.unit= systemd.dump_core - systemd.early_core_pattern= systemd.crash_chvt systemd.crash_shell systemd.crash_reboot diff --git a/man/sd_bus_error_add_map.xml b/man/sd_bus_error_add_map.xml index a49b554459a..7c914b00531 100644 --- a/man/sd_bus_error_add_map.xml +++ b/man/sd_bus_error_add_map.xml @@ -35,20 +35,15 @@ … } sd_bus_error_map; - + SD_BUS_ERROR_MAP(name, code) - - SD_BUS_ERROR_MAP(name, code) - - - SD_BUS_ERROR_MAP_END - + SD_BUS_ERROR_MAP_END int sd_bus_error_add_map const sd_bus_error_map *map - + diff --git a/src/core/main.c b/src/core/main.c index a84fafa97b8..c3b1a3539dd 100644 --- a/src/core/main.c +++ b/src/core/main.c @@ -2086,7 +2086,7 @@ static void log_execution_mode(bool *ret_first_boot) { r = read_one_line_file("/etc/machine-id", &id_text); if (r < 0 || streq(id_text, "uninitialized")) { if (r < 0 && r != -ENOENT) - log_warning_errno(r, "Unexpected error while reading /etc/machine-id, ignoring: %m"); + log_warning_errno(r, "Unexpected error while reading /etc/machine-id, assuming first boot: %m"); first_boot = true; log_info("Detected first boot."); diff --git a/src/journal/journald-server.c b/src/journal/journald-server.c index 6faf48db29c..4c5eadc8713 100644 --- a/src/journal/journald-server.c +++ b/src/journal/journald-server.c @@ -372,8 +372,17 @@ static int system_journal_open(Server *s, bool flush_requested, bool relinquish_ fn = strjoina(s->runtime_storage.path, "/system.journal"); - if (s->system_journal && !relinquish_requested) { + if (!s->system_journal || relinquish_requested) { + /* OK, we really need the runtime journal, so create it if necessary. */ + + (void) mkdir_parents(s->runtime_storage.path, 0755); + (void) mkdir(s->runtime_storage.path, 0750); + + r = open_journal(s, true, fn, O_RDWR|O_CREAT, false, &s->runtime_storage.metrics, &s->runtime_journal); + if (r < 0) + return log_error_errno(r, "Failed to open runtime journal: %m"); + } else if (!flushed_flag_is_set(s)) { /* Try to open the runtime journal, but only * if it already exists, so that we can flush * it into the system journal */ @@ -385,17 +394,6 @@ static int system_journal_open(Server *s, bool flush_requested, bool relinquish_ r = 0; } - - } else { - - /* OK, we really need the runtime journal, so create it if necessary. */ - - (void) mkdir_parents(s->runtime_storage.path, 0755); - (void) mkdir(s->runtime_storage.path, 0750); - - r = open_journal(s, true, fn, O_RDWR|O_CREAT, false, &s->runtime_storage.metrics, &s->runtime_journal); - if (r < 0) - return log_error_errno(r, "Failed to open runtime journal: %m"); } if (s->runtime_journal) { diff --git a/src/network/networkd-sriov.c b/src/network/networkd-sriov.c index 77ada236025..3e228a7c451 100644 --- a/src/network/networkd-sriov.c +++ b/src/network/networkd-sriov.c @@ -209,7 +209,11 @@ static int link_set_sr_iov_phys_port(Link *link) { if (!link->dev) return -ENODEV; + /* This may return -EINVAL or -ENODEV, instead of -ENOENT, if the device has been removed or is being + * removed. Let's map -EINVAL to -ENODEV, as the caller will ignore -ENODEV. */ r = sd_device_get_sysattr_value(link->dev, "dev_port", &dev_port); + if (r == -EINVAL) + return -ENODEV; if (r < 0) return r; @@ -242,6 +246,8 @@ static int link_set_sr_iov_virt_ports(Link *link) { return -ENODEV; r = sd_device_get_sysattr_value(link->dev, "dev_port", &dev_port); + if (r == -EINVAL) + return -ENODEV; if (r < 0) return r; diff --git a/src/shared/hwdb-util.c b/src/shared/hwdb-util.c index f70f2df2ed4..0f693a6efbe 100644 --- a/src/shared/hwdb-util.c +++ b/src/shared/hwdb-util.c @@ -193,7 +193,7 @@ static int trie_insert(struct trie *trie, struct trie_node *node, const char *se for (size_t i = 0;; i++) { size_t p; - uint8_t c; + char c; struct trie_node *child; for (p = 0; (c = trie->strings->buf[node->prefix_off + p]); p++) { diff --git a/src/udev/udevd.c b/src/udev/udevd.c index c83c59516b1..2095062b930 100644 --- a/src/udev/udevd.c +++ b/src/udev/udevd.c @@ -55,6 +55,7 @@ #include "pretty-print.h" #include "proc-cmdline.h" #include "process-util.h" +#include "rlimit-util.h" #include "selinux-util.h" #include "signal-util.h" #include "socket-util.h" @@ -2040,6 +2041,9 @@ int run_udevd(int argc, char *argv[]) { if (r < 0) return r; + /* Make sure we can have plenty fds (for example for pidfds) */ + (void) rlimit_nofile_bump(-1); + r = RET_NERRNO(mkdir("/run/udev", 0755)); if (r < 0 && r != -EEXIST) return log_error_errno(r, "Failed to create /run/udev: %m"); diff --git a/test/test-functions b/test/test-functions index 4bdd2a9d24d..f801d49d1df 100644 --- a/test/test-functions +++ b/test/test-functions @@ -369,7 +369,12 @@ qemu_setup_swtpm_socket() { swtpm socket --tpm2 --tpmstate dir="$state_dir" --ctrl type=unixio,path="$state_dir/sock" & pid=$! if ! kill -0 "$pid"; then - echo >&2 "Failed to setup swtpm socket" + derror "Failed to start swtpm" + return 1 + fi + + if ! timeout 5 bash -c "until [[ -S $state_dir/sock ]]; do sleep .5; done"; then + derror "Failed to setup swtpm socket" return 1 fi @@ -532,7 +537,6 @@ run_qemu() { kernel_params+=( "oops=panic" "panic=1" - "softlockup_panic=1" "systemd.wants=end.service" ) fi