lkml.org 
[lkml]   [2020]   [Aug]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRE: x86/kprobes: kretprobe fails to triggered if kprobe at function entry is not optimized (trigger by int3 breakpoint)
    Date


    > -----Original Message-----
    > From: peterz@infradead.org <peterz@infradead.org>
    > Sent: Wednesday, August 26, 2020 6:26 PM
    > To: Masami Hiramatsu <mhiramat@kernel.org>
    > Cc: Eddy Wu (RD-TW) <Eddy_Wu@trendmicro.com>; linux-kernel@vger.kernel.org; x86@kernel.org
    > Subject: Re: x86/kprobes: kretprobe fails to triggered if kprobe at function entry is not optimized (trigger by int3 breakpoint)
    >
    > On Wed, Aug 26, 2020 at 07:00:41PM +0900, Masami Hiramatsu wrote:
    > > Of course, this doesn't solve the llist_del_first() contention in the
    > > pre_kretprobe_handler(). So anyway we need a lock for per-probe llist
    > > (if I understand llist.h comment correctly.)
    >
    > Bah, lemme think about that. Kprobes really shouldn't be using locks :/

    Maybe we can have per-cpu free list for retprobe_instance?
    This ensure we only have one user requesting free instance at a time, given that pre_kretprobe_handler() wont recursive.

    We may be wasting memory if target function perfer some cpu though.


    TREND MICRO EMAIL NOTICE

    The information contained in this email and any attachments is confidential and may be subject to copyright or other intellectual property protection. If you are not the intended recipient, you are not authorized to use or disclose this information, and we request that you notify us by reply mail or telephone and delete the original message from your mail system.

    For details about what personal information we collect and why, please see our Privacy Notice on our website at: Read privacy policy<http://www.trendmicro.com/privacy>
    \
     
     \ /
      Last update: 2020-08-26 15:37    [W:3.050 / U:0.044 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site