Re: [PATCH 2/2] drm/i915/hdcp: fix intel_hdcp_get_repeater_ctl() error return value

2023-12-19 Thread Jani Nikula
On Tue, 19 Dec 2023, Ville Syrjälä wrote: > On Tue, Dec 19, 2023 at 12:47:46PM +0200, Jani Nikula wrote: >> intel_hdcp_get_repeater_ctl() is supposed to return unsigned register >> contents. Returning negative error values is unexpected, and none of the >> callers check for that. >> >> Sort of

Re: [PATCH 2/2] drm/i915/hdcp: fix intel_hdcp_get_repeater_ctl() error return value

2023-12-19 Thread Ville Syrjälä
On Tue, Dec 19, 2023 at 12:47:46PM +0200, Jani Nikula wrote: > intel_hdcp_get_repeater_ctl() is supposed to return unsigned register > contents. Returning negative error values is unexpected, and none of the > callers check for that. > > Sort of fix the error cases by returning 0. I don't think

[PATCH 2/2] drm/i915/hdcp: fix intel_hdcp_get_repeater_ctl() error return value

2023-12-19 Thread Jani Nikula
intel_hdcp_get_repeater_ctl() is supposed to return unsigned register contents. Returning negative error values is unexpected, and none of the callers check for that. Sort of fix the error cases by returning 0. I don't think we should hit these cases anyway, and using 0 for the registers is safer