diff options
| author | Thomas Zimmermann <[email protected]> | 2023-06-21 12:53:35 +0000 |
|---|---|---|
| committer | Thomas Zimmermann <[email protected]> | 2023-06-27 12:26:25 +0000 |
| commit | 4cfe75f0f14f044dae66ad0e6eea812d038465d9 (patch) | |
| tree | 435df70f8e80c50702edc4e119755bfcc77537eb /drivers/gpu/drm/ast/ast_post.c | |
| parent | drm/ttm: Don't shadow the operation context (diff) | |
| download | kernel-4cfe75f0f14f044dae66ad0e6eea812d038465d9.tar.gz kernel-4cfe75f0f14f044dae66ad0e6eea812d038465d9.zip | |
drm/ast: Fix DRAM init on AST2200
Fix the test for the AST2200 in the DRAM initialization. The value
in ast->chip has to be compared against an enum constant instead of
a numerical value.
This bug got introduced when the driver was first imported into the
kernel.
Signed-off-by: Thomas Zimmermann <[email protected]>
Fixes: 312fec1405dd ("drm: Initial KMS driver for AST (ASpeed Technologies) 2000 series (v2)")
Cc: Dave Airlie <[email protected]>
Cc: [email protected]
Cc: <[email protected]> # v3.5+
Reviewed-by: Sui Jingfeng <[email protected]>
Reviewed-by: Jocelyn Falempe <[email protected]>
Tested-by: Jocelyn Falempe <[email protected]> # AST2600
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Diffstat (limited to 'drivers/gpu/drm/ast/ast_post.c')
| -rw-r--r-- | drivers/gpu/drm/ast/ast_post.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/ast/ast_post.c b/drivers/gpu/drm/ast/ast_post.c index a005aec18a02..0262aaafdb1c 100644 --- a/drivers/gpu/drm/ast/ast_post.c +++ b/drivers/gpu/drm/ast/ast_post.c @@ -291,7 +291,7 @@ static void ast_init_dram_reg(struct drm_device *dev) ; } while (ast_read32(ast, 0x10100) != 0xa8); } else {/* AST2100/1100 */ - if (ast->chip == AST2100 || ast->chip == 2200) + if (ast->chip == AST2100 || ast->chip == AST2200) dram_reg_info = ast2100_dram_table_data; else dram_reg_info = ast1100_dram_table_data; |
