Lines Matching refs:ll
42 static void basic_request_handler(sd_ipv4ll *ll, int event, void *userdata) {
104 sd_ipv4ll *ll;
111 assert_se(sd_ipv4ll_new(&ll) == 0);
112 assert_se(ll);
115 assert_se(sd_ipv4ll_attach_event(ll, e, 0) == 0);
116 assert_se(sd_ipv4ll_attach_event(ll, e, 0) == -EBUSY);
119 assert_se(sd_ipv4ll_set_callback(ll, NULL, NULL) == 0);
121 assert_se(sd_ipv4ll_set_address(ll, &address) == -EINVAL);
123 assert_se(sd_ipv4ll_set_address(ll, &address) == -EINVAL);
125 assert_se(sd_ipv4ll_set_address(ll, &address) == -EINVAL);
127 assert_se(sd_ipv4ll_set_address(ll, &address) == 0);
129 assert_se(sd_ipv4ll_set_address(ll, &address) == -EINVAL);
132 assert_se(sd_ipv4ll_set_address_seed(ll, seed) == 0);
135 assert_se(sd_ipv4ll_set_mac(ll, NULL) == -EINVAL);
136 assert_se(sd_ipv4ll_set_mac(ll, &mac_addr) == 0);
139 assert_se(sd_ipv4ll_set_index(ll, -1) == -EINVAL);
140 assert_se(sd_ipv4ll_set_index(ll, -99) == -EINVAL);
141 assert_se(sd_ipv4ll_set_index(ll, 1) == 0);
142 assert_se(sd_ipv4ll_set_index(ll, 99) == 0);
144 assert_se(sd_ipv4ll_ref(ll) == ll);
145 assert_se(sd_ipv4ll_unref(ll) == NULL);
148 assert_se(sd_ipv4ll_unref(ll) == NULL);
153 sd_ipv4ll *ll;
161 assert_se(sd_ipv4ll_new(&ll) == 0);
162 assert_se(sd_ipv4ll_start(ll) == -EINVAL);
164 assert_se(sd_ipv4ll_attach_event(ll, e, 0) == 0);
165 assert_se(sd_ipv4ll_start(ll) == -EINVAL);
167 assert_se(sd_ipv4ll_set_mac(ll, &mac_addr) == 0);
168 assert_se(sd_ipv4ll_start(ll) == -EINVAL);
170 assert_se(sd_ipv4ll_set_callback(ll, basic_request_handler,
172 assert_se(sd_ipv4ll_start(ll) == -EINVAL);
174 assert_se(sd_ipv4ll_set_index(ll, 1) == 0);
175 assert_se(sd_ipv4ll_start(ll) == 0);
178 assert_se(sd_ipv4ll_start(ll) == -EBUSY);
180 assert_se(sd_ipv4ll_is_running(ll));
199 sd_ipv4ll_stop(ll);
203 assert_se(sd_ipv4ll_unref(ll) == NULL);