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
| ||
|
Message-Id: <20121206153227.91a6ec69.akpm@linux-foundation.org> Date: Thu, 6 Dec 2012 15:32:27 -0800 From: Andrew Morton <akpm@...ux-foundation.org> To: Tushar Behera <tushar.behera@...aro.org> Cc: linux-kernel@...r.kernel.org, axboe@...nel.dk, patches@...aro.org Subject: Re: [PATCH] block: Fix sparse warning On Mon, 19 Nov 2012 16:30:40 +0530 Tushar Behera <tushar.behera@...aro.org> wrote: > blk_drain_queue is only used in this file, so should be marked static. > > Fixes following sparse warning. > > block/blk-core.c:361:6: warning: symbol 'blk_drain_queue' was not > declared. Should it be static? > > Signed-off-by: Tushar Behera <tushar.behera@...aro.org> > --- > block/blk-core.c | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/block/blk-core.c b/block/blk-core.c > index a8b1527..5db63eb 100644 > --- a/block/blk-core.c > +++ b/block/blk-core.c > @@ -358,7 +358,7 @@ EXPORT_SYMBOL(blk_put_queue); > * If not, only ELVPRIV requests are drained. The caller is responsible > * for ensuring that no new requests which need to be drained are queued. > */ > -void blk_drain_queue(struct request_queue *q, bool drain_all) > +static void blk_drain_queue(struct request_queue *q, bool drain_all) > { > int i; nit: the objective of this patch is not to reduce the sparse output; it is to improve the kernel by giving an unnecessarily-global symbol static scope. So a better title is one which describes the code fix. The fact that sparse happened to detect it is less important. I chose "block/blk-core.c: make blk_drain_queue() static". -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists