From: Yong Wu Date: Mon, 14 Feb 2022 06:07:58 +0000 (+0800) Subject: drm/komeda: Make use of the helper component_compare_of X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=a190622af3f9a6ff86554bf7665f022cb919223e;p=linux.git drm/komeda: Make use of the helper component_compare_of Use the common compare helper from component. Cc: "James (Qian) Wang" Cc: Liviu Dudau Cc: Mihail Atanassov Cc: Brian Starkey Signed-off-by: Yong Wu Link: https://lore.kernel.org/r/20220214060819.7334-3-yong.wu@mediatek.com Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/gpu/drm/arm/display/komeda/komeda_drv.c b/drivers/gpu/drm/arm/display/komeda/komeda_drv.c index e7933930a6577..c325872699ecb 100644 --- a/drivers/gpu/drm/arm/display/komeda/komeda_drv.c +++ b/drivers/gpu/drm/arm/display/komeda/komeda_drv.c @@ -92,11 +92,6 @@ static const struct component_master_ops komeda_master_ops = { .unbind = komeda_unbind, }; -static int compare_of(struct device *dev, void *data) -{ - return dev->of_node == data; -} - static void komeda_add_slave(struct device *master, struct component_match **match, struct device_node *np, @@ -106,7 +101,7 @@ static void komeda_add_slave(struct device *master, remote = of_graph_get_remote_node(np, port, endpoint); if (remote) { - drm_of_component_match_add(master, match, compare_of, remote); + drm_of_component_match_add(master, match, component_compare_of, remote); of_node_put(remote); } }