diff options
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/pci/drm/ttm/ttm_bo.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/sys/dev/pci/drm/ttm/ttm_bo.c b/sys/dev/pci/drm/ttm/ttm_bo.c index 9d1942f8c14..30e1eb9c20f 100644 --- a/sys/dev/pci/drm/ttm/ttm_bo.c +++ b/sys/dev/pci/drm/ttm/ttm_bo.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ttm_bo.c,v 1.7 2014/02/10 02:35:09 jsg Exp $ */ +/* $OpenBSD: ttm_bo.c,v 1.8 2014/04/12 06:08:22 jsg Exp $ */ /************************************************************************** * * Copyright (c) 2006-2009 VMware, Inc., Palo Alto, CA., USA @@ -450,9 +450,11 @@ static int ttm_bo_handle_move_mem(struct ttm_buffer_object *bo, moved: if (bo->evicted) { - ret = bdev->driver->invalidate_caches(bdev, bo->mem.placement); - if (ret) - printf("Can not flush read caches\n"); + if (bdev->driver->invalidate_caches) { + ret = bdev->driver->invalidate_caches(bdev, bo->mem.placement); + if (ret) + printf("Can not flush read caches\n"); + } bo->evicted = false; } |