Changeset 2703
- Timestamp:
- 03/15/08 17:05:49 (8 months ago)
- Files:
-
- trunk/src/vdevmap.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/src/vdevmap.c
r2615 r2703 66 66 " --flags <flags> Set the specified flags\n" 67 67 " --open Allow opening of the device\n" 68 " --create If SECURE_MKNOD is given, allow mknod(2)\n"68 " --create If CAP_MKNOD is given, allow mknod(2)\n" 69 69 " --device <dev> Device to apply the command to\n" 70 70 " --remap Remap the device to the target\n" 71 71 " --target <dev> Target for --remap\n" 72 "\n" 73 "EXAMPLES\n" 74 " Remap /dev/hda1 to /dev/vroot1 for xid 42\n" 75 " vdevmap --xid 42 --set --open --device /dev/hda1 --target /dev/vroot1 --remap\n" 76 " Let xid 42 create all device nodes\n" 77 " vdevmap --xid 42 --set --open --create --target /dev/null\n" 78 " vdevmap --xid 42 --set --open --create --target /dev/root\n" 79 " Let xid 43 create just /dev/null\n" 80 " vdevmap --xid 43 --set --open --create --device /dev/null\n" 72 81 "\n" 73 82 "Please report bugs to " PACKAGE_BUGREPORT "\n"); … … 137 146 if (do_remap) flags |= VC_DATTR_REMAP; 138 147 139 if ( target && !do_remap)140 WRITE_MSG(2, " Target specified without --remap; try '--help' for more information\n");148 if (!target && do_remap) 149 WRITE_MSG(2, "Remapping specified without a target; try '--help' for more information\n"); 141 150 else if (xid==VC_NOCTX) 142 151 WRITE_MSG(2, "No xid specified; try '--help' for more information\n"); 143 152 else if (optind!=argc) 144 153 WRITE_MSG(2, "Unused argument(s); try '--help' for more information\n"); 154 else if (!device && !target) 155 WRITE_MSG(2, "Device and target are missing; try '--help' for more information\n"); 145 156 else if (set && vc_set_mapping(xid, device, target, flags)==-1) 146 157 perror("vc_set_mapping()");
