Furquan Shaikh has submitted this change. ( https://review.coreboot.org/c/coreboot/+/40709 )
Change subject: soc/intel: Constify struct device * parameter to intel_igd_get_controller_info ......................................................................
soc/intel: Constify struct device * parameter to intel_igd_get_controller_info
intel_igd_get_controller_info() does not need to modify the device structure. Hence, this change makes the struct device * parameter to intel_igd_get_controller_info() as const.
Change-Id: Ic044a80e3e2c45af6824a23f3cd0b08b94c0f279 Signed-off-by: Furquan Shaikh furquan@google.com Reviewed-on: https://review.coreboot.org/c/coreboot/+/40709 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Aaron Durbin adurbin@chromium.org --- M src/soc/intel/common/block/graphics/graphics.c M src/soc/intel/common/block/include/intelblocks/graphics.h M src/soc/intel/skylake/graphics.c 3 files changed, 3 insertions(+), 3 deletions(-)
Approvals: build bot (Jenkins): Verified Aaron Durbin: Looks good to me, approved
diff --git a/src/soc/intel/common/block/graphics/graphics.c b/src/soc/intel/common/block/graphics/graphics.c index 55c181b..a6d45c6 100644 --- a/src/soc/intel/common/block/graphics/graphics.c +++ b/src/soc/intel/common/block/graphics/graphics.c @@ -34,7 +34,7 @@ }
__weak const struct i915_gpu_controller_info * -intel_igd_get_controller_info(struct device *device) +intel_igd_get_controller_info(const struct device *device) { return NULL; } diff --git a/src/soc/intel/common/block/include/intelblocks/graphics.h b/src/soc/intel/common/block/include/intelblocks/graphics.h index 4187ca1..378fdd0 100644 --- a/src/soc/intel/common/block/include/intelblocks/graphics.h +++ b/src/soc/intel/common/block/include/intelblocks/graphics.h @@ -35,7 +35,7 @@
/* i915 controller info for ACPI backlight controls */ const struct i915_gpu_controller_info * -intel_igd_get_controller_info(struct device *device); +intel_igd_get_controller_info(const struct device *device);
/* Graphics MMIO register read/write APIs */ uint32_t graphics_gtt_read(unsigned long reg); diff --git a/src/soc/intel/skylake/graphics.c b/src/soc/intel/skylake/graphics.c index 5be398c..e1f8fbd 100644 --- a/src/soc/intel/skylake/graphics.c +++ b/src/soc/intel/skylake/graphics.c @@ -177,7 +177,7 @@ }
const struct i915_gpu_controller_info * -intel_igd_get_controller_info(struct device *device) +intel_igd_get_controller_info(const struct device *device) { struct soc_intel_skylake_config *chip = device->chip_info; return &chip->gfx;