Skip to content

Commit 947f019

Browse files
YongWu-HFgregkh
authored andcommitted
drm/vc4: Make use of the helper component_compare_dev
Use the common compare helper from component. Cc: Emma Anholt <[email protected]> Cc: Maxime Ripard <[email protected]> Signed-off-by: Yong Wu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 419838b commit 947f019

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

drivers/gpu/drm/vc4/vc4_drv.c

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -187,11 +187,6 @@ static struct drm_driver vc4_drm_driver = {
187187
.patchlevel = DRIVER_PATCHLEVEL,
188188
};
189189

190-
static int compare_dev(struct device *dev, void *data)
191-
{
192-
return dev == data;
193-
}
194-
195190
static void vc4_match_add_drivers(struct device *dev,
196191
struct component_match **match,
197192
struct platform_driver *const *drivers,
@@ -205,7 +200,7 @@ static void vc4_match_add_drivers(struct device *dev,
205200

206201
while ((d = platform_find_device_by_driver(p, drv))) {
207202
put_device(p);
208-
component_match_add(dev, match, compare_dev, d);
203+
component_match_add(dev, match, component_compare_dev, d);
209204
p = d;
210205
}
211206
put_device(p);

0 commit comments

Comments
 (0)