https://bugs.freedesktop.org/show_bug.cgi?id=89214
Francesco Balestrieri <francesco.balestrieri(a)intel.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|marius.c.vlad(a)intel.com |dri-devel(a)lists.freedesktop
| |.org
--
You are receiving this mail because:
You are the assignee for the bug.
From: Michel Dänzer <michel.daenzer(a)amd.com>
Fixes the BUG_ON spuriously triggering under the following
circumstances:
* ttm_eu_reserve_buffers processes a list containing multiple BOs using
the same reservation object, so it calls
reservation_object_reserve_shared with that reservation object once
for each such BO.
* In reservation_object_reserve_shared, old->shared_count ==
old->shared_max - 1, so obj->staged is freed in preparation of an
in-place update.
* …
[View More]ttm_eu_fence_buffer_objects calls reservation_object_add_shared_fence
once for each of the BOs above, always with the same fence.
* The first call adds the fence in the remaining free slot, after which
old->shared_count == old->shared_max.
In the next call to reservation_object_add_shared_fence, the BUG_ON
triggers. However, nothing bad would happen in
reservation_object_add_shared_inplace, since the fence is already in the
reservation object.
Prevent this by moving the BUG_ON to where an overflow would actually
happen (e.g. if a buggy caller didn't call
reservation_object_reserve_shared before).
Cc: stable(a)vger.kernel.org
Signed-off-by: Michel Dänzer <michel.daenzer(a)amd.com>
---
drivers/dma-buf/reservation.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/dma-buf/reservation.c b/drivers/dma-buf/reservation.c
index 314eb1071cce..532545b9488e 100644
--- a/drivers/dma-buf/reservation.c
+++ b/drivers/dma-buf/reservation.c
@@ -141,6 +141,7 @@ reservation_object_add_shared_inplace(struct reservation_object *obj,
if (signaled) {
RCU_INIT_POINTER(fobj->shared[signaled_idx], fence);
} else {
+ BUG_ON(fobj->shared_count >= fobj->shared_max);
RCU_INIT_POINTER(fobj->shared[fobj->shared_count], fence);
fobj->shared_count++;
}
@@ -230,10 +231,9 @@ void reservation_object_add_shared_fence(struct reservation_object *obj,
old = reservation_object_get_list(obj);
obj->staged = NULL;
- if (!fobj) {
- BUG_ON(old->shared_count >= old->shared_max);
+ if (!fobj)
reservation_object_add_shared_inplace(obj, old, fence);
- } else
+ else
reservation_object_add_shared_replace(obj, old, fobj, fence);
}
EXPORT_SYMBOL(reservation_object_add_shared_fence);
--
2.18.0
[View Less]
https://bugs.freedesktop.org/show_bug.cgi?id=106168
grmat(a)sub.red changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |FIXED
--- Comment #1 from grmat(a)sub.red ---
doesn't happen anymore
--
You are receiving this mail because:
You are the assignee for the bug.
The ->info[] array has DAL_IRQ_SOURCES_NUMBER elements so this condition
should be >= instead of > or we could read one element beyond the end of
the array.
Fixes: 4562236b3bc0 ("drm/amd/dc: Add dc display driver (v2)")
Signed-off-by: Dan Carpenter <dan.carpenter(a)oracle.com>
diff --git a/drivers/gpu/drm/amd/display/dc/irq/irq_service.c b/drivers/gpu/drm/amd/display/dc/irq/irq_service.c
index dcdfa0f01551..604bea01fc13 100644
--- a/drivers/gpu/drm/amd/display/dc/irq/…
[View More]irq_service.c
+++ b/drivers/gpu/drm/amd/display/dc/irq/irq_service.c
@@ -78,7 +78,7 @@ const struct irq_source_info *find_irq_source_info(
struct irq_service *irq_service,
enum dc_irq_source source)
{
- if (source > DAL_IRQ_SOURCES_NUMBER || source < DC_IRQ_SOURCE_INVALID)
+ if (source >= DAL_IRQ_SOURCES_NUMBER || source < DC_IRQ_SOURCE_INVALID)
return NULL;
return &irq_service->info[source];
[View Less]
Hi all,
this patchset is a next attempt to fix packed pixel modes display on MHL2. It appeared, that
the current implementation does not work well with every dongle. Thanks to bigger number
of test devices I managed to prepare a patchset, which should finally fix display
of packed pixel modes on MHL2, while not breaking it on MHL3.
Best regards,
Maciej Purski
Maciej Purski (3):
drm/bridge/sii8620: Send AVI infoframe in all MHL versions
drm/bridge/sii8620: Fix display of packed pixel …
[View More]modes
drm/bridge/sii8620: Fix link mode selection
drivers/gpu/drm/bridge/sil-sii8620.c | 86 +++++++++++++++++++++++-------------
1 file changed, 55 insertions(+), 31 deletions(-)
--
2.7.4
[View Less]
Add suffix UL to constant 1000 in order to give the compiler complete
information about the proper arithmetic to use.
Notice that such constant is used in a context that expects an
expression of type u64 (64 bits, unsigned) and the following
expression is currently being evaluated using 32-bit arithmetic:
mode->clock * 1000
Addresses-Coverity-ID: 1466139 ("Unintentional integer overflow")
Signed-off-by: Gustavo A. R. Silva <gustavo(a)embeddedor.com>
---
drivers/gpu/drm/pl111/…
[View More]pl111_display.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/pl111/pl111_display.c b/drivers/gpu/drm/pl111/pl111_display.c
index a432eb7..61d51b4 100644
--- a/drivers/gpu/drm/pl111/pl111_display.c
+++ b/drivers/gpu/drm/pl111/pl111_display.c
@@ -63,7 +63,7 @@ pl111_mode_valid(struct drm_crtc *crtc,
* We use the pixelclock to also account for interlaced modes, the
* resulting bandwidth is in bytes per second.
*/
- bw = mode->clock * 1000; /* In Hz */
+ bw = mode->clock * 1000UL; /* In Hz */
bw = bw * mode->hdisplay * mode->vdisplay * cpp;
bw = div_u64(bw, mode->htotal * mode->vtotal);
--
2.7.4
[View Less]
Hi All,
The new Google "Fizz" Intel-based ChromeOS device is gaining CEC support
through it's Embedded Controller, to enable the Linux CEC Core to communicate
with it and get the CEC Physical Address from the correct HDMI Connector, the
following must be added/changed:
- Add the CEC sub-device registration in the ChromeOS EC MFD Driver
- Add the CEC related commands and events definitions into the EC MFD driver
- Add a way to get a CEC notifier with it's (optional) connector name
- Add the CEC …
[View More]notifier to the i915 HDMI driver
- Add the proper ChromeOS EC CEC Driver
The CEC notifier with the connector name is the tricky point, since even on
Device-Tree platforms, there is no way to distinguish between multiple HDMI
connectors from the same DRM driver. The solution I implemented is pretty
simple and only adds an optional connector name to eventually distinguish
an HDMI connector notifier from another if they share the same device.
Feel free to comment this patchset !
Changes since v6:
- Added stable identifier comment in intel_display.h
- Renamed to cec_notifier in intel_hdmi.c/intel_drv.h
- Added Acked-by/Reviewed-By tags
Changes since v5:
- Small fixups on include/linux/mfd/cros_ec_commands.h
- Fixed on cros-ec-cec driver accordingly
- Added Reviewed-By tags
Changes since v4:
- Split patch 3 to move the mkbp event size change into a separate patch
Changes since v3 (incorrectly reported as v2):
- Renamed "Chrome OS" to "ChromeOS"
- Updated cros_ec_commands.h new structs definitions to kernel doc format
- Added Reviewed-By tags
Changes since v2:
- Add i915 port_identifier() and use this stable name as cec_notifier conn name
- Fixed and cleaned up the CEC commands and events handling
- Rebased the CEC sub-device registration on top of Enric's serie
- Fixed comments typo on cec driver
- Protected the DMI match only with PCI and DMI Kconfigs
Changes since v1:
- Added cec_notifier_put to intel_hdmi
- Fixed all small reported issues on the EC CEC driver
- Moved the cec_notifier_get out of the #if .. #else .. #endif
Changes since RFC:
- Moved CEC sub-device registration after CEC commands and events definitions patch
- Removed get_notifier_get_byname
- Added CEC_CORE select into i915 Kconfig
- Removed CEC driver fallback if notifier is not configured on HW, added explicit warn
- Fixed CEC core return type on error
- Moved to cros-ec-cec media platform directory
- Use bus_find_device() to find the pci i915 device instead of get_notifier_get_byname()
- Fix Logical Address setup
- Added comment about HW support
- Removed memset of msg structures
Neil Armstrong (6):
media: cec-notifier: Get notifier by device and connector name
drm/i915: hdmi: add CEC notifier to intel_hdmi
mfd: cros-ec: Increase maximum mkbp event size
mfd: cros-ec: Introduce CEC commands and events definitions.
mfd: cros_ec_dev: Add CEC sub-device registration
media: platform: Add ChromeOS EC CEC driver
drivers/gpu/drm/i915/Kconfig | 1 +
drivers/gpu/drm/i915/intel_display.h | 24 ++
drivers/gpu/drm/i915/intel_drv.h | 2 +
drivers/gpu/drm/i915/intel_hdmi.c | 13 +
drivers/media/cec/cec-notifier.c | 11 +-
drivers/media/platform/Kconfig | 11 +
drivers/media/platform/Makefile | 2 +
drivers/media/platform/cros-ec-cec/Makefile | 1 +
drivers/media/platform/cros-ec-cec/cros-ec-cec.c | 347 +++++++++++++++++++++++
drivers/mfd/cros_ec_dev.c | 16 ++
drivers/platform/chrome/cros_ec_proto.c | 40 ++-
include/linux/mfd/cros_ec.h | 2 +-
include/linux/mfd/cros_ec_commands.h | 100 +++++++
include/media/cec-notifier.h | 27 +-
14 files changed, 581 insertions(+), 16 deletions(-)
create mode 100644 drivers/media/platform/cros-ec-cec/Makefile
create mode 100644 drivers/media/platform/cros-ec-cec/cros-ec-cec.c
--
2.7.4
[View Less]