Linux v4.8-14109-g1573d2c
- Drop the extra parallel build optiosn from perf since perf does that on its own.
This commit is contained in:
parent
dbdee9093f
commit
996a0fa54e
@ -1,51 +0,0 @@
|
||||
From 13304cca47c956c308ce8f3fc7b37b61895fa1ea Mon Sep 17 00:00:00 2001
|
||||
From: Laura Abbott <labbott@redhat.com>
|
||||
Date: Tue, 11 Oct 2016 13:10:26 -0700
|
||||
Subject: [PATCH 1/2] Revert "tools build: Support compiling C++ source file"
|
||||
|
||||
This reverts commit f61bdc3304281e9ff9eec4f1ed9fb15bcf4d8a5e.
|
||||
---
|
||||
tools/build/Build.include | 1 -
|
||||
tools/build/Makefile.build | 7 -------
|
||||
2 files changed, 8 deletions(-)
|
||||
|
||||
diff --git a/tools/build/Build.include b/tools/build/Build.include
|
||||
index 1dcb95e..0248938 100644
|
||||
--- a/tools/build/Build.include
|
||||
+++ b/tools/build/Build.include
|
||||
@@ -90,7 +90,6 @@ if_changed = $(if $(strip $(any-prereq) $(arg-check)), \
|
||||
# - per object C flags
|
||||
# - BUILD_STR macro to allow '-D"$(variable)"' constructs
|
||||
c_flags = -Wp,-MD,$(depfile),-MT,$@ $(CFLAGS) -D"BUILD_STR(s)=\#s" $(CFLAGS_$(basetarget).o) $(CFLAGS_$(obj))
|
||||
-cxx_flags = -Wp,-MD,$(depfile),-MT,$@ $(CXXFLAGS) -D"BUILD_STR(s)=\#s" $(CXXFLAGS_$(basetarget).o) $(CXXFLAGS_$(obj))
|
||||
|
||||
###
|
||||
## HOSTCC C flags
|
||||
diff --git a/tools/build/Makefile.build b/tools/build/Makefile.build
|
||||
index 99c0ccd..190519a 100644
|
||||
--- a/tools/build/Makefile.build
|
||||
+++ b/tools/build/Makefile.build
|
||||
@@ -61,9 +61,6 @@ quiet_cmd_cc_o_c = CC $@
|
||||
quiet_cmd_host_cc_o_c = HOSTCC $@
|
||||
cmd_host_cc_o_c = $(HOSTCC) $(host_c_flags) -c -o $@ $<
|
||||
|
||||
-quiet_cmd_cxx_o_c = CXX $@
|
||||
- cmd_cxx_o_c = $(CXX) $(cxx_flags) -c -o $@ $<
|
||||
-
|
||||
quiet_cmd_cpp_i_c = CPP $@
|
||||
cmd_cpp_i_c = $(CC) $(c_flags) -E -o $@ $<
|
||||
|
||||
@@ -91,10 +88,6 @@ $(OUTPUT)%.o: %.c FORCE
|
||||
$(call rule_mkdir)
|
||||
$(call if_changed_dep,$(host)cc_o_c)
|
||||
|
||||
-$(OUTPUT)%.o: %.cpp FORCE
|
||||
- $(call rule_mkdir)
|
||||
- $(call if_changed_dep,cxx_o_c)
|
||||
-
|
||||
$(OUTPUT)%.o: %.S FORCE
|
||||
$(call rule_mkdir)
|
||||
$(call if_changed_dep,$(host)cc_o_c)
|
||||
--
|
||||
2.7.4
|
||||
|
@ -1,43 +0,0 @@
|
||||
From b0a46f7c26a6c754ff4fc716741c5aeacf125ec9 Mon Sep 17 00:00:00 2001
|
||||
From: Laura Abbott <labbott@redhat.com>
|
||||
Date: Thu, 6 Oct 2016 11:15:11 -0700
|
||||
Subject: [PATCH] drivers: net: phy: Correct duplicate MDIO_XGENE entry
|
||||
|
||||
An extra entry for MDIO_XGENE got added during merging.
|
||||
Delete the extra.
|
||||
|
||||
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
|
||||
Signed-off-by: Laura Abbott <labbott@redhat.com>
|
||||
---
|
||||
drivers/net/phy/Kconfig | 8 +-------
|
||||
1 file changed, 1 insertion(+), 7 deletions(-)
|
||||
|
||||
diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig
|
||||
index 5078a0d..2651c8d 100644
|
||||
--- a/drivers/net/phy/Kconfig
|
||||
+++ b/drivers/net/phy/Kconfig
|
||||
@@ -142,6 +142,7 @@ config MDIO_THUNDER
|
||||
|
||||
config MDIO_XGENE
|
||||
tristate "APM X-Gene SoC MDIO bus controller"
|
||||
+ depends on ARCH_XGENE || COMPILE_TEST
|
||||
help
|
||||
This module provides a driver for the MDIO busses found in the
|
||||
APM X-Gene SoC's.
|
||||
@@ -320,13 +321,6 @@ config XILINX_GMII2RGMII
|
||||
the Reduced Gigabit Media Independent Interface(RGMII) between
|
||||
Ethernet physical media devices and the Gigabit Ethernet controller.
|
||||
|
||||
-config MDIO_XGENE
|
||||
- tristate "APM X-Gene SoC MDIO bus controller"
|
||||
- depends on ARCH_XGENE || COMPILE_TEST
|
||||
- help
|
||||
- This module provides a driver for the MDIO busses found in the
|
||||
- APM X-Gene SoC's.
|
||||
-
|
||||
endif # PHYLIB
|
||||
|
||||
config MICREL_KS8995MA
|
||||
--
|
||||
2.7.4
|
||||
|
@ -1,97 +0,0 @@
|
||||
From b9bde1ab2f260d56413511bbb68199ea3c45ec1f Mon Sep 17 00:00:00 2001
|
||||
From: Laura Abbott <labbott@redhat.com>
|
||||
Date: Tue, 11 Oct 2016 13:10:34 -0700
|
||||
Subject: [PATCH 2/2] Revert "tools build: Add support for host programs
|
||||
format"
|
||||
|
||||
This reverts commit 0c3b7e42616f1f6084cfeb0d443cbff0b2c424a9.
|
||||
---
|
||||
tools/build/Build.include | 5 -----
|
||||
tools/build/Makefile | 6 ------
|
||||
tools/build/Makefile.build | 19 ++++---------------
|
||||
3 files changed, 4 insertions(+), 26 deletions(-)
|
||||
|
||||
diff --git a/tools/build/Build.include b/tools/build/Build.include
|
||||
index 0248938..4d000bc 100644
|
||||
--- a/tools/build/Build.include
|
||||
+++ b/tools/build/Build.include
|
||||
@@ -90,8 +90,3 @@ if_changed = $(if $(strip $(any-prereq) $(arg-check)), \
|
||||
# - per object C flags
|
||||
# - BUILD_STR macro to allow '-D"$(variable)"' constructs
|
||||
c_flags = -Wp,-MD,$(depfile),-MT,$@ $(CFLAGS) -D"BUILD_STR(s)=\#s" $(CFLAGS_$(basetarget).o) $(CFLAGS_$(obj))
|
||||
-
|
||||
-###
|
||||
-## HOSTCC C flags
|
||||
-
|
||||
-host_c_flags = -Wp,-MD,$(depfile),-MT,$@ $(CHOSTFLAGS) -D"BUILD_STR(s)=\#s" $(CHOSTFLAGS_$(basetarget).o) $(CHOSTFLAGS_$(obj))
|
||||
diff --git a/tools/build/Makefile b/tools/build/Makefile
|
||||
index 8332959..2659f2f 100644
|
||||
--- a/tools/build/Makefile
|
||||
+++ b/tools/build/Makefile
|
||||
@@ -14,12 +14,6 @@ endef
|
||||
$(call allow-override,CC,$(CROSS_COMPILE)gcc)
|
||||
$(call allow-override,LD,$(CROSS_COMPILE)ld)
|
||||
|
||||
-HOSTCC ?= gcc
|
||||
-HOSTLD ?= ld
|
||||
-HOSTAR ?= ar
|
||||
-
|
||||
-export HOSTCC HOSTLD HOSTAR
|
||||
-
|
||||
ifeq ($(V),1)
|
||||
Q =
|
||||
else
|
||||
diff --git a/tools/build/Makefile.build b/tools/build/Makefile.build
|
||||
index 190519a..27f3583 100644
|
||||
--- a/tools/build/Makefile.build
|
||||
+++ b/tools/build/Makefile.build
|
||||
@@ -58,9 +58,6 @@ quiet_cmd_mkdir = MKDIR $(dir $@)
|
||||
quiet_cmd_cc_o_c = CC $@
|
||||
cmd_cc_o_c = $(CC) $(c_flags) -c -o $@ $<
|
||||
|
||||
-quiet_cmd_host_cc_o_c = HOSTCC $@
|
||||
- cmd_host_cc_o_c = $(HOSTCC) $(host_c_flags) -c -o $@ $<
|
||||
-
|
||||
quiet_cmd_cpp_i_c = CPP $@
|
||||
cmd_cpp_i_c = $(CC) $(c_flags) -E -o $@ $<
|
||||
|
||||
@@ -73,24 +70,16 @@ quiet_cmd_gen = GEN $@
|
||||
# If there's nothing to link, create empty $@ object.
|
||||
quiet_cmd_ld_multi = LD $@
|
||||
cmd_ld_multi = $(if $(strip $(obj-y)),\
|
||||
- $(LD) -r -o $@ $(filter $(obj-y),$^),rm -f $@; $(AR) rcs $@)
|
||||
-
|
||||
-quiet_cmd_host_ld_multi = HOSTLD $@
|
||||
- cmd_host_ld_multi = $(if $(strip $(obj-y)),\
|
||||
- $(HOSTLD) -r -o $@ $(filter $(obj-y),$^),rm -f $@; $(HOSTAR) rcs $@)
|
||||
-
|
||||
-ifneq ($(filter $(obj),$(hostprogs)),)
|
||||
- host = host_
|
||||
-endif
|
||||
+ $(LD) -r -o $@ $(filter $(obj-y),$^),rm -f $@; $(AR) rcs $@)
|
||||
|
||||
# Build rules
|
||||
$(OUTPUT)%.o: %.c FORCE
|
||||
$(call rule_mkdir)
|
||||
- $(call if_changed_dep,$(host)cc_o_c)
|
||||
+ $(call if_changed_dep,cc_o_c)
|
||||
|
||||
$(OUTPUT)%.o: %.S FORCE
|
||||
$(call rule_mkdir)
|
||||
- $(call if_changed_dep,$(host)cc_o_c)
|
||||
+ $(call if_changed_dep,cc_o_c)
|
||||
|
||||
$(OUTPUT)%.i: %.c FORCE
|
||||
$(call rule_mkdir)
|
||||
@@ -130,7 +119,7 @@ $(sort $(subdir-obj-y)): $(subdir-y) ;
|
||||
|
||||
$(in-target): $(obj-y) FORCE
|
||||
$(call rule_mkdir)
|
||||
- $(call if_changed,$(host)ld_multi)
|
||||
+ $(call if_changed,ld_multi)
|
||||
|
||||
__build: $(in-target)
|
||||
@:
|
||||
--
|
||||
2.7.4
|
||||
|
@ -1,636 +0,0 @@
|
||||
From 9db79f3a51c97e0cfcde1b25299e8db9ee3d64ab Mon Sep 17 00:00:00 2001
|
||||
From: Eric Anholt <eric@anholt.net>
|
||||
Date: Wed, 14 Sep 2016 19:21:29 +0100
|
||||
Subject: [PATCH 1/4] drm/vc4: Fall back to using an EDID probe in the absence
|
||||
of a GPIO.
|
||||
|
||||
On Pi0/1/2, we use an external GPIO line for hotplug detection, since
|
||||
the HDMI_HOTPLUG register isn't connected to anything. However, with
|
||||
the Pi3 the HPD GPIO line has moved off to a GPIO expander that will
|
||||
be tricky to get to (the firmware is constantly polling the expander
|
||||
using i2c0, so we'll need to coordinate with it).
|
||||
|
||||
As a stop-gap, if we don't have a GPIO line, use an EDID probe to
|
||||
detect connection. Fixes HDMI display on the pi3.
|
||||
|
||||
Signed-off-by: Eric Anholt <eric@anholt.net>
|
||||
---
|
||||
drivers/gpu/drm/vc4/vc4_hdmi.c | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdmi.c
|
||||
index 4452f36..5adc0c7 100644
|
||||
--- a/drivers/gpu/drm/vc4/vc4_hdmi.c
|
||||
+++ b/drivers/gpu/drm/vc4/vc4_hdmi.c
|
||||
@@ -174,6 +174,9 @@ vc4_hdmi_connector_detect(struct drm_connector *connector, bool force)
|
||||
return connector_status_disconnected;
|
||||
}
|
||||
|
||||
+ if (drm_probe_ddc(vc4->hdmi->ddc))
|
||||
+ return connector_status_connected;
|
||||
+
|
||||
if (HDMI_READ(VC4_HDMI_HOTPLUG) & VC4_HDMI_HOTPLUG_CONNECTED)
|
||||
return connector_status_connected;
|
||||
else
|
||||
--
|
||||
2.9.3
|
||||
|
||||
From 7b4c39f34fbbdfe0cd0e626686ee01ab96601598 Mon Sep 17 00:00:00 2001
|
||||
From: Eric Anholt <eric@anholt.net>
|
||||
Date: Fri, 16 Sep 2016 10:59:45 +0100
|
||||
Subject: [PATCH 2/4] drm/vc4: Enable limited range RGB output on HDMI with CEA
|
||||
modes.
|
||||
|
||||
Fixes broken grayscale ramps on many HDMI monitors, where large areas
|
||||
at the ends of the ramp would all appear as black or white.
|
||||
|
||||
Signed-off-by: Eric Anholt <eric@anholt.net>
|
||||
---
|
||||
drivers/gpu/drm/vc4/vc4_hdmi.c | 31 +++++++++++++++++++++++++++++--
|
||||
drivers/gpu/drm/vc4/vc4_regs.h | 9 ++++++++-
|
||||
2 files changed, 37 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdmi.c
|
||||
index 5adc0c7..5df4e74 100644
|
||||
--- a/drivers/gpu/drm/vc4/vc4_hdmi.c
|
||||
+++ b/drivers/gpu/drm/vc4/vc4_hdmi.c
|
||||
@@ -276,6 +276,7 @@ static void vc4_hdmi_encoder_mode_set(struct drm_encoder *encoder,
|
||||
struct drm_display_mode *unadjusted_mode,
|
||||
struct drm_display_mode *mode)
|
||||
{
|
||||
+ struct vc4_hdmi_encoder *vc4_encoder = to_vc4_hdmi_encoder(encoder);
|
||||
struct drm_device *dev = encoder->dev;
|
||||
struct vc4_dev *vc4 = to_vc4_dev(dev);
|
||||
bool debug_dump_regs = false;
|
||||
@@ -291,6 +292,7 @@ static void vc4_hdmi_encoder_mode_set(struct drm_encoder *encoder,
|
||||
u32 vertb = (VC4_SET_FIELD(0, VC4_HDMI_VERTB_VSPO) |
|
||||
VC4_SET_FIELD(mode->vtotal - mode->vsync_end,
|
||||
VC4_HDMI_VERTB_VBP));
|
||||
+ u32 csc_ctl;
|
||||
|
||||
if (debug_dump_regs) {
|
||||
DRM_INFO("HDMI regs before:\n");
|
||||
@@ -329,9 +331,34 @@ static void vc4_hdmi_encoder_mode_set(struct drm_encoder *encoder,
|
||||
(vsync_pos ? 0 : VC4_HD_VID_CTL_VSYNC_LOW) |
|
||||
(hsync_pos ? 0 : VC4_HD_VID_CTL_HSYNC_LOW));
|
||||
|
||||
+ csc_ctl = VC4_SET_FIELD(VC4_HD_CSC_CTL_ORDER_BGR,
|
||||
+ VC4_HD_CSC_CTL_ORDER);
|
||||
+
|
||||
+ if (vc4_encoder->hdmi_monitor && drm_match_cea_mode(mode) > 1) {
|
||||
+ /* CEA VICs other than #1 requre limited range RGB
|
||||
+ * output. Apply a colorspace conversion to squash
|
||||
+ * 0-255 down to 16-235. The matrix here is:
|
||||
+ *
|
||||
+ * [ 0 0 0.8594 16]
|
||||
+ * [ 0 0.8594 0 16]
|
||||
+ * [ 0.8594 0 0 16]
|
||||
+ * [ 0 0 0 1]
|
||||
+ */
|
||||
+ csc_ctl |= VC4_HD_CSC_CTL_ENABLE;
|
||||
+ csc_ctl |= VC4_HD_CSC_CTL_RGB2YCC;
|
||||
+ csc_ctl |= VC4_SET_FIELD(VC4_HD_CSC_CTL_MODE_CUSTOM,
|
||||
+ VC4_HD_CSC_CTL_MODE);
|
||||
+
|
||||
+ HD_WRITE(VC4_HD_CSC_12_11, (0x000 << 16) | 0x000);
|
||||
+ HD_WRITE(VC4_HD_CSC_14_13, (0x100 << 16) | 0x6e0);
|
||||
+ HD_WRITE(VC4_HD_CSC_22_21, (0x6e0 << 16) | 0x000);
|
||||
+ HD_WRITE(VC4_HD_CSC_24_23, (0x100 << 16) | 0x000);
|
||||
+ HD_WRITE(VC4_HD_CSC_32_31, (0x000 << 16) | 0x6e0);
|
||||
+ HD_WRITE(VC4_HD_CSC_34_33, (0x100 << 16) | 0x000);
|
||||
+ }
|
||||
+
|
||||
/* The RGB order applies even when CSC is disabled. */
|
||||
- HD_WRITE(VC4_HD_CSC_CTL, VC4_SET_FIELD(VC4_HD_CSC_CTL_ORDER_BGR,
|
||||
- VC4_HD_CSC_CTL_ORDER));
|
||||
+ HD_WRITE(VC4_HD_CSC_CTL, csc_ctl);
|
||||
|
||||
HDMI_WRITE(VC4_HDMI_FIFO_CTL, VC4_HDMI_FIFO_CTL_MASTER_SLAVE_N);
|
||||
|
||||
diff --git a/drivers/gpu/drm/vc4/vc4_regs.h b/drivers/gpu/drm/vc4/vc4_regs.h
|
||||
index 160942a..9ecd6ff 100644
|
||||
--- a/drivers/gpu/drm/vc4/vc4_regs.h
|
||||
+++ b/drivers/gpu/drm/vc4/vc4_regs.h
|
||||
@@ -528,10 +528,17 @@
|
||||
# define VC4_HD_CSC_CTL_MODE_SHIFT 2
|
||||
# define VC4_HD_CSC_CTL_MODE_RGB_TO_SD_YPRPB 0
|
||||
# define VC4_HD_CSC_CTL_MODE_RGB_TO_HD_YPRPB 1
|
||||
-# define VC4_HD_CSC_CTL_MODE_CUSTOM 2
|
||||
+# define VC4_HD_CSC_CTL_MODE_CUSTOM 3
|
||||
# define VC4_HD_CSC_CTL_RGB2YCC BIT(1)
|
||||
# define VC4_HD_CSC_CTL_ENABLE BIT(0)
|
||||
|
||||
+#define VC4_HD_CSC_12_11 0x044
|
||||
+#define VC4_HD_CSC_14_13 0x048
|
||||
+#define VC4_HD_CSC_22_21 0x04c
|
||||
+#define VC4_HD_CSC_24_23 0x050
|
||||
+#define VC4_HD_CSC_32_31 0x054
|
||||
+#define VC4_HD_CSC_34_33 0x058
|
||||
+
|
||||
#define VC4_HD_FRAME_COUNT 0x068
|
||||
|
||||
/* HVS display list information. */
|
||||
--
|
||||
2.9.3
|
||||
|
||||
From 107d3188b3723840deddaa5efeffcaf167e462f2 Mon Sep 17 00:00:00 2001
|
||||
From: Eric Anholt <eric@anholt.net>
|
||||
Date: Wed, 28 Sep 2016 08:42:42 -0700
|
||||
Subject: [PATCH 3/4] drm/vc4: Fix races when the CS reads from render targets.
|
||||
|
||||
With the introduction of bin/render pipelining, the previous job may
|
||||
not be completed when we start binning the next one. If the previous
|
||||
job wrote our VBO, IB, or CS textures, then the binning stage might
|
||||
get stale or uninitialized results.
|
||||
|
||||
Fixes the major rendering failure in glmark2 -b terrain.
|
||||
|
||||
Signed-off-by: Eric Anholt <eric@anholt.net>
|
||||
Fixes: ca26d28bbaa3 ("drm/vc4: improve throughput by pipelining binning and rendering jobs")
|
||||
Cc: stable@vger.kernel.org
|
||||
---
|
||||
drivers/gpu/drm/vc4/vc4_drv.h | 19 ++++++++++++++++++-
|
||||
drivers/gpu/drm/vc4/vc4_gem.c | 13 +++++++++++++
|
||||
drivers/gpu/drm/vc4/vc4_render_cl.c | 21 +++++++++++++++++----
|
||||
drivers/gpu/drm/vc4/vc4_validate.c | 17 ++++++++++++++---
|
||||
4 files changed, 62 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/drivers/gpu/drm/vc4/vc4_drv.h b/drivers/gpu/drm/vc4/vc4_drv.h
|
||||
index 428e249..f696b75 100644
|
||||
--- a/drivers/gpu/drm/vc4/vc4_drv.h
|
||||
+++ b/drivers/gpu/drm/vc4/vc4_drv.h
|
||||
@@ -122,9 +122,16 @@ to_vc4_dev(struct drm_device *dev)
|
||||
struct vc4_bo {
|
||||
struct drm_gem_cma_object base;
|
||||
|
||||
- /* seqno of the last job to render to this BO. */
|
||||
+ /* seqno of the last job to render using this BO. */
|
||||
uint64_t seqno;
|
||||
|
||||
+ /* seqno of the last job to use the RCL to write to this BO.
|
||||
+ *
|
||||
+ * Note that this doesn't include binner overflow memory
|
||||
+ * writes.
|
||||
+ */
|
||||
+ uint64_t write_seqno;
|
||||
+
|
||||
/* List entry for the BO's position in either
|
||||
* vc4_exec_info->unref_list or vc4_dev->bo_cache.time_list
|
||||
*/
|
||||
@@ -216,6 +223,9 @@ struct vc4_exec_info {
|
||||
/* Sequence number for this bin/render job. */
|
||||
uint64_t seqno;
|
||||
|
||||
+ /* Latest write_seqno of any BO that binning depends on. */
|
||||
+ uint64_t bin_dep_seqno;
|
||||
+
|
||||
/* Last current addresses the hardware was processing when the
|
||||
* hangcheck timer checked on us.
|
||||
*/
|
||||
@@ -230,6 +240,13 @@ struct vc4_exec_info {
|
||||
struct drm_gem_cma_object **bo;
|
||||
uint32_t bo_count;
|
||||
|
||||
+ /* List of BOs that are being written by the RCL. Other than
|
||||
+ * the binner temporary storage, this is all the BOs written
|
||||
+ * by the job.
|
||||
+ */
|
||||
+ struct drm_gem_cma_object *rcl_write_bo[4];
|
||||
+ uint32_t rcl_write_bo_count;
|
||||
+
|
||||
/* Pointers for our position in vc4->job_list */
|
||||
struct list_head head;
|
||||
|
||||
diff --git a/drivers/gpu/drm/vc4/vc4_gem.c b/drivers/gpu/drm/vc4/vc4_gem.c
|
||||
index b262c5c..ae1609e 100644
|
||||
--- a/drivers/gpu/drm/vc4/vc4_gem.c
|
||||
+++ b/drivers/gpu/drm/vc4/vc4_gem.c
|
||||
@@ -471,6 +471,11 @@ vc4_update_bo_seqnos(struct vc4_exec_info *exec, uint64_t seqno)
|
||||
list_for_each_entry(bo, &exec->unref_list, unref_head) {
|
||||
bo->seqno = seqno;
|
||||
}
|
||||
+
|
||||
+ for (i = 0; i < exec->rcl_write_bo_count; i++) {
|
||||
+ bo = to_vc4_bo(&exec->rcl_write_bo[i]->base);
|
||||
+ bo->write_seqno = seqno;
|
||||
+ }
|
||||
}
|
||||
|
||||
/* Queues a struct vc4_exec_info for execution. If no job is
|
||||
@@ -673,6 +678,14 @@ vc4_get_bcl(struct drm_device *dev, struct vc4_exec_info *exec)
|
||||
goto fail;
|
||||
|
||||
ret = vc4_validate_shader_recs(dev, exec);
|
||||
+ if (ret)
|
||||
+ goto fail;
|
||||
+
|
||||
+ /* Block waiting on any previous rendering into the CS's VBO,
|
||||
+ * IB, or textures, so that pixels are actually written by the
|
||||
+ * time we try to read them.
|
||||
+ */
|
||||
+ ret = vc4_wait_for_seqno(dev, exec->bin_dep_seqno, ~0ull, true);
|
||||
|
||||
fail:
|
||||
drm_free_large(temp);
|
||||
diff --git a/drivers/gpu/drm/vc4/vc4_render_cl.c b/drivers/gpu/drm/vc4/vc4_render_cl.c
|
||||
index 0f12418..08886a3 100644
|
||||
--- a/drivers/gpu/drm/vc4/vc4_render_cl.c
|
||||
+++ b/drivers/gpu/drm/vc4/vc4_render_cl.c
|
||||
@@ -45,6 +45,8 @@ struct vc4_rcl_setup {
|
||||
|
||||
struct drm_gem_cma_object *rcl;
|
||||
u32 next_offset;
|
||||
+
|
||||
+ u32 next_write_bo_index;
|
||||
};
|
||||
|
||||
static inline void rcl_u8(struct vc4_rcl_setup *setup, u8 val)
|
||||
@@ -407,6 +409,8 @@ static int vc4_rcl_msaa_surface_setup(struct vc4_exec_info *exec,
|
||||
if (!*obj)
|
||||
return -EINVAL;
|
||||
|
||||
+ exec->rcl_write_bo[exec->rcl_write_bo_count++] = *obj;
|
||||
+
|
||||
if (surf->offset & 0xf) {
|
||||
DRM_ERROR("MSAA write must be 16b aligned.\n");
|
||||
return -EINVAL;
|
||||
@@ -417,7 +421,8 @@ static int vc4_rcl_msaa_surface_setup(struct vc4_exec_info *exec,
|
||||
|
||||
static int vc4_rcl_surface_setup(struct vc4_exec_info *exec,
|
||||
struct drm_gem_cma_object **obj,
|
||||
- struct drm_vc4_submit_rcl_surface *surf)
|
||||
+ struct drm_vc4_submit_rcl_surface *surf,
|
||||
+ bool is_write)
|
||||
{
|
||||
uint8_t tiling = VC4_GET_FIELD(surf->bits,
|
||||
VC4_LOADSTORE_TILE_BUFFER_TILING);
|
||||
@@ -440,6 +445,9 @@ static int vc4_rcl_surface_setup(struct vc4_exec_info *exec,
|
||||
if (!*obj)
|
||||
return -EINVAL;
|
||||
|
||||
+ if (is_write)
|
||||
+ exec->rcl_write_bo[exec->rcl_write_bo_count++] = *obj;
|
||||
+
|
||||
if (surf->flags & VC4_SUBMIT_RCL_SURFACE_READ_IS_FULL_RES) {
|
||||
if (surf == &exec->args->zs_write) {
|
||||
DRM_ERROR("general zs write may not be a full-res.\n");
|
||||
@@ -542,6 +550,8 @@ vc4_rcl_render_config_surface_setup(struct vc4_exec_info *exec,
|
||||
if (!*obj)
|
||||
return -EINVAL;
|
||||
|
||||
+ exec->rcl_write_bo[exec->rcl_write_bo_count++] = *obj;
|
||||
+
|
||||
if (tiling > VC4_TILING_FORMAT_LT) {
|
||||
DRM_ERROR("Bad tiling format\n");
|
||||
return -EINVAL;
|
||||
@@ -599,15 +609,18 @@ int vc4_get_rcl(struct drm_device *dev, struct vc4_exec_info *exec)
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
- ret = vc4_rcl_surface_setup(exec, &setup.color_read, &args->color_read);
|
||||
+ ret = vc4_rcl_surface_setup(exec, &setup.color_read, &args->color_read,
|
||||
+ false);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
- ret = vc4_rcl_surface_setup(exec, &setup.zs_read, &args->zs_read);
|
||||
+ ret = vc4_rcl_surface_setup(exec, &setup.zs_read, &args->zs_read,
|
||||
+ false);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
- ret = vc4_rcl_surface_setup(exec, &setup.zs_write, &args->zs_write);
|
||||
+ ret = vc4_rcl_surface_setup(exec, &setup.zs_write, &args->zs_write,
|
||||
+ true);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
diff --git a/drivers/gpu/drm/vc4/vc4_validate.c b/drivers/gpu/drm/vc4/vc4_validate.c
|
||||
index 9ce1d0a..26503e3 100644
|
||||
--- a/drivers/gpu/drm/vc4/vc4_validate.c
|
||||
+++ b/drivers/gpu/drm/vc4/vc4_validate.c
|
||||
@@ -267,6 +267,9 @@ validate_indexed_prim_list(VALIDATE_ARGS)
|
||||
if (!ib)
|
||||
return -EINVAL;
|
||||
|
||||
+ exec->bin_dep_seqno = max(exec->bin_dep_seqno,
|
||||
+ to_vc4_bo(&ib->base)->write_seqno);
|
||||
+
|
||||
if (offset > ib->base.size ||
|
||||
(ib->base.size - offset) / index_size < length) {
|
||||
DRM_ERROR("IB access overflow (%d + %d*%d > %zd)\n",
|
||||
@@ -555,8 +558,7 @@ static bool
|
||||
reloc_tex(struct vc4_exec_info *exec,
|
||||
void *uniform_data_u,
|
||||
struct vc4_texture_sample_info *sample,
|
||||
- uint32_t texture_handle_index)
|
||||
-
|
||||
+ uint32_t texture_handle_index, bool is_cs)
|
||||
{
|
||||
struct drm_gem_cma_object *tex;
|
||||
uint32_t p0 = *(uint32_t *)(uniform_data_u + sample->p_offset[0]);
|
||||
@@ -714,6 +716,11 @@ reloc_tex(struct vc4_exec_info *exec,
|
||||
|
||||
*validated_p0 = tex->paddr + p0;
|
||||
|
||||
+ if (is_cs) {
|
||||
+ exec->bin_dep_seqno = max(exec->bin_dep_seqno,
|
||||
+ to_vc4_bo(&tex->base)->write_seqno);
|
||||
+ }
|
||||
+
|
||||
return true;
|
||||
fail:
|
||||
DRM_INFO("Texture p0 at %d: 0x%08x\n", sample->p_offset[0], p0);
|
||||
@@ -835,7 +842,8 @@ validate_gl_shader_rec(struct drm_device *dev,
|
||||
if (!reloc_tex(exec,
|
||||
uniform_data_u,
|
||||
&validated_shader->texture_samples[tex],
|
||||
- texture_handles_u[tex])) {
|
||||
+ texture_handles_u[tex],
|
||||
+ i == 2)) {
|
||||
return -EINVAL;
|
||||
}
|
||||
}
|
||||
@@ -867,6 +875,9 @@ validate_gl_shader_rec(struct drm_device *dev,
|
||||
uint32_t stride = *(uint8_t *)(pkt_u + o + 5);
|
||||
uint32_t max_index;
|
||||
|
||||
+ exec->bin_dep_seqno = max(exec->bin_dep_seqno,
|
||||
+ to_vc4_bo(&vbo->base)->write_seqno);
|
||||
+
|
||||
if (state->addr & 0x8)
|
||||
stride |= (*(uint32_t *)(pkt_u + 100 + i * 4)) & ~0xff;
|
||||
|
||||
--
|
||||
2.9.3
|
||||
|
||||
From f379f5432e4b74e3d1d894ce2fefbe1b8a3c24fd Mon Sep 17 00:00:00 2001
|
||||
From: Eric Anholt <eric@anholt.net>
|
||||
Date: Wed, 28 Sep 2016 19:20:44 -0700
|
||||
Subject: [PATCH 4/4] drm/vc4: Increase timeout for HDMI_SCHEDULER_CONTROL
|
||||
changes.
|
||||
|
||||
Fixes occasional debug spew at boot when connected directly through
|
||||
HDMI, and probably confusing the HDMI state machine when we go trying
|
||||
to poke registers for the enable sequence too soon.
|
||||
|
||||
Signed-off-by: Eric Anholt <eric@anholt.net>
|
||||
---
|
||||
drivers/gpu/drm/vc4/vc4_hdmi.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdmi.c
|
||||
index 5df4e74..9a6883d 100644
|
||||
--- a/drivers/gpu/drm/vc4/vc4_hdmi.c
|
||||
+++ b/drivers/gpu/drm/vc4/vc4_hdmi.c
|
||||
@@ -399,7 +399,7 @@ static void vc4_hdmi_encoder_enable(struct drm_encoder *encoder)
|
||||
VC4_HDMI_SCHEDULER_CONTROL_MODE_HDMI);
|
||||
|
||||
ret = wait_for(HDMI_READ(VC4_HDMI_SCHEDULER_CONTROL) &
|
||||
- VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE, 1);
|
||||
+ VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE, 1000);
|
||||
WARN_ONCE(ret, "Timeout waiting for "
|
||||
"VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE\n");
|
||||
} else {
|
||||
@@ -411,7 +411,7 @@ static void vc4_hdmi_encoder_enable(struct drm_encoder *encoder)
|
||||
~VC4_HDMI_SCHEDULER_CONTROL_MODE_HDMI);
|
||||
|
||||
ret = wait_for(!(HDMI_READ(VC4_HDMI_SCHEDULER_CONTROL) &
|
||||
- VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE), 1);
|
||||
+ VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE), 1000);
|
||||
WARN_ONCE(ret, "Timeout waiting for "
|
||||
"!VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE\n");
|
||||
}
|
||||
--
|
||||
2.9.3
|
||||
|
||||
From bd712d14886c37eb804036b2ac3036df79d33476 Mon Sep 17 00:00:00 2001
|
||||
From: Eric Anholt <eric@anholt.net>
|
||||
Date: Thu, 29 Sep 2016 15:34:43 -0700
|
||||
Subject: [PATCH] drm/vc4: Set up the AVI and SPD infoframes.
|
||||
|
||||
Fixes a purple bar on the left side of the screen with my Dell
|
||||
2408WFP. It will also be required for supporting the double-clocked
|
||||
video modes.
|
||||
|
||||
Signed-off-by: Eric Anholt <eric@anholt.net>
|
||||
---
|
||||
drivers/gpu/drm/vc4/vc4_hdmi.c | 136 +++++++++++++++++++++++++++++++++++++++--
|
||||
drivers/gpu/drm/vc4/vc4_regs.h | 5 ++
|
||||
2 files changed, 136 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdmi.c
|
||||
index 9a6883d..f722334 100644
|
||||
--- a/drivers/gpu/drm/vc4/vc4_hdmi.c
|
||||
+++ b/drivers/gpu/drm/vc4/vc4_hdmi.c
|
||||
@@ -62,6 +62,8 @@ struct vc4_hdmi {
|
||||
struct vc4_hdmi_encoder {
|
||||
struct vc4_encoder base;
|
||||
bool hdmi_monitor;
|
||||
+ bool limited_rgb_range;
|
||||
+ bool rgb_range_selectable;
|
||||
};
|
||||
|
||||
static inline struct vc4_hdmi_encoder *
|
||||
@@ -205,6 +207,12 @@ static int vc4_hdmi_connector_get_modes(struct drm_connector *connector)
|
||||
return -ENODEV;
|
||||
|
||||
vc4_encoder->hdmi_monitor = drm_detect_hdmi_monitor(edid);
|
||||
+
|
||||
+ if (edid && edid->input & DRM_EDID_INPUT_DIGITAL) {
|
||||
+ vc4_encoder->rgb_range_selectable =
|
||||
+ drm_rgb_quant_range_selectable(edid);
|
||||
+ }
|
||||
+
|
||||
drm_mode_connector_update_edid_property(connector, edid);
|
||||
ret = drm_add_edid_modes(connector, edid);
|
||||
|
||||
@@ -272,6 +280,117 @@ static const struct drm_encoder_funcs vc4_hdmi_encoder_funcs = {
|
||||
.destroy = vc4_hdmi_encoder_destroy,
|
||||
};
|
||||
|
||||
+static int vc4_hdmi_stop_packet(struct drm_encoder *encoder,
|
||||
+ enum hdmi_infoframe_type type)
|
||||
+{
|
||||
+ struct drm_device *dev = encoder->dev;
|
||||
+ struct vc4_dev *vc4 = to_vc4_dev(dev);
|
||||
+ u32 packet_id = type - 0x80;
|
||||
+
|
||||
+ HDMI_WRITE(VC4_HDMI_RAM_PACKET_CONFIG,
|
||||
+ HDMI_READ(VC4_HDMI_RAM_PACKET_CONFIG) & ~BIT(packet_id));
|
||||
+
|
||||
+ return wait_for(!(HDMI_READ(VC4_HDMI_RAM_PACKET_STATUS) &
|
||||
+ BIT(packet_id)), 100);
|
||||
+}
|
||||
+
|
||||
+static void vc4_hdmi_write_infoframe(struct drm_encoder *encoder,
|
||||
+ union hdmi_infoframe *frame)
|
||||
+{
|
||||
+ struct drm_device *dev = encoder->dev;
|
||||
+ struct vc4_dev *vc4 = to_vc4_dev(dev);
|
||||
+ u32 packet_id = frame->any.type - 0x80;
|
||||
+ u32 packet_reg = VC4_HDMI_GCP_0 + VC4_HDMI_PACKET_STRIDE * packet_id;
|
||||
+ uint8_t buffer[VC4_HDMI_PACKET_STRIDE];
|
||||
+ ssize_t len, i;
|
||||
+ int ret;
|
||||
+
|
||||
+ WARN_ONCE(!(HDMI_READ(VC4_HDMI_RAM_PACKET_CONFIG) &
|
||||
+ VC4_HDMI_RAM_PACKET_ENABLE),
|
||||
+ "Packet RAM has to be on to store the packet.");
|
||||
+
|
||||
+ len = hdmi_infoframe_pack(frame, buffer, sizeof(buffer));
|
||||
+ if (len < 0)
|
||||
+ return;
|
||||
+
|
||||
+ ret = vc4_hdmi_stop_packet(encoder, frame->any.type);
|
||||
+ if (ret) {
|
||||
+ DRM_ERROR("Failed to wait for infoframe to go idle: %d\n", ret);
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ for (i = 0; i < len; i += 7) {
|
||||
+ HDMI_WRITE(packet_reg,
|
||||
+ buffer[i + 0] << 0 |
|
||||
+ buffer[i + 1] << 8 |
|
||||
+ buffer[i + 2] << 16);
|
||||
+ packet_reg += 4;
|
||||
+
|
||||
+ HDMI_WRITE(packet_reg,
|
||||
+ buffer[i + 3] << 0 |
|
||||
+ buffer[i + 4] << 8 |
|
||||
+ buffer[i + 5] << 16 |
|
||||
+ buffer[i + 6] << 24);
|
||||
+ packet_reg += 4;
|
||||
+ }
|
||||
+
|
||||
+ HDMI_WRITE(VC4_HDMI_RAM_PACKET_CONFIG,
|
||||
+ HDMI_READ(VC4_HDMI_RAM_PACKET_CONFIG) | BIT(packet_id));
|
||||
+ ret = wait_for((HDMI_READ(VC4_HDMI_RAM_PACKET_STATUS) &
|
||||
+ BIT(packet_id)), 100);
|
||||
+ if (ret)
|
||||
+ DRM_ERROR("Failed to wait for infoframe to start: %d\n", ret);
|
||||
+}
|
||||
+
|
||||
+static void vc4_hdmi_set_avi_infoframe(struct drm_encoder *encoder)
|
||||
+{
|
||||
+ struct vc4_hdmi_encoder *vc4_encoder = to_vc4_hdmi_encoder(encoder);
|
||||
+ struct drm_crtc *crtc = encoder->crtc;
|
||||
+ const struct drm_display_mode *mode = &crtc->state->adjusted_mode;
|
||||
+ union hdmi_infoframe frame;
|
||||
+ int ret;
|
||||
+
|
||||
+ ret = drm_hdmi_avi_infoframe_from_display_mode(&frame.avi, mode);
|
||||
+ if (ret < 0) {
|
||||
+ DRM_ERROR("couldn't fill AVI infoframe\n");
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ if (vc4_encoder->rgb_range_selectable) {
|
||||
+ if (vc4_encoder->limited_rgb_range) {
|
||||
+ frame.avi.quantization_range =
|
||||
+ HDMI_QUANTIZATION_RANGE_LIMITED;
|
||||
+ } else {
|
||||
+ frame.avi.quantization_range =
|
||||
+ HDMI_QUANTIZATION_RANGE_FULL;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ vc4_hdmi_write_infoframe(encoder, &frame);
|
||||
+}
|
||||
+
|
||||
+static void vc4_hdmi_set_spd_infoframe(struct drm_encoder *encoder)
|
||||
+{
|
||||
+ union hdmi_infoframe frame;
|
||||
+ int ret;
|
||||
+
|
||||
+ ret = hdmi_spd_infoframe_init(&frame.spd, "Broadcom", "Videocore");
|
||||
+ if (ret < 0) {
|
||||
+ DRM_ERROR("couldn't fill SPD infoframe\n");
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ frame.spd.sdi = HDMI_SPD_SDI_PC;
|
||||
+
|
||||
+ vc4_hdmi_write_infoframe(encoder, &frame);
|
||||
+}
|
||||
+
|
||||
+static void vc4_hdmi_set_infoframes(struct drm_encoder *encoder)
|
||||
+{
|
||||
+ vc4_hdmi_set_avi_infoframe(encoder);
|
||||
+ vc4_hdmi_set_spd_infoframe(encoder);
|
||||
+}
|
||||
+
|
||||
static void vc4_hdmi_encoder_mode_set(struct drm_encoder *encoder,
|
||||
struct drm_display_mode *unadjusted_mode,
|
||||
struct drm_display_mode *mode)
|
||||
@@ -336,8 +455,9 @@ static void vc4_hdmi_encoder_mode_set(struct drm_encoder *encoder,
|
||||
|
||||
if (vc4_encoder->hdmi_monitor && drm_match_cea_mode(mode) > 1) {
|
||||
/* CEA VICs other than #1 requre limited range RGB
|
||||
- * output. Apply a colorspace conversion to squash
|
||||
- * 0-255 down to 16-235. The matrix here is:
|
||||
+ * output unless overridden by an AVI infoframe.
|
||||
+ * Apply a colorspace conversion to squash 0-255 down
|
||||
+ * to 16-235. The matrix here is:
|
||||
*
|
||||
* [ 0 0 0.8594 16]
|
||||
* [ 0 0.8594 0 16]
|
||||
@@ -355,6 +475,9 @@ static void vc4_hdmi_encoder_mode_set(struct drm_encoder *encoder,
|
||||
HD_WRITE(VC4_HD_CSC_24_23, (0x100 << 16) | 0x000);
|
||||
HD_WRITE(VC4_HD_CSC_32_31, (0x000 << 16) | 0x6e0);
|
||||
HD_WRITE(VC4_HD_CSC_34_33, (0x100 << 16) | 0x000);
|
||||
+ vc4_encoder->limited_rgb_range = true;
|
||||
+ } else {
|
||||
+ vc4_encoder->limited_rgb_range = false;
|
||||
}
|
||||
|
||||
/* The RGB order applies even when CSC is disabled. */
|
||||
@@ -373,6 +496,8 @@ static void vc4_hdmi_encoder_disable(struct drm_encoder *encoder)
|
||||
struct drm_device *dev = encoder->dev;
|
||||
struct vc4_dev *vc4 = to_vc4_dev(dev);
|
||||
|
||||
+ HDMI_WRITE(VC4_HDMI_RAM_PACKET_CONFIG, 0);
|
||||
+
|
||||
HDMI_WRITE(VC4_HDMI_TX_PHY_RESET_CTL, 0xf << 16);
|
||||
HD_WRITE(VC4_HD_VID_CTL,
|
||||
HD_READ(VC4_HD_VID_CTL) & ~VC4_HD_VID_CTL_ENABLE);
|
||||
@@ -425,9 +550,10 @@ static void vc4_hdmi_encoder_enable(struct drm_encoder *encoder)
|
||||
HDMI_READ(VC4_HDMI_SCHEDULER_CONTROL) |
|
||||
VC4_HDMI_SCHEDULER_CONTROL_VERT_ALWAYS_KEEPOUT);
|
||||
|
||||
- /* XXX: Set HDMI_RAM_PACKET_CONFIG (1 << 16) and set
|
||||
- * up the infoframe.
|
||||
- */
|
||||
+ HDMI_WRITE(VC4_HDMI_RAM_PACKET_CONFIG,
|
||||
+ VC4_HDMI_RAM_PACKET_ENABLE);
|
||||
+
|
||||
+ vc4_hdmi_set_infoframes(encoder);
|
||||
|
||||
drift = HDMI_READ(VC4_HDMI_FIFO_CTL);
|
||||
drift &= VC4_HDMI_FIFO_VALID_WRITE_MASK;
|
||||
diff --git a/drivers/gpu/drm/vc4/vc4_regs.h b/drivers/gpu/drm/vc4/vc4_regs.h
|
||||
index 9ecd6ff..a4b5370 100644
|
||||
--- a/drivers/gpu/drm/vc4/vc4_regs.h
|
||||
+++ b/drivers/gpu/drm/vc4/vc4_regs.h
|
||||
@@ -438,6 +438,8 @@
|
||||
#define VC4_HDMI_RAM_PACKET_CONFIG 0x0a0
|
||||
# define VC4_HDMI_RAM_PACKET_ENABLE BIT(16)
|
||||
|
||||
+#define VC4_HDMI_RAM_PACKET_STATUS 0x0a4
|
||||
+
|
||||
#define VC4_HDMI_HORZA 0x0c4
|
||||
# define VC4_HDMI_HORZA_VPOS BIT(14)
|
||||
# define VC4_HDMI_HORZA_HPOS BIT(13)
|
||||
@@ -499,6 +501,9 @@
|
||||
|
||||
#define VC4_HDMI_TX_PHY_RESET_CTL 0x2c0
|
||||
|
||||
+#define VC4_HDMI_GCP_0 0x400
|
||||
+#define VC4_HDMI_PACKET_STRIDE 0x24
|
||||
+
|
||||
#define VC4_HD_M_CTL 0x00c
|
||||
# define VC4_HD_M_REGISTER_FILE_STANDBY (3 << 6)
|
||||
# define VC4_HD_M_RAM_STANDBY (3 << 4)
|
||||
--
|
||||
2.9.3
|
||||
|
@ -2588,6 +2588,7 @@ CONFIG_TOUCHSCREEN_ZFORCE=m
|
||||
# CONFIG_TOUCHSCREEN_TSC2004 is not set
|
||||
# CONFIG_TOUCHSCREEN_MELFAS_MIP4 is not set
|
||||
# CONFIG_TOUCHSCREEN_EKTF2127 is not set
|
||||
# CONFIG_TOUCHSCREEN_ATMEL_MXT_T37 is not set
|
||||
|
||||
CONFIG_INPUT_MISC=y
|
||||
CONFIG_INPUT_E3X0_BUTTON=m
|
||||
@ -2620,6 +2621,10 @@ CONFIG_RMI4_F11=y
|
||||
CONFIG_RMI4_F12=y
|
||||
CONFIG_RMI4_F30=y
|
||||
CONFIG_RMI4_SPI=m
|
||||
# This throws off module filtering because it depends on V4L2 which is filtered
|
||||
# Leave this off until someone explicitly requests it and figure out what to
|
||||
# do then.
|
||||
# CONFIG_RMI4_F54 is not set
|
||||
|
||||
#
|
||||
# Character devices
|
||||
@ -3416,6 +3421,7 @@ CONFIG_DRM_RADEON_USERPTR=y
|
||||
CONFIG_DRM_AMDGPU=m
|
||||
CONFIG_DRM_AMD_ACP=y
|
||||
# CONFIG_DRM_AMDGPU_CIK is not set
|
||||
# CONFIG_DRM_AMDGPU_SI is not set
|
||||
CONFIG_DRM_AMDGPU_USERPTR=y
|
||||
# CONFIG_DRM_AMDGPU_GART_DEBUGFS is not set
|
||||
CONFIG_DRM_AMD_POWERPLAY=y
|
||||
@ -3448,12 +3454,16 @@ CONFIG_DRM_VIRTIO_GPU=m
|
||||
# CONFIG_DRM_PANEL is not set
|
||||
# CONFIG_DRM_PANEL_SIMPLE is not set
|
||||
# CONFIG_DRM_PANEL_SAMSUNG_S6E8AA0 is not set
|
||||
# CONFIG_DRM_PANEL_JDI_LT070ME05000 is not set
|
||||
CONFIG_DRM_VGEM=m
|
||||
# CONFIG_DRM_MALI_DISPLAY is not set
|
||||
# CONFIG_DRM_SII902X is not set
|
||||
# CONFIG_DRM_TOSHIBA_TC358767 is not set
|
||||
# CONFIG_DRM_I2C_ADV7533 is not set
|
||||
# CONFIG_DRM_DUMB_VGA_DAC is not set
|
||||
# CONFIG_DRM_LEGACY is not set
|
||||
|
||||
# CONFIG_SW_SYNC is not set
|
||||
|
||||
#
|
||||
# PCMCIA character devices
|
||||
@ -3576,6 +3586,7 @@ CONFIG_VIDEO_USBTV=m
|
||||
CONFIG_VIDEO_TW686X=m
|
||||
# Staging version?
|
||||
# CONFIG_VIDEO_TW686X_KH is not set
|
||||
# CONFIG_VIDEO_TW5864 is not set
|
||||
|
||||
CONFIG_USB_VIDEO_CLASS=m
|
||||
CONFIG_USB_VIDEO_CLASS_INPUT_EVDEV=y
|
||||
|
@ -238,6 +238,7 @@ CONFIG_ND_PFN=m
|
||||
|
||||
CONFIG_DEV_DAX=m
|
||||
CONFIG_DEV_DAX_PMEM=m
|
||||
CONFIG_NR_DEV_DAX=32768
|
||||
|
||||
# Staging
|
||||
CONFIG_INFINIBAND_HFI1=m
|
||||
|
2
gitrev
2
gitrev
@ -1 +1 @@
|
||||
101105b1717f536ca741f940033996302d4ef191
|
||||
1573d2caf713874cfe0d1336c823d0fb548d8bed
|
||||
|
26
kernel.spec
26
kernel.spec
@ -42,7 +42,7 @@ Summary: The Linux kernel
|
||||
# For non-released -rc kernels, this will be appended after the rcX and
|
||||
# gitX tags, so a 3 here would become part of release "0.rcX.gitX.3"
|
||||
#
|
||||
%global baserelease 2
|
||||
%global baserelease 1
|
||||
%global fedora_build %{baserelease}
|
||||
|
||||
# base_sublevel is the kernel version we're starting with and patching
|
||||
@ -69,7 +69,7 @@ Summary: The Linux kernel
|
||||
# The rc snapshot level
|
||||
%define rcrev 0
|
||||
# The git snapshot level
|
||||
%define gitrev 6
|
||||
%define gitrev 7
|
||||
# Set rpm version accordingly
|
||||
%define rpmversion 4.%{upstream_sublevel}.0
|
||||
%endif
|
||||
@ -515,8 +515,6 @@ Patch430: ARM-tegra-usb-no-reset.patch
|
||||
|
||||
Patch431: bcm2837-initial-support.patch
|
||||
|
||||
Patch432: bcm283x-vc4-fixes.patch
|
||||
|
||||
Patch460: lib-cpumask-Make-CPUMASK_OFFSTACK-usable-without-deb.patch
|
||||
|
||||
Patch466: input-kill-stupid-messages.patch
|
||||
@ -600,25 +598,12 @@ Patch508: kexec-uefi-copy-secure_boot-flag-in-boot-params.patch
|
||||
#CVE-2016-3134 rhbz 1317383 1317384
|
||||
Patch665: netfilter-x_tables-deal-with-bogus-nextoffset-values.patch
|
||||
|
||||
#rhbz 1200901 (There should be something better upstream at some point)
|
||||
Patch842: qxl-reapply-cursor-after-SetCrtc-calls.patch
|
||||
|
||||
#rhbz 1360688
|
||||
Patch847: rc-core-fix-repeat-events.patch
|
||||
|
||||
#rhbz 1374212
|
||||
Patch848: 0001-cpupower-Correct-return-type-of-cpu_power_is_cpu_onl.patch
|
||||
|
||||
#ongoing complaint, full discussion delayed until ksummit/plumbers
|
||||
Patch849: 0001-iio-Use-event-header-from-kernel-tree.patch
|
||||
|
||||
# Fix came in locally
|
||||
Patch851: 0001-drivers-net-phy-Correct-duplicate-MDIO_XGENE-entry.patch
|
||||
|
||||
# Maybe related to perf build failures?
|
||||
Patch852: 0001-Revert-tools-build-Support-compiling-C-source-file.patch
|
||||
Patch853: 0002-Revert-tools-build-Add-support-for-host-programs-for.patch
|
||||
|
||||
# END OF PATCH DEFINITIONS
|
||||
|
||||
%endif
|
||||
@ -1660,7 +1645,7 @@ BuildKernel %make_target %kernel_image
|
||||
%endif
|
||||
|
||||
%global perf_make \
|
||||
make -s EXTRA_CFLAGS="${RPM_OPT_FLAGS}" LDFLAGS="%{__global_ldflags}" %{?cross_opts} %{?_smp_mflags} -C tools/perf V=1 NO_PERF_READ_VDSO32=1 NO_PERF_READ_VDSOX32=1 WERROR=0 NO_LIBUNWIND=1 HAVE_CPLUS_DEMANGLE=1 NO_GTK2=1 NO_STRLCPY=1 NO_BIONIC=1 prefix=%{_prefix}
|
||||
make -s EXTRA_CFLAGS="${RPM_OPT_FLAGS}" LDFLAGS="%{__global_ldflags}" %{?cross_opts} -C tools/perf V=1 NO_PERF_READ_VDSO32=1 NO_PERF_READ_VDSOX32=1 WERROR=0 NO_LIBUNWIND=1 HAVE_CPLUS_DEMANGLE=1 NO_GTK2=1 NO_STRLCPY=1 NO_BIONIC=1 prefix=%{_prefix}
|
||||
%if %{with_perf}
|
||||
# perf
|
||||
%{perf_make} DESTDIR=$RPM_BUILD_ROOT all
|
||||
@ -2155,6 +2140,11 @@ fi
|
||||
#
|
||||
#
|
||||
%changelog
|
||||
* Wed Oct 12 2016 Laura Abbott <labbott@redhat.com> - 4.9.0-0.rc0.git7.1
|
||||
- Linux v4.8-14109-g1573d2c
|
||||
- Drop the extra parallel build optiosn from perf since perf does that on
|
||||
its own.
|
||||
|
||||
* Wed Oct 12 2016 Josh Boyer <jwboyer@fedoraproject.org>
|
||||
- Adjust aarch64 config options
|
||||
|
||||
|
@ -1,439 +0,0 @@
|
||||
From 92777b4dfc3920edb449d0be6ead65d8460653cc Mon Sep 17 00:00:00 2001
|
||||
From: Ray Strode <rstrode@redhat.com>
|
||||
Date: Tue, 12 May 2015 12:51:18 -0400
|
||||
Subject: [PATCH] drm/qxl: reapply cursor after SetCrtc calls
|
||||
|
||||
The qxl driver currently destroys and recreates the
|
||||
qxl "primary" any time the first crtc is set.
|
||||
|
||||
A side-effect of destroying the primary is mouse state
|
||||
associated with the crtc is lost, which leads to
|
||||
disappearing mouse cursors on wayland sessions.
|
||||
|
||||
This commit changes the driver to reapply the cursor
|
||||
any time SetCrtc is called. It achieves this by keeping
|
||||
a copy of the cursor data on the qxl_crtc struct.
|
||||
|
||||
Signed-off-by: Ray Strode <rstrode@redhat.com>
|
||||
|
||||
https://bugzilla.redhat.com/show_bug.cgi?id=1200901
|
||||
---
|
||||
drivers/gpu/drm/qxl/qxl_display.c | 98 +++++++++++++++++++++++++++++++++++++++
|
||||
drivers/gpu/drm/qxl/qxl_drv.h | 1 +
|
||||
2 files changed, 99 insertions(+)
|
||||
|
||||
diff --git a/drivers/gpu/drm/qxl/qxl_display.c b/drivers/gpu/drm/qxl/qxl_display.c
|
||||
index 3aef127..34ab444 100644
|
||||
--- a/drivers/gpu/drm/qxl/qxl_display.c
|
||||
+++ b/drivers/gpu/drm/qxl/qxl_display.c
|
||||
@@ -184,60 +184,61 @@ static struct mode_size {
|
||||
{1440, 900},
|
||||
{1400, 1050},
|
||||
{1680, 1050},
|
||||
{1600, 1200},
|
||||
{1920, 1080},
|
||||
{1920, 1200}
|
||||
};
|
||||
|
||||
static int qxl_add_common_modes(struct drm_connector *connector,
|
||||
unsigned pwidth,
|
||||
unsigned pheight)
|
||||
{
|
||||
struct drm_device *dev = connector->dev;
|
||||
struct drm_display_mode *mode = NULL;
|
||||
int i;
|
||||
for (i = 0; i < ARRAY_SIZE(common_modes); i++) {
|
||||
mode = drm_cvt_mode(dev, common_modes[i].w, common_modes[i].h,
|
||||
60, false, false, false);
|
||||
if (common_modes[i].w == pwidth && common_modes[i].h == pheight)
|
||||
mode->type |= DRM_MODE_TYPE_PREFERRED;
|
||||
drm_mode_probed_add(connector, mode);
|
||||
}
|
||||
return i - 1;
|
||||
}
|
||||
|
||||
static void qxl_crtc_destroy(struct drm_crtc *crtc)
|
||||
{
|
||||
struct qxl_crtc *qxl_crtc = to_qxl_crtc(crtc);
|
||||
|
||||
drm_crtc_cleanup(crtc);
|
||||
+ kfree(qxl_crtc->cursor);
|
||||
kfree(qxl_crtc);
|
||||
}
|
||||
|
||||
static int qxl_crtc_page_flip(struct drm_crtc *crtc,
|
||||
struct drm_framebuffer *fb,
|
||||
struct drm_pending_vblank_event *event,
|
||||
uint32_t page_flip_flags)
|
||||
{
|
||||
struct drm_device *dev = crtc->dev;
|
||||
struct qxl_device *qdev = dev->dev_private;
|
||||
struct qxl_framebuffer *qfb_src = to_qxl_framebuffer(fb);
|
||||
struct qxl_framebuffer *qfb_old = to_qxl_framebuffer(crtc->primary->fb);
|
||||
struct qxl_bo *bo_old = gem_to_qxl_bo(qfb_old->obj);
|
||||
struct qxl_bo *bo = gem_to_qxl_bo(qfb_src->obj);
|
||||
unsigned long flags;
|
||||
struct drm_clip_rect norect = {
|
||||
.x1 = 0,
|
||||
.y1 = 0,
|
||||
.x2 = fb->width,
|
||||
.y2 = fb->height
|
||||
};
|
||||
int inc = 1;
|
||||
int one_clip_rect = 1;
|
||||
int ret = 0;
|
||||
|
||||
crtc->primary->fb = fb;
|
||||
bo_old->is_primary = false;
|
||||
bo->is_primary = true;
|
||||
|
||||
ret = qxl_bo_reserve(bo, false);
|
||||
@@ -269,60 +270,145 @@ static int qxl_crtc_page_flip(struct drm_crtc *crtc,
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int
|
||||
qxl_hide_cursor(struct qxl_device *qdev)
|
||||
{
|
||||
struct qxl_release *release;
|
||||
struct qxl_cursor_cmd *cmd;
|
||||
int ret;
|
||||
|
||||
ret = qxl_alloc_release_reserved(qdev, sizeof(*cmd), QXL_RELEASE_CURSOR_CMD,
|
||||
&release, NULL);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
ret = qxl_release_reserve_list(release, true);
|
||||
if (ret) {
|
||||
qxl_release_free(qdev, release);
|
||||
return ret;
|
||||
}
|
||||
|
||||
cmd = (struct qxl_cursor_cmd *)qxl_release_map(qdev, release);
|
||||
cmd->type = QXL_CURSOR_HIDE;
|
||||
qxl_release_unmap(qdev, release, &cmd->release_info);
|
||||
|
||||
qxl_push_cursor_ring_release(qdev, release, QXL_CMD_CURSOR, false);
|
||||
qxl_release_fence_buffer_objects(release);
|
||||
return 0;
|
||||
}
|
||||
|
||||
+static int qxl_crtc_stash_cursor(struct drm_crtc *crtc,
|
||||
+ struct qxl_cursor *cursor)
|
||||
+{
|
||||
+ struct qxl_crtc *qcrtc = to_qxl_crtc(crtc);
|
||||
+ size_t cursor_size;
|
||||
+
|
||||
+ cursor_size = sizeof(struct qxl_cursor) + cursor->data_size;
|
||||
+
|
||||
+ if (!qcrtc->cursor || qcrtc->cursor->data_size != cursor->data_size) {
|
||||
+ kfree(qcrtc->cursor);
|
||||
+ qcrtc->cursor = kmalloc(cursor_size, GFP_KERNEL);
|
||||
+
|
||||
+ if (!qcrtc->cursor)
|
||||
+ return -ENOMEM;
|
||||
+ }
|
||||
+
|
||||
+ memcpy(qcrtc->cursor, cursor, cursor_size);
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+static int qxl_crtc_apply_cursor(struct drm_crtc *crtc)
|
||||
+{
|
||||
+ struct qxl_crtc *qcrtc = to_qxl_crtc(crtc);
|
||||
+ struct drm_device *dev = crtc->dev;
|
||||
+ struct qxl_device *qdev = dev->dev_private;
|
||||
+ struct qxl_cursor *cursor;
|
||||
+ struct qxl_cursor_cmd *cmd;
|
||||
+ struct qxl_bo *cursor_bo;
|
||||
+ struct qxl_release *release;
|
||||
+ size_t cursor_size;
|
||||
+ int ret = 0;
|
||||
+
|
||||
+ if (!qcrtc->cursor)
|
||||
+ return 0;
|
||||
+
|
||||
+ cursor_size = sizeof(*qcrtc->cursor) + qcrtc->cursor->data_size;
|
||||
+
|
||||
+ ret = qxl_alloc_release_reserved(qdev, sizeof(*cmd),
|
||||
+ QXL_RELEASE_CURSOR_CMD,
|
||||
+ &release, NULL);
|
||||
+ if (ret)
|
||||
+ return ret;
|
||||
+
|
||||
+ ret = qxl_alloc_bo_reserved(qdev, release, cursor_size, &cursor_bo);
|
||||
+ if (ret)
|
||||
+ goto out_free_release;
|
||||
+
|
||||
+ ret = qxl_release_reserve_list(release, false);
|
||||
+ if (ret)
|
||||
+ goto out_free_bo;
|
||||
+
|
||||
+ ret = qxl_bo_kmap(cursor_bo, (void **)&cursor);
|
||||
+ if (ret)
|
||||
+ goto out_backoff;
|
||||
+
|
||||
+ memcpy(cursor, qcrtc->cursor, cursor_size);
|
||||
+
|
||||
+ qxl_bo_kunmap(cursor_bo);
|
||||
+
|
||||
+ cmd = (struct qxl_cursor_cmd *)qxl_release_map(qdev, release);
|
||||
+ cmd->type = QXL_CURSOR_SET;
|
||||
+ cmd->u.set.position.x = qcrtc->cur_x + qcrtc->hot_spot_x;
|
||||
+ cmd->u.set.position.y = qcrtc->cur_y + qcrtc->hot_spot_y;
|
||||
+
|
||||
+ cmd->u.set.shape = qxl_bo_physical_address(qdev, cursor_bo, 0);
|
||||
+
|
||||
+ cmd->u.set.visible = 1;
|
||||
+ qxl_release_unmap(qdev, release, &cmd->release_info);
|
||||
+
|
||||
+ qxl_push_cursor_ring_release(qdev, release, QXL_CMD_CURSOR, false);
|
||||
+ qxl_release_fence_buffer_objects(release);
|
||||
+ qxl_bo_unref(&cursor_bo);
|
||||
+
|
||||
+ return ret;
|
||||
+
|
||||
+out_backoff:
|
||||
+ qxl_release_backoff_reserve_list(release);
|
||||
+out_free_bo:
|
||||
+ qxl_bo_unref(&cursor_bo);
|
||||
+out_free_release:
|
||||
+ qxl_release_free(qdev, release);
|
||||
+ return ret;
|
||||
+}
|
||||
+
|
||||
static int qxl_crtc_cursor_set2(struct drm_crtc *crtc,
|
||||
struct drm_file *file_priv,
|
||||
uint32_t handle,
|
||||
uint32_t width,
|
||||
uint32_t height, int32_t hot_x, int32_t hot_y)
|
||||
{
|
||||
struct drm_device *dev = crtc->dev;
|
||||
struct qxl_device *qdev = dev->dev_private;
|
||||
struct qxl_crtc *qcrtc = to_qxl_crtc(crtc);
|
||||
struct drm_gem_object *obj;
|
||||
struct qxl_cursor *cursor;
|
||||
struct qxl_cursor_cmd *cmd;
|
||||
struct qxl_bo *cursor_bo, *user_bo;
|
||||
struct qxl_release *release;
|
||||
void *user_ptr;
|
||||
|
||||
int size = 64*64*4;
|
||||
int ret = 0;
|
||||
if (!handle)
|
||||
return qxl_hide_cursor(qdev);
|
||||
|
||||
obj = drm_gem_object_lookup(file_priv, handle);
|
||||
if (!obj) {
|
||||
DRM_ERROR("cannot find cursor object\n");
|
||||
return -ENOENT;
|
||||
}
|
||||
|
||||
user_bo = gem_to_qxl_bo(obj);
|
||||
|
||||
ret = qxl_bo_reserve(user_bo, false);
|
||||
@@ -343,60 +429,66 @@ static int qxl_crtc_cursor_set2(struct drm_crtc *crtc,
|
||||
&release, NULL);
|
||||
if (ret)
|
||||
goto out_kunmap;
|
||||
|
||||
ret = qxl_alloc_bo_reserved(qdev, release, sizeof(struct qxl_cursor) + size,
|
||||
&cursor_bo);
|
||||
if (ret)
|
||||
goto out_free_release;
|
||||
|
||||
ret = qxl_release_reserve_list(release, false);
|
||||
if (ret)
|
||||
goto out_free_bo;
|
||||
|
||||
ret = qxl_bo_kmap(cursor_bo, (void **)&cursor);
|
||||
if (ret)
|
||||
goto out_backoff;
|
||||
|
||||
cursor->header.unique = 0;
|
||||
cursor->header.type = SPICE_CURSOR_TYPE_ALPHA;
|
||||
cursor->header.width = 64;
|
||||
cursor->header.height = 64;
|
||||
cursor->header.hot_spot_x = hot_x;
|
||||
cursor->header.hot_spot_y = hot_y;
|
||||
cursor->data_size = size;
|
||||
cursor->chunk.next_chunk = 0;
|
||||
cursor->chunk.prev_chunk = 0;
|
||||
cursor->chunk.data_size = size;
|
||||
|
||||
memcpy(cursor->chunk.data, user_ptr, size);
|
||||
|
||||
+ ret = qxl_crtc_stash_cursor(crtc, cursor);
|
||||
+ if (ret) {
|
||||
+ DRM_ERROR("cannot save cursor, may be lost on next mode set\n");
|
||||
+ ret = 0;
|
||||
+ }
|
||||
+
|
||||
qxl_bo_kunmap(cursor_bo);
|
||||
|
||||
qxl_bo_kunmap(user_bo);
|
||||
|
||||
qcrtc->cur_x += qcrtc->hot_spot_x - hot_x;
|
||||
qcrtc->cur_y += qcrtc->hot_spot_y - hot_y;
|
||||
qcrtc->hot_spot_x = hot_x;
|
||||
qcrtc->hot_spot_y = hot_y;
|
||||
|
||||
cmd = (struct qxl_cursor_cmd *)qxl_release_map(qdev, release);
|
||||
cmd->type = QXL_CURSOR_SET;
|
||||
cmd->u.set.position.x = qcrtc->cur_x + qcrtc->hot_spot_x;
|
||||
cmd->u.set.position.y = qcrtc->cur_y + qcrtc->hot_spot_y;
|
||||
|
||||
cmd->u.set.shape = qxl_bo_physical_address(qdev, cursor_bo, 0);
|
||||
|
||||
cmd->u.set.visible = 1;
|
||||
qxl_release_unmap(qdev, release, &cmd->release_info);
|
||||
|
||||
qxl_push_cursor_ring_release(qdev, release, QXL_CMD_CURSOR, false);
|
||||
qxl_release_fence_buffer_objects(release);
|
||||
|
||||
/* finish with the userspace bo */
|
||||
ret = qxl_bo_reserve(user_bo, false);
|
||||
if (!ret) {
|
||||
qxl_bo_unpin(user_bo);
|
||||
qxl_bo_unreserve(user_bo);
|
||||
}
|
||||
drm_gem_object_unreference_unlocked(obj);
|
||||
|
||||
@@ -628,60 +720,66 @@ static int qxl_crtc_mode_set(struct drm_crtc *crtc,
|
||||
x, y,
|
||||
mode->hdisplay, mode->vdisplay,
|
||||
adjusted_mode->hdisplay,
|
||||
adjusted_mode->vdisplay);
|
||||
|
||||
if (bo->is_primary == false)
|
||||
recreate_primary = true;
|
||||
|
||||
if (bo->surf.stride * bo->surf.height > qdev->vram_size) {
|
||||
DRM_ERROR("Mode doesn't fit in vram size (vgamem)");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
ret = qxl_bo_reserve(bo, false);
|
||||
if (ret != 0)
|
||||
return ret;
|
||||
ret = qxl_bo_pin(bo, bo->type, NULL);
|
||||
if (ret != 0) {
|
||||
qxl_bo_unreserve(bo);
|
||||
return -EINVAL;
|
||||
}
|
||||
qxl_bo_unreserve(bo);
|
||||
if (recreate_primary) {
|
||||
qxl_io_destroy_primary(qdev);
|
||||
qxl_io_log(qdev,
|
||||
"recreate primary: %dx%d,%d,%d\n",
|
||||
bo->surf.width, bo->surf.height,
|
||||
bo->surf.stride, bo->surf.format);
|
||||
qxl_io_create_primary(qdev, 0, bo);
|
||||
bo->is_primary = true;
|
||||
+
|
||||
+ ret = qxl_crtc_apply_cursor(crtc);
|
||||
+ if (ret) {
|
||||
+ DRM_ERROR("could not set cursor after modeset");
|
||||
+ ret = 0;
|
||||
+ }
|
||||
}
|
||||
|
||||
if (bo->is_primary) {
|
||||
DRM_DEBUG_KMS("setting surface_id to 0 for primary surface %d on crtc %d\n", bo->surface_id, qcrtc->index);
|
||||
surf_id = 0;
|
||||
} else {
|
||||
surf_id = bo->surface_id;
|
||||
}
|
||||
|
||||
if (old_bo && old_bo != bo) {
|
||||
old_bo->is_primary = false;
|
||||
ret = qxl_bo_reserve(old_bo, false);
|
||||
qxl_bo_unpin(old_bo);
|
||||
qxl_bo_unreserve(old_bo);
|
||||
}
|
||||
|
||||
qxl_monitors_config_set(qdev, qcrtc->index, x, y,
|
||||
mode->hdisplay,
|
||||
mode->vdisplay, surf_id);
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void qxl_crtc_prepare(struct drm_crtc *crtc)
|
||||
{
|
||||
DRM_DEBUG("current: %dx%d+%d+%d (%d).\n",
|
||||
crtc->mode.hdisplay, crtc->mode.vdisplay,
|
||||
crtc->x, crtc->y, crtc->enabled);
|
||||
}
|
||||
|
||||
static void qxl_crtc_commit(struct drm_crtc *crtc)
|
||||
diff --git a/drivers/gpu/drm/qxl/qxl_drv.h b/drivers/gpu/drm/qxl/qxl_drv.h
|
||||
index 8e633ca..6b63c54 100644
|
||||
--- a/drivers/gpu/drm/qxl/qxl_drv.h
|
||||
+++ b/drivers/gpu/drm/qxl/qxl_drv.h
|
||||
@@ -110,60 +110,61 @@ struct qxl_bo {
|
||||
void *kptr;
|
||||
int type;
|
||||
|
||||
/* Constant after initialization */
|
||||
struct drm_gem_object gem_base;
|
||||
bool is_primary; /* is this now a primary surface */
|
||||
bool hw_surf_alloc;
|
||||
struct qxl_surface surf;
|
||||
uint32_t surface_id;
|
||||
struct qxl_release *surf_create;
|
||||
};
|
||||
#define gem_to_qxl_bo(gobj) container_of((gobj), struct qxl_bo, gem_base)
|
||||
#define to_qxl_bo(tobj) container_of((tobj), struct qxl_bo, tbo)
|
||||
|
||||
struct qxl_gem {
|
||||
struct mutex mutex;
|
||||
struct list_head objects;
|
||||
};
|
||||
|
||||
struct qxl_bo_list {
|
||||
struct ttm_validate_buffer tv;
|
||||
};
|
||||
|
||||
struct qxl_crtc {
|
||||
struct drm_crtc base;
|
||||
int index;
|
||||
int cur_x;
|
||||
int cur_y;
|
||||
int hot_spot_x;
|
||||
int hot_spot_y;
|
||||
+ struct qxl_cursor *cursor;
|
||||
};
|
||||
|
||||
struct qxl_output {
|
||||
int index;
|
||||
struct drm_connector base;
|
||||
struct drm_encoder enc;
|
||||
};
|
||||
|
||||
struct qxl_framebuffer {
|
||||
struct drm_framebuffer base;
|
||||
struct drm_gem_object *obj;
|
||||
};
|
||||
|
||||
#define to_qxl_crtc(x) container_of(x, struct qxl_crtc, base)
|
||||
#define drm_connector_to_qxl_output(x) container_of(x, struct qxl_output, base)
|
||||
#define drm_encoder_to_qxl_output(x) container_of(x, struct qxl_output, enc)
|
||||
#define to_qxl_framebuffer(x) container_of(x, struct qxl_framebuffer, base)
|
||||
|
||||
struct qxl_mman {
|
||||
struct ttm_bo_global_ref bo_global_ref;
|
||||
struct drm_global_reference mem_global_ref;
|
||||
bool mem_global_referenced;
|
||||
struct ttm_bo_device bdev;
|
||||
};
|
||||
|
||||
struct qxl_mode_info {
|
||||
int num_modes;
|
||||
struct qxl_mode *modes;
|
||||
bool mode_config_initialized;
|
||||
|
||||
--
|
||||
2.7.4
|
||||
|
@ -1,46 +0,0 @@
|
||||
From: "Ole Ernst <olebowle@unknown.net>"
|
||||
Date: Sat, 30 Jul 2016 15:19:27 +0200
|
||||
Subject: Partly revert "[media] rc-core: allow calling rc_open with device not initialized"
|
||||
|
||||
This partly reverts commit 078600f514a12fd763ac84c86af68ef5b5267563.
|
||||
|
||||
Due to the relocation of input_register_device() call, holding down a
|
||||
button on an IR remote no longer resulted in repeated key down events.
|
||||
|
||||
See: http://www.spinics.net/lists/linux-media/msg103384.html
|
||||
|
||||
Signed-off-by: Ole Ernst <olebowle@xxxxxxx>
|
||||
---
|
||||
drivers/media/rc/rc-main.c | 9 ++++-----
|
||||
1 file changed, 4 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/drivers/media/rc/rc-main.c b/drivers/media/rc/rc-main.c
|
||||
index 8e7f292..26fd63b 100644
|
||||
--- a/drivers/media/rc/rc-main.c
|
||||
+++ b/drivers/media/rc/rc-main.c
|
||||
@@ -1460,6 +1460,10 @@ int rc_register_device(struct rc_dev *dev)
|
||||
dev->input_dev->phys = dev->input_phys;
|
||||
dev->input_dev->name = dev->input_name;
|
||||
|
||||
+ rc = input_register_device(dev->input_dev);
|
||||
+ if (rc)
|
||||
+ goto out_table;
|
||||
+
|
||||
/*
|
||||
* Default delay of 250ms is too short for some protocols, especially
|
||||
* since the timeout is currently set to 250ms. Increase it to 500ms,
|
||||
@@ -1475,11 +1479,6 @@ int rc_register_device(struct rc_dev *dev)
|
||||
*/
|
||||
dev->input_dev->rep[REP_PERIOD] = 125;
|
||||
|
||||
- /* rc_open will be called here */
|
||||
- rc = input_register_device(dev->input_dev);
|
||||
- if (rc)
|
||||
- goto out_table;
|
||||
-
|
||||
path = kobject_get_path(&dev->dev.kobj, GFP_KERNEL);
|
||||
dev_info(&dev->dev, "%s as %s\n",
|
||||
dev->input_name ?: "Unspecified device", path ?: "N/A");
|
||||
--
|
||||
2.9.0
|
||||
|
Loading…
Reference in New Issue
Block a user