/systemd-251/test/ |
D | sys-script.py | 35 f('sys/kernel/kexec_crash_loaded', 0o664, b'0\n') 36 f('sys/kernel/kexec_loaded', 0o664, b'0\n') 37 f('sys/kernel/uevent_helper', 0o664, b'\n') 38 f('sys/kernel/vmcoreinfo', 0o664, b'f15380 1000\n') 39 f('sys/kernel/notes', 0o664, b'\x04\x00\x00\x00\x14\x00\x00\x00\x03\x00\x00\x00GNU\x00Z\r!\x804\xc2… 40 f('sys/kernel/uevent_seqnum', 0o664, b'1407\n') 43 f('sys/kernel/slab/kmalloc-96/reclaim_account', 0o664, b'0\n') 44 f('sys/kernel/slab/kmalloc-96/ctor', 0o664, b'') 45 f('sys/kernel/slab/kmalloc-96/hwcache_align', 0o664, b'0\n') 46 f('sys/kernel/slab/kmalloc-96/slab_size', 0o664, b'168\n') [all …]
|
/systemd-251/src/shared/ |
D | barrier.c | 93 int barrier_create(Barrier *b) { in barrier_create() argument 94 _unused_ _cleanup_(barrier_destroyp) Barrier *staging = b; in barrier_create() 97 assert(b); in barrier_create() 99 b->me = eventfd(0, EFD_CLOEXEC | EFD_NONBLOCK); in barrier_create() 100 if (b->me < 0) in barrier_create() 103 b->them = eventfd(0, EFD_CLOEXEC | EFD_NONBLOCK); in barrier_create() 104 if (b->them < 0) in barrier_create() 107 r = pipe2(b->pipe, O_CLOEXEC | O_NONBLOCK); in barrier_create() 127 Barrier* barrier_destroy(Barrier *b) { in barrier_destroy() argument 128 if (!b) in barrier_destroy() [all …]
|
D | bitmap.c | 31 Bitmap* bitmap_copy(Bitmap *b) { in bitmap_copy() argument 38 ret->bitmaps = newdup(uint64_t, b->bitmaps, b->n_bitmaps); in bitmap_copy() 42 ret->n_bitmaps = b->n_bitmaps; in bitmap_copy() 46 Bitmap* bitmap_free(Bitmap *b) { in bitmap_free() argument 47 if (!b) in bitmap_free() 50 free(b->bitmaps); in bitmap_free() 51 return mfree(b); in bitmap_free() 54 int bitmap_ensure_allocated(Bitmap **b) { in bitmap_ensure_allocated() argument 57 assert(b); in bitmap_ensure_allocated() 59 if (*b) in bitmap_ensure_allocated() [all …]
|
D | xml.c | 42 const char *c, *e, *b; in xml_tokenize() local 86 b = c + 1; in xml_tokenize() 88 if (startswith(b, "!--")) { in xml_tokenize() 90 e = strstr(b + 3, "-->"); in xml_tokenize() 94 inc_lines(line, b, e + 3 - b); in xml_tokenize() 100 if (*b == '?') { in xml_tokenize() 103 e = strstr(b + 1, "?>"); in xml_tokenize() 107 inc_lines(line, b, e + 2 - b); in xml_tokenize() 113 if (*b == '!') { in xml_tokenize() 116 e = strchr(b + 1, '>'); in xml_tokenize() [all …]
|
D | barrier.h | 40 Barrier* barrier_destroy(Barrier *b); 44 void barrier_set_role(Barrier *b, unsigned role); 46 bool barrier_place(Barrier *b); 47 bool barrier_abort(Barrier *b); 49 bool barrier_wait_next(Barrier *b); 50 bool barrier_wait_abortion(Barrier *b); 51 bool barrier_sync_next(Barrier *b); 52 bool barrier_sync(Barrier *b); 54 static inline bool barrier_i_aborted(Barrier *b) { in barrier_i_aborted() argument 55 return IN_SET(b->barriers, BARRIER_I_ABORTED, BARRIER_WE_ABORTED); in barrier_i_aborted() [all …]
|
D | gpt.h | 16 #define GPT_ROOT_LOONGARCH64 SD_ID128_MAKE(77,05,58,00,79,2c,4f,94,b3,9a,98,c9,1b,76,2b,b6) 18 #define GPT_ROOT_MIPS64_LE SD_ID128_MAKE(70,0b,da,43,7a,34,45,07,b1,79,ee,b9,3d,7a,7c,a3) 23 #define GPT_ROOT_RISCV64 SD_ID128_MAKE(72,ec,70,a6,cf,74,40,e6,bd,49,4b,da,08,e8,f2,24) 33 #define GPT_USR_IA64 SD_ID128_MAKE(43,01,d2,a6,4e,3b,4b,2a,bb,94,9e,0b,2c,42,25,ea) 37 #define GPT_USR_PPC SD_ID128_MAKE(7d,14,fe,c5,cc,71,41,5d,9d,6c,06,bf,0b,3c,3e,af) 39 #define GPT_USR_PPC64_LE SD_ID128_MAKE(15,bb,03,af,77,e7,4d,4a,b1,2b,c0,d0,84,f7,49,1c) 41 #define GPT_USR_RISCV64 SD_ID128_MAKE(be,ae,c3,4b,84,42,43,9b,a4,0b,98,43,81,ed,09,7d) 42 #define GPT_USR_S390 SD_ID128_MAKE(cd,0f,86,9b,d0,fb,4c,a0,b1,41,9e,a8,7c,c7,8d,66) 51 #define GPT_ROOT_ARC_VERITY SD_ID128_MAKE(24,b2,d9,75,0f,97,45,21,af,a1,cd,53,1e,42,1b,8d) 53 #define GPT_ROOT_ARM64_VERITY SD_ID128_MAKE(df,33,00,ce,d6,9f,4c,92,97,8c,9b,fb,0f,38,d8,20) [all …]
|
/systemd-251/src/libsystemd/sd-bus/ |
D | bus-socket.c | 110 bool bus_socket_auth_needs_write(sd_bus *b) { in bus_socket_auth_needs_write() argument 114 if (b->auth_index >= ELEMENTSOF(b->auth_iovec)) in bus_socket_auth_needs_write() 117 for (i = b->auth_index; i < ELEMENTSOF(b->auth_iovec); i++) { in bus_socket_auth_needs_write() 118 struct iovec *j = b->auth_iovec + i; in bus_socket_auth_needs_write() 127 static int bus_socket_write_auth(sd_bus *b) { in bus_socket_write_auth() argument 130 assert(b); in bus_socket_write_auth() 131 assert(b->state == BUS_AUTHENTICATING); in bus_socket_write_auth() 133 if (!bus_socket_auth_needs_write(b)) in bus_socket_write_auth() 136 if (b->prefer_writev) in bus_socket_write_auth() 137 …k = writev(b->output_fd, b->auth_iovec + b->auth_index, ELEMENTSOF(b->auth_iovec) - b->auth_index); in bus_socket_write_auth() [all …]
|
D | bus-container.c | 15 int bus_container_connect_socket(sd_bus *b) { in bus_container_connect_socket() argument 22 assert(b); in bus_container_connect_socket() 23 assert(b->input_fd < 0); in bus_container_connect_socket() 24 assert(b->output_fd < 0); in bus_container_connect_socket() 25 assert(b->nspid > 0 || b->machine); in bus_container_connect_socket() 27 if (b->nspid <= 0) { in bus_container_connect_socket() 29 b->description ? " " : "", strempty(b->description), b->machine); in bus_container_connect_socket() 31 r = container_get_leader(b->machine, &b->nspid); in bus_container_connect_socket() 36 b->description ? " " : "", strempty(b->description), b->nspid); in bus_container_connect_socket() 38 r = namespace_open(b->nspid, &pidnsfd, &mntnsfd, NULL, &usernsfd, &rootfd); in bus_container_connect_socket() [all …]
|
D | test-bus-benchmark.c | 27 static void server(sd_bus *b, size_t *result) { in server() argument 33 r = sd_bus_process(b, &m); in server() 37 assert_se(sd_bus_wait(b, USEC_INFINITY) >= 0); in server() 64 static void transaction(sd_bus *b, size_t sz, const char *server_name) { in transaction() argument 68 …assert_se(sd_bus_message_new_method_call(b, &m, server_name, "/", "benchmark.server", "Work") >= 0… in transaction() 73 assert_se(sd_bus_call(b, m, 0, NULL, &reply) >= 0); in transaction() 79 sd_bus *b; in client_bisect() local 82 r = sd_bus_new(&b); in client_bisect() 85 r = sd_bus_set_address(b, address); in client_bisect() 88 r = sd_bus_start(b); in client_bisect() [all …]
|
D | sd-bus.c | 65 static void bus_detach_io_events(sd_bus *b); 129 void bus_close_io_fds(sd_bus *b) { in bus_close_io_fds() argument 130 assert(b); in bus_close_io_fds() 132 bus_detach_io_events(b); in bus_close_io_fds() 134 if (b->input_fd != b->output_fd) in bus_close_io_fds() 135 safe_close(b->output_fd); in bus_close_io_fds() 136 b->output_fd = b->input_fd = safe_close(b->input_fd); in bus_close_io_fds() 139 void bus_close_inotify_fd(sd_bus *b) { in bus_close_inotify_fd() argument 140 assert(b); in bus_close_inotify_fd() 142 b->inotify_event_source = sd_event_source_disable_unref(b->inotify_event_source); in bus_close_inotify_fd() [all …]
|
D | test-bus-address.c | 11 static void test_one_address(sd_bus *b, in test_one_address() argument 16 r = bus_set_address_system_remote(b, host); in test_one_address() 17 log_info("\"%s\" → %d, \"%s\"", host, r, strna(r >= 0 ? b->address : NULL)); in test_one_address() 21 assert_se(streq(b->address, expected)); in test_one_address() 26 _cleanup_(sd_bus_unrefp) sd_bus *b = NULL; in TEST() 28 assert_se(sd_bus_new(&b) >= 0); in TEST() 31 test_one_address(b, *a, 0, NULL); in TEST() 35 test_one_address(b, "host", in TEST() 37 test_one_address(b, "host:123", in TEST() 39 test_one_address(b, "host:123:123", in TEST() [all …]
|
D | bus-internal.c | 50 char* object_path_startswith(const char *a, const char *b) { in object_path_startswith() argument 54 !object_path_is_valid(b)) in object_path_startswith() 57 if (streq(b, "/")) in object_path_startswith() 60 p = startswith(a, b); in object_path_startswith() 196 static bool complex_pattern_check(char c, const char *a, const char *b) { in complex_pattern_check() argument 199 if (!a && !b) in complex_pattern_check() 202 if (!a || !b) in complex_pattern_check() 206 if (*a != *b) in complex_pattern_check() 207 return (separator && (*a == 0 || *b == 0)); in complex_pattern_check() 214 a++, b++; in complex_pattern_check() [all …]
|
/systemd-251/src/test/ |
D | test-bitmap.c | 6 _cleanup_bitmap_free_ Bitmap *b = NULL, *b2 = NULL; in main() local 9 b = bitmap_new(); in main() 10 assert_se(b); in main() 12 assert_se(bitmap_ensure_allocated(&b) == 0); in main() 13 bitmap_free(b); in main() 14 b = NULL; in main() 15 assert_se(bitmap_ensure_allocated(&b) == 0); in main() 17 assert_se(bitmap_isset(b, 0) == false); in main() 18 assert_se(bitmap_isset(b, 1) == false); in main() 19 assert_se(bitmap_isset(b, 256) == false); in main() [all …]
|
D | test-barrier.c | 45 Barrier b = BARRIER_NULL; \ 48 assert_se(barrier_create(&b) >= 0); \ 49 assert_se(b.me > 0); \ 50 assert_se(b.them > 0); \ 51 assert_se(b.pipe[0] > 0); \ 52 assert_se(b.pipe[1] > 0); \ 57 barrier_set_role(&b, BARRIER_CHILD); \ 65 barrier_set_role(&b, BARRIER_PARENT); \ 70 barrier_destroy(&b); \ 107 assert_se(barrier_place(&b)); [all …]
|
D | test-user-util.c | 437 uid_t a = 4711, b = 4711; in TEST() local 439 assert_se(parse_uid_range("", &a, &b) == -EINVAL && a == 4711 && b == 4711); in TEST() 440 assert_se(parse_uid_range(" ", &a, &b) == -EINVAL && a == 4711 && b == 4711); in TEST() 441 assert_se(parse_uid_range("x", &a, &b) == -EINVAL && a == 4711 && b == 4711); in TEST() 443 assert_se(parse_uid_range("0", &a, &b) >= 0 && a == 0 && b == 0); in TEST() 444 assert_se(parse_uid_range("1", &a, &b) >= 0 && a == 1 && b == 1); in TEST() 445 assert_se(parse_uid_range("2-2", &a, &b) >= 0 && a == 2 && b == 2); in TEST() 446 assert_se(parse_uid_range("3-3", &a, &b) >= 0 && a == 3 && b == 3); in TEST() 447 assert_se(parse_uid_range("4-5", &a, &b) >= 0 && a == 4 && b == 5); in TEST() 449 assert_se(parse_uid_range("7-6", &a, &b) == -EINVAL && a == 4 && b == 5); in TEST() [all …]
|
D | test-install-file.c | 13 _cleanup_free_ char *a = NULL, *b = NULL, *c = NULL; in TEST() local 18 assert_se(b = path_join(p, "bar")); in TEST() 26 assert_se(install_file(AT_FDCWD, a, AT_FDCWD, b, 0) >= 0); in TEST() 27 assert_se(install_file(AT_FDCWD, b, AT_FDCWD, a, INSTALL_FSYNC) >= 0); in TEST() 29 assert_se(write_string_file(b, "ttss", WRITE_STRING_FILE_CREATE) >= 0); in TEST() 30 assert_se(install_file(AT_FDCWD, a, AT_FDCWD, b, INSTALL_FSYNC_FULL) == -EEXIST); in TEST() 31 assert_se(install_file(AT_FDCWD, a, AT_FDCWD, b, INSTALL_FSYNC_FULL|INSTALL_REPLACE) >= 0); in TEST() 33 assert_se(stat(b, &stat2) >= 0); in TEST() 38 …assert_se(install_file(AT_FDCWD, b, AT_FDCWD, a, INSTALL_FSYNC_FULL|INSTALL_REPLACE|INSTALL_READ_O… in TEST() 45 assert_se(mkdir(b, 0755) >= 0); in TEST() [all …]
|
/systemd-251/src/login/ |
D | logind-button.c | 18 #define CONST_MAX5(a, b, c, d, e) CONST_MAX(CONST_MAX(a, b), CONST_MAX(CONST_MAX(c, d), e)) argument 33 Button *b; in button_new() local 38 b = new0(Button, 1); in button_new() 39 if (!b) in button_new() 42 b->name = strdup(name); in button_new() 43 if (!b->name) in button_new() 44 return mfree(b); in button_new() 46 if (hashmap_put(m->buttons, b->name, b) < 0) { in button_new() 47 free(b->name); in button_new() 48 return mfree(b); in button_new() [all …]
|
/systemd-251/src/libsystemd/sd-journal/ |
D | lookup3.c | 124 #define mix(a,b,c) \ argument 126 a -= c; a ^= rot(c, 4); c += b; \ 127 b -= a; b ^= rot(a, 6); a += c; \ 128 c -= b; c ^= rot(b, 8); b += a; \ 129 a -= c; a ^= rot(c,16); c += b; \ 130 b -= a; b ^= rot(a,19); a += c; \ 131 c -= b; c ^= rot(b, 4); b += a; \ 159 #define final(a,b,c) \ argument 161 c ^= b; c -= rot(b,14); \ 163 b ^= a; b -= rot(a,25); \ [all …]
|
/systemd-251/src/network/netdev/ |
D | bond.c | 60 Bond *b; in netdev_bond_fill_message_create() local 67 b = BOND(netdev); in netdev_bond_fill_message_create() 69 assert(b); in netdev_bond_fill_message_create() 71 if (b->mode != _NETDEV_BOND_MODE_INVALID) { in netdev_bond_fill_message_create() 72 r = sd_netlink_message_append_u8(m, IFLA_BOND_MODE, b->mode); in netdev_bond_fill_message_create() 77 if (b->xmit_hash_policy != _NETDEV_BOND_XMIT_HASH_POLICY_INVALID) { in netdev_bond_fill_message_create() 78 … r = sd_netlink_message_append_u8(m, IFLA_BOND_XMIT_HASH_POLICY, b->xmit_hash_policy); in netdev_bond_fill_message_create() 83 if (b->lacp_rate != _NETDEV_BOND_LACP_RATE_INVALID && in netdev_bond_fill_message_create() 84 b->mode == NETDEV_BOND_MODE_802_3AD) { in netdev_bond_fill_message_create() 85 r = sd_netlink_message_append_u8(m, IFLA_BOND_AD_LACP_RATE, b->lacp_rate); in netdev_bond_fill_message_create() [all …]
|
D | bridge.c | 49 Bridge *b; in netdev_bridge_post_create_message() local 52 assert_se(b = BRIDGE(netdev)); in netdev_bridge_post_create_message() 63 if (b->forward_delay != USEC_INFINITY) { in netdev_bridge_post_create_message() 64 … r = sd_netlink_message_append_u32(req, IFLA_BR_FORWARD_DELAY, usec_to_jiffies(b->forward_delay)); in netdev_bridge_post_create_message() 69 if (b->hello_time > 0) { in netdev_bridge_post_create_message() 70 … r = sd_netlink_message_append_u32(req, IFLA_BR_HELLO_TIME, usec_to_jiffies(b->hello_time)); in netdev_bridge_post_create_message() 75 if (b->max_age > 0) { in netdev_bridge_post_create_message() 76 … r = sd_netlink_message_append_u32(req, IFLA_BR_MAX_AGE, usec_to_jiffies(b->max_age)); in netdev_bridge_post_create_message() 81 if (b->ageing_time != USEC_INFINITY) { in netdev_bridge_post_create_message() 82 … r = sd_netlink_message_append_u32(req, IFLA_BR_AGEING_TIME, usec_to_jiffies(b->ageing_time)); in netdev_bridge_post_create_message() [all …]
|
D | batadv.c | 19 BatmanAdvanced *b; in batadv_init() local 21 b = BATADV(n); in batadv_init() 24 b->aggregation = true; in batadv_init() 25 b->gateway_bandwidth_down = 10000; in batadv_init() 26 b->gateway_bandwidth_up = 2000; in batadv_init() 27 b->bridge_loop_avoidance = true; in batadv_init() 28 b->distributed_arp_table = true; in batadv_init() 29 b->fragmentation = true; in batadv_init() 30 b->hop_penalty = 15; in batadv_init() 31 b->originator_interval = 1000; in batadv_init() [all …]
|
/systemd-251/src/fundamental/ |
D | string-util-fundamental.h | 15 #define strcmp(a, b) StrCmp((a), (b)) argument 16 #define strncmp(a, b, n) StrnCmp((a), (b), (n)) argument 17 #define strcasecmp(a, b) StriCmp((a), (b)) argument 19 #define memcmp(a, b, n) CompareMem(a, b, n) argument 24 #define streq(a,b) (strcmp((a),(b)) == 0) argument 25 #define strneq(a, b, n) (strncmp((a), (b), (n)) == 0) argument 26 #define strcaseeq(a,b) (strcasecmp((a),(b)) == 0) argument 28 #define strncaseeq(a, b, n) (strncasecmp((a), (b), (n)) == 0) argument 31 static inline sd_int strcmp_ptr(const sd_char *a, const sd_char *b) { in strcmp_ptr() argument 32 if (a && b) in strcmp_ptr() [all …]
|
D | string-util-fundamental.c | 95 sd_int strverscmp_improved(const sd_char *a, const sd_char *b) { in strverscmp_improved() argument 126 if (isempty(a) || isempty(b)) in strverscmp_improved() 127 return strcmp_ptr(a, b); in strverscmp_improved() 136 while (*b != '\0' && !is_valid_version_char(*b)) in strverscmp_improved() 137 b++; in strverscmp_improved() 140 if (*a == '~' || *b == '~') { in strverscmp_improved() 142 r = CMP(*a != '~', *b != '~'); in strverscmp_improved() 148 b++; in strverscmp_improved() 154 if (*a == '\0' || *b == '\0') in strverscmp_improved() 155 return CMP(*a, *b); in strverscmp_improved() [all …]
|
/systemd-251/src/systemd/ |
D | sd-messages.h | 31 …ne SD_MESSAGE_JOURNAL_START SD_ID128_MAKE(f7,73,79,a8,49,0b,40,8b,be,5f,69,40,50,5a,77,7b) 32 …D_MESSAGE_JOURNAL_START_STR SD_ID128_MAKE_STR(f7,73,79,a8,49,0b,40,8b,be,5f,69,40,50,5a,77,7b) 33 …ne SD_MESSAGE_JOURNAL_STOP SD_ID128_MAKE(d9,3f,b3,c9,c2,4d,45,1a,97,ce,a6,15,ce,59,c0,0b) 34 …D_MESSAGE_JOURNAL_STOP_STR SD_ID128_MAKE_STR(d9,3f,b3,c9,c2,4d,45,1a,97,ce,a6,15,ce,59,c0,0b) 35 #define SD_MESSAGE_JOURNAL_DROPPED SD_ID128_MAKE(a5,96,d6,fe,7b,fa,49,94,82,8e,72,30,9e,95,d… 36 #define SD_MESSAGE_JOURNAL_DROPPED_STR SD_ID128_MAKE_STR(a5,96,d6,fe,7b,fa,49,94,82,8e,72,30,9e,… 37 #define SD_MESSAGE_JOURNAL_MISSED SD_ID128_MAKE(e9,bf,28,e6,e8,34,48,1b,b6,f4,8f,54,8a,d1,3… 38 #define SD_MESSAGE_JOURNAL_MISSED_STR SD_ID128_MAKE_STR(e9,bf,28,e6,e8,34,48,1b,b6,f4,8f,54,8a,… 39 #define SD_MESSAGE_JOURNAL_USAGE SD_ID128_MAKE(ec,38,7f,57,7b,84,4b,8f,a9,48,f3,3c,ad,9a,7… 40 #define SD_MESSAGE_JOURNAL_USAGE_STR SD_ID128_MAKE_STR(ec,38,7f,57,7b,84,4b,8f,a9,48,f3,3c,ad,… [all …]
|
/systemd-251/src/udev/ |
D | test-udev-node.c | 17 char a[NAME_MAX+1], b[NAME_MAX+1]; in TEST() local 31 memset(b, 'a', sizeof(b) - 1); in TEST() 32 memcpy(b, "\\x2fdisk\\x2fby-id\\x2f", strlen("\\x2fdisk\\x2fby-id\\x2f")); in TEST() 33 strcpy(b + sizeof(b) - 12, "N3YhcCqFeID"); in TEST() 35 test_udev_node_escape_path_one(a, b); in TEST() 38 strcpy(b + sizeof(b) - 12, "L1oK9iKWdmi"); in TEST() 39 test_udev_node_escape_path_one(a, b); in TEST() 42 strcpy(b + sizeof(b) - 12, "A7oaHBRuuZq"); in TEST() 43 test_udev_node_escape_path_one(a, b); in TEST() 46 b[sizeof(a) - 12] = '\0'; in TEST() [all …]
|