Re: [PATCH 51/70] drm/loongson: Convert to atomic_create_state
| Newsgroups | org.freedesktop.lists.dri-devel |
|---|---|
| Message-ID | <[email protected]> |
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider: - [Medium] Meaningful code and commit message mismatch regarding hardware reset. -- --- Patch [51]: [PATCH 51/70] drm/loongson: Convert to atomic_create_state --- commit 242c1e9da80c08d14806505d193ccb1acbb378d8 Author: Maxime Ripard <[email protected]> drm/loongson: Convert to atomic_create_state This commit converts the drm_crtc_funcs.reset hook to atomic_create_state for the loongson driver. The change is made because the original hook only handled state allocation and initialization without performing a hardware reset. > The loongsoon crtc implementation provides a custom reset hook. However, > this hook only allocates the state, initializes it with > __drm_atomic_helper_crtc_reset(), and frees the previous state. It does > not perform any hardware reset. > > Since the atomic_create_state hook is only meant to deal with state > allocation and initialization, convert it accordingly. The hardware > reset through ops->reset() is kept as part of the state creation > since the core currently calls atomic_create_state in the same > context where the reset hook was called. [Severity: Medium] Is the second paragraph of the commit message accurate for the loongson driver? The first paragraph correctly notes that the original reset hook "does not perform any hardware reset", but the second paragraph claims that "The hardware reset through ops->reset() is kept". Since neither the old code nor the new lsdc_crtc_create_state() function performs a hardware reset, could this be a copy-paste error from another patch in the series? -- Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=51