Lines Matching refs:ret_val

300 	int ret_val = -EPERM;  in cipso_v4_cache_add()  local
316 ret_val = -ENOMEM; in cipso_v4_cache_add()
343 return ret_val; in cipso_v4_cache_add()
385 int ret_val = -EINVAL; in cipso_v4_doi_add() local
423 ret_val = -EEXIST; in cipso_v4_doi_add()
428 ret_val = 0; in cipso_v4_doi_add()
449 doi, type_str, ret_val == 0 ? 1 : 0); in cipso_v4_doi_add()
453 return ret_val; in cipso_v4_doi_add()
512 int ret_val; in cipso_v4_doi_remove() local
520 ret_val = -ENOENT; in cipso_v4_doi_remove()
527 ret_val = 0; in cipso_v4_doi_remove()
534 doi, ret_val == 0 ? 1 : 0); in cipso_v4_doi_remove()
538 return ret_val; in cipso_v4_doi_remove()
605 int ret_val = -ENOENT; in cipso_v4_doi_walk() local
614 ret_val = callback(iter_doi, cb_arg); in cipso_v4_doi_walk()
615 if (ret_val < 0) { in cipso_v4_doi_walk()
624 return ret_val; in cipso_v4_doi_walk()
850 int ret_val; in cipso_v4_map_cat_rbm_ntoh() local
885 ret_val = netlbl_catmap_setbit(&secattr->attr.mls.cat, in cipso_v4_map_cat_rbm_ntoh()
888 if (ret_val != 0) in cipso_v4_map_cat_rbm_ntoh()
889 return ret_val; in cipso_v4_map_cat_rbm_ntoh()
982 int ret_val; in cipso_v4_map_cat_enum_ntoh() local
986 ret_val = netlbl_catmap_setbit(&secattr->attr.mls.cat, in cipso_v4_map_cat_enum_ntoh()
989 if (ret_val != 0) in cipso_v4_map_cat_enum_ntoh()
990 return ret_val; in cipso_v4_map_cat_enum_ntoh()
1114 int ret_val; in cipso_v4_map_cat_rng_ntoh() local
1126 ret_val = netlbl_catmap_setrng(&secattr->attr.mls.cat, in cipso_v4_map_cat_rng_ntoh()
1130 if (ret_val != 0) in cipso_v4_map_cat_rng_ntoh()
1131 return ret_val; in cipso_v4_map_cat_rng_ntoh()
1179 int ret_val; in cipso_v4_gentag_rbm() local
1186 ret_val = cipso_v4_map_lvl_hton(doi_def, in cipso_v4_gentag_rbm()
1189 if (ret_val != 0) in cipso_v4_gentag_rbm()
1190 return ret_val; in cipso_v4_gentag_rbm()
1193 ret_val = cipso_v4_map_cat_rbm_hton(doi_def, in cipso_v4_gentag_rbm()
1197 if (ret_val < 0) in cipso_v4_gentag_rbm()
1198 return ret_val; in cipso_v4_gentag_rbm()
1203 if (READ_ONCE(cipso_v4_rbm_optfmt) && ret_val > 0 && in cipso_v4_gentag_rbm()
1204 ret_val <= 10) in cipso_v4_gentag_rbm()
1207 tag_len = 4 + ret_val; in cipso_v4_gentag_rbm()
1234 int ret_val; in cipso_v4_parsetag_rbm() local
1238 ret_val = cipso_v4_map_lvl_ntoh(doi_def, tag[3], &level); in cipso_v4_parsetag_rbm()
1239 if (ret_val != 0) in cipso_v4_parsetag_rbm()
1240 return ret_val; in cipso_v4_parsetag_rbm()
1245 ret_val = cipso_v4_map_cat_rbm_ntoh(doi_def, in cipso_v4_parsetag_rbm()
1249 if (ret_val != 0) { in cipso_v4_parsetag_rbm()
1251 return ret_val; in cipso_v4_parsetag_rbm()
1278 int ret_val; in cipso_v4_gentag_enum() local
1285 ret_val = cipso_v4_map_lvl_hton(doi_def, in cipso_v4_gentag_enum()
1288 if (ret_val != 0) in cipso_v4_gentag_enum()
1289 return ret_val; in cipso_v4_gentag_enum()
1292 ret_val = cipso_v4_map_cat_enum_hton(doi_def, in cipso_v4_gentag_enum()
1296 if (ret_val < 0) in cipso_v4_gentag_enum()
1297 return ret_val; in cipso_v4_gentag_enum()
1299 tag_len = 4 + ret_val; in cipso_v4_gentag_enum()
1326 int ret_val; in cipso_v4_parsetag_enum() local
1330 ret_val = cipso_v4_map_lvl_ntoh(doi_def, tag[3], &level); in cipso_v4_parsetag_enum()
1331 if (ret_val != 0) in cipso_v4_parsetag_enum()
1332 return ret_val; in cipso_v4_parsetag_enum()
1337 ret_val = cipso_v4_map_cat_enum_ntoh(doi_def, in cipso_v4_parsetag_enum()
1341 if (ret_val != 0) { in cipso_v4_parsetag_enum()
1343 return ret_val; in cipso_v4_parsetag_enum()
1369 int ret_val; in cipso_v4_gentag_rng() local
1376 ret_val = cipso_v4_map_lvl_hton(doi_def, in cipso_v4_gentag_rng()
1379 if (ret_val != 0) in cipso_v4_gentag_rng()
1380 return ret_val; in cipso_v4_gentag_rng()
1383 ret_val = cipso_v4_map_cat_rng_hton(doi_def, in cipso_v4_gentag_rng()
1387 if (ret_val < 0) in cipso_v4_gentag_rng()
1388 return ret_val; in cipso_v4_gentag_rng()
1390 tag_len = 4 + ret_val; in cipso_v4_gentag_rng()
1416 int ret_val; in cipso_v4_parsetag_rng() local
1420 ret_val = cipso_v4_map_lvl_ntoh(doi_def, tag[3], &level); in cipso_v4_parsetag_rng()
1421 if (ret_val != 0) in cipso_v4_parsetag_rng()
1422 return ret_val; in cipso_v4_parsetag_rng()
1427 ret_val = cipso_v4_map_cat_rng_ntoh(doi_def, in cipso_v4_parsetag_rng()
1431 if (ret_val != 0) { in cipso_v4_parsetag_rng()
1433 return ret_val; in cipso_v4_parsetag_rng()
1765 int ret_val; in cipso_v4_genopt() local
1779 ret_val = cipso_v4_gentag_rbm(doi_def, in cipso_v4_genopt()
1785 ret_val = cipso_v4_gentag_enum(doi_def, in cipso_v4_genopt()
1791 ret_val = cipso_v4_gentag_rng(doi_def, in cipso_v4_genopt()
1797 ret_val = cipso_v4_gentag_loc(doi_def, in cipso_v4_genopt()
1807 } while (ret_val < 0 && in cipso_v4_genopt()
1810 if (ret_val < 0) in cipso_v4_genopt()
1811 return ret_val; in cipso_v4_genopt()
1812 cipso_v4_gentag_hdr(doi_def, buf, ret_val); in cipso_v4_genopt()
1813 return CIPSO_V4_HDR_LEN + ret_val; in cipso_v4_genopt()
1834 int ret_val = -EPERM; in cipso_v4_sock_setattr() local
1855 ret_val = -ENOMEM; in cipso_v4_sock_setattr()
1859 ret_val = cipso_v4_genopt(buf, buf_len, doi_def, secattr); in cipso_v4_sock_setattr()
1860 if (ret_val < 0) in cipso_v4_sock_setattr()
1862 buf_len = ret_val; in cipso_v4_sock_setattr()
1871 ret_val = -ENOMEM; in cipso_v4_sock_setattr()
1900 return ret_val; in cipso_v4_sock_setattr()
1919 int ret_val = -EPERM; in cipso_v4_req_setattr() local
1932 ret_val = -ENOMEM; in cipso_v4_req_setattr()
1936 ret_val = cipso_v4_genopt(buf, buf_len, doi_def, secattr); in cipso_v4_req_setattr()
1937 if (ret_val < 0) in cipso_v4_req_setattr()
1939 buf_len = ret_val; in cipso_v4_req_setattr()
1948 ret_val = -ENOMEM; in cipso_v4_req_setattr()
1967 return ret_val; in cipso_v4_req_setattr()
2087 int ret_val = -ENOMSG; in cipso_v4_getattr() local
2104 ret_val = cipso_v4_parsetag_rbm(doi_def, &cipso[6], secattr); in cipso_v4_getattr()
2107 ret_val = cipso_v4_parsetag_enum(doi_def, &cipso[6], secattr); in cipso_v4_getattr()
2110 ret_val = cipso_v4_parsetag_rng(doi_def, &cipso[6], secattr); in cipso_v4_getattr()
2113 ret_val = cipso_v4_parsetag_loc(doi_def, &cipso[6], secattr); in cipso_v4_getattr()
2116 if (ret_val == 0) in cipso_v4_getattr()
2121 return ret_val; in cipso_v4_getattr()
2167 int ret_val; in cipso_v4_skbuff_setattr() local
2175 ret_val = cipso_v4_genopt(buf, buf_len, doi_def, secattr); in cipso_v4_skbuff_setattr()
2176 if (ret_val < 0) in cipso_v4_skbuff_setattr()
2177 return ret_val; in cipso_v4_skbuff_setattr()
2178 buf_len = ret_val; in cipso_v4_skbuff_setattr()
2191 ret_val = skb_cow(skb, skb_headroom(skb) + len_delta); in cipso_v4_skbuff_setattr()
2192 if (ret_val < 0) in cipso_v4_skbuff_setattr()
2193 return ret_val; in cipso_v4_skbuff_setattr()
2243 int ret_val; in cipso_v4_skbuff_delattr() local
2252 ret_val = skb_cow(skb, skb_headroom(skb)); in cipso_v4_skbuff_delattr()
2253 if (ret_val < 0) in cipso_v4_skbuff_delattr()
2254 return ret_val; in cipso_v4_skbuff_delattr()
2285 int ret_val; in cipso_v4_init() local
2287 ret_val = cipso_v4_cache_init(); in cipso_v4_init()
2288 if (ret_val != 0) in cipso_v4_init()
2290 ret_val); in cipso_v4_init()