/* The profiling data set associated with this node is being unloaded. Store a copy of the profiling data and turn this node into a "ghost".  */
static int ghost_node(struct gcov_node *node)
/* The profiling data set associated with this node is being unloaded. Store a copy of the profiling data and turn this node into a "ghost".  */
static int ghost_node(struct gcov_node *node)
{
	node->ghost = gcov_info_dup(node->info);
	if (!node->ghost) {
		pr_warning("could not save data for '%s' (out of memory)\n",
			   node->info->filename);
		return -ENOMEM;
	}
	node->info = NULL;
	return 0;
}