| 176 | #define TCON_WRITE(sc, reg, val) bus_write_4((sc)->res[1], (reg), (val)) |
| 177 | |
| 178 | static int |
| 179 | a10fb_allocfb(struct a10fb_softc *sc) |
| 180 | { |
| 181 | sc->vaddr = kmem_alloc_contig(sc->fbsize, M_NOWAIT | M_ZERO, 0, ~0, |
| 182 | FB_ALIGN, 0, VM_MEMATTR_WRITE_COMBINING); |
| 183 | if (sc->vaddr == 0) { |
| 184 | device_printf(sc->dev, "failed to allocate FB memory\n"); |
| 185 | return (ENOMEM); |
| 186 | } |
| 187 | sc->paddr = pmap_kextract(sc->vaddr); |
| 188 | |
| 189 | return (0); |
| 190 | } |
| 191 | |
| 192 | static void |
| 193 | a10fb_freefb(struct a10fb_softc *sc) |
no test coverage detected