Lines Matching refs:bfr
334 struct apple_rtkit_shmem *bfr) in apple_rtkit_free_buffer() argument
336 if (bfr->size == 0) in apple_rtkit_free_buffer()
340 rtk->ops->shmem_destroy(rtk->cookie, bfr); in apple_rtkit_free_buffer()
341 else if (bfr->buffer) in apple_rtkit_free_buffer()
342 dma_free_coherent(rtk->dev, bfr->size, bfr->buffer, bfr->iova); in apple_rtkit_free_buffer()
344 bfr->buffer = NULL; in apple_rtkit_free_buffer()
345 bfr->iomem = NULL; in apple_rtkit_free_buffer()
346 bfr->iova = 0; in apple_rtkit_free_buffer()
347 bfr->size = 0; in apple_rtkit_free_buffer()
348 bfr->is_mapped = false; in apple_rtkit_free_buffer()
352 struct apple_rtkit_shmem *bfr, size_t offset, in apple_rtkit_memcpy() argument
355 if (bfr->iomem) in apple_rtkit_memcpy()
356 memcpy_fromio(dst, bfr->iomem + offset, len); in apple_rtkit_memcpy()
358 memcpy(dst, bfr->buffer + offset, len); in apple_rtkit_memcpy()
364 u8 *bfr; in apple_rtkit_crashlog_rx() local
385 bfr = kzalloc(rtk->crashlog_buffer.size, GFP_KERNEL); in apple_rtkit_crashlog_rx()
386 if (bfr) { in apple_rtkit_crashlog_rx()
387 apple_rtkit_memcpy(rtk, bfr, &rtk->crashlog_buffer, 0, in apple_rtkit_crashlog_rx()
389 apple_rtkit_crashlog_dump(rtk, bfr, rtk->crashlog_buffer.size); in apple_rtkit_crashlog_rx()
397 rtk->ops->crashed(rtk->cookie, bfr, rtk->crashlog_buffer.size); in apple_rtkit_crashlog_rx()
399 kfree(bfr); in apple_rtkit_crashlog_rx()