Skip to content
Commit b0a46ffb authored by Takashi Iwai's avatar Takashi Iwai Committed by Yongxin Liu
Browse files

iwlwifi: dbg: Mark ucode tlv data as const

commit 403ea939

 upstream.

The ucode TLV data may be read-only and should be treated as const
pointers, but currently a few code forcibly cast to the writable
pointer unnecessarily.  This gave developers a wrong impression as if
it can be modified, resulting in crashing regressions already a couple
of times.

This patch adds the const prefix to those cast pointers, so that such
attempt can be caught more easily in future.

Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
Acked-by: default avatarLuca Coelho <luciano.coelho@intel.com>
Link: https://lore.kernel.org/r/20210112132449.22243-3-tiwai@suse.de
Signed-off-by: default avatarLuca Coelho <luciano.coelho@intel.com>
Signed-off-by: default avatarYongxin Liu <yongxin.liu@windriver.com>
parent 2b90d4cc
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment