lkml.org 
[lkml]   [2020]   [Apr]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: [PATCH] mm: Add kvfree_sensitive() for freeing sensitive data objects
    Date
    David Rientjes <rientjes@google.com> wrote:

    > > +static inline void kvfree_sensitive(const void *addr, size_t len)
    > > +{
    > > + if (addr) {
    >
    > Shouldn't this be if (unlikely(ZERO_OR_NULL_PTR(addr))?

    You've reversed the logic - it needs a '!' there.

    David

    \
     
     \ /
      Last update: 2020-04-06 09:45    [W:2.038 / U:0.012 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site