svn commit: r248514 - head/sys/vm

Alexey Dokuchaev danfe at freebsd.org
Mon Jun 3 14:39:12 UTC 2019


On Tue, Mar 19, 2013 at 02:39:27PM +0000, Konstantin Belousov wrote:
> New Revision: 248514
> URL: http://svnweb.freebsd.org/changeset/base/248514
> 
> Log:
>   Do not map the swap i/o pbufs if the geom provider for the swap
>   partition accepts unmapped requests.
>   
> Modified: head/sys/vm/swap_pager.c
> ...
> @@ -2180,6 +2190,7 @@ swaponsomething(struct vnode *vp, void *
>  	sp->sw_flags = 0;
>  	sp->sw_nblks = nblks;
>  	sp->sw_used = 0;
>  	sp->sw_strategy = strategy;
>  	sp->sw_close = close;
> +	sp->sw_flags = flags;

PVS Studio complains here: /usr/src/sys/vm/swap_pager.c:2238:1: warning:
V519 The 'sp->sw_flags' variable is assigned values twice successively.
Perhaps this is a mistake. Check lines: 2233, 2238.

Looks like "sp->sw_flags = 0" should've been removed, can you confirm?

./danfe


More information about the svn-src-head mailing list