/* Create devtmpfs instance, driver-core devices will add their device nodes here.  */
int __init devtmpfs_init(void)
/* Create devtmpfs instance, driver-core devices will add their device nodes here.  */
int __init devtmpfs_init(void)
{
	int err;
	struct vfsmount *mnt;
	char options[] = "mode=0755";
	err = register_filesystem(&dev_fs_type);
	if (err) {
		printk(KERN_ERR "devtmpfs: unable to register devtmpfs "
		       "type %i\n", err);
		return err;
	}
	mnt = kern_mount_data(&dev_fs_type, options);
	if (IS_ERR(mnt)) {
		err = PTR_ERR(mnt);
		printk(KERN_ERR "devtmpfs: unable to create devtmpfs %i\n", err);
		unregister_filesystem(&dev_fs_type);
		return err;
	}
	dev_mnt = mnt;
	printk(KERN_INFO "devtmpfs: initialized\n");
	return 0;
}