Lines Matching defs:lun
189 struct lun *lun;
202 asprintf(&name, "%s,lun,%ju", target->t_name, tmp);
203 lun = lun_new(conf, name);
204 if (lun == NULL)
207 lun_set_scsiname(lun, name);
208 target->t_luns[tmp] = lun;
217 log_warnx("lun section in target \"%s\" is missing "
229 log_warnx("lun section in target \"%s\" is missing "
234 lun = lun_find(conf, ucl_object_tostring(name));
235 if (lun == NULL)
238 target->t_luns[tmp] = lun;
355 if (!strcmp(key, "lun")) {
362 log_warnx("\"lun\" section is not an object");
885 if (!strcmp(key, "lun")) {
899 struct lun *lun;
904 lun = lun_new(conf, name);
905 if (lun == NULL)
913 log_warnx("\"backend\" property of lun "
915 lun->l_name);
919 lun_set_backend(lun, ucl_object_tostring(obj));
924 log_warnx("\"blocksize\" property of lun "
925 "\"%s\" is not an integer", lun->l_name);
929 lun_set_blocksize(lun, ucl_object_toint(obj));
934 log_warnx("\"device-id\" property of lun "
935 "\"%s\" is not an integer", lun->l_name);
939 lun_set_device_id(lun, ucl_object_tostring(obj));
944 log_warnx("\"options\" property of lun "
945 "\"%s\" is not an object", lun->l_name);
951 option_new(&lun->l_options,
959 log_warnx("\"path\" property of lun "
960 "\"%s\" is not a string", lun->l_name);
964 lun_set_path(lun, ucl_object_tostring(obj));
969 log_warnx("\"serial\" property of lun "
970 "\"%s\" is not a string", lun->l_name);
974 lun_set_serial(lun, ucl_object_tostring(obj));
979 log_warnx("\"size\" property of lun "
980 "\"%s\" is not an integer", lun->l_name);
984 lun_set_size(lun, ucl_object_toint(obj));