forked from ~ljy/RK356X_SDK_RELEASE

hc
2023-12-11 223293205a7265c8b02882461ba8996650048ade
kernel/drivers/video/fbdev/omap2/omapfb/dss/hdmi4.c
....@@ -1,20 +1,9 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * HDMI interface DSS driver for TI's OMAP4 family of SoCs.
3
- * Copyright (C) 2010-2011 Texas Instruments Incorporated - http://www.ti.com/
4
+ * Copyright (C) 2010-2011 Texas Instruments Incorporated - https://www.ti.com/
45 * Authors: Yong Zhi
56 * Mythri pk <mythripk@ti.com>
6
- *
7
- * This program is free software; you can redistribute it and/or modify it
8
- * under the terms of the GNU General Public License version 2 as published by
9
- * the Free Software Foundation.
10
- *
11
- * This program is distributed in the hope that it will be useful, but WITHOUT
12
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14
- * more details.
15
- *
16
- * You should have received a copy of the GNU General Public License along with
17
- * this program. If not, see <http://www.gnu.org/licenses/>.
187 */
198
209 #define DSS_SUBSYS_NAME "HDMI"
....@@ -30,7 +19,7 @@
3019 #include <linux/platform_device.h>
3120 #include <linux/pm_runtime.h>
3221 #include <linux/clk.h>
33
-#include <linux/gpio.h>
22
+#include <linux/of.h>
3423 #include <linux/regulator/consumer.h>
3524 #include <linux/component.h>
3625 #include <video/omapfb_dss.h>
....@@ -467,10 +456,8 @@
467456 static int hdmi_read_edid(struct omap_dss_device *dssdev,
468457 u8 *edid, int len)
469458 {
470
- bool need_enable;
459
+ bool need_enable = !hdmi.core_enabled;
471460 int r;
472
-
473
- need_enable = hdmi.core_enabled == false;
474461
475462 if (need_enable) {
476463 r = hdmi_core_enable(dssdev);