Lines Matching +full:es +full:- +full:enable

1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * eisa_enumerator.c - provide support for EISA adapters in PA-RISC machines
36 * little-endian on the big-endian PAROSC */
92 res->name = name; in configure_memory()
93 res->start = mem_parent->start + get_24(buf+len+2); in configure_memory()
94 res->end = res->start + get_16(buf+len+5)*1024; in configure_memory()
95 res->flags = IORESOURCE_MEM; in configure_memory()
182 res->name = board; in configure_port()
183 res->start = get_16(buf+len+1); in configure_port()
184 res->end = get_16(buf+len+1)+(c&HPEE_PORT_SIZE_MASK)+1; in configure_port()
185 res->flags = IORESOURCE_IO; in configure_port()
206 * I assume that there are and- and or- masks
303 /* the init field seems to be a two-byte field in configure_function()
304 * which is non-zero if there are an other function following in configure_function()
314 struct eeprom_eisa_slot_info *es, in parse_slot_config() argument
330 return -1; in parse_slot_config()
332 print_eisa_id(board, es->eisa_slot_id); in parse_slot_config()
334 slot, board, es->flags&HPEE_FLAG_BOARD_IS_ISA ? "ISA" : "EISA"); in parse_slot_config()
336 maxlen = es->config_data_length < HPEE_MAX_LENGTH ? in parse_slot_config()
337 es->config_data_length : HPEE_MAX_LENGTH; in parse_slot_config()
338 while ((pos < maxlen) && (num_func <= es->num_functions)) { in parse_slot_config()
355 printk("function %d have free-form configuration, skipping ", in parse_slot_config()
398 num_func, pos-p0, function_len); in parse_slot_config()
399 res=-1; in parse_slot_config()
409 if (pos != es->config_data_length) { in parse_slot_config()
411 pos, es->config_data_length); in parse_slot_config()
412 res=-1; in parse_slot_config()
415 if (num_func != es->num_functions) { in parse_slot_config()
417 num_func, es->num_functions); in parse_slot_config()
418 res=-2; in parse_slot_config()
425 static int init_slot(int slot, struct eeprom_eisa_slot_info *es) in init_slot() argument
431 if (!(es->slot_info&HPEE_SLOT_INFO_NO_READID)) { in init_slot()
437 if (es->eisa_slot_id == 0xffffffff) in init_slot()
438 return -1; in init_slot()
446 print_eisa_id(id_string, es->eisa_slot_id); in init_slot()
449 return -1; in init_slot()
452 if (es->eisa_slot_id != id) { in init_slot()
457 print_eisa_id(id_string, es->eisa_slot_id); in init_slot()
460 return -1; in init_slot()
465 /* now: we need to enable the board if in init_slot()
470 if (es->slot_features & HPEE_SLOT_FEATURES_ENABLE) { in init_slot()
471 /* enable board */ in init_slot()
494 for (i=0;i<eh->num_slots;i++) { in eisa_enumerator()
495 struct eeprom_eisa_slot_info *es; in eisa_enumerator() local
497 es = (struct eeprom_eisa_slot_info*) in eisa_enumerator()
500 if (-1==init_slot(i+1, es)) { in eisa_enumerator()
504 if (es->config_data_offset < HPEE_MAX_LENGTH) { in eisa_enumerator()
505 if (parse_slot_config(i+1, &eeprom_buf[es->config_data_offset], in eisa_enumerator()
506 es, io_parent, mem_parent)) { in eisa_enumerator()
507 return -1; in eisa_enumerator()
510 printk (KERN_WARNING "EISA EEPROM offset 0x%x out of range\n",es->config_data_offset); in eisa_enumerator()
511 return -1; in eisa_enumerator()
514 return eh->num_slots; in eisa_enumerator()