Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 10 May 2019 16:31:51 +0000 (UTC)
From:      Alan Somers <asomers@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-projects@freebsd.org
Subject:   svn commit: r347434 - projects/fuse2/sys/fs/fuse
Message-ID:  <201905101631.x4AGVpv0081273@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: asomers
Date: Fri May 10 16:31:51 2019
New Revision: 347434
URL: https://svnweb.freebsd.org/changeset/base/347434

Log:
  fusefs: minor optimization to interrupted fuse operations
  
  If the daemon is known to ignore FUSE_INTERRUPT, then we may as well block
  all signals while waiting for a response.
  
  Sponsored by:	The FreeBSD Foundation

Modified:
  projects/fuse2/sys/fs/fuse/fuse_ipc.c

Modified: projects/fuse2/sys/fs/fuse/fuse_ipc.c
==============================================================================
--- projects/fuse2/sys/fs/fuse/fuse_ipc.c	Fri May 10 16:01:25 2019	(r347433)
+++ projects/fuse2/sys/fs/fuse/fuse_ipc.c	Fri May 10 16:31:51 2019	(r347434)
@@ -442,7 +442,13 @@ fticket_wait_answer(struct fuse_ticket *ftick)
 	int err = 0, stops_deferred;
 	struct fuse_data *data;
 
-	SIGEMPTYSET(blockedset);
+	if (fsess_isimpl(ftick->tk_data->mp, FUSE_INTERRUPT)) {
+		SIGEMPTYSET(blockedset);
+	} else {
+		/* May as well block all signals */
+		SIGFILLSET(blockedset);
+		SIGDELSET(blockedset, SIGKILL);
+	}
 	stops_deferred = sigdeferstop(SIGDEFERSTOP_SILENT);
 	kern_sigprocmask(td, SIG_BLOCK, NULL, &oldset, 0);
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201905101631.x4AGVpv0081273>