mirror of
https://github.com/torvalds/linux.git
synced 2026-05-23 14:42:08 +02:00
drm/bridge: megachips-stdpxxxx-ge-b850v3-fw: convert to devm_drm_bridge_alloc() API
This is the new API for allocating DRM bridges. Acked-by: Maxime Ripard <mripard@kernel.org> Reviewed-by: Anusha Srivatsa <asrivats@redhat.com> Link: https://lore.kernel.org/r/20250509-drm-bridge-convert-to-alloc-api-v3-5-b8bc1f16d7aa@bootlin.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
This commit is contained in:
parent
2b42027f44
commit
0d2577d8f0
|
|
@ -225,13 +225,11 @@ static int ge_b850v3_lvds_init(struct device *dev)
|
|||
if (ge_b850v3_lvds_ptr)
|
||||
goto success;
|
||||
|
||||
ge_b850v3_lvds_ptr = devm_kzalloc(dev,
|
||||
sizeof(*ge_b850v3_lvds_ptr),
|
||||
GFP_KERNEL);
|
||||
|
||||
if (!ge_b850v3_lvds_ptr) {
|
||||
ge_b850v3_lvds_ptr = devm_drm_bridge_alloc(dev, struct ge_b850v3_lvds, bridge,
|
||||
&ge_b850v3_lvds_funcs);
|
||||
if (IS_ERR(ge_b850v3_lvds_ptr)) {
|
||||
mutex_unlock(&ge_b850v3_lvds_dev_mutex);
|
||||
return -ENOMEM;
|
||||
return PTR_ERR(ge_b850v3_lvds_ptr);
|
||||
}
|
||||
|
||||
success:
|
||||
|
|
@ -264,7 +262,6 @@ static int ge_b850v3_register(void)
|
|||
struct device *dev = &stdp4028_i2c->dev;
|
||||
|
||||
/* drm bridge initialization */
|
||||
ge_b850v3_lvds_ptr->bridge.funcs = &ge_b850v3_lvds_funcs;
|
||||
ge_b850v3_lvds_ptr->bridge.ops = DRM_BRIDGE_OP_DETECT |
|
||||
DRM_BRIDGE_OP_EDID;
|
||||
ge_b850v3_lvds_ptr->bridge.type = DRM_MODE_CONNECTOR_DisplayPort;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user