public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* register_filesystem(): Why does it return -EBUSY?
@ 2005-10-30  5:45 Hareesh Nagarajan
  0 siblings, 0 replies; only message in thread
From: Hareesh Nagarajan @ 2005-10-30  5:45 UTC (permalink / raw)
  To: linux-kernel

If we have a look at the register_filesystem() function defined in 
fs/filesystems.c, we see that if a filesystem with a same name has 
already been registered then find_filesystem will return NON-NULL 
otherwise it will return NULL. So shouldn't 'res' be set to -EEXIST 
instead of -EBUSY? What is the reasoning behind register_filesystem 
returning -EBUSY for this particular condition?

int register_filesystem(struct file_system_type * fs) { ...
         struct file_system_type ** p;
	...
         p = find_filesystem(fs->name);
         if (*p)
                 res = -EBUSY; <-- Shouldn't this be -EEXIST?
         else
                 *p = fs;
	...
	return res;
}

Thanks,

Hareesh Nagarajan

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2005-10-30  5:55 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-10-30  5:45 register_filesystem(): Why does it return -EBUSY? Hareesh Nagarajan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox