[PATCH 01/10] drm/ast: Declare helpers for POST in header
Jocelyn Falempe
jfalempe at redhat.com
Thu Jul 3 10:24:01 UTC 2025
On 02/07/2025 15:12, Thomas Zimmermann wrote:
> Provide POST helpers in header file before splitting up the AST
> POST code.
Thanks, it looks good to me.
Reviewed-by: Jocelyn Falempe <jfalempe at redhat.com>
>
> Signed-off-by: Thomas Zimmermann <tzimmermann at suse.de>
> ---
> drivers/gpu/drm/ast/ast_post.c | 10 +++++-----
> drivers/gpu/drm/ast/ast_post.h | 16 ++++++++++++++++
> 2 files changed, 21 insertions(+), 5 deletions(-)
> create mode 100644 drivers/gpu/drm/ast/ast_post.h
>
> diff --git a/drivers/gpu/drm/ast/ast_post.c b/drivers/gpu/drm/ast/ast_post.c
> index 37568cf3822c..36542d266f9c 100644
> --- a/drivers/gpu/drm/ast/ast_post.c
> +++ b/drivers/gpu/drm/ast/ast_post.c
> @@ -33,6 +33,7 @@
>
> #include "ast_dram_tables.h"
> #include "ast_drv.h"
> +#include "ast_post.h"
>
> static void ast_post_chip_2300(struct ast_device *ast);
> static void ast_post_chip_2500(struct ast_device *ast);
> @@ -75,7 +76,7 @@ static void ast_set_def_ext_reg(struct ast_device *ast)
> ast_set_index_reg_mask(ast, AST_IO_VGACRI, 0xb6, 0xff, reg);
> }
>
> -static u32 __ast_mindwm(void __iomem *regs, u32 r)
> +u32 __ast_mindwm(void __iomem *regs, u32 r)
> {
> u32 data;
>
> @@ -89,7 +90,7 @@ static u32 __ast_mindwm(void __iomem *regs, u32 r)
> return __ast_read32(regs, 0x10000 + (r & 0x0000ffff));
> }
>
> -static void __ast_moutdwm(void __iomem *regs, u32 r, u32 v)
> +void __ast_moutdwm(void __iomem *regs, u32 r, u32 v)
> {
> u32 data;
>
> @@ -438,7 +439,7 @@ static const u32 pattern[8] = {
> 0x7C61D253
> };
>
> -static bool mmc_test(struct ast_device *ast, u32 datagen, u8 test_ctl)
> +bool mmc_test(struct ast_device *ast, u32 datagen, u8 test_ctl)
> {
> u32 data, timeout;
>
> @@ -478,8 +479,7 @@ static u32 mmc_test2(struct ast_device *ast, u32 datagen, u8 test_ctl)
> return data;
> }
>
> -
> -static bool mmc_test_burst(struct ast_device *ast, u32 datagen)
> +bool mmc_test_burst(struct ast_device *ast, u32 datagen)
> {
> return mmc_test(ast, datagen, 0xc1);
> }
> diff --git a/drivers/gpu/drm/ast/ast_post.h b/drivers/gpu/drm/ast/ast_post.h
> new file mode 100644
> index 000000000000..314fa0475c79
> --- /dev/null
> +++ b/drivers/gpu/drm/ast/ast_post.h
> @@ -0,0 +1,16 @@
> +/* SPDX-License-Identifier: MIT */
> +
> +#ifndef AST_POST_H
> +#define AST_POST_H
> +
> +#include <linux/types.h>
> +
> +struct ast_device;
> +
> +u32 __ast_mindwm(void __iomem *regs, u32 r);
> +void __ast_moutdwm(void __iomem *regs, u32 r, u32 v);
> +
> +bool mmc_test(struct ast_device *ast, u32 datagen, u8 test_ctl);
> +bool mmc_test_burst(struct ast_device *ast, u32 datagen);
> +
> +#endif
More information about the dri-devel
mailing list