On Wed, May 22, 2019 at 07:51:13PM -0700, Scott Branden wrote:
> Adjust request_firmware_into_buf API to allow for portions
> of firmware file to be read into a buffer.  mdt_loader still
> retricts request fo whole file read into buffer.
> 
> Signed-off-by: Scott Branden <scott.bran...@broadcom.com>
> ---
>  drivers/soc/qcom/mdt_loader.c | 7 +++++--
>  1 file changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/soc/qcom/mdt_loader.c b/drivers/soc/qcom/mdt_loader.c
> index 1c488024c698..ad20d159699c 100644
> --- a/drivers/soc/qcom/mdt_loader.c
> +++ b/drivers/soc/qcom/mdt_loader.c
> @@ -172,8 +172,11 @@ static int __qcom_mdt_load(struct device *dev, const 
> struct firmware *fw,
>  
>               if (phdr->p_filesz) {
>                       sprintf(fw_name + fw_name_len - 3, "b%02d", i);
> -                     ret = request_firmware_into_buf(&seg_fw, fw_name, dev,
> -                                                     ptr, phdr->p_filesz);
> +                     ret = request_firmware_into_buf
> +                                             (&seg_fw, fw_name, dev,
> +                                              ptr, phdr->p_filesz,
> +                                              0,
> +                                              KERNEL_PREAD_FLAG_WHOLE);

So, all that work in the first 2 patches for no real change at all?  Why
are these changes even needed?

And didn't you break this driver in patch 2/3?  You can't fix it up
later here, you need to also resolve that in the 2nd patch.

thanks,

greg k-h

Reply via email to