diff options
author | Huang Rui <ray.huang@amd.com> | 2017-04-17 10:32:52 +0300 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2017-04-29 00:32:37 +0300 |
commit | aef1ba58f5c60ec2de38258cb76db7842ccb6e1b (patch) | |
tree | 69ea46eac00e5f97bf93696e3bf6c9f5b11e3e79 /drivers/gpu/drm/ttm | |
parent | b3124dfcce8147e1340a06952f32443dc7e102b1 (diff) | |
download | linux-aef1ba58f5c60ec2de38258cb76db7842ccb6e1b.tar.xz |
drm/ttm: cleanup unuse ret value
The ret must be 0 here, otherwise, the function will return after init_mem_type.
Signed-off-by: Huang Rui <ray.huang@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/ttm')
-rw-r--r-- | drivers/gpu/drm/ttm/ttm_bo.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c index e44626a2e698..a6d7fcb99c0b 100644 --- a/drivers/gpu/drm/ttm/ttm_bo.c +++ b/drivers/gpu/drm/ttm/ttm_bo.c @@ -1394,7 +1394,7 @@ EXPORT_SYMBOL(ttm_bo_evict_mm); int ttm_bo_init_mm(struct ttm_bo_device *bdev, unsigned type, unsigned long p_size) { - int ret = -EINVAL; + int ret; struct ttm_mem_type_manager *man; unsigned i; @@ -1412,7 +1412,6 @@ int ttm_bo_init_mm(struct ttm_bo_device *bdev, unsigned type, return ret; man->bdev = bdev; - ret = 0; if (type != TTM_PL_SYSTEM) { ret = (*man->func->init)(man, p_size); if (ret) |