[Mesa-dev] [PATCH 02/12] isl: prefix non-static API with isl_

Emil Velikov emil.l.velikov at gmail.com
Tue Oct 11 17:26:16 UTC 2016


From: Emil Velikov <emil.velikov at collabora.com>

The rest of ISL already follows this approach. Be consistent and resolve
the final references.

Signed-off-by: Emil Velikov <emil.velikov at collabora.com>
---
 src/intel/isl/isl.c      | 32 ++++++++++++++++----------------
 src/intel/isl/isl_gen4.c | 20 ++++++++++----------
 src/intel/isl/isl_gen4.h | 20 ++++++++++----------
 src/intel/isl/isl_gen6.c | 20 ++++++++++----------
 src/intel/isl/isl_gen6.h | 20 ++++++++++----------
 src/intel/isl/isl_gen7.c | 26 +++++++++++++-------------
 src/intel/isl/isl_gen7.h | 26 +++++++++++++-------------
 src/intel/isl/isl_gen8.c | 20 ++++++++++----------
 src/intel/isl/isl_gen8.h | 20 ++++++++++----------
 src/intel/isl/isl_gen9.c | 16 ++++++++--------
 src/intel/isl/isl_gen9.h | 12 ++++++------
 11 files changed, 116 insertions(+), 116 deletions(-)

diff --git a/src/intel/isl/isl.c b/src/intel/isl/isl.c
index 66e2df3..839bcfd 100644
--- a/src/intel/isl/isl.c
+++ b/src/intel/isl/isl.c
@@ -253,10 +253,10 @@ isl_surf_choose_tiling(const struct isl_device *dev,
    }
 
    if (ISL_DEV_GEN(dev) >= 6) {
-      gen6_filter_tiling(dev, info, &tiling_flags);
+      isl_gen6_filter_tiling(dev, info, &tiling_flags);
    } else {
       isl_finishme("%s: gen%u", __func__, ISL_DEV_GEN(dev));
-      gen6_filter_tiling(dev, info, &tiling_flags);
+      isl_gen6_filter_tiling(dev, info, &tiling_flags);
    }
 
    #define CHOOSE(__tiling) \
@@ -300,13 +300,13 @@ isl_choose_msaa_layout(const struct isl_device *dev,
                  enum isl_msaa_layout *msaa_layout)
 {
    if (ISL_DEV_GEN(dev) >= 8) {
-      return gen8_choose_msaa_layout(dev, info, tiling, msaa_layout);
+      return isl_gen8_choose_msaa_layout(dev, info, tiling, msaa_layout);
    } else if (ISL_DEV_GEN(dev) >= 7) {
-      return gen7_choose_msaa_layout(dev, info, tiling, msaa_layout);
+      return isl_gen7_choose_msaa_layout(dev, info, tiling, msaa_layout);
    } else if (ISL_DEV_GEN(dev) >= 6) {
-      return gen6_choose_msaa_layout(dev, info, tiling, msaa_layout);
+      return isl_gen6_choose_msaa_layout(dev, info, tiling, msaa_layout);
    } else {
-      return gen4_choose_msaa_layout(dev, info, tiling, msaa_layout);
+      return isl_gen4_choose_msaa_layout(dev, info, tiling, msaa_layout);
    }
 }
 
@@ -471,20 +471,20 @@ isl_choose_image_alignment_el(const struct isl_device *dev,
    }
 
    if (ISL_DEV_GEN(dev) >= 9) {
-      gen9_choose_image_alignment_el(dev, info, tiling, dim_layout,
-                                     msaa_layout, image_align_el);
+      isl_gen9_choose_image_alignment_el(dev, info, tiling, dim_layout,
+                                         msaa_layout, image_align_el);
    } else if (ISL_DEV_GEN(dev) >= 8) {
-      gen8_choose_image_alignment_el(dev, info, tiling, dim_layout,
-                                     msaa_layout, image_align_el);
+      isl_gen8_choose_image_alignment_el(dev, info, tiling, dim_layout,
+                                         msaa_layout, image_align_el);
    } else if (ISL_DEV_GEN(dev) >= 7) {
-      gen7_choose_image_alignment_el(dev, info, tiling, dim_layout,
-                                     msaa_layout, image_align_el);
+      isl_gen7_choose_image_alignment_el(dev, info, tiling, dim_layout,
+                                          msaa_layout, image_align_el);
    } else if (ISL_DEV_GEN(dev) >= 6) {
-      gen6_choose_image_alignment_el(dev, info, tiling, dim_layout,
-                                     msaa_layout, image_align_el);
+      isl_gen6_choose_image_alignment_el(dev, info, tiling, dim_layout,
+                                         msaa_layout, image_align_el);
    } else {
-      gen4_choose_image_alignment_el(dev, info, tiling, dim_layout,
-                                     msaa_layout, image_align_el);
+      isl_gen4_choose_image_alignment_el(dev, info, tiling, dim_layout,
+                                         msaa_layout, image_align_el);
    }
 }
 
diff --git a/src/intel/isl/isl_gen4.c b/src/intel/isl/isl_gen4.c
index 1d584fc..9fed454 100644
--- a/src/intel/isl/isl_gen4.c
+++ b/src/intel/isl/isl_gen4.c
@@ -25,10 +25,10 @@
 #include "isl_priv.h"
 
 bool
-gen4_choose_msaa_layout(const struct isl_device *dev,
-                        const struct isl_surf_init_info *info,
-                        enum isl_tiling tiling,
-                        enum isl_msaa_layout *msaa_layout)
+isl_gen4_choose_msaa_layout(const struct isl_device *dev,
+                            const struct isl_surf_init_info *info,
+                            enum isl_tiling tiling,
+                            enum isl_msaa_layout *msaa_layout)
 {
    /* Gen4 and Gen5 do not support MSAA */
    assert(info->samples >= 1);
@@ -38,12 +38,12 @@ gen4_choose_msaa_layout(const struct isl_device *dev,
 }
 
 void
-gen4_choose_image_alignment_el(const struct isl_device *dev,
-                               const struct isl_surf_init_info *restrict info,
-                               enum isl_tiling tiling,
-                               enum isl_dim_layout dim_layout,
-                               enum isl_msaa_layout msaa_layout,
-                               struct isl_extent3d *image_align_el)
+isl_gen4_choose_image_alignment_el(const struct isl_device *dev,
+                                   const struct isl_surf_init_info *restrict info,
+                                   enum isl_tiling tiling,
+                                   enum isl_dim_layout dim_layout,
+                                   enum isl_msaa_layout msaa_layout,
+                                   struct isl_extent3d *image_align_el)
 {
    assert(info->samples == 1);
    assert(msaa_layout == ISL_MSAA_LAYOUT_NONE);
diff --git a/src/intel/isl/isl_gen4.h b/src/intel/isl/isl_gen4.h
index 48175ca..2a47d19 100644
--- a/src/intel/isl/isl_gen4.h
+++ b/src/intel/isl/isl_gen4.h
@@ -30,18 +30,18 @@ extern "C" {
 #endif
 
 bool
-gen4_choose_msaa_layout(const struct isl_device *dev,
-                        const struct isl_surf_init_info *info,
-                        enum isl_tiling tiling,
-                        enum isl_msaa_layout *msaa_layout);
+isl_gen4_choose_msaa_layout(const struct isl_device *dev,
+                            const struct isl_surf_init_info *info,
+                            enum isl_tiling tiling,
+                            enum isl_msaa_layout *msaa_layout);
 
 void
-gen4_choose_image_alignment_el(const struct isl_device *dev,
-                               const struct isl_surf_init_info *restrict info,
-                               enum isl_tiling tiling,
-                               enum isl_dim_layout dim_layout,
-                               enum isl_msaa_layout msaa_layout,
-                               struct isl_extent3d *image_align_el);
+isl_gen4_choose_image_alignment_el(const struct isl_device *dev,
+                                   const struct isl_surf_init_info *restrict info,
+                                   enum isl_tiling tiling,
+                                   enum isl_dim_layout dim_layout,
+                                   enum isl_msaa_layout msaa_layout,
+                                   struct isl_extent3d *image_align_el);
 
 #ifdef __cplusplus
 }
diff --git a/src/intel/isl/isl_gen6.c b/src/intel/isl/isl_gen6.c
index 07c08f6..b746903 100644
--- a/src/intel/isl/isl_gen6.c
+++ b/src/intel/isl/isl_gen6.c
@@ -25,10 +25,10 @@
 #include "isl_priv.h"
 
 bool
-gen6_choose_msaa_layout(const struct isl_device *dev,
-                  const struct isl_surf_init_info *info,
-                  enum isl_tiling tiling,
-                  enum isl_msaa_layout *msaa_layout)
+isl_gen6_choose_msaa_layout(const struct isl_device *dev,
+                            const struct isl_surf_init_info *info,
+                            enum isl_tiling tiling,
+                            enum isl_msaa_layout *msaa_layout)
 {
    assert(ISL_DEV_GEN(dev) == 6);
    assert(info->samples >= 1);
@@ -66,12 +66,12 @@ gen6_choose_msaa_layout(const struct isl_device *dev,
 }
 
 void
-gen6_choose_image_alignment_el(const struct isl_device *dev,
-                               const struct isl_surf_init_info *restrict info,
-                               enum isl_tiling tiling,
-                               enum isl_dim_layout dim_layout,
-                               enum isl_msaa_layout msaa_layout,
-                               struct isl_extent3d *image_align_el)
+isl_gen6_choose_image_alignment_el(const struct isl_device *dev,
+                                   const struct isl_surf_init_info *restrict info,
+                                   enum isl_tiling tiling,
+                                   enum isl_dim_layout dim_layout,
+                                   enum isl_msaa_layout msaa_layout,
+                                   struct isl_extent3d *image_align_el)
 {
    /* Handled by isl_choose_image_alignment_el */
    assert(info->format != ISL_FORMAT_HIZ);
diff --git a/src/intel/isl/isl_gen6.h b/src/intel/isl/isl_gen6.h
index 04414c7..99b0b77 100644
--- a/src/intel/isl/isl_gen6.h
+++ b/src/intel/isl/isl_gen6.h
@@ -30,18 +30,18 @@ extern "C" {
 #endif
 
 bool
-gen6_choose_msaa_layout(const struct isl_device *dev,
-                        const struct isl_surf_init_info *info,
-                        enum isl_tiling tiling,
-                        enum isl_msaa_layout *msaa_layout);
+isl_gen6_choose_msaa_layout(const struct isl_device *dev,
+                            const struct isl_surf_init_info *info,
+                            enum isl_tiling tiling,
+                            enum isl_msaa_layout *msaa_layout);
 
 void
-gen6_choose_image_alignment_el(const struct isl_device *dev,
-                               const struct isl_surf_init_info *restrict info,
-                               enum isl_tiling tiling,
-                               enum isl_dim_layout dim_layout,
-                               enum isl_msaa_layout msaa_layout,
-                               struct isl_extent3d *image_align_el);
+isl_gen6_choose_image_alignment_el(const struct isl_device *dev,
+                                   const struct isl_surf_init_info *restrict info,
+                                   enum isl_tiling tiling,
+                                   enum isl_dim_layout dim_layout,
+                                   enum isl_msaa_layout msaa_layout,
+                                   struct isl_extent3d *image_align_el);
 
 #ifdef __cplusplus
 }
diff --git a/src/intel/isl/isl_gen7.c b/src/intel/isl/isl_gen7.c
index 805b62b..76213f8 100644
--- a/src/intel/isl/isl_gen7.c
+++ b/src/intel/isl/isl_gen7.c
@@ -25,10 +25,10 @@
 #include "isl_priv.h"
 
 bool
-gen7_choose_msaa_layout(const struct isl_device *dev,
-                        const struct isl_surf_init_info *info,
-                        enum isl_tiling tiling,
-                        enum isl_msaa_layout *msaa_layout)
+isl_gen7_choose_msaa_layout(const struct isl_device *dev,
+                            const struct isl_surf_init_info *info,
+                            enum isl_tiling tiling,
+                            enum isl_msaa_layout *msaa_layout)
 {
    bool require_array = false;
    bool require_interleaved = false;
@@ -184,9 +184,9 @@ gen7_format_needs_valign2(const struct isl_device *dev,
  * flags except ISL_TILING_X_BIT and ISL_TILING_LINEAR_BIT.
  */
 void
-gen6_filter_tiling(const struct isl_device *dev,
-                   const struct isl_surf_init_info *restrict info,
-                   isl_tiling_flags_t *flags)
+isl_gen6_filter_tiling(const struct isl_device *dev,
+                       const struct isl_surf_init_info *restrict info,
+                       isl_tiling_flags_t *flags)
 {
    /* IVB+ requires separate stencil */
    assert(ISL_DEV_USE_SEPARATE_STENCIL(dev));
@@ -384,12 +384,12 @@ gen7_choose_valign_el(const struct isl_device *dev,
 }
 
 void
-gen7_choose_image_alignment_el(const struct isl_device *dev,
-                               const struct isl_surf_init_info *restrict info,
-                               enum isl_tiling tiling,
-                               enum isl_dim_layout dim_layout,
-                               enum isl_msaa_layout msaa_layout,
-                               struct isl_extent3d *image_align_el)
+isl_gen7_choose_image_alignment_el(const struct isl_device *dev,
+                                   const struct isl_surf_init_info *restrict info,
+                                   enum isl_tiling tiling,
+                                   enum isl_dim_layout dim_layout,
+                                   enum isl_msaa_layout msaa_layout,
+                                   struct isl_extent3d *image_align_el)
 {
    /* Handled by isl_choose_image_alignment_el */
    assert(info->format != ISL_FORMAT_HIZ);
diff --git a/src/intel/isl/isl_gen7.h b/src/intel/isl/isl_gen7.h
index e35e2df..3c841a1 100644
--- a/src/intel/isl/isl_gen7.h
+++ b/src/intel/isl/isl_gen7.h
@@ -30,23 +30,23 @@ extern "C" {
 #endif
 
 void
-gen6_filter_tiling(const struct isl_device *dev,
-                   const struct isl_surf_init_info *restrict info,
-                   isl_tiling_flags_t *flags);
+isl_gen6_filter_tiling(const struct isl_device *dev,
+                       const struct isl_surf_init_info *restrict info,
+                       isl_tiling_flags_t *flags);
 
 bool
-gen7_choose_msaa_layout(const struct isl_device *dev,
-                        const struct isl_surf_init_info *info,
-                        enum isl_tiling tiling,
-                        enum isl_msaa_layout *msaa_layout);
+isl_gen7_choose_msaa_layout(const struct isl_device *dev,
+                            const struct isl_surf_init_info *info,
+                            enum isl_tiling tiling,
+                            enum isl_msaa_layout *msaa_layout);
 
 void
-gen7_choose_image_alignment_el(const struct isl_device *dev,
-                               const struct isl_surf_init_info *restrict info,
-                               enum isl_tiling tiling,
-                               enum isl_dim_layout dim_layout,
-                               enum isl_msaa_layout msaa_layout,
-                               struct isl_extent3d *image_align_el);
+isl_gen7_choose_image_alignment_el(const struct isl_device *dev,
+                                   const struct isl_surf_init_info *restrict info,
+                                   enum isl_tiling tiling,
+                                   enum isl_dim_layout dim_layout,
+                                   enum isl_msaa_layout msaa_layout,
+                                   struct isl_extent3d *image_align_el);
 
 #ifdef __cplusplus
 }
diff --git a/src/intel/isl/isl_gen8.c b/src/intel/isl/isl_gen8.c
index 2d7f41f..81c69dc 100644
--- a/src/intel/isl/isl_gen8.c
+++ b/src/intel/isl/isl_gen8.c
@@ -25,10 +25,10 @@
 #include "isl_priv.h"
 
 bool
-gen8_choose_msaa_layout(const struct isl_device *dev,
-                        const struct isl_surf_init_info *info,
-                        enum isl_tiling tiling,
-                        enum isl_msaa_layout *msaa_layout)
+isl_gen8_choose_msaa_layout(const struct isl_device *dev,
+                            const struct isl_surf_init_info *info,
+                            enum isl_tiling tiling,
+                            enum isl_msaa_layout *msaa_layout)
 {
    bool require_array = false;
    bool require_interleaved = false;
@@ -180,12 +180,12 @@ gen8_choose_valign_el(const struct isl_device *dev,
 }
 
 void
-gen8_choose_image_alignment_el(const struct isl_device *dev,
-                               const struct isl_surf_init_info *restrict info,
-                               enum isl_tiling tiling,
-                               enum isl_dim_layout dim_layout,
-                               enum isl_msaa_layout msaa_layout,
-                               struct isl_extent3d *image_align_el)
+isl_gen8_choose_image_alignment_el(const struct isl_device *dev,
+                                   const struct isl_surf_init_info *restrict info,
+                                   enum isl_tiling tiling,
+                                   enum isl_dim_layout dim_layout,
+                                   enum isl_msaa_layout msaa_layout,
+                                   struct isl_extent3d *image_align_el)
 {
    /* Handled by isl_choose_image_alignment_el */
    assert(info->format != ISL_FORMAT_HIZ);
diff --git a/src/intel/isl/isl_gen8.h b/src/intel/isl/isl_gen8.h
index 4699269..75b89cf 100644
--- a/src/intel/isl/isl_gen8.h
+++ b/src/intel/isl/isl_gen8.h
@@ -30,18 +30,18 @@ extern "C" {
 #endif
 
 bool
-gen8_choose_msaa_layout(const struct isl_device *dev,
-                        const struct isl_surf_init_info *info,
-                        enum isl_tiling tiling,
-                        enum isl_msaa_layout *msaa_layout);
+isl_gen8_choose_msaa_layout(const struct isl_device *dev,
+                            const struct isl_surf_init_info *info,
+                            enum isl_tiling tiling,
+                            enum isl_msaa_layout *msaa_layout);
 
 void
-gen8_choose_image_alignment_el(const struct isl_device *dev,
-                               const struct isl_surf_init_info *restrict info,
-                               enum isl_tiling tiling,
-                               enum isl_dim_layout dim_layout,
-                               enum isl_msaa_layout msaa_layout,
-                               struct isl_extent3d *image_align_el);
+isl_gen8_choose_image_alignment_el(const struct isl_device *dev,
+                                   const struct isl_surf_init_info *restrict info,
+                                   enum isl_tiling tiling,
+                                   enum isl_dim_layout dim_layout,
+                                   enum isl_msaa_layout msaa_layout,
+                                   struct isl_extent3d *image_align_el);
 
 #ifdef __cplusplus
 }
diff --git a/src/intel/isl/isl_gen9.c b/src/intel/isl/isl_gen9.c
index da8c749..e5d0f95 100644
--- a/src/intel/isl/isl_gen9.c
+++ b/src/intel/isl/isl_gen9.c
@@ -97,12 +97,12 @@ gen9_calc_std_image_alignment_sa(const struct isl_device *dev,
 }
 
 void
-gen9_choose_image_alignment_el(const struct isl_device *dev,
-                               const struct isl_surf_init_info *restrict info,
-                               enum isl_tiling tiling,
-                               enum isl_dim_layout dim_layout,
-                               enum isl_msaa_layout msaa_layout,
-                               struct isl_extent3d *image_align_el)
+isl_gen9_choose_image_alignment_el(const struct isl_device *dev,
+                                   const struct isl_surf_init_info *restrict info,
+                                   enum isl_tiling tiling,
+                                   enum isl_dim_layout dim_layout,
+                                   enum isl_msaa_layout msaa_layout,
+                                   struct isl_extent3d *image_align_el)
 {
    /* Handled by isl_choose_image_alignment_el */
    assert(info->format != ISL_FORMAT_HIZ);
@@ -196,6 +196,6 @@ gen9_choose_image_alignment_el(const struct isl_device *dev,
       return;
    }
 
-   gen8_choose_image_alignment_el(dev, info, tiling, dim_layout,
-                                  msaa_layout, image_align_el);
+   isl_gen8_choose_image_alignment_el(dev, info, tiling, dim_layout,
+                                      msaa_layout, image_align_el);
 }
diff --git a/src/intel/isl/isl_gen9.h b/src/intel/isl/isl_gen9.h
index 9672ec5..44aab7f 100644
--- a/src/intel/isl/isl_gen9.h
+++ b/src/intel/isl/isl_gen9.h
@@ -30,12 +30,12 @@ extern "C" {
 #endif
 
 void
-gen9_choose_image_alignment_el(const struct isl_device *dev,
-                               const struct isl_surf_init_info *restrict info,
-                               enum isl_tiling tiling,
-                               enum isl_dim_layout dim_layout,
-                               enum isl_msaa_layout msaa_layout,
-                               struct isl_extent3d *image_align_el);
+isl_gen9_choose_image_alignment_el(const struct isl_device *dev,
+                                   const struct isl_surf_init_info *restrict info,
+                                   enum isl_tiling tiling,
+                                   enum isl_dim_layout dim_layout,
+                                   enum isl_msaa_layout msaa_layout,
+                                   struct isl_extent3d *image_align_el);
 
 #ifdef __cplusplus
 }
-- 
2.10.0



More information about the mesa-dev mailing list