On 24/11/2026 00:01, Jiaxing Hu wrote: > Add DRM_IOCTL_ROCKET_GET_PARAM so that userspace can tell which NPU it > runs on. DRM_ROCKET_PARAM_HW_VERSION returns an enum > drm_rocket_hw_version value, taken from the compatible's match data when > the first core probes. The PC_VERSION registers cannot be used: the > RK3568 reads 0 from them.
I also spotted that the vendor driver uses compatible-based matching for this kind of thing. > @@ -197,6 +224,9 @@ static int rocket_probe(struct platform_device *pdev) > devres_close_group(&drm_dev->dev, rdev_group); > } > > + if (hw_version != rdev->hw_version) > + return -EINVAL; > + This check can be dropped, we can assume that a DT that gives cores with a mix of hw versions is invalid and broken. With that change feel free to add my Reviewed-By
