selinux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/5] selinux: Assorted simplifications and cleanups
@ 2020-02-03 11:27 Ondrej Mosnacek
  2020-02-03 11:27 ` [PATCH v3 1/5] selinux: simplify evaluate_cond_node() Ondrej Mosnacek
                   ` (4 more replies)
  0 siblings, 5 replies; 11+ messages in thread
From: Ondrej Mosnacek @ 2020-02-03 11:27 UTC (permalink / raw)
  To: selinux, Paul Moore; +Cc: Stephen Smalley

This series contains some boolean code simplifications that I discovered
while working on another patch. I believe they also save some run time
(although not in any perf-critical paths) and some memory overhead.

Changes in v3:
 - properly destroy all cond nodes in error path (bug found by Paul)
 - additional style fixes suggested by Paul

Changes in v2:
 - drop already merged 1st patch
 - drop the rewrite of security_preserve_bools(), keep only the
   evaluate_cond_node() return type change (requested by Paul)

Ondrej Mosnacek (5):
  selinux: simplify evaluate_cond_node()
  selinux: convert cond_list to array
  selinux: convert cond_av_list to array
  selinux: convert cond_expr to array
  selinux: generalize evaluate_cond_node()

 security/selinux/include/conditional.h |   8 +-
 security/selinux/selinuxfs.c           |   4 +-
 security/selinux/ss/conditional.c      | 251 ++++++++++---------------
 security/selinux/ss/conditional.h      |  27 +--
 security/selinux/ss/policydb.c         |   2 +-
 security/selinux/ss/policydb.h         |   3 +-
 security/selinux/ss/services.c         |  32 ++--
 7 files changed, 137 insertions(+), 190 deletions(-)

-- 
2.24.1


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

end of thread, other threads:[~2020-02-12  2:52 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-03 11:27 [PATCH v3 0/5] selinux: Assorted simplifications and cleanups Ondrej Mosnacek
2020-02-03 11:27 ` [PATCH v3 1/5] selinux: simplify evaluate_cond_node() Ondrej Mosnacek
2020-02-12  2:29   ` Paul Moore
2020-02-03 11:27 ` [PATCH v3 2/5] selinux: convert cond_list to array Ondrej Mosnacek
2020-02-12  2:41   ` Paul Moore
2020-02-03 11:27 ` [PATCH v3 3/5] selinux: convert cond_av_list " Ondrej Mosnacek
2020-02-12  2:47   ` Paul Moore
2020-02-03 11:27 ` [PATCH v3 4/5] selinux: convert cond_expr " Ondrej Mosnacek
2020-02-12  2:49   ` Paul Moore
2020-02-03 11:27 ` [PATCH v3 5/5] selinux: generalize evaluate_cond_node() Ondrej Mosnacek
2020-02-12  2:52   ` Paul Moore

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).