Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/amd/display: add const qualifiers to watermark params struct

[why]
There are few non const input pointer fields. Setting them to const to
prevent future modification of read-only data.

Reviewed-by: Dillon Varone <dillon.varone@amd.com>
Signed-off-by: Wenjing Liu <wenjing.liu@amd.com>
Signed-off-by: Aurabindo Pillai <aurabindo.pillai@amd.com>
Tested-by: Dan Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

authored by

Wenjing Liu and committed by
Alex Deucher
dd2308c1 2b104fc3

+17 -17
+17 -17
drivers/gpu/drm/amd/display/dc/dml2_0/dml21/src/dml2_core/dml2_core_shared_types.h
··· 1721 1721 double ReturnBW; 1722 1722 bool SynchronizeTimings; 1723 1723 bool SynchronizeDRRDisplaysForUCLKPStateChange; 1724 - unsigned int *dpte_group_bytes; 1724 + const unsigned int *dpte_group_bytes; 1725 1725 struct dml2_core_internal_SOCParametersList mmSOCParameters; 1726 1726 unsigned int WritebackChunkSize; 1727 1727 double SOCCLK; 1728 1728 double DCFClkDeepSleep; 1729 - unsigned int *DETBufferSizeY; 1730 - unsigned int *DETBufferSizeC; 1731 - unsigned int *SwathHeightY; 1732 - unsigned int *SwathHeightC; 1733 - unsigned int *SwathWidthY; 1734 - unsigned int *SwathWidthC; 1735 - unsigned int *DPPPerSurface; 1736 - double *BytePerPixelDETY; 1737 - double *BytePerPixelDETC; 1738 - unsigned int *DSTXAfterScaler; 1739 - unsigned int *DSTYAfterScaler; 1729 + const unsigned int *DETBufferSizeY; 1730 + const unsigned int *DETBufferSizeC; 1731 + const unsigned int *SwathHeightY; 1732 + const unsigned int *SwathHeightC; 1733 + const unsigned int *SwathWidthY; 1734 + const unsigned int *SwathWidthC; 1735 + const unsigned int *DPPPerSurface; 1736 + const double *BytePerPixelDETY; 1737 + const double *BytePerPixelDETC; 1738 + const unsigned int *DSTXAfterScaler; 1739 + const unsigned int *DSTYAfterScaler; 1740 1740 bool UnboundedRequestEnabled; 1741 1741 unsigned int CompressedBufferSizeInkByte; 1742 1742 bool max_outstanding_when_urgent_expected; 1743 - unsigned int max_outstanding_requests; 1744 - unsigned int max_request_size_bytes; 1745 - unsigned int *meta_row_height_l; 1746 - unsigned int *meta_row_height_c; 1747 - enum dml2_pstate_method *uclk_pstate_switch_modes; 1743 + const unsigned int max_outstanding_requests; 1744 + const unsigned int max_request_size_bytes; 1745 + const unsigned int *meta_row_height_l; 1746 + const unsigned int *meta_row_height_c; 1747 + const enum dml2_pstate_method *uclk_pstate_switch_modes; 1748 1748 1749 1749 // Output 1750 1750 struct dml2_core_internal_watermarks *Watermark;