mtrr.h 643 B

1234567891011121314
  1. /* MTRR write-combining for MMIO framebuffer ranges. */
  2. #ifndef MTRR_H
  3. #define MTRR_H
  4. /* Program one variable-range MTRR as write-combining over [base, base+size),
  5. * or reuse an entry an earlier boot already left there. Returns 1 when a WC
  6. * range covering the request is in place and fills wc_base and wc_size with the
  7. * range that entry actually covers (it is size-aligned and rounded up);
  8. * returns 0 if the CPU lacks MTRR, has no free variable ranges, or the range
  9. * cannot be covered by a single size-aligned region. */
  10. int mtrr_set_wc(unsigned int base, unsigned int size,
  11. unsigned int *wc_base, unsigned int *wc_size);
  12. #endif