Lines Matching refs:ra
144 sd_radv *ra; in TEST() local
146 assert_se(sd_radv_new(&ra) >= 0); in TEST()
147 assert_se(ra); in TEST()
150 assert_se(sd_radv_set_ifindex(ra, 0) < 0); in TEST()
151 assert_se(sd_radv_set_ifindex(ra, -1) < 0); in TEST()
152 assert_se(sd_radv_set_ifindex(ra, -2) < 0); in TEST()
153 assert_se(sd_radv_set_ifindex(ra, 42) >= 0); in TEST()
156 assert_se(sd_radv_set_mac(ra, NULL) >= 0); in TEST()
157 assert_se(sd_radv_set_mac(ra, &mac_addr) >= 0); in TEST()
160 assert_se(sd_radv_set_mtu(ra, 0) < 0); in TEST()
161 assert_se(sd_radv_set_mtu(ra, 1279) < 0); in TEST()
162 assert_se(sd_radv_set_mtu(ra, 1280) >= 0); in TEST()
163 assert_se(sd_radv_set_mtu(ra, ~0) >= 0); in TEST()
166 assert_se(sd_radv_set_hop_limit(ra, 0) >= 0); in TEST()
167 assert_se(sd_radv_set_hop_limit(ra, ~0) >= 0); in TEST()
170 assert_se(sd_radv_set_router_lifetime(ra, 0) >= 0); in TEST()
171 assert_se(sd_radv_set_router_lifetime(ra, USEC_INFINITY) < 0); in TEST()
172 assert_se(sd_radv_set_router_lifetime(ra, USEC_PER_YEAR) < 0); in TEST()
173 assert_se(sd_radv_set_router_lifetime(ra, 300 * USEC_PER_SEC) >= 0); in TEST()
176 assert_se(sd_radv_set_preference(ra, SD_NDISC_PREFERENCE_LOW) >= 0); in TEST()
177 assert_se(sd_radv_set_preference(ra, SD_NDISC_PREFERENCE_MEDIUM) >= 0); in TEST()
178 assert_se(sd_radv_set_preference(ra, SD_NDISC_PREFERENCE_HIGH) >= 0); in TEST()
179 assert_se(sd_radv_set_preference(ra, ~0) < 0); in TEST()
181 assert_se(sd_radv_set_preference(ra, SD_NDISC_PREFERENCE_HIGH) >= 0); in TEST()
182 assert_se(sd_radv_set_router_lifetime(ra, 300 * USEC_PER_SEC) >= 0); in TEST()
183 assert_se(sd_radv_set_router_lifetime(ra, 0) < 0); in TEST()
184 assert_se(sd_radv_set_preference(ra, SD_NDISC_PREFERENCE_MEDIUM) >= 0); in TEST()
185 assert_se(sd_radv_set_router_lifetime(ra, 0) >= 0); in TEST()
188 assert_se(sd_radv_set_managed_information(ra, true) >= 0); in TEST()
189 assert_se(sd_radv_set_managed_information(ra, false) >= 0); in TEST()
192 assert_se(sd_radv_set_other_information(ra, true) >= 0); in TEST()
193 assert_se(sd_radv_set_other_information(ra, false) >= 0); in TEST()
196 assert_se(sd_radv_set_rdnss(ra, 0, NULL, 0) >= 0); in TEST()
197 assert_se(sd_radv_set_rdnss(ra, 0, NULL, 128) < 0); in TEST()
198 assert_se(sd_radv_set_rdnss(ra, 600, &test_rdnss, 0) >= 0); in TEST()
199 assert_se(sd_radv_set_rdnss(ra, 600, &test_rdnss, 1) >= 0); in TEST()
200 assert_se(sd_radv_set_rdnss(ra, 0, &test_rdnss, 1) >= 0); in TEST()
201 assert_se(sd_radv_set_rdnss(ra, 0, NULL, 0) >= 0); in TEST()
203 assert_se(sd_radv_set_dnssl(ra, 0, NULL) >= 0); in TEST()
204 assert_se(sd_radv_set_dnssl(ra, 600, NULL) >= 0); in TEST()
205 assert_se(sd_radv_set_dnssl(ra, 0, (char **)test_dnssl) >= 0); in TEST()
206 assert_se(sd_radv_set_dnssl(ra, 600, (char **)test_dnssl) >= 0); in TEST()
208 ra = sd_radv_unref(ra); in TEST()
209 assert_se(!ra); in TEST()
238 sd_radv *ra = userdata; in radv_recv() local
271 e = sd_radv_get_event(ra); in radv_recv()
277 assert_se(sd_radv_stop(ra) >= 0); in radv_recv()
283 TEST(ra) { in TEST() argument
285 sd_radv *ra; in TEST() local
292 assert_se(sd_radv_new(&ra) >= 0); in TEST()
293 assert_se(ra); in TEST()
295 assert_se(sd_radv_attach_event(ra, e, 0) >= 0); in TEST()
297 assert_se(sd_radv_set_ifindex(ra, 42) >= 0); in TEST()
298 assert_se(sd_radv_set_mac(ra, &mac_addr) >= 0); in TEST()
299 assert_se(sd_radv_set_router_lifetime(ra, 180 * USEC_PER_SEC) >= 0); in TEST()
300 assert_se(sd_radv_set_hop_limit(ra, 64) >= 0); in TEST()
301 assert_se(sd_radv_set_managed_information(ra, true) >= 0); in TEST()
302 assert_se(sd_radv_set_other_information(ra, true) >= 0); in TEST()
303 assert_se(sd_radv_set_rdnss(ra, 60, &test_rdnss, 1) >= 0); in TEST()
304 assert_se(sd_radv_set_dnssl(ra, 60, (char **)test_dnssl) >= 0); in TEST()
319 assert_se((sd_radv_add_prefix(ra, p) >= 0) == prefix[i].successful); in TEST()
321 assert_se((sd_radv_add_prefix(ra, p) >= 0) == prefix[i].successful); in TEST()
328 EPOLLIN, radv_recv, ra) >= 0); in TEST()
334 assert_se(sd_radv_start(ra) >= 0); in TEST()
338 ra = sd_radv_unref(ra); in TEST()
339 assert_se(!ra); in TEST()