Lines Matching +full:neo +full:- +full:8
1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * pnpbios -- PnP BIOS driver
5 * This driver provides access to Plug-'n'-Play services provided by
20 * by Adam Belay <ambx1@neo.rr.com>
25 * Adam Belay - <ambx1@neo.rr.com> - March 16, 2003
93 return -ENOMEM; in pnp_dock_event()
96 return -ENOMEM; in pnp_dock_event()
112 /* hint that policy agent should enter no-stdout debug mode */ in pnp_dock_event()
115 /* extensible set of named bus-specific parameters, in pnp_dock_event()
127 info->location_id, info->serial, info->capabilities); in pnp_dock_event()
142 int docked = -1, d = 0; in pnp_dock_thread()
191 u8 nodenum = dev->number; in pnpbios_get_resources()
195 return -EPERM; in pnpbios_get_resources()
197 pnp_dbg(&dev->dev, "get resources\n"); in pnpbios_get_resources()
200 return -1; in pnpbios_get_resources()
203 return -ENODEV; in pnpbios_get_resources()
206 dev->active = pnp_is_active(dev); in pnpbios_get_resources()
213 u8 nodenum = dev->number; in pnpbios_set_resources()
218 return -EPERM; in pnpbios_set_resources()
220 pnp_dbg(&dev->dev, "set resources\n"); in pnpbios_set_resources()
223 return -1; in pnpbios_set_resources()
226 return -ENODEV; in pnpbios_set_resources()
230 return -1; in pnpbios_set_resources()
232 ret = pnp_bios_set_dev_node(node->handle, (char)PNPMODE_DYNAMIC, node); in pnpbios_set_resources()
235 ret = -1; in pnpbios_set_resources()
241 unsigned char *p = (char *)node->data; in pnpbios_zero_data_stream()
242 unsigned char *end = (char *)(node->data + node->size); in pnpbios_zero_data_stream()
248 len = (p[2] << 8) | p[1]; in pnpbios_zero_data_stream()
267 u8 nodenum = dev->number; in pnpbios_disable_resources()
270 if (dev->flags & PNPBIOS_NO_DISABLE || !pnpbios_is_dynamic(dev)) in pnpbios_disable_resources()
271 return -EPERM; in pnpbios_disable_resources()
275 return -ENOMEM; in pnpbios_disable_resources()
279 return -ENODEV; in pnpbios_disable_resources()
283 ret = pnp_bios_set_dev_node(dev->number, (char)PNPMODE_DYNAMIC, node); in pnpbios_disable_resources()
286 ret = -1; in pnpbios_disable_resources()
302 char id[8]; in insert_device()
307 if (dev->number == node->handle) in insert_device()
308 return -EEXIST; in insert_device()
311 pnp_eisa_id_to_string(node->eisa_id & PNP_EISA_ID_MASK, id); in insert_device()
312 dev = pnp_alloc_dev(&pnpbios_protocol, node->handle, id); in insert_device()
314 return -ENOMEM; in insert_device()
317 dev->active = pnp_is_active(dev); in insert_device()
318 dev->flags = node->flags; in insert_device()
319 if (!(dev->flags & PNPBIOS_NO_CONFIG)) in insert_device()
320 dev->capabilities |= PNP_CONFIGURABLE; in insert_device()
321 if (!(dev->flags & PNPBIOS_NO_DISABLE) && pnpbios_is_dynamic(dev)) in insert_device()
322 dev->capabilities |= PNP_DISABLE; in insert_device()
323 dev->capabilities |= PNP_READ; in insert_device()
325 dev->capabilities |= PNP_WRITE; in insert_device()
326 if (dev->flags & PNPBIOS_REMOVABLE) in insert_device()
327 dev->capabilities |= PNP_REMOVABLE; in insert_device()
330 if (!dev->active) in insert_device()
335 put_device(&dev->dev); in insert_device()
405 invert = (strncmp(str, "no-", 3) == 0); in pnpbios_setup()
421 #define PNP_SIGNATURE (('$' << 0) + ('P' << 8) + ('n' << 16) + ('P' << 24))
432 * Search the defined area (0xf0000-0xffff0) for a valid PnP BIOS in pnpbios_probe_system()
439 if (check->fields.signature != PNP_SIGNATURE) in pnpbios_probe_system()
444 length = check->fields.length; in pnpbios_probe_system()
451 sum += check->chars[i]; in pnpbios_probe_system()
457 if (check->fields.version < 0x10) { in pnpbios_probe_system()
460 check->fields.version >> 4, in pnpbios_probe_system()
461 check->fields.version & 15); in pnpbios_probe_system()
466 check->fields.version >> 4, check->fields.version & 15, in pnpbios_probe_system()
467 check->fields.pm16cseg, check->fields.pm16offset, in pnpbios_probe_system()
468 check->fields.pm16dseg); in pnpbios_probe_system()
479 printk(KERN_WARNING "%s detected. Disabling PnPBIOS\n", d->ident); in exploding_pnp_bios()
512 return -ENODEV; in pnpbios_init()
519 return -ENODEV; in pnpbios_init()
525 return -ENODEV; in pnpbios_init()