Lines Matching refs:new
274 struct nsm_handle *new; in nsm_create_handle() local
276 new = kzalloc(sizeof(*new) + hostname_len + 1, GFP_KERNEL); in nsm_create_handle()
277 if (unlikely(new == NULL)) in nsm_create_handle()
280 atomic_set(&new->sm_count, 1); in nsm_create_handle()
281 new->sm_name = (char *)(new + 1); in nsm_create_handle()
282 memcpy(nsm_addr(new), sap, salen); in nsm_create_handle()
283 new->sm_addrlen = salen; in nsm_create_handle()
284 nsm_init_private(new); in nsm_create_handle()
286 if (rpc_ntop(nsm_addr(new), new->sm_addrbuf, in nsm_create_handle()
287 sizeof(new->sm_addrbuf)) == 0) in nsm_create_handle()
288 (void)snprintf(new->sm_addrbuf, sizeof(new->sm_addrbuf), in nsm_create_handle()
290 memcpy(new->sm_name, hostname, hostname_len); in nsm_create_handle()
291 new->sm_name[hostname_len] = '\0'; in nsm_create_handle()
293 return new; in nsm_create_handle()
316 struct nsm_handle *cached, *new = NULL; in nsm_get_handle() local
340 kfree(new); in nsm_get_handle()
348 if (new != NULL) { in nsm_get_handle()
349 list_add(&new->sm_link, &ln->nsm_handles); in nsm_get_handle()
352 new->sm_name, new->sm_addrbuf); in nsm_get_handle()
353 return new; in nsm_get_handle()
358 new = nsm_create_handle(sap, salen, hostname, hostname_len); in nsm_get_handle()
359 if (unlikely(new == NULL)) in nsm_get_handle()