Commit c0cd6925 authored by Thomas Zimmermann's avatar Thomas Zimmermann

drm/ast: Set DDC timeout in milliseconds

Compute the i2c timeout in jiffies from a value in milliseconds. The
original values of 2 jiffies equals 2 milliseconds if HZ has been
configured to a value of 1000. This corresponds to 2.2 milliseconds
used by most other DRM drivers. Update ast accordingly.
Signed-off-by: default avatarThomas Zimmermann <tzimmermann@suse.de>
Fixes: 312fec14 ("drm: Initial KMS driver for AST (ASpeed Technologies) 2000 series (v2)")
Cc: Dave Airlie <airlied@redhat.com>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: Maxime Ripard <mripard@kernel.org>
Cc: Thomas Zimmermann <tzimmermann@suse.de>
Cc: Jocelyn Falempe <jfalempe@redhat.com>
Cc: dri-devel@lists.freedesktop.org
Cc: <stable@vger.kernel.org> # v3.5+
Reviewed-by: default avatarJocelyn Falempe <jfalempe@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240403103325.30457-2-tzimmermann@suse.de
parent fe6660b6
...@@ -153,7 +153,7 @@ struct ast_ddc *ast_ddc_create(struct ast_device *ast) ...@@ -153,7 +153,7 @@ struct ast_ddc *ast_ddc_create(struct ast_device *ast)
bit = &ddc->bit; bit = &ddc->bit;
bit->udelay = 20; bit->udelay = 20;
bit->timeout = 2; bit->timeout = usecs_to_jiffies(2200);
bit->data = ddc; bit->data = ddc;
bit->setsda = ast_ddc_algo_bit_data_setsda; bit->setsda = ast_ddc_algo_bit_data_setsda;
bit->setscl = ast_ddc_algo_bit_data_setscl; bit->setscl = ast_ddc_algo_bit_data_setscl;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment