lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ae190d9c-160d-7d3d-6a57-a50655b36a73@huawei.com>
Date:   Tue, 10 May 2022 09:19:23 +0800
From:   Yang Yingliang <yangyingliang@...wei.com>
To:     <linux-kernel@...r.kernel.org>, <linux-arm-msm@...r.kernel.org>,
        <linux-media@...r.kernel.org>
CC:     <mchehab@...nel.org>, <hverkuil-cisco@...all.nl>,
        <robert.foss@...aro.org>, <bryan.odonoghue@...aro.org>,
        <vladimir.zapolskiy@...aro.org>
Subject: Re: [PATCH] media: camss: csid: fix wrong size passed to
 devm_kmalloc_array()

I made a mistake, this patch was sent twice, please ignore this patch.

Thanks,
Yang
On 2022/5/9 22:04, Yang Yingliang wrote:
> 'supplies' is a pointer, the real size of struct regulator_bulk_data
> should be pass to devm_kmalloc_array().
>
> Fixes: 0d8140179715 ("media: camss: Add regulator_bulk support")
> Signed-off-by: Yang Yingliang <yangyingliang@...wei.com>
> ---
>   drivers/media/platform/qcom/camss/camss-csid.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/media/platform/qcom/camss/camss-csid.c b/drivers/media/platform/qcom/camss/camss-csid.c
> index f993f349b66b..80628801cf09 100644
> --- a/drivers/media/platform/qcom/camss/camss-csid.c
> +++ b/drivers/media/platform/qcom/camss/camss-csid.c
> @@ -666,7 +666,7 @@ int msm_csid_subdev_init(struct camss *camss, struct csid_device *csid,
>   	if (csid->num_supplies) {
>   		csid->supplies = devm_kmalloc_array(camss->dev,
>   						    csid->num_supplies,
> -						    sizeof(csid->supplies),
> +						    sizeof(*csid->supplies),
>   						    GFP_KERNEL);
>   		if (!csid->supplies)
>   			return -ENOMEM;

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ