linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* RFC: remove function pointer casts and constify function tables
@ 2017-05-09  9:19 Christoph Hellwig
  2017-05-09  9:19 ` [PATCH 01/32] sunrpc: properly type argument to kxdreproc_t Christoph Hellwig
                   ` (31 more replies)
  0 siblings, 32 replies; 55+ messages in thread
From: Christoph Hellwig @ 2017-05-09  9:19 UTC (permalink / raw)
  To: Trond Myklebust, Anna Schumaker, J. Bruce Fields, Jeff Layton; +Cc: linux-nfs

This series was inspired by two recent events:  talking to a academic
researcher about the harm of function pointer casts for static analysis
at a conference, and reading up the whole Grsecurity drama, including
finding that their patchset does a lot of work to remove these casts
in sunrpc and nfs (and in fact those seem the biggest culprit in the
kernel), and constifying the operation vectors like so many others in
the kernel, although done in a rather hacky and/or mechnical way.

This series tries to solve both patches properly, and except for two
hacks that simply remove the p_count and pc_count counters should
be reasonably clean.  I'd love to hear feedback especially for those
two patches, and if maybe no one actually cares about those counters
in the end, which would make my life easier by not having to find
a replacement mechnism.

Note that the first part of the series is about the RPC forechannel,
and the latter about the backchannel, but due to bidirection operation
in NFSv4 there is no really clean split between the client and server
parts.

^ permalink raw reply	[flat|nested] 55+ messages in thread

end of thread, other threads:[~2017-05-10 18:38 UTC | newest]

Thread overview: 55+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-05-09  9:19 RFC: remove function pointer casts and constify function tables Christoph Hellwig
2017-05-09  9:19 ` [PATCH 01/32] sunrpc: properly type argument to kxdreproc_t Christoph Hellwig
2017-05-09  9:19 ` [PATCH 02/32] sunrpc: fix encoder callback prototypes Christoph Hellwig
2017-05-09  9:43   ` Mkrtchyan, Tigran
2017-05-09 13:11     ` Christoph Hellwig
2017-05-09 13:30       ` Jeff Layton
2017-05-09 14:17         ` J. Bruce Fields
2017-05-10 18:38           ` J. Bruce Fields
2017-05-09 12:28   ` Trond Myklebust
2017-05-09  9:19 ` [PATCH 03/32] lockd: " Christoph Hellwig
2017-05-09 12:29   ` Trond Myklebust
2017-05-09  9:19 ` [PATCH 04/32] nfs: " Christoph Hellwig
2017-05-09 12:30   ` Trond Myklebust
2017-05-09  9:19 ` [PATCH 05/32] nfsd: " Christoph Hellwig
2017-05-09  9:19 ` [PATCH 06/32] sunrpc/auth_gss: " Christoph Hellwig
2017-05-09 12:32   ` Trond Myklebust
2017-05-09  9:19 ` [PATCH 07/32] sunrpc: properly type argument to kxdrdproc_t Christoph Hellwig
2017-05-09 12:34   ` Trond Myklebust
2017-05-09  9:19 ` [PATCH 08/32] sunrpc: fix decoder callback prototypes Christoph Hellwig
2017-05-09  9:19 ` [PATCH 09/32] sunrpc/auth_gss: " Christoph Hellwig
2017-05-09 12:35   ` Trond Myklebust
2017-05-09  9:19 ` [PATCH 10/32] nfsd: " Christoph Hellwig
2017-05-09  9:19 ` [PATCH 11/32] lockd: " Christoph Hellwig
2017-05-09 12:36   ` Trond Myklebust
2017-05-09  9:19 ` [PATCH 12/32] nfs: " Christoph Hellwig
2017-05-09 12:37   ` Trond Myklebust
2017-05-09  9:19 ` [PATCH 13/32] nfs: don't cast callback decode/proc/encode routines Christoph Hellwig
2017-05-09 12:38   ` Trond Myklebust
2017-05-09  9:19 ` [PATCH 14/32] RFC: sunrpc: remove p_count Christoph Hellwig
2017-05-09 12:41   ` Trond Myklebust
2017-05-09  9:19 ` [PATCH 15/32] sunrpc: mark all struct rpc_procinfo instances as const Christoph Hellwig
2017-05-09 12:42   ` Trond Myklebust
2017-05-09  9:19 ` [PATCH 16/32] lockd: fix some weird indentation Christoph Hellwig
2017-05-09 12:43   ` Trond Myklebust
2017-05-09  9:19 ` [PATCH 17/32] nfsd4: const-ify nfs_cb_version4 Christoph Hellwig
2017-05-09  9:19 ` [PATCH 18/32] nfsd: use named initializers in PROC() Christoph Hellwig
2017-05-09  9:19 ` [PATCH 19/32] nfsd: remove the unused PROC() macro in nfs3proc.c Christoph Hellwig
2017-05-09  9:19 ` [PATCH 20/32] sunrpc: properly type pc_func callbacks Christoph Hellwig
2017-05-09  9:19 ` [PATCH 21/32] sunrpc: properly type pc_release callbacks Christoph Hellwig
2017-05-09  9:20 ` [PATCH 22/32] sunrpc: properly type pc_decode callbacks Christoph Hellwig
2017-05-09  9:20 ` [PATCH 23/32] sunrpc: properly type pc_encode callbacks Christoph Hellwig
2017-05-09 12:10   ` Trond Myklebust
2017-05-09  9:20 ` [PATCH 24/32] sunrpc: remove kxdrproc_t Christoph Hellwig
2017-05-09  9:20 ` [PATCH 25/32] nfsd4: properly type op_set_currentstateid callbacks Christoph Hellwig
2017-05-09  9:20 ` [PATCH 26/32] nfsd4: properly type op_get_currentstateid callbacks Christoph Hellwig
2017-05-09  9:20 ` [PATCH 27/32] nfsd4: remove nfsd4op_rsize Christoph Hellwig
2017-05-09  9:20 ` [PATCH 28/32] nfsd4: properly type op_func callbacks Christoph Hellwig
2017-05-09  9:20 ` [PATCH 29/32] RFC: sunrpc: remove pc_count Christoph Hellwig
2017-05-09 12:16   ` Trond Myklebust
2017-05-09 13:43     ` Chuck Lever
2017-05-09 17:35   ` Jeff Layton
2017-05-09  9:20 ` [PATCH 30/32] sunrpc: mark all struct svc_procinfo instances as const Christoph Hellwig
2017-05-09  9:20 ` [PATCH 31/32] sunrpc: mark all struct svc_version " Christoph Hellwig
2017-05-09 12:11   ` Trond Myklebust
2017-05-09  9:20 ` [PATCH 32/32] nfsd4: const-ify nfsd4_ops Christoph Hellwig

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).