summary refs log tree commit diff stats
path: root/hw/sensor/emc141x.c
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé <philmd@linaro.org>2025-02-10 09:49:38 +0100
committerPhilippe Mathieu-Daudé <philmd@linaro.org>2025-02-16 14:26:07 +0100
commit788369f477a3c89023f5ab19590baee4239623bb (patch)
tree6a5a7bd384684e993fac2fe107494c4405b7d4f7 /hw/sensor/emc141x.c
parentd31f1185fb029b44c439a6961a6cb087df6567d9 (diff)
downloadfocaccia-qemu-788369f477a3c89023f5ab19590baee4239623bb.tar.gz
focaccia-qemu-788369f477a3c89023f5ab19590baee4239623bb.zip
hw: Make class data 'const'
When the %data argument is not modified, we can declare it const.

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20250210133134.90879-8-philmd@linaro.org>
Diffstat (limited to 'hw/sensor/emc141x.c')
-rw-r--r--hw/sensor/emc141x.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/sensor/emc141x.c b/hw/sensor/emc141x.c
index aeccd2a3c9..33c1bd330f 100644
--- a/hw/sensor/emc141x.c
+++ b/hw/sensor/emc141x.c
@@ -265,7 +265,7 @@ static void emc141x_initfn(Object *obj)
                         emc141x_set_temperature, NULL, NULL);
 }
 
-static void emc141x_class_init(ObjectClass *klass, void *data)
+static void emc141x_class_init(ObjectClass *klass, const void *data)
 {
     DeviceClass *dc = DEVICE_CLASS(klass);
     I2CSlaveClass *k = I2C_SLAVE_CLASS(klass);