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: <194e2b7a-52c6-5962-b0df-8f8939a95e41@broadcom.com>
Date:   Tue, 16 May 2023 16:29:07 -0700
From:   Florian Fainelli <florian.fainelli@...adcom.com>
To:     Arnd Bergmann <arnd@...nel.org>,
        Florian Fainelli <f.fainelli@...il.com>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Stefan Wahren <stefan.wahren@...e.com>
Cc:     Arnd Bergmann <arnd@...db.de>,
        Broadcom internal kernel review list 
        <bcm-kernel-feedback-list@...adcom.com>,
        Umang Jain <umang.jain@...asonboard.com>,
        Adrien Thierry <athierry@...hat.com>,
        Phil Elwell <phil@...pberrypi.com>,
        Peter Zijlstra <peterz@...radead.org>,
        Uwe Kleine-König <u.kleine-koenig@...gutronix.de>,
        linux-rpi-kernel@...ts.infradead.org,
        linux-arm-kernel@...ts.infradead.org,
        linux-staging@...ts.linux.dev, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] staging: vchiq_arm: mark vchiq_platform_init() static

On 5/16/23 13:25, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@...db.de>
> 
> This function has no callers from other files, and the declaration
> was removed a while ago, causing a W=1 warning:
> 
> drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c:465:5: error: no previous prototype for 'vchiq_platform_init'
> 
> Marking it static solves this problem but introduces a new warning
> since gcc determines that 'g_fragments_base' is never initialized
> in some kernel configurations:
> 
> In file included from include/linux/string.h:254,
>                   from include/linux/bitmap.h:11,
>                   from include/linux/cpumask.h:12,
>                   from include/linux/mm_types_task.h:14,
>                   from include/linux/mm_types.h:5,
>                   from include/linux/buildid.h:5,
>                   from include/linux/module.h:14,
>                   from drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c:8:
> In function 'memcpy_to_page',
>      inlined from 'free_pagelist' at drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c:433:4:
> include/linux/fortify-string.h:57:33: error: argument 2 null where non-null expected [-Werror=nonnull]
> include/linux/highmem.h:427:9: note: in expansion of macro 'memcpy'
>    427 |         memcpy(to + offset, from, len);
>        |         ^~~~~~
> 
> Add a NULL pointer check for this in addition to the static annotation
> to avoid both.
> 
> Fixes: 89cc4218f640 ("staging: vchiq_arm: drop unnecessary declarations")
> Signed-off-by: Arnd Bergmann <arnd@...db.de>

Reviewed-by: Florian Fainelli <florian.fainelli@...adcom.com>
-- 
Florian


Download attachment "smime.p7s" of type "application/pkcs7-signature" (4221 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ