summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGurchetan Singh <gurchetansingh@chromium.org>2017-09-28 15:12:01 -0700
committerchrome-bot <chrome-bot@chromium.org>2017-09-28 23:26:39 -0700
commit2426d0373145f74c7f8809786f7171c688fcddb2 (patch)
tree158d3830c2a6c9729c4066dd670b00e65a5f9420
parent5af202315b9e595a007e74f67dbc0d521c2aa05d (diff)
minigbm: clang-format and various nits
BUG=NONE TEST=emerge-eve {minigbm, arc-cros-gralloc} Change-Id: I3418680828e7b69c6b5e1c56dcdba171aba92473 Reviewed-on: https://chromium-review.googlesource.com/691420 Commit-Ready: Gurchetan Singh <gurchetansingh@chromium.org> Tested-by: Gurchetan Singh <gurchetansingh@chromium.org> Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
-rw-r--r--mediatek.c1
-rw-r--r--rockchip.c5
-rw-r--r--tegra.c3
3 files changed, 2 insertions, 7 deletions
diff --git a/mediatek.c b/mediatek.c
index 46c37b3..d6ec521 100644
--- a/mediatek.c
+++ b/mediatek.c
@@ -125,7 +125,6 @@ static int mediatek_bo_unmap(struct bo *bo, struct map_info *data)
static int mediatek_bo_flush(struct bo *bo, struct map_info *data)
{
struct mediatek_private_map_data *priv = data->priv;
-
if (priv)
memcpy(priv->gem_addr, priv->cached_addr, bo->total_size);
diff --git a/rockchip.c b/rockchip.c
index 816d704..c6fc9ef 100644
--- a/rockchip.c
+++ b/rockchip.c
@@ -134,7 +134,7 @@ static int rockchip_init(struct driver *drv)
/* Camera ISP supports only NV12 output. */
drv_modify_combination(drv, DRM_FORMAT_NV12, &metadata,
- BO_USE_CAMERA_READ | BO_USE_CAMERA_WRITE);
+ BO_USE_CAMERA_READ | BO_USE_CAMERA_WRITE);
/*
* R8 format is used for Android's HAL_PIXEL_FORMAT_BLOB and is used for JPEG snapshots
* from camera.
@@ -161,7 +161,6 @@ static int rockchip_init(struct driver *drv)
static bool has_modifier(const uint64_t *list, uint32_t count, uint64_t modifier)
{
uint32_t i;
-
for (i = 0; i < count; i++)
if (list[i] == modifier)
return true;
@@ -235,7 +234,6 @@ static int rockchip_bo_create(struct bo *bo, uint32_t width, uint32_t height, ui
uint32_t flags)
{
uint64_t modifiers[] = { DRM_FORMAT_MOD_NONE };
-
return rockchip_bo_create_with_modifiers(bo, width, height, format, modifiers,
ARRAY_SIZE(modifiers));
}
@@ -292,7 +290,6 @@ static int rockchip_bo_unmap(struct bo *bo, struct map_info *data)
static int rockchip_bo_flush(struct bo *bo, struct map_info *data)
{
struct rockchip_private_map_data *priv = data->priv;
-
if (priv)
memcpy(priv->gem_addr, priv->cached_addr, bo->total_size);
diff --git a/tegra.c b/tegra.c
index 2fac455..ad9f871 100644
--- a/tegra.c
+++ b/tegra.c
@@ -348,8 +348,7 @@ static int tegra_bo_flush(struct bo *bo, struct map_info *data)
struct tegra_private_map_data *priv = data->priv;
if (priv && priv->prot & PROT_WRITE)
- transfer_tiled_memory(bo, priv->tiled, priv->untiled,
- TEGRA_WRITE_TILED_BUFFER);
+ transfer_tiled_memory(bo, priv->tiled, priv->untiled, TEGRA_WRITE_TILED_BUFFER);
return 0;
}