Lines Matching full:off
387 static int aplic_mmio_read_offset(struct kvm *kvm, gpa_t off, u32 *val32) in aplic_mmio_read_offset() argument
392 if ((off & 0x3) != 0) in aplic_mmio_read_offset()
395 if (off == APLIC_DOMAINCFG) { in aplic_mmio_read_offset()
398 } else if ((off >= APLIC_SOURCECFG_BASE) && in aplic_mmio_read_offset()
399 (off < (APLIC_SOURCECFG_BASE + (aplic->nr_irqs - 1) * 4))) { in aplic_mmio_read_offset()
400 i = ((off - APLIC_SOURCECFG_BASE) >> 2) + 1; in aplic_mmio_read_offset()
402 } else if ((off >= APLIC_SETIP_BASE) && in aplic_mmio_read_offset()
403 (off < (APLIC_SETIP_BASE + aplic->nr_words * 4))) { in aplic_mmio_read_offset()
404 i = (off - APLIC_SETIP_BASE) >> 2; in aplic_mmio_read_offset()
406 } else if (off == APLIC_SETIPNUM) { in aplic_mmio_read_offset()
408 } else if ((off >= APLIC_CLRIP_BASE) && in aplic_mmio_read_offset()
409 (off < (APLIC_CLRIP_BASE + aplic->nr_words * 4))) { in aplic_mmio_read_offset()
410 i = (off - APLIC_CLRIP_BASE) >> 2; in aplic_mmio_read_offset()
412 } else if (off == APLIC_CLRIPNUM) { in aplic_mmio_read_offset()
414 } else if ((off >= APLIC_SETIE_BASE) && in aplic_mmio_read_offset()
415 (off < (APLIC_SETIE_BASE + aplic->nr_words * 4))) { in aplic_mmio_read_offset()
416 i = (off - APLIC_SETIE_BASE) >> 2; in aplic_mmio_read_offset()
418 } else if (off == APLIC_SETIENUM) { in aplic_mmio_read_offset()
420 } else if ((off >= APLIC_CLRIE_BASE) && in aplic_mmio_read_offset()
421 (off < (APLIC_CLRIE_BASE + aplic->nr_words * 4))) { in aplic_mmio_read_offset()
423 } else if (off == APLIC_CLRIENUM) { in aplic_mmio_read_offset()
425 } else if (off == APLIC_SETIPNUM_LE) { in aplic_mmio_read_offset()
427 } else if (off == APLIC_SETIPNUM_BE) { in aplic_mmio_read_offset()
429 } else if (off == APLIC_GENMSI) { in aplic_mmio_read_offset()
431 } else if ((off >= APLIC_TARGET_BASE) && in aplic_mmio_read_offset()
432 (off < (APLIC_TARGET_BASE + (aplic->nr_irqs - 1) * 4))) { in aplic_mmio_read_offset()
433 i = ((off - APLIC_TARGET_BASE) >> 2) + 1; in aplic_mmio_read_offset()
452 static int aplic_mmio_write_offset(struct kvm *kvm, gpa_t off, u32 val32) in aplic_mmio_write_offset() argument
457 if ((off & 0x3) != 0) in aplic_mmio_write_offset()
460 if (off == APLIC_DOMAINCFG) { in aplic_mmio_write_offset()
463 } else if ((off >= APLIC_SOURCECFG_BASE) && in aplic_mmio_write_offset()
464 (off < (APLIC_SOURCECFG_BASE + (aplic->nr_irqs - 1) * 4))) { in aplic_mmio_write_offset()
465 i = ((off - APLIC_SOURCECFG_BASE) >> 2) + 1; in aplic_mmio_write_offset()
467 } else if ((off >= APLIC_SETIP_BASE) && in aplic_mmio_write_offset()
468 (off < (APLIC_SETIP_BASE + aplic->nr_words * 4))) { in aplic_mmio_write_offset()
469 i = (off - APLIC_SETIP_BASE) >> 2; in aplic_mmio_write_offset()
471 } else if (off == APLIC_SETIPNUM) { in aplic_mmio_write_offset()
473 } else if ((off >= APLIC_CLRIP_BASE) && in aplic_mmio_write_offset()
474 (off < (APLIC_CLRIP_BASE + aplic->nr_words * 4))) { in aplic_mmio_write_offset()
475 i = (off - APLIC_CLRIP_BASE) >> 2; in aplic_mmio_write_offset()
477 } else if (off == APLIC_CLRIPNUM) { in aplic_mmio_write_offset()
479 } else if ((off >= APLIC_SETIE_BASE) && in aplic_mmio_write_offset()
480 (off < (APLIC_SETIE_BASE + aplic->nr_words * 4))) { in aplic_mmio_write_offset()
481 i = (off - APLIC_SETIE_BASE) >> 2; in aplic_mmio_write_offset()
483 } else if (off == APLIC_SETIENUM) { in aplic_mmio_write_offset()
485 } else if ((off >= APLIC_CLRIE_BASE) && in aplic_mmio_write_offset()
486 (off < (APLIC_CLRIE_BASE + aplic->nr_words * 4))) { in aplic_mmio_write_offset()
487 i = (off - APLIC_CLRIE_BASE) >> 2; in aplic_mmio_write_offset()
489 } else if (off == APLIC_CLRIENUM) { in aplic_mmio_write_offset()
491 } else if (off == APLIC_SETIPNUM_LE) { in aplic_mmio_write_offset()
493 } else if (off == APLIC_SETIPNUM_BE) { in aplic_mmio_write_offset()
495 } else if (off == APLIC_GENMSI) { in aplic_mmio_write_offset()
501 } else if ((off >= APLIC_TARGET_BASE) && in aplic_mmio_write_offset()
502 (off < (APLIC_TARGET_BASE + (aplic->nr_irqs - 1) * 4))) { in aplic_mmio_write_offset()
503 i = ((off - APLIC_TARGET_BASE) >> 2) + 1; in aplic_mmio_write_offset()