On 9/4/2024 5:32 AM, Przemek Kitszel wrote:
>       dev = ice_pf_to_dev(pf);
> -     /* ice_cfg_tx_topo buf argument is not a constant,
> -      * so we have to make a copy
> -      */
> -     buf_copy = kmemdup(firmware->data, firmware->size, GFP_KERNEL);
> -
> -     err = ice_cfg_tx_topo(hw, buf_copy, firmware->size);
> +     err = ice_cfg_tx_topo(hw, (void *)firmware->data, firmware->size);
>       if (!err) {

Yea, just casting away the const is sufficient here, the function
doesn't modify this buffer.

Reviewed-by: Jacob Keller <jacob.e.kel...@intel.com>

Reply via email to