]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
drm/ast: Use constants for SCU registers
authorThomas Zimmermann <tzimmermann@suse.de>
Fri, 27 Mar 2026 13:32:57 +0000 (14:32 +0100)
committerThomas Zimmermann <tzimmermann@suse.de>
Wed, 8 Apr 2026 09:04:48 +0000 (11:04 +0200)
commit06c076cb300b9eabb016e4898d5743e5fad959bb
treee64b6f9cf66ac01da6b4997e1875358e1e9f098f
parent392993767d940fd3d0db35e64b5fcf4e00f2ea49
drm/ast: Use constants for SCU registers

SCU is the System Control Unit. SCU registers are located in the memory
range at [0x1e6e2000, 0x1e6e2fff]. Refer to them with constants named
AST_REG_SCU<n>, where <n> is the byte offset into the range.

Replacing the magic values in the ast driver was done with grep and sed
as shown below

  git grep -l \,\ 0x1e6e2 | xargs sed -i -e 's/, 0x1e6e2/, AST_REG_SCU/g'
  git grep -l \,\ 0x1E6E2 | xargs sed -i -e 's/, 0x1E6E2/, AST_REG_SCU/g'

plus some manual fixes.

Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com>
Link: https://patch.msgid.link/20260327133532.79696-6-tzimmermann@suse.de
drivers/gpu/drm/ast/ast_2300.c
drivers/gpu/drm/ast/ast_2500.c
drivers/gpu/drm/ast/ast_dp501.c
drivers/gpu/drm/ast/ast_reg.h