xref: /netbsd-src/external/gpl2/lvm2/dist/libdm/libdm-common.h (revision 7c604eea85b4f330dc75ffe65e947f4d73758aa0)
1*7c604eeaShaad /*	$NetBSD: libdm-common.h,v 1.1.1.2 2009/12/02 00:26:05 haad Exp $	*/
256a34939Shaad 
356a34939Shaad /*
456a34939Shaad  * Copyright (C) 2001-2004 Sistina Software, Inc. All rights reserved.
556a34939Shaad  * Copyright (C) 2004-2007 Red Hat, Inc. All rights reserved.
656a34939Shaad  *
756a34939Shaad  * This file is part of the device-mapper userspace tools.
856a34939Shaad  *
956a34939Shaad  * This copyrighted material is made available to anyone wishing to use,
1056a34939Shaad  * modify, copy, or redistribute it subject to the terms and conditions
1156a34939Shaad  * of the GNU Lesser General Public License v.2.1.
1256a34939Shaad  *
1356a34939Shaad  * You should have received a copy of the GNU Lesser General Public License
1456a34939Shaad  * along with this program; if not, write to the Free Software Foundation,
1556a34939Shaad  * Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
1656a34939Shaad  */
1756a34939Shaad 
1856a34939Shaad #ifndef LIB_DMCOMMON_H
1956a34939Shaad #define LIB_DMCOMMON_H
2056a34939Shaad 
2156a34939Shaad #include "libdevmapper.h"
2256a34939Shaad 
2356a34939Shaad struct target *create_target(uint64_t start,
2456a34939Shaad 			     uint64_t len,
2556a34939Shaad 			     const char *type, const char *params);
2656a34939Shaad 
2756a34939Shaad int add_dev_node(const char *dev_name, uint32_t minor, uint32_t major,
28*7c604eeaShaad 		 uid_t uid, gid_t gid, mode_t mode, int check_udev);
29*7c604eeaShaad int rm_dev_node(const char *dev_name, int check_udev);
30*7c604eeaShaad int rename_dev_node(const char *old_name, const char *new_name,
31*7c604eeaShaad 		    int check_udev);
3256a34939Shaad int get_dev_node_read_ahead(const char *dev_name, uint32_t *read_ahead);
3356a34939Shaad int set_dev_node_read_ahead(const char *dev_name, uint32_t read_ahead,
3456a34939Shaad 			    uint32_t read_ahead_flags);
3556a34939Shaad void update_devs(void);
3656a34939Shaad 
3756a34939Shaad #endif
38