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: <5BB01958-8611-458D-B813-F28CD3BA0A15@oracle.com>
Date: Tue, 27 Aug 2024 18:48:34 +0000
From: Sherry Yang <sherry.yang@...cle.com>
To: Abhinav Kumar <quic_abhinavk@...cinc.com>
CC: "robdclark@...il.com" <robdclark@...il.com>,
        "dmitry.baryshkov@...aro.org"
	<dmitry.baryshkov@...aro.org>,
        "sean@...rly.run" <sean@...rly.run>,
        "marijn.suijten@...ainline.org" <marijn.suijten@...ainline.org>,
        "airlied@...il.com" <airlied@...il.com>,
        "daniel@...ll.ch" <daniel@...ll.ch>,
        "ruanjinjie@...wei.com" <ruanjinjie@...wei.com>,
        "linux-arm-msm@...r.kernel.org" <linux-arm-msm@...r.kernel.org>,
        "dri-devel@...ts.freedesktop.org" <dri-devel@...ts.freedesktop.org>,
        "freedreno@...ts.freedesktop.org" <freedreno@...ts.freedesktop.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 1/1] drm/msm: fix %s null argument error


> On Aug 27, 2024, at 10:50 AM, Abhinav Kumar <quic_abhinavk@...cinc.com> wrote:
> 
> 
> 
> On 8/27/2024 9:53 AM, Sherry Yang wrote:
>> The following build error was triggered because of NULL string argument:
>> BUILDSTDERR: drivers/gpu/drm/msm/disp/mdp5/mdp5_smp.c: In function 'mdp5_smp_dump':
>> BUILDSTDERR: drivers/gpu/drm/msm/disp/mdp5/mdp5_smp.c:352:51: error: '%s' directive argument is null [-Werror=format-overflow=]
>> BUILDSTDERR:   352 |                         drm_printf(p, "%s:%d\t%d\t%s\n",
>> BUILDSTDERR:       |                                                   ^~
>> BUILDSTDERR: drivers/gpu/drm/msm/disp/mdp5/mdp5_smp.c:352:51: error: '%s' directive argument is null [-Werror=format-overflow=]
>> This happens from the commit a61ddb4393ad ("drm: enable (most) W=1
>> warnings by default across the subsystem"). Using "(null)" instead
>> to fix it.
>> Fixes: bc5289eed481 ("drm/msm/mdp5: add debugfs to show smp block status")
>> Signed-off-by: Sherry Yang <sherry.yang@...cle.com>
>> ---
>>  drivers/gpu/drm/msm/disp/mdp5/mdp5_smp.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> I am not sure how the patch got titled 1/1 and not just "PATCH". It should be just "PATCH"

My bad. I generated the patch with parameter “--numbered” in “git format-patch”, it will output in [PATCH n/m] format, even with a single patch. Will drop it for single patch next time.

Thanks,
Sherry

> 
>> diff --git a/drivers/gpu/drm/msm/disp/mdp5/mdp5_smp.c b/drivers/gpu/drm/msm/disp/mdp5/mdp5_smp.c
>> index 3a7f7edda96b..500b7dc895d0 100644
>> --- a/drivers/gpu/drm/msm/disp/mdp5/mdp5_smp.c
>> +++ b/drivers/gpu/drm/msm/disp/mdp5/mdp5_smp.c
>> @@ -351,7 +351,7 @@ void mdp5_smp_dump(struct mdp5_smp *smp, struct drm_printer *p,
>>     drm_printf(p, "%s:%d\t%d\t%s\n",
>>   pipe2name(pipe), j, inuse,
>> - plane ? plane->name : NULL);
>> + plane ? plane->name : "(null)");
>>     total += inuse;
>>   }
> 
> Change itself looks fine to me,
> 
> 
> Reviewed-by: Abhinav Kumar <quic_abhinavk@...cinc.com>


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ