dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drm/i915: Remove unused function pointer typedef long_pulse_detect_func
@ 2021-02-15 11:30 Chen Lin
  2021-02-16 11:40 ` Ville Syrjälä
  0 siblings, 1 reply; 3+ messages in thread
From: Chen Lin @ 2021-02-15 11:30 UTC (permalink / raw)
  To: airlied, daniel
  Cc: intel-gfx, linux-kernel, dri-devel, Chen Lin, rodrigo.vivi

From: Chen Lin <chen.lin5@zte.com.cn>

Remove the 'long_pulse_detect_func' typedef as it is not used.

Signed-off-by: Chen Lin <chen.lin5@zte.com.cn>
---
 drivers/gpu/drm/i915/i915_irq.c |    1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c
index 6cdb052..c294ac6 100644
--- a/drivers/gpu/drm/i915/i915_irq.c
+++ b/drivers/gpu/drm/i915/i915_irq.c
@@ -78,7 +78,6 @@ static inline void pmu_irq_stats(struct drm_i915_private *i915,
 	WRITE_ONCE(i915->pmu.irq_count, i915->pmu.irq_count + 1);
 }
 
-typedef bool (*long_pulse_detect_func)(enum hpd_pin pin, u32 val);
 typedef u32 (*hotplug_enables_func)(struct drm_i915_private *i915,
 				    enum hpd_pin pin);
 
-- 
1.7.9.5


_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] drm/i915: Remove unused function pointer typedef long_pulse_detect_func
  2021-02-15 11:30 [PATCH] drm/i915: Remove unused function pointer typedef long_pulse_detect_func Chen Lin
@ 2021-02-16 11:40 ` Ville Syrjälä
  2021-02-16 15:39   ` [v2] drm/i915: Use function pointer typedef long_pulse_detect_func in intel_get_hpd_pins Chen Lin
  0 siblings, 1 reply; 3+ messages in thread
From: Ville Syrjälä @ 2021-02-16 11:40 UTC (permalink / raw)
  To: Chen Lin
  Cc: airlied, intel-gfx, linux-kernel, dri-devel, Chen Lin, rodrigo.vivi

On Mon, Feb 15, 2021 at 07:30:19PM +0800, Chen Lin wrote:
> From: Chen Lin <chen.lin5@zte.com.cn>
> 
> Remove the 'long_pulse_detect_func' typedef as it is not used.
> 
> Signed-off-by: Chen Lin <chen.lin5@zte.com.cn>
> ---
>  drivers/gpu/drm/i915/i915_irq.c |    1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c
> index 6cdb052..c294ac6 100644
> --- a/drivers/gpu/drm/i915/i915_irq.c
> +++ b/drivers/gpu/drm/i915/i915_irq.c
> @@ -78,7 +78,6 @@ static inline void pmu_irq_stats(struct drm_i915_private *i915,
>  	WRITE_ONCE(i915->pmu.irq_count, i915->pmu.irq_count + 1);
>  }
>  
> -typedef bool (*long_pulse_detect_func)(enum hpd_pin pin, u32 val);
>  typedef u32 (*hotplug_enables_func)(struct drm_i915_private *i915,
>  				    enum hpd_pin pin);

I thought we used in when passing it as an argument to
intel_get_hpd_pins(), but looks like that's not the case.
I guess we should unify this stuff by either removing both
these typedefs and adjusting intel_hpd_hotplug_enables()
accordingly, or we should use the typedef in intel_get_hpd_pins() as
well.

-- 
Ville Syrjälä
Intel
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [v2] drm/i915: Use function pointer typedef long_pulse_detect_func in intel_get_hpd_pins
  2021-02-16 11:40 ` Ville Syrjälä
@ 2021-02-16 15:39   ` Chen Lin
  0 siblings, 0 replies; 3+ messages in thread
From: Chen Lin @ 2021-02-16 15:39 UTC (permalink / raw)
  To: ville.syrjala
  Cc: airlied, intel-gfx, linux-kernel, dri-devel, chen.lin5, rodrigo.vivi

From: Chen Lin <chen.lin5@zte.com.cn>

Use function pointer typedef long_pulse_detect_func in intel_get_hpd_pins.

Signed-off-by: Chen Lin <chen.lin5@zte.com.cn>
---
 drivers/gpu/drm/i915/i915_irq.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c
index 6cdb052..4339bad 100644
--- a/drivers/gpu/drm/i915/i915_irq.c
+++ b/drivers/gpu/drm/i915/i915_irq.c
@@ -1203,7 +1203,7 @@ static void intel_get_hpd_pins(struct drm_i915_private *dev_priv,
 			       u32 *pin_mask, u32 *long_mask,
 			       u32 hotplug_trigger, u32 dig_hotplug_reg,
 			       const u32 hpd[HPD_NUM_PINS],
-			       bool long_pulse_detect(enum hpd_pin pin, u32 val))
+			       long_pulse_detect_func long_pulse_detect)
 {
 	enum hpd_pin pin;
 
-- 
1.7.9.5


_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-02-16 15:41 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-15 11:30 [PATCH] drm/i915: Remove unused function pointer typedef long_pulse_detect_func Chen Lin
2021-02-16 11:40 ` Ville Syrjälä
2021-02-16 15:39   ` [v2] drm/i915: Use function pointer typedef long_pulse_detect_func in intel_get_hpd_pins Chen Lin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).