Lines Matching defs:device

31 # include <device.h>
50 /* TFTP should come first because others don't handle net device. */
1094 /* XX used for device completion in 'set_device' and 'print_completions' */
1106 set_device (char *device)
1109 /* In Stage 1.5, the first 4 bytes of FILENAME has a device number. */
1110 unsigned long dev = *((unsigned long *) device);
1123 return device + sizeof (unsigned long);
1135 if (*device == '(' && !*(device + 1))
1137 return device + 1;
1139 if (*device == '(' && *(++device))
1141 if (*device != ',' && *device != ')')
1143 char ch = *device;
1145 if (*device == 'f' || *device == 'h'
1146 || (*device == 'n' && network_ready)
1147 || (*device == 'c' && cdrom_drive != GRUB_INVALID_DRIVE))
1149 if (*device == 'f' || *device == 'h'
1150 || (*device == 'c' && cdrom_drive != GRUB_INVALID_DRIVE))
1155 if (!*(device + 1))
1157 device++;
1158 *device++ = 'd';
1159 *device = '\0';
1160 return device;
1162 else if (*(device + 1) == 'd' && !*(device + 2))
1163 return device + 2;
1166 if ((*device == 'f'
1167 || *device == 'h'
1169 || (*device == 'n' && network_ready)
1171 || (*device == 'c' && cdrom_drive != GRUB_INVALID_DRIVE))
1172 && (device += 2, (*(device - 1) != 'd')))
1185 safe_parse_maxint (&device, (int *) &current_drive);
1197 if (*device == ')')
1202 else if (*device == ',')
1207 device++;
1209 if (*device >= '0' && *device <= '9')
1215 || !safe_parse_maxint (&device, (int *) &current_partition)
1224 if (*device == ',')
1225 device++;
1227 if (*device >= 'a' && *device <= 'p')
1229 current_partition = (((*(device++) - 'a') << 8)
1233 else if (*device >= 'a' && *device <= 'p')
1236 current_partition = ((*(device++) - 'a') << 8) | 0xFF00FF;
1239 if (*device == ')')
1256 return device + 1;
1259 if (!*device)
1270 * This performs a "mount" on the current device, both drive and partition
1321 * Set BSD boot device.
1468 * This lists the possible completions of a device string, filename, or